Withdraw (Batch)

Request withdrawal of funds

Withdraw cryptocurrency to any specified address

POST https://api.legranpay.io/v1/merchant/withdraws/batch-request

Headers

Name
Type
Description

X-MERCHANT-KEY*

String

You merchant key

X-MERCHANT-SIGNATURE*

String

You merchant secret key

Request Body

Name
Type
Description

withdrawals*

Array

Array of withdrawal

Success example
{
    "error": false,
    "data": {
        "uid": "28dc3cd5-9752-4ac2-b3db-b3ce47f2b7f9",
        "createdAt": 1687554178
    }
}
Failed example
{
    "error": true,
    "code": 1006,
    "message": "Withdrawal is not available with the indicated parameters. Check the currency and blockchain API for more details"
}
Request example
[
    {
        "currency": "BTC",
        "blockchain": "BITCOIN_REGTEST",
        "amount": "0.0025",
        "address": "bcrt1qktythmm0mr0k8k9lkz7t6t6nr06w94c5840ygt"
    },
    {
        "currency": "BTC",
        "blockchain": "BITCOIN_REGTEST",
        "amount": "0.0015",
        "address": "bcrt1qql4fya36lf03n33dm6z9x2pffjhm47ue24ws07",
        "validate": true
    }
]

Possible errors

  • 500

  • 1005

  • 1006

  • 1007

  • 1014

  • 1016

Last updated