Sign up
Stripe provides self-service sign up for sandbox accounts. To sign up for an account, visit the sign up page.Credentials
When setting up the SPEI via Stripe connection in the dashboard, the following credentials can be configured:Secret key
A Stripe Secret key can be found in the Stripe Dashboard within Developer Settings under API keys.Webhook secret
A Stripe Webhook Secret can be found in the Stripe Dashboard within Developer Settings under Webhooks once webhooks have been configured (see Webhooks below).Stripe connected account (when applicable)
If using Stripe Connect, you can set the Stripe Account ID of the connected account that you intend to use for all transactions through the connection.Approval URL (optional)
By default, the connector returns an approval URL that redirects buyers to a Stripe-hosted page with instructions for completing a bank transfer. If required, you can set a different approval URL here which allows you to build your own page for showing bank transfer instructions to buyers. When set, the Approval URL is returned with a Session Token appended as a query parameter namedtoken. This Session Token can be used with the Transaction Session API to retrieve the details required to build your own page.
Webhooks
SPEI payments and refunds are completed asynchronously, so webhooks must be configured to update the status of transactions. Webhooks are configured in the Stripe Dashboard within Developer Settings under Webhooks. The SPEI connector relies on the following Stripe webhooks:payment_intent.succeededpayment_intent.partially_fundedpayment_intent.canceledcharge.refund.updated
Integration
The default integration for SPEI via Stripe uses a redirect to a payments page hosted by Stripe.Redirect integration
Start by creating a new transaction with the following required fields.POST /transactions
payment_method.approval_url and the status is set to processing.
approval_url (open in a browser or Webview), where they see instructions for completing a bank transfer.
Once the buyer completes a bank transfer, the transaction progresses to a capture_succeeded state in response to a webhook from Stripe.
Direct integration
If you intend to use your own hosted page for presenting the buyer with bank transfer instructions, you can include anintegration_client parameter set to web, ios or android when creating a new transaction.
session_token. You use this token with the session endpoint to retrieve the session data for the transaction and build a custom page that displays the bank transfer instructions.