### Deposit Callback Payload Examples Source: https://docs.cryptoprocessing.com/api-reference/callbacks/deposit-callbacks Provides examples of deposit callback payloads for different states, such as 'Confirmed'. ```APIDOC ## Deposit Callback Payload Examples ### Confirmed Deposit Callback Sent when a deposit has been successfully confirmed and can be treated as final on your side. At this stage, it is safe to perform business actions such as crediting the customer’s balance. ```json { "id": 1, "end_user_reference": "12345", "type": "deposit", "crypto_address": { "id": 1 } } ``` ``` -------------------------------- ### Callback Processing Example Source: https://docs.cryptoprocessing.com/integration-guide/withdrawals This example illustrates how to process the callback received from CryptoProcessing after a withdrawal has been successfully processed. This is crucial for updating your system's state. ```javascript sx(_components.span, { style: { color: "#0A3069", "--shiki-dark": "#CE9178" }, children: "\"BTC\"" }) }), "\n", _jsx(_components.span, { className: "line", children: _jsx(_components.span, { style: { color: "#1F2328", "--shiki-dark": "#D4D4D4" }, children: " }" }) }), "\n", _jsx(_components.span, { className: "line", children: _jsx(_components.span, { style: { color: "#1F2328", "--shiki-dark": "#D4D4D4" }, children: "}" }) }), "\n"] }) }) }) }) }), "\n"], }) }) }) }), "\n"], }) }) }), _jsx(Step, { title: "Process the callback", children: _jsxs(_components.p, { children: ["Once the withdrawal is processed, CryptoProcessing will send you a ", _jsx(_components.a, { href: "/api-reference/callbacks#withdraw-eur-with-exchange-to-btc", children: "callback" }), "."] }) })] }); } ``` -------------------------------- ### Deposit Callback Payload Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/deposit-callbacks This example shows the structure of a typical deposit callback payload. It includes details about the transaction, user, and currency involved. ```json { "data": { "transaction": { "id": 328, "end_user_reference": "12345", "type": "deposit_exchange", "crypto_address": { "id": 382270, "currency": "BTC", "convert_to": "EUR", "address": "39mFf3X46YzUtfdwVQpYXPCMydc74ccbAZ" } } } } ``` -------------------------------- ### Withdrawal Response Example Source: https://docs.cryptoprocessing.com/integration-guide/withdrawals Example of a successful response after initiating a withdrawal request. ```json { "amount": "25.00", "currency": "EUR", "address": "tb1qjv8alc7c708tddm9nrdtpwm5xna30fgkql5vgs", "foreign_id": "user_12345", "status": "success", "withdrawal_id": "wd_12345", "created_at": "2023-01-01T12:00:00Z", "updated_at": "2023-01-01T12:00:00Z" } ``` -------------------------------- ### Deposit Callback with Conversion Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/deposit-callbacks This example shows the deposit callback payload when funds are received and automatically converted to a different currency before being credited. It includes the `convert_to` field. ```APIDOC ## Deposit Callback with Conversion Example ### Description This example shows the deposit callback payload when funds are received and automatically converted to a different currency before being credited. It includes the `convert_to` field. ### Method POST (Callback) ### Endpoint `/your-callback-endpoint` ### Parameters #### Request Body - **deposit** (object) - Required - Details of the deposit. - **currency** (string) - Required - The currency of the deposit (e.g., "BTC"). - **amount** (string) - Required - The amount of the deposit in the original currency (e.g., "0.01959472"). - **convert_to** (string) - Required - The currency to which the deposit was converted (e.g., "USD"). - **amount_converted** (string) - Required - The amount after conversion (e.g., "500.00"). - **status** (string) - Required - The status of the deposit (e.g., "confirmed"). ### Request Example ```json { "deposit": { "currency": "BTC", "amount": "0.01959472", "convert_to": "USD", "amount_converted": "500.00", "status": "confirmed" } } ``` ### Response #### Success Response (200 OK) - The callback endpoint should return a 200 OK status to acknowledge receipt of the callback. #### Response Example ```json { "message": "Callback received successfully" } ``` ``` -------------------------------- ### Withdrawal Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This example demonstrates the structure of a withdrawal callback, including details on confirmations and fees. It is used to notify your system about the status of a withdrawal. ```json { "type": "withdrawal", "data": { "confirmations": "0", "fees": [ { "type": "mining", "currency": "BTC", "amount": "0" } ] } } ``` -------------------------------- ### Verify Implementation Example (JSON) Source: https://docs.cryptoprocessing.com/api-reference/authentication Generate a signature for the provided JSON body using 'AbCdEfG123456' as the secret key. This example demonstrates the expected input format for signature generation. ```json {\"currency\":\"BTC\", \"foreign_id\":\"123456\"} ``` -------------------------------- ### Exchange Response Example Source: https://docs.cryptoprocessing.com/api-reference/endpoints/exchange-now This is an example of a successful response after initiating an exchange. It includes details about the transaction, such as sender and receiver amounts, fees, the exchange rate, and the transaction status. ```JSON { "data": { "sender_currency": "BTC", "sender_amount": "0.00300000", "receiver_currency": "EUR", "receiver_amount": "231.94279333", "fee_currency": "BTC", "fee_amount": "0.00015000", "price": "77314.26444333", "id": 134704200, "foreign_id": "test_foreign_id_0319", "type": "exchange", "status": "processing" } } ``` -------------------------------- ### Deposit Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/deposit-callbacks This is an example of a deposit callback payload when funds are received directly into a configured address. It includes details about the transaction, currency, amount, and status. ```APIDOC ## Deposit Callback Example ### Description This is an example of a deposit callback payload when funds are received directly into a configured address. It includes details about the transaction, currency, amount, and status. ### Method POST (Callback) ### Endpoint `/your-callback-endpoint` ### Request Body - **deposit** (object) - Required - Details of the deposit. - **currency** (string) - Required - The currency of the deposit (e.g., "BTC"). - **amount** (string) - Required - The amount of the deposit (e.g., "0.01959472"). - **error** (string) - Optional - Any error message associated with the deposit. - **status** (string) - Required - The status of the deposit (e.g., "confirmed"). ### Request Example ```json { "deposit": { "currency": "BTC", "amount": "0.01959472", "error": "", "status": "confirmed" } } ``` ### Response #### Success Response (200 OK) - The callback endpoint should return a 200 OK status to acknowledge receipt of the callback. #### Response Example ```json { "message": "Callback received successfully" } ``` ``` -------------------------------- ### System Health Data Example Source: https://docs.cryptoprocessing.com/api-reference/endpoints/addresses-take Provides an example of the data structure returned for system health checks, including address and currency details. ```json { "data": { "id": 240407213, "currency": "BTC", "address": "tb1qfdxh6gkfr0qgyatnlkd8khcnxph9tw06n6qwjc", "tag": null, "foreign_id": "test_foreign_id", "end_user_reference": "test_end_user_reference" } } ``` -------------------------------- ### Deposit Address Response Example Source: https://docs.cryptoprocessing.com/integration-guide/deposits This is an example of a successful response when requesting a deposit address. It includes the generated address, currency, and user references. ```json { "data": { "id": 23553829, "currency": "BTC", "convert_to": "EUR", "address": "2NFZ9SmEm3mQ7jqVF4vPXBwCyn9KpmEwkTj", "tag": null, "foreign_id": "user_12345", "end_user_reference": "user_12345" } } ``` -------------------------------- ### Invoice Payment Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/invoice-payment-callbacks This example demonstrates the structure of a callback received when an invoice payment is processed. It includes details about the invoice, payment, and associated transactions. ```json { "invoice_id": 1504, "currency": "EUR", "amount": "214.00000000", "transactions": [ { "id": 1504, "currency": "BTC", "transaction_type": "blockchain", "type": "deposit", "address": ``` -------------------------------- ### Deposit Callback Payload Examples Source: https://docs.cryptoprocessing.com/api-reference/callbacks/deposit-callbacks Examples of deposit callback payloads for different confirmation statuses. Use these to understand the data structure for integrating with your system. ```json { "id": 1, "end_user_reference": "12345", "type": "deposit", "crypto_address": { "id": 1, "address": "1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa", "currency": { "code": "BTC", "name": "Bitcoin" } }, "currency_sent": { "code": "BTC", "amount": "0.001" }, "currency_received": { "code": "USD", "amount": "50.00", "amount_minus_fee": "49.50" }, "status": "confirmed", "created_at": "2023-01-01T12:00:00Z", "updated_at": "2023-01-01T12:05:00Z" } ``` ```json { "id": 2, "end_user_reference": "67890", "type": "deposit", "crypto_address": { "id": 2, "address": "bc1qar0srrr7xfkvy5l643lydnw9re59gtzzwf5mdq", "currency": { "code": "BTC", "name": "Bitcoin" } }, "currency_sent": { "code": "BTC", "amount": "0.005" }, "currency_received": { "code": "USD", "amount": "250.00", "amount_minus_fee": "247.50" }, "status": "pending", "created_at": "2023-01-01T13:00:00Z", "updated_at": "2023-01-01T13:01:00Z" } ``` -------------------------------- ### Withdrawal Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This is an example of a withdrawal callback event, showing the structure of the data received when a withdrawal is confirmed. ```APIDOC ## Withdrawal Callback ### Description Callback sent when a withdrawal has been successfully completed and can be treated as final. ### Type withdrawal ### Fields - **id** (integer) - The unique identifier of the withdrawal operation. - **foreign_id** (string) - An external identifier for the operation. - **end_user_reference** (string) - Identifier for the customer who received the funds. - **type** (string) - The type of operation, always "withdrawal". - **crypto_address** (object) - Details of the cryptocurrency address involved. - **id** (integer) - The ID of the crypto address. - **currency** (string) - The currency of the address (e.g., "BTC"). - **address** (string) - The cryptocurrency address. - **tag** (string | null) - The tag associated with the address, if any. - **transactions** (array) - A list of transactions associated with the withdrawal. - **id** (integer) - The ID of the transaction. - **currency** (string) - The currency of the transaction. - **transaction_type** (string) - The type of transaction (e.g., "blockchain"). - **type** (string) - The type of operation, always "withdrawal". - **address** (string) - The recipient address for the transaction. - **tag** (string | null) - The tag associated with the address, if any. - **amount** (string) - The amount of cryptocurrency transferred. - **txid** (string) - The transaction ID on the blockchain. - **confirmations** (string) - The number of confirmations for the transaction. - **fees** (array) - A list of fees associated with the withdrawal (empty in this example). ### Response Example ```json { "id": 123, "foreign_id": "operation_987", "end_user_reference": "user_12345", "type": "withdrawal", "crypto_address": { "id": 123, "currency": "BTC", "address": "tb1qurv0m4ufsj8xqejvmn0y43kqew33kvqrrxswgm", "tag": null }, "transactions": [ { "id": 999, "currency": "BTC", "transaction_type": "blockchain", "type": "withdrawal", "address": "tb1qurv0m4ufsj8xqejvmn0y43kqew33kvqrrxswgm", "tag": null, "amount": "0.01000000", "txid": "bb040d895ef7141ea0b06b04227d8f5dd4ee12d5b890e6e5633f6439393a666b", "confirmations": "0" } ], "fees": [] } ``` ``` -------------------------------- ### Invoice Payment Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/invoice-payment-callbacks This example demonstrates the structure of a typical invoice payment callback. It includes details such as amount, transaction ID, confirmations, and fee information. ```json { "amount": "0.01000000", "txid": "528dcda13270f8590853405600bf5634d53aa66d2ce5d3a873006a670f9da788", "confirmations": "1", "fees": [ { "type": "fee_crypto_deposit", "currency": "BTC", "amount": "0.0008" } ] } ``` -------------------------------- ### Withdraw BTC Request Example Source: https://docs.cryptoprocessing.com/api-reference/endpoints/crypto-withdrawal-instant This snippet shows an example of a cURL request to initiate an instant withdrawal of BTC. It includes sender and receiver information required for compliance with regulations like MiCA. ```bash curl -X POST https://api.cryptoprocessing.com/v1/withdrawals/crypto/instant \ -H "Authorization: Token " \ --header 'X-Processing-Signature: ' --data ' { "sender_currency": "BTC", "sender_amount": "0.00020000", "address": "tb1qfdxh6gkfr0qgyatnlkd8khcnxph9tw06n6qwjc", "foreign_id": "withdrawal_123", "end_user_reference": "user_12345", "sender_type": "legal", "sender_data": { "legal_name": "Example GmbH", "country_of_registration": "DEU" }, "receiver_type": "natural", "receiver_data": { "first_name": "Friedrich", "last_name": "Müller", "date_of_birth": "1995-08-17" } } ' ``` -------------------------------- ### Withdrawal Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This example demonstrates the JSON payload received for a completed withdrawal callback. It includes details such as the withdrawal ID, currency, amount, status, and any associated error messages. ```APIDOC ## Withdrawal Callback Example ### Description This example shows the structure of a withdrawal callback notification. ### Method POST (typically, to your webhook URL) ### Endpoint `YOUR_WEBHOOK_URL` ### Request Body - **id** (integer) - The unique identifier for the withdrawal. - **type** (string) - The type of event, e.g., `fee_crypto_withdrawal_from_fiat`. - **currency** (string) - The currency of the withdrawal (e.g., BTC). - **amount** (string) - The amount of the withdrawal. - **error** (string) - Any error message associated with the withdrawal. Empty if successful. - **status** (string) - The current status of the withdrawal (e.g., `confirmed`). ### Request Example ```json { "id": 123, "type": "fee_crypto_withdrawal_from_fiat", "currency": "BTC", "amount": "0.00028735", "error": "", "status": "confirmed" } ``` ### Response (Typically, your webhook should return a 200 OK to acknowledge receipt) #### Success Response (200 OK) An empty response or a simple acknowledgment is usually sufficient. ``` -------------------------------- ### Withdrawal Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This example demonstrates the structure of a withdrawal callback received by your server. It includes details about the withdrawal, such as the destination address, amount, transaction ID (if available), and any errors that occurred. ```json { "address": "tb1qurv0m4ufsj8xqejvmn0y43kqew33kvqrrxswgm", "tag": null, "amount": "0.01000000", "txid": null, "confirmations": "0", "fees": [], "error": "Declined by user ID:777" } ``` -------------------------------- ### Withdrawal Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This example demonstrates the structure of a withdrawal callback payload, including details like address, tag, amount, txid, confirmations, fees, error, and status. ```json { "address": "tb1qurv0m4ufsj8xqejvmn0y43kqew33kvqrrxswgm", "tag": null, "amount": "0.01000000", "txid": null, "confirmations": "0", "fees": [], "error": "", "status": "unconfirmed" } ``` -------------------------------- ### Withdrawal Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This example demonstrates the structure of a withdrawal callback payload. It includes details such as the withdrawal type, address, amount, transaction ID, and confirmations. ```json { "type": "withdrawal", "address": "tb1qurv0m4ufsj8xqejvmn0y43kqew33kvqrrxswgm", "tag": null, "amount": "0.01000000", "txid": null, "confirmations": "0" } ``` -------------------------------- ### Invoice Payment Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/invoice-payment-callbacks This example demonstrates the structure of a callback received when an invoice payment is processed. It includes details about the payment, fees, currency, amount, and any associated errors or status updates. ```json { "data": { "id": "inv_xxxxxxxxxxxxxxxx", "order_id": "order_xxxxxxxxxxxxxxxx", "address": "bc1qxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "amount": "0.0008", "currency": "BTC", "type": "invoice", "status": "paid", "created_at": "2023-10-27T10:00:00Z", "updated_at": "2023-10-27T10:05:00Z", "url": "https://cryptoprocessing.com/pay/inv_xxxxxxxxxxxxxxxx", "from": "1A1oP9oV8V5x1f2g3h4i5j6k7l8m9n0o", "to": "bc1qxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "transaction_hash": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "fee_crypto_deposit": [ { "type": "fee_crypto_deposit", "currency": "BTC", "amount": "0.0008" } ], "error": null, "status": "paid" } } ``` -------------------------------- ### Account Balances Response Example Source: https://docs.cryptoprocessing.com/api-reference/endpoints/accounts-list This is a basic example of the JSON response structure when listing account balances. It shows balances for both cryptocurrency (BTC) and fiat (EUR) types. ```json { "data": [ { "currency": "BTC", "type": "crypto", "balance": "0.04" }, { "currency": "EUR", "type": "fiat", "balance": "10000" } ] } ``` -------------------------------- ### Invoice Payment Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/invoice-payment-callbacks This example demonstrates the structure of a callback received when an invoice payment is processed. It includes details like ID, currency, transaction type, address, and amount. ```json { "id": 1505, "currency": "BTC", "transaction_type": "blockchain", "type": "deposit", "address": "2NCfH4keMq2SZj3H73VeQYtb8yBgTuUrACf", "tag": null, "amount": "0.00010000", "txid": "" ``` -------------------------------- ### Invoice Payment Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/invoice-payment-callbacks This example demonstrates the structure of a typical invoice payment callback. It includes details such as transaction type, address, amount, and transaction ID. ```json { "currency": "BTC", "transaction_type": "blockchain", "type": "deposit", "address": "2NCfH4keMq2SZj3H73VeQYtb8yBgTuUrACf", "tag": null, "amount": "0.00010000", "txid": "6dd68265eb2b3a1be0dd4a40975345155d0fbbe244c84efcc7f6b910629a38f9", "confirmations": "0" } ``` -------------------------------- ### Invoice Payment Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/invoice-payment-callbacks This example demonstrates the structure of a typical invoice payment callback. It includes details such as remaining amount, currency, and transaction information. This is useful for verifying payment status and updating your records. ```json { "payment_id": "pi_3Nf4a4L3f7L3f7L3f7L3f7L3f7", "invoice_id": "inv_3Nf4a4L3f7L3f7L3f7L3f7L3f7", "status": "paid", "amount": "0.02000000", "remaining_amount": "0.00000000", "currency_received": { "currency": "BTC", "amount": "0.02000000" }, "transactions": [ { "id": "750294", "currency": "BTC" } ] } ``` -------------------------------- ### Withdrawal Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This example demonstrates the structure of a withdrawal callback payload when a withdrawal is declined. It includes details such as the tag, amount, transaction ID, confirmations, any error message, and the final status. ```APIDOC ## Withdrawal Callback Example ### Description This example demonstrates the structure of a withdrawal callback payload when a withdrawal is declined. It includes details such as the tag, amount, transaction ID, confirmations, any error message, and the final status. ### Response Example ```json { "tag": "tb1qurv0m4ufsj8xqejvmn0y43kqew33kvqrrxswgm", "amount": "0.01000000", "txid": null, "confirmations": "0", "fees": [], "error": "Declined by user ID:777", "status": "declined" } ``` ``` -------------------------------- ### Withdrawal Request Response Example Source: https://docs.cryptoprocessing.com/integration-guide/withdrawals This is an example of a successful response when requesting a withdrawal with currency exchange. ```JSON { "data": { "id": 132512382, "foreign_id": "user_12345", "end_user_reference": "user_12345", "type": "withdrawal_exchange", "status": "processing", "amount": "25.00000000", "sender_amount": "25.00000000", "sender_currency": "EUR", "receiver_currency": "BTC" } } ``` -------------------------------- ### GET /transactions/info Source: https://docs.cryptoprocessing.com/getting-started/manage-user-permissions Get transaction details by `id`, `foreign_id`, or `txid`. Include only one of these parameters in your request. ```APIDOC ## GET /transactions/info ### Description Get transaction details by `id`, `foreign_id`, or `txid`. Include only one of these parameters in your request. ### Method GET ### Endpoint /transactions/info ### Parameters #### Query Parameters - **id** (string) - Optional - The ID of the transaction. - **foreign_id** (string) - Optional - The foreign ID of the transaction. - **txid** (string) - Optional - The transaction ID (txid). ### Request Body This endpoint does not explicitly define a request body in the provided documentation. ### Response #### Success Response (200) Details of the response are not provided in the source text. #### Response Example No example provided in the source text. ``` -------------------------------- ### Generate BTC Deposit Address Source: https://docs.cryptoprocessing.com/api-reference/endpoints/addresses-take This example demonstrates how to generate a new Bitcoin (BTC) deposit address for a user. It includes the necessary headers and a sample request body. ```APIDOC ## POST /api/v2/addresses/take ### Description Generates a deposit address for a user. ### Method POST ### Endpoint /api/v2/addresses/take ### Parameters #### Request Body - **currency** (string) - Required - The currency for which to generate an address (e.g., "BTC"). - **foreign_id** (string) - Required - A unique identifier for the transaction or user. - **end_user_reference** (string) - Optional - A reference to the end user. - **sender_type** (string) - Optional - The type of sender (e.g., "legal"). - **sender_data** (object) - Optional - Data related to the sender. - **legal_name** (string) - Required if sender_type is "legal" - The legal name of the sender. - **country_of_registration** (string) - Required if sender_type is "legal" - The country of registration. ### Request Example ```json { "currency": "BTC", "foreign_id": "test_foreign_id", "end_user_reference": "test_end_user_reference", "sender_type": "legal", "sender_data": { "legal_name": "Example GmbH", "country_of_registration": "DEU" } } ``` ### Response #### Success Response (201) - **data** (object) - Contains the details of the generated address. - **id** (integer) - The internal ID of the address. - **currency** (string) - The currency of the address. - **address** (string) - The generated deposit address. - **tag** (string|null) - The tag associated with the address, if any. - **foreign_id** (string) - The foreign ID provided in the request. - **end_user_reference** (string) - The end user reference provided in the request. #### Response Example ```json { "data": { "id": 240407213, "currency": "BTC", "address": "tb1qfdxh6gkfr0qgyatnlkd8khcnxph9tw06n6qwjc", "tag": null, "foreign_id": "test_foreign_id", "end_user_reference": "test_end_user_reference" } } ``` ``` -------------------------------- ### Get a fixed exchange quote Source: https://docs.cryptoprocessing.com/api-reference/authentication Get a fixed exchange quote for a specific amount, which can then be used with [/exchange/fixed](/api-reference/endpoints/exchange-fixed). ```APIDOC ## POST /exchange/calculate ### Description Get a fixed exchange quote for a specific amount, which can then be used with [/exchange/fixed](/api-reference/endpoints/exchange-fixed). ### Method POST ### Endpoint /exchange/calculate ### Response #### Success Response (200) - **field1** (type) - Description ``` -------------------------------- ### Withdrawal Callback Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This is a general example of a withdrawal callback. It includes fields like id, foreign_id, amount, error, and status. ```json { "id": 123, "foreign_id": "operation_987", "amount": "0.00028735", "error": "", "status": "confirmed" } ``` -------------------------------- ### Example of Cross-Currency Transaction Configuration Source: https://docs.cryptoprocessing.com/getting-started/cross-currency This snippet shows a configuration for a cross-currency transaction, including details about the variant and feature enablement. It's useful for understanding how different features are managed. ```json {\"name\": \"cross-currency\", \"enabled\": true, \"variant\": {\"name\": \"disabled\", \"enabled\": false, \"feature_enabled\": true}, \"impressionData\": false} ``` -------------------------------- ### Exchange Callback Payload Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/exchange-callbacks An example of a callback payload for a confirmed exchange, showing the structure of the notification received when an exchange is successfully completed. ```APIDOC ## Exchange Callback Payload Example This section provides an example of the JSON payload received for a confirmed exchange. ### Response Example ```json { "id": 134782394, "type": "exchange", "currency_sent": { "currency": "BTC", "amount": "0.00010000" }, "currency_received": { "currency": "USD", "amount": "2.50000000" }, "status": "confirmed", "created_at": "2023-10-26T10:00:00Z", "updated_at": "2023-10-26T10:05:00Z" } ``` ``` -------------------------------- ### Application Configuration Object Source: https://docs.cryptoprocessing.com/reference/get-your-api-key This JSON-like structure represents the configuration object for bootstrapping an application. It includes settings for application ID, auto-bootstrapping, user authentication, subdomain details, Git source information, and feature entitlements. This configuration is essential for initializing the application with the correct parameters and features. ```json ["$","$L20",null,{"appId":"$undefined","autoBoot":true,"children":["$","$L21",null,{"value":{"auth":"$undefined","userAuth":"$undefined"},"children":["$","$L22",null,{"value":{"subdomain":"cryptoprocessing","actualSubdomain":"cryptoprocessing","gitSource":{"type":"github","owner":"c-docs-migration","repo":"mintlify-docs","deployBranch":"main","contentDirectory":"","isPrivate":true},"inkeep":"$undefined","chroma":{"liveDeploymentHistoryId":"6a197576cb133d7846d2a015","collectionId":"27fdf8d7-774d-4a0f-ac03-a2393b956840"},"feedback":{"thumbs":true},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6a197576cb133d7846d2a015:success","clientVersion":"0.0.2986","preview":"$undefined","searchFilterCounts":[{"language":"default","tag":"Guides","count":32},{"language":"default","tag":"API reference","count":23},{"language":"default","tag":"Reference","count":15},{"language":"default","tag":"Product overview","count":13},{"language":"default","tag":"Integration guide","count":7},{"language":"default","tag":"Plugin integrations","count":6},{"language":"default","tag":"Callbacks","count":4},{"language":"default","tag":"Deposits & withdrawals","count":4},{"language":"default","tag":"Exchange","count":3},{"language":"default","tag":"Crypto withdrawals","count":3}]},"children":["$","$L23",null,{"value":{"docsConfig":{"theme":"palm","$schema":"https://mintlify.com/docs.json","name":"CryptoProcessing","colors":{"primary":"#16A34A","light":"#07C983","dark":"#15803D"},"logo":{"light":"https://mintcdn.com/cryptoprocessing/a6YDXhedL41XzYVq/logo/CRPR_logo_light_40.svg?fit=max&auto=format&n=a6YDXhedL41XzYVq&q=85&s=6356b1df206211aa3a4cfe310d6641a8","dark":"https://mintcdn.com/cryptoprocessing/a6YDXhedL41XzYVq/logo/CRPR_logo_dark_40.svg?fit=max&auto=format&n=a6YDXhedL41XzYVq&q=85&s=1a66f47d53c1644df077c2d4ba01a069"},"favicon":"https://mintcdn.com/cryptoprocessing/a6YDXhedL41XzYVq/favicon.png?fit=max&auto=format&n=a6YDXhedL41XzYVq&q=85&s=f8a027e8d46dd18b7682a2088b6bdfe9"},"api":{"playground":{"display":"simple"}}},"navbar":{"links":[{"href":"mailto:support@cryptoprocessing.com","label":"Support"}]},"primary":{"type":"button","label":"Dashboard","href":"https://cryptoprocessing.com"}},"navigation":{"global":{"anchors":[{"anchor":"Supported currencies","icon":"coins","href":"/introduction/supported-currencies"},{"anchor":"Supported trading pairs","icon":"left-right","href":"/introduction/supported-trading-pairs"},{"anchor":"Confirmations and limits","icon":"info","href":"/reference/confirmations-and-limits"}]},"tabs":[{"tab":"Guides","groups":[{"group":"Integration guide","pages":["index","integration-guide/checklist",{"group":"Crypto deposits","root":"integration-guide/deposits","pages":["integration-guide/deposits/design-payment-form","integration-guide/deposits/test-cases"]},{"group":"Crypto withdrawals","root":"integration-guide/withdrawals","pages":["integration-guide/withdrawals/design-withdrawal-form","integration-guide/withdrawals/instant"]}]}]}]}}}]}]}]}] ``` -------------------------------- ### Install Joomla CryptoProcessing by CoinsPaid Plugin Source: https://docs.cryptoprocessing.com/llms-full.txt Install the CryptoProcessing by CoinsPaid plugin in Joomla. Upload the plugin package file through the Joomla administration panel. ```php composer require : ``` -------------------------------- ### Withdraw BTC with conversion from EUR Source: https://docs.cryptoprocessing.com/api-reference/endpoints/crypto-withdrawal-instant-exchange This example demonstrates how to withdraw BTC by converting from EUR using the instant exchange feature. It includes sender and receiver details, amounts, and an address for the withdrawal. ```APIDOC ## POST /api/v2/crypto/withdrawal_instant_exchange ### Description Initiates an instant withdrawal with conversion from a cryptocurrency or fiat balance to a cryptocurrency. ### Method POST ### Endpoint /api/v2/crypto/withdrawal_instant_exchange ### Parameters #### Request Body - **sender_currency** (string) - Required - The currency of the sender's balance (e.g., EUR). - **received_currency** (string) - Required - The cryptocurrency to be received (e.g., BTC). - **sender_amount** (string) - Required - The amount to be sent from the sender's balance. - **address** (string) - Required - The destination address for the cryptocurrency withdrawal. - **foreign_id** (string) - Required - A unique identifier for the withdrawal transaction. - **end_user_reference** (string) - Optional - A reference to the end user. - **sender_type** (string) - Required - The type of the sender ('natural' or 'legal'). - **sender_data** (object) - Required - Data specific to the sender type. - **legal_name** (string) - Required if sender_type is 'legal' - The legal name of the entity. - **country_of_registration** (string) - Required if sender_type is 'legal' - The country of registration. - **receiver_type** (string) - Required - The type of the receiver ('natural' or 'legal'). - **receiver_data** (object) - Required - Data specific to the receiver type. - **first_name** (string) - Required if receiver_type is 'natural' - The first name of the receiver. - **last_name** (string) - Required if receiver_type is 'natural' - The last name of the receiver. - **date_of_birth** (string) - Required if receiver_type is 'natural' - The date of birth of the receiver in YYYY-MM-DD format. ### Request Example ```json { "sender_currency": "EUR", "received_currency": "BTC", "sender_amount": "100", "address": "tb1qfdxh6gkfr0qgyatnlkd8khcnxph9tw06n6qwjc", "foreign_id": "withdrawal_123", "end_user_reference": "user_12345", "sender_type": "legal", "sender_data": { "legal_name": "Example GmbH", "country_of_registration": "DEU" }, "receiver_type": "natural", "receiver_data": { "first_name": "Friedrich", "last_name": "Müller", "date_of_birth": "1995-08-17" } } ``` ### Response #### Success Response (201) - **data** (object) - Contains details of the withdrawal. - **id** (integer) - The unique identifier of the withdrawal. - **foreign_id** (string) - The identifier provided in the request. - **end_user_reference** (string) - The end user reference provided in the request. - **type** (string) - The type of the transaction. - **status** (string) - The current status of the withdrawal (e.g., 'processing'). - **sender_currency** (string) - The currency of the sender. - **sender_amount** (string) - The amount sent from the sender's balance. - **received_currency** (string) - The currency received. - **received_amount** (string) - The amount received. #### Response Example ```json { "data": { "id": 134702815, "foreign_id": "withdrawal_123", "end_user_reference": "user_12345", "type": "withdrawal_instant_exchange", "status": "processing", "sender_currency": "EUR", "sender_amount": "100.00000000", "received_currency": "BTC", "received_amount": "0.00153827" } } ``` ``` -------------------------------- ### Install Drupal Coinspaid Commerce Payment Gateway Source: https://docs.cryptoprocessing.com/llms-full.txt Install the Coinspaid Commerce Payment Gateway module in Drupal. Ensure you have downloaded the module from the extension page. ```bash php bin/magento setup:upgrade ``` -------------------------------- ### Withdrawal Callback Payload Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks This example shows the JSON payload received for a successful blockchain withdrawal. It includes details such as transaction ID, currency, address, and amount. ```json { "id": "999", "currency": "BTC", "transaction_type": "blockchain", "type": "withdrawal", "address": "tb1qurv0m4ufsj8xqejvmn0y43kqew33kvqrrxswgm", "tag": null, "amount": "0.01000000", "txid": "a1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcd" } ``` -------------------------------- ### Withdrawal Callback System Health Example Source: https://docs.cryptoprocessing.com/api-reference/callbacks/withdrawal-callbacks Illustrates a system health callback for a withdrawal, indicating an 'error' due to insufficient funds. ```json span, { className: "line line-highlight", children: [ _jsx(_components.span, { style: { color: "#116329", "--shiki-dark": "#9CDCFE" }, children: " \"error\"" }), _jsx(_components.span, { style: { color: "#1F2328", "--shiki-dark": "#D4D4D4" }, children: ": " }), _jsx(_components.span, { style: { color: "#0A3069", "--shiki-dark": "#CE9178" }, children: "\"Not enough money on balance\"" }), _jsx(_components.span, { style: { color: "#1F2328", "--shiki-dark": "#D4D4D4" }, children: "," }) ] }), "\n", _jsxs(_components.span, { className: "line line-highlight", children: [ _jsx(_components.span, { style: { color: "#116329", "--shiki-dark": "#9CDCFE" }, children: " \"status\"" }), _jsx(_components.span, { style: { color: "#1F2328", "--shiki-dark": "#D4D4D4" }, children: ": " }), _jsx(_components.span, { style: { color: "#0A3069", "--shiki-dark": "#CE9178" }, children: "\"cancelled\"" }) ] }), "\n", _jsx(_components.span, { className: "line", children: _jsx(_components.span, { style: { color: "#1F2328", "--shiki-dark": "#D4D4D4" }, children: "}" }) }), "\n" ] }) ``` -------------------------------- ### Example JSON body for signature generation Source: https://docs.cryptoprocessing.com/llms-full.txt This is an example JSON body that can be used to generate an HMAC-SHA512 signature for API authentication. Ensure the JSON string is exact and not reformatted. ```json {"currency":"BTC","foreign_id":"123456"} ``` -------------------------------- ### Invoice Payment Callback Structure Source: https://docs.cryptoprocessing.com/api-reference/callbacks/invoice-payment-callbacks This example shows the structure of a typical invoice payment callback. It includes details about the currency, address, and payment amounts. ```json { "convert_to": "EUR", "address": "2N8pvnVKEFjVCP4TteJVCPTbg9Aqibfws8C", "tag": null, "currency_sent": { "currency": "BTC", "amount": "0.00309556", "remaining_amount": "0.00000000" }, "currency_received": null } ``` -------------------------------- ### Instant Withdrawal with Conversion Callback Source: https://docs.cryptoprocessing.com/integration-guide/withdrawals/test-cases This test case outlines the expected callback for an instant withdrawal that includes currency conversion. It details the 'withdrawal_instant_exchange' callback and the meaning of 'currency_sent' and 'currency_received'. ```text The site gets a withdrawal_instant_exchange callback. The callback status is confirmed. currency_sent describes the amount you sent (minus the network fee). Its currency is the same as you specified in sender_currency. currency_received describes the amount you received on your balance. Its currency is the same as you specified in received_currency. ``` -------------------------------- ### Expected HMAC-SHA512 signature for example JSON Source: https://docs.cryptoprocessing.com/llms-full.txt This is the expected lowercase hexadecimal HMAC-SHA512 signature for the provided example JSON body and secret key. This signature should be sent in the X-Processing-Signature header. ```text 03c25fcf7cd35e7d995e402cd5d51edd72d48e1471e865907967809a0c189ba55b90815f20e2bb10f82c7a9e9d865546fda58989c2ae9e8e2ff7bc29195fa1ec ```