Cryptopay API
  • Welcome
  • Guides
    • Introduction
    • Environments
    • Creating a Test Account
    • API Credentials
    • API Basics
      • Responses
      • Date formats
      • Authentication
        • How it works
        • Signature
        • Creating a signature. Code samples
      • Callbacks
    • API Client Libraries
    • API Reference
    • Cryptocurrency Payments
    • Currencies
      • Supported Currencies
      • Currency Icons
    • Confirmations
    • Tools for accepting payments
    • Prebuilt integrations
      • E-commerce payment plugins
      • Payment and software providers
    • Channels
      • Channel payment
      • Payment statuses
      • Channel payment sequence
      • Create a Channel
      • Visual representation at Cashier
      • Channel hosted page
      • Channel payment callbacks
    • Invoices
      • Invoice statuses
      • Invoice payment sequence
      • How to handle unresolved invoices
        • Underpaid
        • Overpaid
        • Paid late
        • Illicit resource
        • Invoice refunds sequence
      • Create an invoice
      • Visual presentation at Cashier
      • Invoice hosted page
      • Online checkout
        • How-to
      • Payment links
      • Invoice callbacks
    • Payouts
      • Payout statuses
      • Payout sequence
      • Payout fees consideration
        • Network fees
      • Create a Coin Withdrawal
        • Possible errors
        • Withdrawals from fiat accounts
        • Withdrawals from cryptocurrency accounts
        • high_risk_address error message
      • Visual representation at Cashier
      • Minimum transaction amount
      • Coin Withdrawal callbacks
      • Travel Rule Compliance
    • Email Billing
      • Create an email billing
      • Email billing callbacks
    • Testing
      • Channels
      • Invoices
      • Payouts
    • Risks
    • Customers
    • Transactions types and Statuses
Powered by GitBook
On this page
  1. Guides
  2. Channels

Channel payment callbacks

PreviousChannel hosted pageNextInvoices

Last updated 6 months ago

Handling callbacks correctly is crucial to ensure your integration’s business logic works as expected. It is highly recommended to validate payment statuses and callbacks before acting on it inside your system.

Refer to to get more information on what callbacks are and how to validate them before acting on it inside your system.

Callback event

Description

created

A customer has just broadcast their transaction on the network

completed

The transaction has just been confirmed on the network. The channel payment status has been changed to completed

on_hold

refunded

The funds have been returned back to the sender

cancelled

The transaction was on the network but hasn't been confirmed within 14 days. The channel payment status has been changed to cancelled

