简体   繁体   中英

How to set 1/3/5 years billing period in Paypal express checkout PHP

I'm using paypal as payment gateway and want to create recurring profile like

  • 1 year plan for $20
  • 3 year plan for $40
  • 5 year plan for $50

but when i'm adding BILLINGPERIOD=year&BILLINGFREQUENCY=3 as params, getting error from paypal api :

And getting Error :

Billing frequency must be > 0 and be less than or equal to one year
Error Message: Invalid billing frequencyError Code: 11516
Error Severity Code: Error 

Please help me here.

This isn't possible with the paypal api, you need to create your own mechanism.

From the paypal api:

The combination of BillingPeriod and BillingFrequency cannot exceed one year.

If the billingperiod is Month you can set the billingfrequency to eg 1, 4, 9 and 12 but not to 13.

If the billingperiod is Year you can set the billingfrequency only to 1.

Source: https://developer.paypal.com/docs/classic/api/merchant/CreateRecurringPaymentsProfile_API_Operation_NVP/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM