Integrating 3rd Party Affiliate program with Membership

I'm wanting some advice on how to integrate a 3rd party affiliate program such as Post Affiliate Pro into the membership plugin. Can someone please point me in the right direction as to where to start and which files to modify?

Thanks a lot for any assistance
Paul