Create mandate

Mandates API v1

Warning

The v1 API has been deprecated. The v1 API will be supported for the foreseeable future, at least until July 2023. However, new features will only be added to the v2 API.

The documentation for creating mandates in the new v2 API can be found here. For more information on the v2 API, refer to our v2 migration guide.

POSThttps://api.mollie.com/v1/customers/*customerId*/mandates

Create a mandate for a specific customer. Mandates allow you to charge a customer’s credit card or bank account recurrently.

It is only possible to create mandates for IBANs with this endpoint. To create mandates for credit cards, have your customers perform a ‘first payment’ with their credit card.

Note

Created mandates are unique to your account and can not be transferred to other accounts.

Parameters

Replace customerId in the endpoint URL by the customer’s ID, for example /v1/customers/cst_8wmqcHMN4U/mandates.

methodstringrequired

Payment method of the mandate.

Possible values: directdebit

consumerNamestringrequired
The consumer’s name.
consumerAccountstringrequired
The consumer’s IBAN.
consumerBicstringoptional
The consumer’s bank’s BIC.
signatureDatedateoptional
The date when the mandate was signed in YYYY-MM-DD format.
mandateReferencedateoptional
A custom mandate reference. Use an unique mandateReference as some banks decline a Direct Debit payment if the mandateReference is not unique.

Access token parameters

If you are using organization access tokens or are creating an OAuth app, the testmode parameter is also available.

testmodebooleanoptional

Response

201 application/json

A mandate object is returned, as described in Get mandate.

Example

Request

1
2
3
4
5
6
7
8
curl -X POST https://api.mollie.com/v1/customers/cst_stTC2WHAuS/mandates \
    -H "Authorization: Bearer test_dHar4XY7LxsDOtmnkVtjNVWXLSlXsM" \
    -d "method=directdebit" \
    -d "consumerName=Customer A" \
    -d "consumerAccount=NL53INGB0000000000" \
    -d "consumerBic=INGBNL2A" \
    -d "signatureDate=2016-05-01" \
    -d "mandateReference=YOUR-COMPANY-MD13804"

Response

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
HTTP/1.1 201 Created
Content-Type: application/json

{
    "resource": "mandate",
    "id": "mdt_pWUnw6pkBN",
    "mode": "test",
    "status": "valid",
    "method": "directdebit",
    "customerId": "cst_stTC2WHAuS",
    "details": {
        "consumerName": "Customer A",
        "consumerAccount": "NL53INGB0000000000",
        "consumerBic": "INGBNL2A"
    },
    "mandateReference": "YOUR-COMPANY-MD13804",
    "createdDatetime": "2016-04-30T22:00:00.0Z"
}