Set up future PayTo paymentsInvite only
Learn how to set up future PayTo payments.
PayTo allows customers in Australia to authenticate PayTo agreements for one-off and recurring payments in their banking apps. Customers pay with PayTo by receiving notification of a pending agreement request, authorising the terms of the agreement, then returning to your app.
Setting up a PayTo agreement for future payments allows you to get customer authorisation now for collecting future payments. Customers can view, manage, pause, and cancel their PayTo agreements in their banking apps.
Caution
Stripe doesn’t support modification or pausing of PayTo agreements by customers. If a customer attempts to pause or modify an agreement, we cancel the agreement and send you a mandate.
webhook. After receiving the webhook, you can contact your customer to find out why they adjusted their agreement, as well as set up a new agreement.
Caution
Stripe automatically presents your customers payment method options by evaluating their currency, payment method restrictions, and other parameters. We recommend that you configure your payment methods from the Stripe Dashboard using the instructions in Accept a payment.
If you want to continue manually configuring the payment methods you present to your customers with Checkout, use this guide. Otherwise, update your integration to configure payment methods in the Dashboard.
Set up StripeServer-side
First, you need a Stripe account. Register now.
To access the Stripe API from your application, use our official libraries:
Create a CustomerServer-side
Create a Customer after they create an account with your business and associate it with your internal representation of their account. This enables you to retrieve and use their saved payment method details later.
Create a SetupIntentServer-side
A SetupIntent is an object that represents your intent to collect a future payment from a customer and tracks the authorisation process. To create a SetupIntent that accepts a PayTo payment method, specify the terms of the agreement, and payto
in the payment_method_types list. If you maintain a list of payment method types that you pass when creating a SetupIntent, add payto
to it.
Specify the terms of the agreement you want your customer to agree to using payment method options.
Stripe supports various types of agreements, with controls for the amount, duration, cadence, and purpose of the agreement. Specify agreement terms that match your requirements as closely as possible – customers see these precise terms at authorisation time, so accuracy can improve your conversion rate.
Beta
The default purpose
is set to retail
. Override this field using any of the valid values if retail
doesn’t accurately represent the purpose of the agreement.
Retrieve the client secret
The SetupIntent includes a client secret that the client side uses to securely complete the payment process. You can use different approaches to pass the client secret to the client side.
Collect payment method details and submit the request for authorisationClient-side
Collect payment details on the client with the Payment Element. The Payment Element is a pre-built UI component that simplifies collecting payment details for a variety of payment methods.
The Payment Element contains an iframe that securely sends payment information to Stripe over an HTTPS connection. Avoid placing the Payment Element within another iframe because some payment methods require redirecting to another page for payment confirmation.
The checkout page address must start with https://
rather than http://
for your integration to work. You can test your integration without using HTTPS, but remember to enable it when you’re ready to accept live payments.
Use stripe.confirmSetup to complete the setup using details from the Payment Element. This sends an authorisation request to the buyer.
Note
stripe.
might take several seconds to complete while waiting for customers to authorise the payment. During that time, disable your form from being resubmitted and show a waiting indicator like a spinner. If you receive an error, show it to the customer, re-enable the form, and hide the waiting indicator.
Charge the PayTo PaymentMethod later
When you need to charge your customer, create a new PaymentIntent. Find the mandate ID, customer ID, and payment method ID by retrieving the previous SetupIntent.
View the necessary IDs in the response below.
{ // ... "customer": "cus_PW6rQWRGAaBD7z", // <---- Here is the customer "mandate": "mandate_1Ok6ZrA8DuEjWaGw2nrO9xeS", // <---- Here is the mandate "metadata": {}, "next_action": null, "on_behalf_of": null, "payment_method": "pm_1Ok4l9A8DuEjWaGwhB4SGrWh", // <---- Here is the payment method "payment_method_configuration_details": null, "payment_method_options": { "payto": { "mandate_options": { "amount": 150000, "amount_type": "maximum", "start_date": "2026-12-25", "end_date": "2036-12-25", "payment_schedule": "annual", "payments_per_period": 13, "purpose": "mortgage", } } }, "payment_method_types": [ "payto" ], "single_use_mandate": null, "status": "succeeded", "usage": "off_session" // ... }
Create a PaymentIntent with the PaymentMethod, Mandate, and Customer IDs.
Test your integration
Test your PayTo integration with your test API keys by using the various test PayIDs and bank account details below. Each set of details results in a different scenario your integration might commonly face in live mode.