Skip to content

Request payment (RTP) from a customer for an invoice

POST https://api.leapa.co/v2/invoices/{invoiceId}/request-rtp

This endpoint needs your API key

Send it as a bearer token in the Authorization header. A request without one is answered with 401. See Authentication for where to find your key and how to keep it secret.

Request

curl -X POST "https://api.leapa.co/v2/invoices/inv_7c1f9a2b48/request-rtp" \
  -H "Authorization: Bearer $LEAPA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "debtor_alias": "+25779123456",
    "debtor_account": "00012345678901",
    "debtor_bank_bic": "BIBUBIBI",
    "debtor_name": "Jeanne Ndayishimiye",
    "amount": 45000,
    "currency": "BIF"
  }'

Response

OK

{
  "invoice_id": "inv_7c1f9a2b48",
  "uetr": "97ed4827-7b6f-4491-a06f-b548d5a7512d",
  "amount": 45000,
  "currency": "BIF",
  "status": "pending",
  "expires_at": 1769850251000,
  "message": "Request sent to the payer"
}

Path parameters

Values that go into the URL itself.

  • invoiceIdstringrequired
    Example:inv_7c1f9a2b48

Request body

application/json

Required. Send it as JSON.

  • debtor_aliasstring
  • debtor_accountstring
  • debtor_bank_bicstring
  • debtor_namestring
  • amountinteger<int64>
  • currencystring

Response

application/json
  • invoice_idstring
  • uetrstring
  • amountinteger<int64>
  • currencystring
  • statusstring
  • expires_atinteger<int64>
  • messagestring

Status codes

  • 200OK
  • 400Bad request
  • 401Unauthorized
  • 402Payment required
  • 403Forbidden
  • 404Not found
  • 428Precondition required
  • 500Server error

Request

curl -X POST "https://api.leapa.co/v2/invoices/inv_7c1f9a2b48/request-rtp" \
  -H "Authorization: Bearer $LEAPA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "debtor_alias": "+25779123456",
    "debtor_account": "00012345678901",
    "debtor_bank_bic": "BIBUBIBI",
    "debtor_name": "Jeanne Ndayishimiye",
    "amount": 45000,
    "currency": "BIF"
  }'

Response

OK

{
  "invoice_id": "inv_7c1f9a2b48",
  "uetr": "97ed4827-7b6f-4491-a06f-b548d5a7512d",
  "amount": 45000,
  "currency": "BIF",
  "status": "pending",
  "expires_at": 1769850251000,
  "message": "Request sent to the payer"
}