Automatic Payment
This section details the steps needed to use the methods to create a subscription and request automatic payments.
Authorizing API calls
Attention
Regarding the authorization process of the Automatic Payment API, all calls must be sent with the special x-api-key
header, using the api key provided by Khipu. Each method specification explains the use of the header in the Security section.
Simplified flow for merchants
It's easy to enable the Automatic Payment process to your customers, you just need to use the Subscription API to ask for a new Subscription ID, to associate it with the service you will be charging your customer on a recurring basis. When the customer finishes the signing process in its bank, you will receive a notification in the callback URL you provided when asking for the Subscription ID.
After a positive confirmation, you can begin using the Charge API to send your requests for automatic payment. The remaining part of the process is asynchronous and you will be notified when the conciliation process finishes.
Sequence diagram
The next image shows a basic sequence diagram with the steps mentioned above.
After the last step, the rest of the process is identical to that of a regular payment, regarding the conciliation and fund transfer. See the Payment API documentation for details and examples.