Getting information about cross-chain exchange
The method allows you to get information on a previously created cross-chain exchange
Header parameters
x-api-public-keystringOptional
Public API-key
x-api-signaturestringOptional
Signing the request body with a private API-key
Content-typestringOptionalExample:
Request content type
application/jsonBody
Request body for getting exchange data
idstringRequiredExample:
Swap ID
88d9e00d-a4fd-4a6f-b58a-11b1c9bc797eResponses
200Success
application/json
Successful response
successbooleanRequired
Request success indicator
post/api-gateway/swaps/get
POST /api-gateway/swaps/get HTTP/1.1
Host: ocp.onchainpay.io
Content-Type: application/json
Accept: */*
Content-Length: 45
{
"id": "88d9e00d-a4fd-4a6f-b58a-11b1c9bc797e"
}200Success
{
"success": true,
"response": {
"id": "88d9e00d-a4fd-4a6f-b58a-11b1c9bc797e",
"clientId": "merchant_unique_id",
"addressFromId": "bd0b179d-6ae3-4516-bd85-243a82b2a87a",
"addressToId": "1de0bedc-26e6-4b83-bd89-f307b6f80f7a",
"currencyFrom": "USDT",
"currencyTo": "USDC",
"networkFrom": "ethereum",
"networkTo": "tron",
"status": "PENDING",
"rejectMessage": "null",
"amountFrom": "200",
"amountTo": "200",
"price": "1",
"serviceBlockchainFeeSource": "ADVANCE",
"serviceBlockchainFee": "2",
"serviceBlockchainFeeUSD": "2",
"providerBlockchainFeeSource": "AMOUNT",
"providerBlockchainFee": "2",
"providerBlockchainFeeUSD": "2",
"serviceFeeSource": "ADVANCE",
"serviceFee": "2",
"serviceFeeUSD": "2",
"webhookUrl": "https://merchant.domain/webhooks/swap",
"createdAt": "2026-01-29T11:14:13.709Z"
}
}Last updated