API Dashboard
Escrow API
Escrow Pay
CryptoExchange API :: Quick Start Guide
Creating a transaction
Create your first transaction with the Escrow API in seconds.
- Choose your favourite client from the samples below.
- Update the authentication field with your Cryptoexchange.com username and password.
- Run the code snippet to create your first transaction.
curl "https://cryptoexchange.com/api/v1/escrow/partner/transactions" \
-X POST \
-H "Authorization:Bearer your-api-key" \
-H "Content-Type: application/json" \
-d '
{
"initiator_id": 17,
"participant_email": "[email protected]",
"participant_phone": "+12343342344",
"initiator_role": "seller",
"fee_pay_strategy": "buyer",
"type": "motor_vehicle",
"price": 12312.33,
"currency": "USD",
"crypto_currency": "BTC",
"payload": {
"vin": "dfsdfgdgs2342342",
"odometer": {
"type": "mi",
"value": "1000"
},
"shipping": {
"type": "none",
"payer": "buyer",
"price": {
"amount": "",
"currency": "USD"
}
}
},
"title": "Ford Focus 2001",
"phone": "+1885118600",
"inspection_period": 1,
"registration_expiry_date": "07/22/2022",
"notes": ""
}'
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://cryptoexchange.com/api/v1/escrow/partner/transactions',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS =>'{
"initiator_id": 17,
"participant_email": "[email protected]",
"participant_phone": "+12343342344",
"initiator_role": "seller",
"fee_pay_strategy": "buyer",
"type": "motor_vehicle",
"price": 12312.33,
"currency": "USD",
"crypto_currency": "BTC",
"payload": {
"vin": "dfsdfgdgs2342342",
"odometer": {
"type": "mi",
"value": "1000"
},
"shipping": {
"type": "none",
"payer": "buyer",
"price": {
"amount": "",
"currency": "USD"
}
}
},
"title": "Ford Focus 2001",
"phone": "+1885118600",
"inspection_period": 1,
"registration_expiry_date": "07/22/2022",
"notes": ""
}',
CURLOPT_HTTPHEADER => array(
'Accept: application/json',
'Authorization:Bearer your-api-key',
'Content-Type: application/json'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
If your request was successful, the Escrow API should return a 201 status code, and a response body like this:
{
"id": "44165ddd-e469-415f-a7f0-e7f5a5c316e6"
}