NAV
shell

Introduction

Welcome to the Merit Payout API.

Authentication

Sample API call with the Authorization header

curl "{{BaseURL}}/path/to/resource" \
  -H "Authorization: Bearer <TOKEN>"

Make sure to replace with your Token.

All the API requests to the server should include Token in the Authorization header:

Authorization: Bearer <TOKEN>

Token will be provided while onboarding.

Base URL

Base URL for Merit API endpoints

Description URL
Staging https://api.sandbox.meritincentives.com/payouts
Prod https://api.meritincentives.com/payouts
Content-Type application/json
Authorization Bearer <TOKEN>

Create payout

POST {host}/v1/payouts

This API let you create payout.

Headers

Key Value
Authorization Bearer <TOKEN>

Request body

Create Payout JSON structured like this:

{
  "reference_id": "63a641f6-4215-43da-b1d9-d59b99be8d40",
  "recipient": "recipient@email.com",
  "currency": "GBP",
  "amount": "100.00",
  "payout_provider": "paypal"
}
Field Description Type Required
amount The amount to be paid out. This field contains a numeric value with up to two decimal places. The minimum allowable value is 1, and the maximum allowable value is 5,000. string true
currency The currency code in ISO 4217 format (e.g., USD for U.S. Dollars, EUR for Euros) string true
recipient The email address of the payout recipient. Only basic format validation will be applied. Note that no verification will be done to confirm the email exists on the payout provider platform. string true
payout_provider The name of the payout provider to be used for the transaction, specified in lowercase. Currently, "paypal" is the only supported provider string true
reference_id A unique reference identifier for the transaction, used for tracking and reconciliation. This field must be unique for each transaction and is limited to a maximum length of 255 characters string true

Response

Create Payout JSON structured like this:

{
  "id": "550e8400-e29b-41d4-a716-446655440",
  "recipient": "recipient@email.com",
  "currency": "GBP",
  "amount": "100.00",
  "payout_provider": "paypal",
  "status": "initiated",
  "status_code": "success",
  "reference_id": "63a641f6-4215-43da-b1d9-d59b99be8d40",
  "status_details": {
    "message": ""
  },
  "created_at": 1741088732,
  "updated_at": 1741088733
}
Field Description Type
id Payout ID string
recipient The email address of the payout recipient string
currency The currency code in ISO 4217 format (e.g., USD for U.S. Dollars, EUR for Euros) string
amount The amount to be paid out string
payout_provider The name of the payout provider to be used for the transaction string
status PayoutStatus string
status_code PayoutStatusCode string
reference_id Reference ID used to create payout string
status_details StatusDetails object
created_at The timestamp when the payout was created int
updated_at The timestamp of the last update to the payout int

Get payout

GET {host}/v1/payouts/{id}

This API lets you get payout by ID.

Headers

Key Value
Authorization Bearer <TOKEN>

Request fields

Field Description Type Required
id Payout ID string true

Response

Create Payout JSON structured like this:

{
  "id": "550e8400-e29b-41d4-a716-446655440",
  "recipient": "recipient@email.com",
  "currency": "GBP",
  "amount": "100.00",
  "payout_provider": "paypal",
  "status": "initiated",
  "status_code": "success",
  "reference_id": "63a641f6-4215-43da-b1d9-d59b99be8d40",
  "status_details": {
    "message": ""
  },
  "created_at": 1741088732,
  "updated_at": 1741088733
}
Field Description Type
id Payout ID string
recipient The email address of the payout recipient string
currency The currency code in ISO 4217 format (e.g., USD for U.S. Dollars, EUR for Euros) string
amount The amount to be paid out string
payout_provider The name of the payout provider to be used for the transaction string
status PayoutStatus string
status_code PayoutStatusCode string
reference_id Reference ID used to create payout string
status_details StatusDetails object
created_at The timestamp when the payout was created int
updated_at The timestamp of the last update to the payout int

Cancel payout

POST {host}/v1/payouts/{id}/cancel

This API lets you cancel a payout. Cancellation is available only for payouts in statuses PROCESSING and PENDING_CLAIM.

Headers

Key Value
Authorization Bearer <TOKEN>

Request fields

Field Description Type Required
id Payout ID string true

Response

Cancel Payout JSON structured like this:

{
  "id": "550e8400-e29b-41d4-a716-446655440",
  "recipient": "recipient@email.com",
  "currency": "GBP",
  "amount": "100.00",
  "payout_provider": "paypal",
  "status": "canceled",
  "status_code": "success",
  "reference_id": "63a641f6-4215-43da-b1d9-d59b99be8d40",
  "status_details": {
    "message": ""
  },
  "created_at": 1741088732,
  "updated_at": 1741088733
}
Field Description Type
id Payout ID string
recipient The email address of the payout recipient string
currency The currency code in ISO 4217 format (e.g., USD for U.S. Dollars, EUR for Euros) string
amount The amount to be paid out string
payout_provider The name of the payout provider to be used for the transaction string
status PayoutStatus string
status_code PayoutStatusCode string
reference_id Reference ID used to create payout string
status_details StatusDetails object
created_at The timestamp when the payout was created int
updated_at The timestamp of the last update to the payout int

