Use Remote Operations API create_user to create new users and still have S2Member handle IPN messages

If you don’t want the long winded version you can skip to the bold parts :slight_smile: I am building a site that needs membership access. However, I not only want to customize the entire experience the users have when signing up (flowing to different pages for different options), but I want to allow them to enter their payment information one time only and be able to charge them in the future (with their permission ahead of time) without them needing to log in to the site or entering their payment info again. Here is my idea which will hopefully help everyone understand the process, and you can hopefully point me in the right direction. Thank you ahead of time!!

Requirements:

  • Accept 2 types of payment: Credit Cards via Stripe and PayPal.
  • Allow user to enter Credit Card info for Stripe or PayPal info for PayPal. This will then charge them a variable fee for part of their purchase as well as create a monthly subscription.
  • They will have a $ balance that they will use for services, and they’ll be able to set the auto-recharge to reload their balance to $20 if it falls below $1 (can be different amounts) so I need to have a payment token of some kind that I can use for all of these future charges.
  • I want S2Member to be able to still manage their cancelled subscriptions and other events like it does when you generate Pro Forms through the IPN.

My Idea (with some fuzzy understanding of parts)

  • Create my own sign up form with different pages and options etc to walk them through my custom sign up process. DONE
  • Write my own code to integrate PayPal and Stripe. DONE for Stripe
  • Use the Stripe Customer Id and Subscription Id along with the other information about their account to create a new user through the Remote Operations API create_user command and set the Stripe Webhook IPN to be the S2Member Stripe IPN for Stripe setting. I’m hoping that if S2Member has the customer Id and subscription Id it will still be able to automatically receive updates from the Stripe IPN about cancelled subscriptions etc as long as I have the IPN set up in Stripe. I then have access to their Stripe Customer ID for future charges.
  • This is where I’m fuzzy with PayPal. I want to do the same thing as Stripe only do it with PayPal with their terminology. They don’t seem to have customer Id like Stripe does for future charges but I think there’s a way to do that. The main question is again if I charge them with my own code and I set up the IPN settings in my PayPal account and if I populate the subscription Id with the create_user RO API I’m hoping S2Member will manage their subscription cancellation logic as well.

Because my situation is pretty unique and S2Member seem to have the ability to do it out of the box, I feel that as long as I can use the create_user RO API and still have S2Member manage the IPN logic through Stripe and PayPal by setting the Subscription Id for the user that I will be able to accomplish my goal.

Thanks a lot for your time and help! Cheers!
Paul