Creating Payment Methods via API
Often our customers want to create customer payment methods via the MonetizeNow API's in their own product as opposed to via the UI or via a MonetizeNow invoice. We fully support in two simple processes, depending on your desires.
Option 1: Directly via Stripe
- Send Payment information directly to Stripe via Stripe Elements
- Share this Payment information to MonetizeNow via
POST /api/accounts/${accountId}/paymentMethods
Full API details here
Option 2: Fully in MonetizeNow
- Check if a Stripe customer already exists
GET /api/accounts/${accountId}/paymentGateways/${gatewayId}/gatewayAccount
- If not, create one,
POST /api/accounts/${accountId}/paymentGateways/${gatewayId}/gatewayAccount
This returns a gatewayAccountId that is specific to that Stripe customer and looks like cus_PY9p1v12wEo - Create a Stripe setup intent
POST /api/paymentGateways/${gatewayId}/gatewayAccounts/${gatewayAccountId}/setupIntent
- Get the Stripe client secret
GET /api/paymentGateways/${gatewayId}/gatewayAccounts/${gatewayAccountId}/clientSecret
- Render the Stripe payment UI for secure payment information capture
- We pass in the client secret to initialize the Stripe UI
- Save payment method
POST /api/accounts/${accountId}/paymentMethods
Updated 9 months ago