Status Details

Object provides additional information about certain payout statuses that may require user action or intervention.

Field Description Type
message The message contains specific instructions, reasons, or next steps to resolve payment issues. string

Payout Status

Status Description
created The payout request has been successfully received and recorded in the system.
pending_verification The payout request is awaiting verification. This status will not be visible to clients as the workflow which leads to this status is not enabled for API clients.
initiated The payout has been initiated and is awaiting further processing.
processing The payout is actively being processed by the system.
pending_claim The payout is waiting to be claimed by the recipient. This occurs when the recipient does not have an account with the provider.
processed The payout has been successfully completed, and funds have been transferred to the recipient. This is the terminal status for a successful payout.
failed The payout attempt was unsuccessful, and the transaction was not completed. This could be due to an issue with the payout provider, insufficient funds, or an error in recipient details. This is a terminal status. The client can send a new payout request with a different reference_id. Any funds deducted would be refunded.
expired The payout was not claimed by the recipient within the specified time frame and has expired. This is a terminal status. Any funds deducted would be refunded
canceled The payout request was canceled by either the sender or the system before completion. This is a terminal status. Any funds deducted would be refunded
pending_approval The payout is awaiting approval from an authorized person or system.
approved The payout has been reviewed and approved.
declined The payout request was reviewed and declined, possibly due to verification failures, compliance issues, or other policy restrictions. This is a terminal status. Any funds deducted would be refunded

Payout Status Code

Status Code Description
success Operation complete successfully
unable_to_process Payout failed completely. Reach out to dev team for more details
provider_error Something goes wrong. We cannot reach provider to create payout
insufficient_funds Client doesn't have enough funds in their account

Errors

Errors structure

Field Description Type
code Error Code string
message Short description of the error string
details Optional Object. Error details. Optional object([string][string])

Validation Error Example:

{
  "code": "VALIDATION_ERROR",
  "message": "Validation error",
  "details": {
    "field": "body.email",
    "issue": "Invalid email format: Please enter a valid email address (e.g., name@example.com)."
  }
}

Client Error Example:

{
  "code": "CANNOT_CANCEL_PAYOUT",
  "message": "The payout cannot be canceled as it has reached a status where cancellation is no longer allowed.",
  "detail": {}
}
{
  "code": "DUPLICATE_REFERENCE_ID",
  "message": "The provided reference ID has already been used. Payout: 12",
  "details": {
    "field": "body.reference_id",
    "issue": "The provided reference ID has already been used. Payout: 12"
  }
}
Error Code HTTP code Meaning
INVALID_REQUEST 400 Bad Request -- Your request contains invalid data or parameters.
DUPLICATE_REFERENCE_ID 400 Bad Request -- The provided reference ID has already been used. Payout: X.
LIMIT_EXCEEDED 400 Bad Request -- The requested amount exceeds the allowable limit.
CANNOT_CANCEL_PAYOUT 400 Bad Request -- The payout cannot be canceled as it has reached a status where cancellation is no longer allowed.
PROVIDER_NOT_FOUND 400 Bad Request -- The specified payout provider could not be found or is not supported.
CURRENCY_MISMATCH 400 Bad Request -- The currency specified in the request does not match the expected or allowed currency for the operation.
NOT_AUTHORIZED 401 Unauthorized -- Authentication credentials were not provided.
PAYMENT_FAILED 402 Payment Required -- There was an error during payment
INSUFFICIENT_FUNDS 402 Payment Required -- The account has insufficient funds to fulfill the request.
NO_ACCESS 403 No Access -- You do not have access to perform this action.
NOT_FOUND 404 Not Found -- The specified resource could not be found.
METHOD_NOT_ALLOWED 405 Method Not Allowed -- Method \”X\” not allowed.
THROTTLED 429 Too Many Requests -- The request has been blocked because the maximum number of allowed requests has been exceeded within a specified time period. Please wait and try again later to avoid further restrictions.
CONFIGURATION_ERROR 500 Internal Server Error -- A configuration error has occurred. Please contact the development team to resolve this issue.
INTERNAL_SERVER_ERROR 500 Internal Server Error -- A server error occurred.
PROVIDER_CANCEL_ERROR 502 Bad Gateway -- The payout cancellation request could not be completed due to an error from the external service provider. Please try again.