0οΈZero Amount Authorization
Best way to validate customer payment data and charge the customer later
In this section, we will understand zero-auth flow, it's usage, and webhook consumption
The zero amount authorization flow in Hyperswitch allows the merchant to validate customer payment data and charge the customer later. On customer registration, the merchant can initiate a zero-auth flow transaction with Hyperswitch to authenticate the customer payment method (card, bank account etc.) and receive authorization from the customer to use the payment method to charge them at a later point. A payment_method_id would be created and issued to the merchant. And in the future they can charge against this payment_method_id.
The following API cURLs demonstrate the usage of the zero-auth flow. The example below uses the credit card payment method. But this can be extended to bank debits and other payment methods as well.
How to use the zero amount authorization flow?
Creating a 0 amount payment along with
setup_future_usage= off_session
to set up a mandate to store and charge the customer's payment method later ( Called as 'CIT' : Customer initiated transaction)
Confirm the payment after collecting payment information from the user [You can skip this step if you are using the Hyperswitch Unified Checkout]
Retrieve the
payment_method_id
that was created against the above payment by retrieving the payment. You will get the payment_method_id in the response
Charge the customer later by passing the payment_method_id (Called as 'MIT': Merchant initiated Transaction)
Pass the above payment_method_id
under the recurring_details
object along with off_session=true
in the payments request and confirm the payment. Make sure you are using the same customer_id
and profile_id
from the CIT.
Last updated