Coinpal is a non-custodial cryptocurrency payment processing platform. Accept payments in a wide range of cryptos and get them instantly converted into a coin of your choice and sent to your wallet.
TODOS
TODOS
TODOS
https://pay.coinpal.io/gateway/pay/checkout
Creates payment. With this method, your customer will be able to complete the payment without leaving your website. Data must be sent as a form-date payload.
Sign String Make Rule
sign = sha256(secretKey+requestId+merchantNo+orderNo+orderAmount+orderCurrency)
Parameters Body
Name | Max Length | Mandatory | Default Value | Description |
---|---|---|---|---|
version | 10 | Yes | 2 | version No |
requestId | 156 | Yes | Request serial number, each request needs to be unique | |
merchantNo | 64 | Yes | Merchant number | |
merchantName | 256 | No | Merchant name on the cashier page | |
orderNo | 256 | Yes | Merchant order number | |
orderCurrencyType | 16 | Yes | Currency type,either 'crypto' or 'fiat' | |
orderCurrency | 10 | Yes | Order currency | |
orderAmount | 16 | Yes | Order amount | |
orderDescription | 256 | No | Order description | |
resultNotifyUser | 10 | No | true | Whether coinpal sends the final confirmation result of transaction for the user |
unpaidAutoRefund | 10 | No | true | Whether coinpal automatic refund is required in case of underpayment or overpayment |
payerEmail | 256 | No | Payer email | |
payerIP | 256 | Yes | Payer Ip | |
notifyURL | 256 | Yes | Merchant asynchronous notification address | |
redirectURL | 256 | Yes | After the user pays successfully or the payment expires, the page will call back the address | |
cancelURL | 256 | No | After the user clicks Payment Cancel, the page will call back the address. If no value is passed, the default callback is to redirectUR | |
successUrl | 256 | No | The redirectURL will be used by default if the redirect address is blank | |
remark | 500 | No | The redirectURL will be used by default if the redirect address is blank | |
sign | 64 | Yes | The extension field can be defined by the merchant. After successful payment, it will be returned as is |
Response Body (Success)
Name | Max Length | Mandatory | Default Value | Description |
---|---|---|---|---|
version | 10 | Yes | 2 | version No |
requestId | 156 | Yes | Request serial number, each request needs to be unique | |
merchantNo | 64 | Yes | Merchant number | |
orderNo | 256 | Yes | Merchant order number | |
reference | 256 | Yes | Coinpal order number | |
orderCurrency | 10 | Yes | Order currency | |
orderAmount | 16 | Yes | Order amount | |
nextStep | 200 | Yes | redirect | Next step |
nextStepContent | 200 | Yes | Checkout link | |
status | 16 | Yes | Order status | |
respCode | 10 | Yes | 200 | Response code |
respMessage | 256 | Yes | success | Message info |
remark | 500 | Yes |
Response Body (Error)
Fields | Max Length | Mandatory | Default Value | Description |
---|---|---|---|---|
respCode | 10 | Yes | Response code | |
respMessage | 256 | Yes | Error info |
Request Demo (PHP)
<?php
//todo demo
$url = "https://pay.coinpal.io/gateway/pay/checkout";
$secretKey = '2bab786405d1279e825692e13245670379e6485a2fb701233e76d8f8b1482a9a';
$data['version'] = '2';
$data['requestId'] = 'TEST10000000000123';
$data['merchantNo'] = '10000000';
$data['merchantName'] = 'Cionpal';
$data['orderNo'] = 'MER12345678910';
$data['orderCurrencyType'] = 'fiat';
$data['orderCurrency'] = 'USD';
$data['orderAmount'] = '10.5';
$data['orderDescription'] = 'Iphone 14';
$data['payerIP'] = '192.168.0.1';
$data['notifyURL'] = 'https://www.order-test.cn/notify.php?order='.$data['orderNo'];
$data['redirectURL'] = 'https://www.order-test.cn';
$data['remark'] = 'Remark';
$data['sign'] = hash('sha256', $secretKey . $data['requestId'] . $data['merchantNo'] . $data['orderNo'] . $data['orderAmount'] . $data['orderCurrency']);
function curl_request($url,$pdata){
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $pdata);
curl_setopt($ch, CURLOPT_TIMEOUT,60);
$result = curl_exec($ch);
if($result === false){
return curl_error($ch);
}
curl_close($ch);
return $result;
}
$order_data = curl_request($url,$data);
https://pay.coinpal.io/gateway/pay/query
Parameters Body
Name | Max Length | Mandatory | Default Value | Description |
---|---|---|---|---|
token | 64 | No | Cashier token (when gcid is blank, token is required) | |
gcid | 24 | No | Coinpal order number(gcid is required when token is empty) |
Response Body (Success)
Name | Max Length | Mandatory | Default Value | Description |
---|---|---|---|---|
version | 10 | Yes | 2 | version No |
requestId | 156 | Yes | Request serial number, each request needs to be unique | |
merchantNo | 64 | Yes | Merchant number | |
orderNo | 256 | Yes | Merchant order number | |
reference | 256 | Yes | Coinpal order number | |
orderCurrency | 10 | Yes | Order currency | |
orderAmount | 16 | Yes | Order amount | |
nextStep | 200 | Yes | redirect | Next step |
nextStepContent | 200 | Yes | Checkout link | |
status | 16 | Yes | Order status | |
respCode | 10 | Yes | 200 | Response code |
respMessage | 256 | Yes | success | Message info |
remark | 500 | Yes |
Response Body (Error)
Fields | Max Length | Mandatory | Default Value | Description |
---|---|---|---|---|
respCode | 10 | Yes | Response code | |
respMessage | 256 | Yes | Error info |
When the payment status and payment amount change, we will notify your server in the form of asynchronous notification
Name | Max Length | Mandatory | Default Value | Description |
---|---|---|---|---|
version | 10 | Yes | 2 | version No |
requestId | 156 | Yes | Request serial number, each request needs to be unique | |
merchantNo | 64 | Yes | Merchant number | |
orderNo | 256 | Yes | Merchant order number | |
reference | 256 | Yes | Coinpal order number | |
orderCurrency | 10 | Yes | Order currency | |
orderAmount | 16 | Yes | Order amount | |
dueCurrency | 16 | Yes | Order due currency | |
dueAmount | 16 | Yes | Order due amount | |
selectedWallet | 10 | Yes | Wallet id | |
paidCurrency | 10 | Yes | Paid currency | |
paidAmount | 16 | Yes | Paid amount | |
paidAddress | 10 | Yes | Paid address | |
confirmedTime | 20 | Yes | Confirmed time | |
status | 16 | Yes | Order status | |
remark | 500 | Yes | ||
notify_url | 256 | Yes | Merchant asynchronous notification address | |
sign | 64 | Yes |
sign = sha256(secretKey+requestId+merchantNo+orderNo+orderAmount+orderCurrency)
Status List
Value | Description |
---|---|
unpaid | Order created successfully |
pending | Payment in progress |
partial_paid_confirming | partial paid successfully, to be confirmed by the public chain block |
partial_paid | partial paid successfully and the public chain block was confirmed |
paid_confirming | Paid successfully, to be confirmed by the public chain block |
paid | paid successfully and the public chain block was confirmed |
failed | Payment failed |
Currency |
---|
BTC |
ETH |
USDT |
USDC |
USD |
GBP |
EUR |
HKD |
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。