Create payments to your merchant account
Pay in to your merchant account with a single payment, payment mandate or bank transfer.
To create a payment or mandate to a merchant account, set the beneficiary to your merchant account within the API request. Depending on whether you're creating a single payment or a mandate, the beneficiary
object differs slightly.
It's generally easiest to specify the beneficiary using your merchant account ID, but you can also input your merchant account's sort code and account number to make the payment.
Create a single payment to your merchant account
When you create a payment with the /v3/payments
endpoint, you can specify your merchant account as the beneficiary. Within the beneficiary
object, set the type
to merchant_account
. Provide your merchant_account_id
as the value for the payment_method.beneficiary.merchant_account_id
object.
Below is an example of a payment created to a merchant account.
curl --request POST \
--url https://api.truelayer-sandbox.com/v3/payments \
--header 'accept: application/json; charset=UTF-8' \
--header 'content-type: application/json; charset=UTF-8' \
--data '
{
"currency": "GBP",
"payment_method": {
"type": "bank_transfer",
"provider_selection": {
"type": "user_selected",
"filter": {
"release_channel": "general_availability",
"customer_segments": [
"retail"
]
},
"scheme_selection": {
"type": "user_selected",
"allow_remitter_fee": false
}
},
"beneficiary": {
"type": "merchant_account",
"verification": {
"type": "automated"
},
"merchant_account_id": "AB8FA060-3F1B-4AE8-9692-4AA3131020D0",
"account_holder_name": "Ben Eficiary",
"reference": "payment-ref"
}
},
"user": {
"id": "f9b48c9d-176b-46dd-b2da-fe1a2b77350c",
"name": "Remi Terr",
"email": "[email protected]",
"phone": "+447777777777",
"date_of_birth": "1990-01-31"
}
}
'
Create a VRP mandate to your merchant account
When you create a variable recurring payment mandate with the /v3/mandates
endpoint, you can specify your merchant account as the beneficiary. To do so, provide your merchant_account_id
as the value for the mandate.sweeping.beneficiary.merchant_account_id
or mandate.commercial.beneficiary.merchant_account_id
object.
Below is an example of a mandate created to make payments to a merchant account.
curl --request POST \
--url https://api.truelayer-sandbox.com/v3/mandates \
--header 'accept: application/json; charset=UTF-8' \
--header 'content-type: application/json; charset=UTF-8' \
--data '
{
"mandate": {
"type": "sweeping",
"provider_selection": {
"type": "user_selected",
"filter": {
"release_channel": "general_availability"
}
},
"beneficiary": {
"type": "merchant_account",
"merchant_account_id": "AB8FA060-3F1B-4AE8-9692-4AA3131020D0",
"account_holder_name": "example"
}
},
"currency": "GBP",
"user": {
"id": "f9b48c9d-176b-46dd-b2da-fe1a2b77350c",
"name": "Remi Terr",
"email": "[email protected]",
"phone": "+447777777777",
"date_of_birth": "1990-01-31"
},
"constraints": {
"periodic_limits": {
"day": {
"period_alignment": "consent"
},
"week": {
"period_alignment": "consent"
},
"fortnight": {
"period_alignment": "consent"
},
"month": {
"period_alignment": "consent"
},
"half_year": {
"period_alignment": "consent"
},
"year": {
"period_alignment": "consent"
Pay your merchant account via bank details
You can also accept payments into your merchant account using the merchant account's account number and sort code or IBAN.
To find the details of your merchant account, either:
- Sign in to Console, access your merchant account dashboard, select the merchant account to receive the payment, and click the Details tab
- Use the
/v3/merchant-account/{id}
or/v3/merchant-account
endpoint and check theaccount_identifiers
object in the response.
Updated 7 months ago