curl -X POST https://api.liddie.io/api/v1/payments/6a0000000000000000000001/process-cross-chain \
-H "Authorization: Bearer lid_live_..." \
-H "Content-Type: application/json" \
-d '{ "acceptedCurrency": "USDT_TRC20", "acceptedAmount": "99.5" }'
const res = await fetch(
'https://api.liddie.io/api/v1/payments/6a0000000000000000000001/process-cross-chain',
{
method: 'POST',
headers: {
'Authorization': 'Bearer lid_live_...',
'Content-Type': 'application/json'
},
body: JSON.stringify({
acceptedCurrency: 'USDT_TRC20',
acceptedAmount: '99.5' // decimal string, not a number
})
}
);
const result = await res.json(); // { ok: true, data: {...} } or { ok: false, error: {...} }
{ "ok": false, "error": { "code": "NO_CROSS_CHAIN_DEPOSITS", "message": "No cross-chain deposits detected on this payment" } }
Payments
Accept a cross-chain deposit
Accept a wrong-currency (cross-chain) or overpaid deposit parked on a Liddie payment, crediting it in the currency and amount you confirm.
POST
/
api
/
v1
/
payments
/
{paymentId}
/
process-cross-chain
curl -X POST https://api.liddie.io/api/v1/payments/6a0000000000000000000001/process-cross-chain \
-H "Authorization: Bearer lid_live_..." \
-H "Content-Type: application/json" \
-d '{ "acceptedCurrency": "USDT_TRC20", "acceptedAmount": "99.5" }'
const res = await fetch(
'https://api.liddie.io/api/v1/payments/6a0000000000000000000001/process-cross-chain',
{
method: 'POST',
headers: {
'Authorization': 'Bearer lid_live_...',
'Content-Type': 'application/json'
},
body: JSON.stringify({
acceptedCurrency: 'USDT_TRC20',
acceptedAmount: '99.5' // decimal string, not a number
})
}
);
const result = await res.json(); // { ok: true, data: {...} } or { ok: false, error: {...} }
{ "ok": false, "error": { "code": "NO_CROSS_CHAIN_DEPOSITS", "message": "No cross-chain deposits detected on this payment" } }
Sometimes a payer sends a different currency (or a large overpayment) to your deposit address. The platform detects it and parks it — this endpoint lets you accept the parked deposit explicitly.
You don’t have to call this endpoint at all. If you do nothing, an auto-accept protocol may settle the parked deposit after the configured window — watch
crossChainAutoAcceptAt on the payment for the deadline. Call this endpoint only when you want to accept sooner, or on your own terms.curl -X POST https://api.liddie.io/api/v1/payments/6a0000000000000000000001/process-cross-chain \
-H "Authorization: Bearer lid_live_..." \
-H "Content-Type: application/json" \
-d '{ "acceptedCurrency": "USDT_TRC20", "acceptedAmount": "99.5" }'
const res = await fetch(
'https://api.liddie.io/api/v1/payments/6a0000000000000000000001/process-cross-chain',
{
method: 'POST',
headers: {
'Authorization': 'Bearer lid_live_...',
'Content-Type': 'application/json'
},
body: JSON.stringify({
acceptedCurrency: 'USDT_TRC20',
acceptedAmount: '99.5' // decimal string, not a number
})
}
);
const result = await res.json(); // { ok: true, data: {...} } or { ok: false, error: {...} }
{ "ok": false, "error": { "code": "NO_CROSS_CHAIN_DEPOSITS", "message": "No cross-chain deposits detected on this payment" } }
Authorization
- API-key scope:
payments:create· JWT roles:merchant_adminorsuper_admin—merchant_memberis excluded. - Your merchant account must be active.
- Tenant scope is forced server-side from the credential, so another merchant’s payment reads as
404regardless of role. - Rate limit: 20/min.
Parameters
string
required
24-hex payment id of the payment whose address received the wrong-currency deposit.
string
required
The currency of the detected deposit you are accepting, e.g.
USDT_TRC20.string
required
A decimal string, e.g.
"99.5" — not a number.Response envelope
Every response — success or error — uses the same envelope:| Field | Description |
|---|---|
ok | Envelope discriminator: true on success, false on any error. |
data | Present when ok is true — the accepted/credited result. |
error.code | Machine-readable error code, e.g. NO_CROSS_CHAIN_DEPOSITS, INVALID_ID, NO_MERCHANT_CONTEXT. |
error.message | Human-readable explanation of the error. |
200 {"ok":true,"data":{...}}— the deposit is accepted and credited.4xx {"ok":false,"error":{"code":"...","message":"..."}}— e.g.INVALID_ID,NO_MERCHANT_CONTEXT, or a domain code. On a payment with no wrong-currency deposit you get400 {"code":"NO_CROSS_CHAIN_DEPOSITS","message":"No cross-chain deposits detected on this payment"}.
See also
- Get a payment:
crossChainAutoAcceptAttells you a parked deposit is awaiting acceptance. - Webhooks & IPN: get notified when a wrong-currency deposit is detected or settled.
- Authentication: the role gate (
merchant_admin/super_admin) explained.