Create a payment method
POST {{baseUrl}}/payment_methods/bank_accounts
Create a new payment method for a customer
Parameter | Type | Required | Description |
---|---|---|---|
customerId | string | true | The customerId that you want to create the payment method for. |
accountType | string | true | The bank account or card type. Can be either: savings , checkings or debit_card . |
accountNumber | string | true | The bank account or debit card number. |
bank | string | true | The name of the Mexican bank where the account or card is held. For a full list of institutions, please see our dedicated Payment Institutions page. |
reference | string | false | An optional reference description for the bank account. |
You will receive the following response from our API, confirming that the customer was created. Make sure to save the paymentMethodId
you receive, as this ID is required when generating an agreement.
{
"paymentMethodId": "uuid"
}
Request Body
{"customerId"=>"uuid_of_customer", "accountType"=>"savings_checkings_or_debit_card", "accountNumber"=>"account_or_debit_number", "bank"=>"belvo_bank_name", "reference"=>"optional_internal_reference"}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string | ||
Accept | string |
RESPONSES
status: Created
{"paymentMethodId":"0d1a377b-b4c5-4a94-9e2e-83e59d1f6a9c"}