DAP now integrates with 2CO!
To integrate DAP with your 2CO account, pls update the IPN in your 2CO account to point to http://yoursite.com/dap/dap-2co.php (replace yoursite.com with the name of your site) for the following events:
- Order Created
– Fraud Status Changed
– Recurring Installment Success
– Recurring Installment Failed
– Recurring Restarted
NOTE: When you create products in 2CO to sell, make sure you create products by the EXACT same name in DAP otherwise the transaction will not be processed by DAP.
Here’s how the script will work:
1) Order Created
DAP will create and activate the membership account at the time of purchase.
DAP will look for the message type of ORDER_CREATED and invoice_status of “approved” to automatically create the membership account. The user will receive the welcome email with full access to the purchased items (based on content drip settings in dap products page) upon purchase completion.
2) Fraud Status Changed
2CO approves or disapproves a purchase inmediately. If the purchase is approved, DAP will receive an “Order created” message via IPN from 2CO; if not, 2CO will not send any message. After that, 2CO has a “second tier” fraud check. Upon the completion of Fraud Check, 2CO will send out FRAUD_STATUS_CHANGED message. DAP will not take any action if fraud_status = “pass”. But if fraud_status in NOT “pass”, then dap will set the user’s product status in DAP to INACTIVE. So the user will not be able to access the DAP product any more.
3) Recurring Installment Success
Upon successful recurring payment notification from 2CO, DAP will simply extend the user’s access end date based on the ‘recurring cycle’ setting in dap products page -> Price/Recurring tab for the product.
4) Recurring Installment Failed
DAP will reset the access end date to current date if recurring payment fails so user will not be able to access content past the failed date.
5) Recurring Restarted
DAP will start back from where the user last left off. The user’s access end date will be extended from whatever it was set to previously. The access end date is extended based on the recurring period settings in the dap products page -> Price/Recurring tab for the product.