Create a Direct Debit mandate
Creates a Direct Debit mandate for a customer. Bank details are validated with the bureau and stored KMS-encrypted; only masked values are returned.
/mandatesCreates a Direct Debit mandate for a customer. Bank details are validated with the bureau and stored KMS-encrypted; only masked values are returned.
Related endpoints
GET /mandates— List Direct Debit mandatesGET /mandates/{id}— Retrieve a Direct Debit mandatePOST /mandates/{id}/cancel— Cancel a Direct Debit mandatePOST /mandates/{id}/suspend— Suspend a Direct Debit mandatePOST /mandates/{id}/reinstate— Reinstate a suspended Direct Debit mandatePOST /mandates/{id}/collections— Schedule a one-off Direct Debit collection
Common errors
400 invalid_request— malformed payload or failed validation.401 authentication_error— missing, invalid, expired, or revoked credential. Codes:authentication_failed,invalid_api_key,expired_api_key,api_key_revoked,session_invalid,merchant_required. Carries aWWW-Authenticate: Bearerchallenge.404 resource_missing— the referenced resource does not exist or is not visible to your key.409 conflict— Idempotency-Key collision with a different body, or a concurrent state-transition conflict.410 gone— the resource has been archived or permanently deleted.422 unprocessable_entity— business-rule failure (for example, refunding more than the original charge).
Idempotency
Pass an Idempotency-Key header (UUID v4 recommended) to make retries safe. Keys are valid for 24 hours; see the idempotency guide.
Authorization
apiKey Your RevKeen merchant API key. Create and manage keys in Dashboard → Settings → Developer. Use rk_sandbox_* for staging/test and rk_live_* for production. The same key may be sent as Authorization: Bearer <key> if that suits your HTTP client better. A missing, invalid, expired, or revoked key returns 401 with a WWW-Authenticate: Bearer challenge; a valid key without the required scope returns 403.
In: header
Header Parameters
Required stable key for this logical mandate submission. Reuse the same key only with an identical request.
^[A-Za-z0-9_-]{8,64}$Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Parameters for creating a Direct Debit mandate. Bank details are validated with the bureau and stored KMS-encrypted; only masked values are ever returned.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://api.revkeen.com/v2/mandates" \
-H "x-api-key: $REVKEEN_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"customerId": "11111111-1111-4111-8111-111111111111",
"accountHolderName": "Jane Smith",
"sortCode": "20-00-00",
"accountNumber": "55779911"
}'Synthetic documentation data, validated against the response schema; not a live API result.
{ "data": { "id": "00000000-0000-4000-8000-000000000001", "mandate_ref": "string", "mandate_reference": "string", "customer_id": "00000000-0000-4000-8000-000000000001", "status": "pending_lodgement", "account_holder_name": "string", "sort_code": "XX-XX-00", "account_number_last4": "string", "bank_name": "string", "statement_name": "string", "notice_days": 0, "first_collection_date": "string", "next_collection_date": "string", "backup_payment_method_id": "string", "activated_at": "2019-08-24T14:15:22Z", "suspended_at": "2019-08-24T14:15:22Z", "cancelled_at": "2019-08-24T14:15:22Z", "failure_reason": "string", "mandate_request_id": "string", "invoice_id": "string", "pdf_documents": [ { "id": "00000000-0000-4000-8000-000000000001", "mandate_request_id": "string", "mandate_id": "00000000-0000-4000-8000-000000000001", "customer_id": "00000000-0000-4000-8000-000000000001", "merchant_id": "00000000-0000-4000-8000-000000000001", "pdf_type": "signed_mandate_confirmation", "storage_key": "string", "pdf_url": "string", "generated_at": "2026-09-01T12:00:00Z", "template_version": "string", "compliance_version": "string" } ], "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z" }}