Creating a payment

The method allows you to create a payment with an arbitrary amount in the coin in which the address was connected

Creating a payment

post
Header parameters
x-api-public-keystringOptional

Public API-key

x-api-signaturestringOptional

Signing the request body with a private API-key

Content-typestringOptional

Request content type

Example: application/json
Body

The body of the request to create a payment for the payment link

merchantIdstringRequired

Merchant ID

Example: 3ce560cc-4d42-4543-b9ef-8cc35c00638c
billingLinkIdstringRequired

Payment link ID

Example: 6a42622f-4968-47e2-a24d-5f5f1dc1acd6
webhookUrlstringOptional

URL for notification of payment status change

Example: https://merchant.domain/webhooks/payment
amountstringRequired

Payment amount in the currency in which the payment link was created

Example: 10
Responses
200Success
application/json
post
POST /api-gateway/recurrents/make-payment HTTP/1.1
Host: ocp.onchainpay.io
Content-Type: application/json
Accept: */*
Content-Length: 178

{
  "merchantId": "3ce560cc-4d42-4543-b9ef-8cc35c00638c",
  "billingLinkId": "6a42622f-4968-47e2-a24d-5f5f1dc1acd6",
  "webhookUrl": "https://merchant.domain/webhooks/payment",
  "amount": "10"
}
200Success
{
  "success": true,
  "response": {
    "id": "15938f00-25f5-4816-8d24-6597e52c742e",
    "merchantId": "3ce560cc-4d42-4543-b9ef-8cc35c00638c",
    "billingLinkId": "6a42622f-4968-47e2-a24d-5f5f1dc1acd6",
    "webhookUrl": "https://merchant.domain/webhooks/payment",
    "amount": "10",
    "tx": null,
    "status": "INIT",
    "createdAt": "2025-06-09T13:18:11.533Z",
    "updatedAt": "2025-06-09T13:18:11.533Z"
  }
}

Last updated