Link

Webhooks

We able to send proxy-transaction-created and proxy-transaction-completed events to specified URL.

To configure webhooks for your proxy wallets please contact our account managers or support.

Required information:

webhookUrl: https://your-domain.com/webhook/path
secret: any-secret-string-for-signature-xxx123

Proxy transaction created

+ POST {webhookUrl}

+ Headers:
  X-Signature: 97dee97560699a639f3cf5...9ea463
  X-Timestamp: 1567165602271

+ Request
  {
    "event": "proxy-transaction-created",
    "eventId": "clientname-8101ad9fe79533d1c37f3cf05b66503f",
    "subscriptionId": "clientname",
    "payload": {
      "proxyTransactionId": "9275432",
      "txId": "0xdf5172cf525a7a8fb4a89845c4b9bc711e73158218f79316370",
      "status": "new",
      "currency": "USDT",
      "mainCurrency": "ETH",
      "value": "91300000",
      "proxyWalletId": "ckey1hhkf00...qj3-ETH-ETH",
      "organizationId": "ORG1",
      "txIndex": "87",
      "extra": {
        "inputTransaction": {
          "inputs": [
            {
              "address": "0x876eabf441b2234523452342a8e0600950cfa",
              "value": "91300000"
            }
          ],
          "outputs": [
            {
              "address": "0x030fba0b1b253452xdfgt234529552201cca",
              "value": "91300000",
              "txIndex": "87"
            }
          ],
          "txId": "0xdf5172cf525a7asdfg3452ertsert234bc711e73158218f79316370",
          "transactionType": "deposit",
          "blockHeight": "1084231",
          "isSuccess": true,
          "contractSuccess": true,
          "currency": "USDT",
          "mainCurrency": "ETH",
          "timestamp": "1600534561000",
          "_embedded": {}
        }
      }
    },
    "createdAt": "1600885395678"
  }

Proxy transaction completed

“status” maybe completed, or error if something went wrong

+ POST {webhookUrl}

+ Headers:
  X-Signature: 97dee97560699a639f3cf5...9ea463
  X-Timestamp: 1567165602271

+ Request
  {
    "eventId": "clientname-8f293325ebf3a2f00bf0be2425cee999",
    "event": "proxy-transaction-completed",
    "subscriptionId": "clientname",
    "payload": {
      "proxyTransactionId": "10072922",
      "txId": "ea175db252255cde2fce5b3fa8ca5a526d22fe5a1889f9f80732b939a5687efa",
      "value": "300000",
      "status": "completed",
      "currency": "BTC",
      "mainCurrency": "BTC",
      "proxyWalletId": "28a26c72-4d72-4f97-9b36-6811ab708216-BTC-BTC",
      "organizationId": "ORG1",
      "extra": {
        "txIndex": "0",
        "confirmations": "2",
        "inputTransaction": {
          "fee": "145",
          "txId": "ea175db252255cde2fce5b3fa8ca5a526d22fe5a1889f9f80732b939a5687efa",
          "inputs": [
            {
              "value": "6799336",
              "address": "tb1q8vxm608rz0ykn22ff2kyqdaade8l0czt32hjwr"
            }
          ],
          "outputs": [
            {
              "value": "300000",
              "address": "mu91guVU3UbcR7zhjAYVLhhQRx4ktr8kQ3",
              "txIndex": "0"
            },
            {
              "value": "6499191",
              "address": "2N9NL7iFxEyMSK5fF79pqqkXteYDXNzKMHw",
              "txIndex": "1"
            }
          ],
          "currency": "BTC",
          "isSuccess": true,
          "timestamp": "1601015276000",
          "blockHeight": "1835948",
          "mainCurrency": "BTC"
        },
        "proxyTransaction": {
          "fee": "192",
          "txId": "db447954abec5f35fc5c1d0534c8e80c2f050803b31b238f9c931e20ea109ccf",
          "inputs": [
            {
              "value": "300000",
              "address": "mu91guVU3UbcR7zhjAYVLhhQRx4ktr8kQ3"
            }
          ],
          "outputs": [
            {
              "value": "299808",
              "address": "muwePWuEDoJPY5WS4PjR7TurGueyBT53ZD",
              "txIndex": "0"
            }
          ],
          "currency": "BTC",
          "isSuccess": true,
          "timestamp": "1601015276000",
          "blockHeight": "1835948",
          "mainCurrency": "BTC"
        }
      }
    },
    "createdAt": "1601016495134"
  }

Check request signature

You can calculate and verify request signature.

X-Signature header is hmac sha256 hash in hex format.

Example:

echo -n "${timestamp}${eventId}${body}" | openssl dgst -sha256 -hmac ${secretKey}

Where ${timestamp} you can get from X-Timestamp header.