{
  "type": "ChannelPayment",
  "event": "created",
  "data": {
    "id": "284d4b79-fea6-46ce-bc2f-0f9cbed6367e",
    "txid": "09723bf75253f3d2bf2f150fd8b5da5bc3026b95f1fe50b1f5f76f43d67a2e30",
    "address": "2N9uVK2MDFNgBVqPnvCTV66Dinx3cp5J7S4",
    "network": "bitcoin",
    "paid_amount": "0.02",
    "paid_currency": "BTC",
    "received_amount": "0.0",
    "received_currency": "EUR",
    "fee": "0.0",
    "fee_currency": "EUR",
    "status": "pending",
    "channel_id": "50eb5775-f77e-4c64-870b-dc93624b5967",
    "custom_id": "631044494",
    "customer_id": "customerID",
    "risk": {
      "score": 0.0,
      "level": "low",
      "resource_name": "Bitstamp",
      "resource_category": "Exchange"
    },
    "hosted_page_url": "https://business-hosted.cryptopay.me/channels/50eb5775-f77e-4c64-870b-dc93624b5967",
    "created_at": "2019-05-02T11:00:01+00:00"
  }
}
{
  "type": "ChannelPayment",
  "event": "completed",
  "data": {
    "id": "284d4b79-fea6-46ce-bc2f-0f9cbed6367e",
    "txid": "09723bf75253f3d2bf2f150fd8b5da5bc3026b95f1fe50b1f5f76f43d67a2e30",
    "address": "2N9uVK2MDFNgBVqPnvCTV66Dinx3cp5J7S4",
    "network": "bitcoin",
    "paid_amount": "0.02",
    "paid_currency": "BTC",
    "received_amount": "97.26",
    "received_currency": "EUR",
    "fee": "0.99",
    "fee_currency": "EUR",
    "exchange": {
      "fee": "0.0",
      "pair": "BTCEUR",
      "rate": "4912.8021",
      "fee_currency": "EUR"
    },
    "status": "completed",
    "channel_id": "50eb5775-f77e-4c64-870b-dc93624b5967",
    "custom_id": "631044494",
    "customer_id": "customerID",
    "risk": {
      "score": 0.0,
      "level": "low",
      "resource_name": "Bitstamp",
      "resource_category": "Exchange"
    },
    "hosted_page_url": "https://business-hosted.cryptopay.me/channels/50eb5775-f77e-4c64-870b-dc93624b5967",
    "created_at": "2019-05-02T11:00:01+00:00"
  }
}
{
  "type": "ChannelPayment",
  "event": "on_hold",
  "data": {
    "id": "284d4b79-fea6-46ce-bc2f-0f9cbed6367e",
    "txid": "09723bf75253f3d2bf2f150fd8b5da5bc3026b95f1fe50b1f5f76f43d67a2e30",
    "address": "2N9uVK2MDFNgBVqPnvCTV66Dinx3cp5J7S4",
    "network": "bitcoin",
    "paid_amount": "0.02",
    "paid_currency": "BTC",
    "received_amount": "0.0",
    "received_currency": "EUR",
    "fee": "0.0",
    "fee_currency": "EUR",
    "status": "on_hold",
    "status_context": "illicit_resource",
    "channel_id": "50eb5775-f77e-4c64-870b-dc93624b5967",
    "custom_id": "631044494",
    "customer_id": "customerID",
    "risk": {
      "score": 0.0,
      "level": "high",
      "resource_name": "Silk Road",
      "resource_category": "Dark Market - Centralised"
    },
    "hosted_page_url": "https://business-hosted.cryptopay.me/channels/50eb5775-f77e-4c64-870b-dc93624b5967",
    "created_at": "2019-05-02T11:00:01+00:00"
  }
}
{
  "type": "ChannelPayment",
  "event": "refunded",
  "data": {
    "id": "284d4b79-fea6-46ce-bc2f-0f9cbed6367e",
    "txid": "09723bf75253f3d2bf2f150fd8b5da5bc3026b95f1fe50b1f5f76f43d67a2e30",
    "address": "2N9uVK2MDFNgBVqPnvCTV66Dinx3cp5J7S4",
    "network": "bitcoin",
    "paid_amount": "0.02",
    "paid_currency": "BTC",
    "received_amount": "0.02",
    "received_currency": "BTC",
    "fee": "0.0",
    "fee_currency": "BTC",
    "status": "refunded",
    "channel_id": "50eb5775-f77e-4c64-870b-dc93624b5967",
    "custom_id": "631044494",
    "customer_id": "customerID",
    "refund_address": "2N4BGqUxiHDkfwscbxcaQ1VcQuo3xjFZRvJ",
    "risk": {
      "score": 0.0,
      "level": "high",
      "resource_name": "Silk Road",
      "resource_category": "Dark Market - Centralised"
    },
    "hosted_page_url": "https://business-hosted.cryptopay.me/channels/50eb5775-f77e-4c64-870b-dc93624b5967",
    "created_at": "2019-05-02T11:00:01+00:00"
  }
}
{
  "type": "ChannelPayment",
  "event": "cancelled",
  "data": {
    "id": "284d4b79-fea6-46ce-bc2f-0f9cbed6367e",
    "txid": "09723bf75253f3d2bf2f150fd8b5da5bc3026b95f1fe50b1f5f76f43d67a2e30",
    "address": "2N9uVK2MDFNgBVqPnvCTV66Dinx3cp5J7S4",
    "network": "bitcoin",
    "paid_amount": "0.02",
    "paid_currency": "BTC",
    "received_amount": "0.0",
    "received_currency": "EUR",
    "fee": "0.0",
    "fee_currency": "EUR",
    "status": "cancelled",
    "channel_id": "50eb5775-f77e-4c64-870b-dc93624b5967",
    "custom_id": "631044494",
    "customer_id": "customerID",
    "risk": {
      "score": 0.0,
      "level": "low",
      "resource_name": "Bitstamp",
      "resource_category": "Exchange"
    },
    "hosted_page_url": "https://business-hosted.cryptopay.me/channels/50eb5775-f77e-4c64-870b-dc93624b5967",
    "created_at": "2019-05-02T11:00:01+00:00"
  }
}

The received cryptocurrency transaction evaluated as High-Risk, therefore the Channel Payment transaction has been put on hold. Our Transaction Monitoring team will review this transaction to make a decision on whether we will be able to process this payment and add the funds to your merchant account balance or we will have to send the funds back to a sender. Refer to the section to get more details on what High-Risk transactions are and why we take it very seriously

this section
Risks