Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Multiple affiliate services in parallel with PAP
 
Randalf
Jr. Member
 
Total Posts:  28
Joined:  2011-02-24
 

Hi,

we are using PAP and two additional affiliate networks in parallel which means that we use a software (=PAP) and two services like doubleclick in parallel. The services determine the sales event on the success.phtml which means that on the success page we determine the newest cookie and then we send the sales event to the affiliate network that owns the newest cookie.

Question: What we need to do is to decide the following:

1. Customer came via our PAP tracking
2. Customer came via affiliate network 1
3. Customer came via affiliate network 2

The newest cookie should count. The affiliate networks we handle on the success.phtm.

How can we control PAP in this scenario? We need to have a decision point at which it is decided if PAP OR affiliate network 1 OR affiliate network 2 gets the sales event.

- Can we do this by modifying your plug-in?
- Should we deinstall your plug-in and add some code to the success.phtm?

 
Magento Community Magento Community
Magento Community
Magento Community
 
MageGuys
Guru
 
Avatar
Total Posts:  380
Joined:  2008-06-07
 

Honestly, this really isn’t possible. In order to do something like this the two affiliate systems (PAP and whatever other system) would have to both be aware of each other and use their API’s to negotiate between them which one gets to track the sale.

If the other affiliate system has a really good API, it MIGHT be possible to broker these negotiations on your side, by doing something like this:
1. Use PAP API to get the current PAP tracking cookie information (See PayPal code in connector for an example of this)
2. Use PAP API to look up the full tracking details for the individual represented in the cookie.
3. Use other affiliate program’s API to get the full tracking details for that system.
4. Compare the two sets of tracking information to determine which system should get the option to track the sale
5. Send the sale tracking request to ONLY that system, via API using the returned tracking information.

Honestly, I’d be surprised if a secondary system supported enough API access to do this, and I suspect that it would violate their terms of service to knowingly suppress the sale tracking code in certain cases. Even if you could do it, there would be a lot of tricky coding involved, and I would not be able to help you with that.

 
Magento Community Magento Community
Magento Community
Magento Community
 
MageGuys
Guru
 
Avatar
Total Posts:  380
Joined:  2008-06-07
 

BTW, to better answer JUST the original question, the PayPal code uses the PAP API to get the current tracking cookie information. Dig in there and you’ll find it. The connector won’t support what you want natively, but with some code tweaks you can use the PAP API to get the data you need. I expect that the real problem will be the other systems.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Randalf
Jr. Member
 
Total Posts:  28
Joined:  2011-02-24
 

What we are doing right now with the commercial networks is the following. The decision which networks gets the deal is done on the success.phtml

1. Customer hits our store: Cookie is set by us. We marked the links with a source parameter so if the customer comes via one of the affiliate networks we write this into the cookie
2. If the customer purchases, we read OUR cookie when the success.phtml is executed. When OUR cookie contains a source of one of our affiliate networks we execute the corresponding code.

So my first idea was that we can just add the PAP communication to the same success.phtml so that in case it is a PAP cookie marked as source within OUR cookie then we simply execute some PAP code.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top