Billing Agreement id assign with user in my database.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I successfully implemented Paypal subscriptions into my app, this are the steps to do create subscription plan and accept it by user:
1. Create billing plan - https://developer.paypal.com/docs/api/payments.billing-plans/v1/#billing-plans_create
2. Activate billing plan - https://developer.paypal.com/docs/api/payments.billing-plans/v1/#billing-plans_update
3. Create billing agreement - https://developer.paypal.com/docs/api/payments.billing-agreements/v1/#billing-agreements_create
4. Redirect buyer to approve agreement (using redirect URL provided in response of 'create billing agreement')
5. Execute the agreement (passing the token returned after buyer approval)
6. The "ID" will be returned in the response and starts with "I-XXXXXXX"- https://developer.paypal.com/docs/api/payments.billing-agreements/v1/#billing-agreements_execute
But i can't figure it out, how can i connect this steps with my database user. When user finish payment in step number 5, user is successfully redirected to my site and i can activate(execute) agreement with token. But how can i connect this agreement with my database user? After successful payment, i want to assign to this user Agreement ID and change user status to "active subscriber".
Can i pass somewhere, for example in step 3, user id ? Is this possible?
I'm using Rails + PayPal-Ruby-SDK (version 2.0-beta).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
- can we assign a unique detail to every subscription creation? in NVP/SOAP APIs
- I want to implement subscription functionality. in REST APIs
- Multiple locations to same email address result in one client only. in SDKs
- Load paypal approval_url in popup window using sdk in SDKs
- I Have PayPal API Billing Authentication Failure Python-Flask in REST APIs