LogoLogo
  • Intro
  • Quick Start
  • Reference
    • API Requests - V2
      • Create Order
      • Create Invoice
      • Deposit Callback
      • Check Order
      • Check Orders
    • API Requests - V1 - deprecated!
      • Create Order
      • Deposit Callback
      • Check Source
      • Check Order
      • Check Orders
Powered by GitBook
On this page
  1. Reference
  2. API Requests - V1 - deprecated!

Check Orders

Get order information

You can make a "check-orders" request to check the payment status of multiple orders.

curl --location -g --request POST '{{BASE_URL}}/check-orders' \
--header 'Authorization: Bearer {{API_KEY}}' \
--header 'Content-Type: application/json' \
--data-raw '{
    "order_ids": ["1","2"]
}'
var myHeaders = new Headers();
myHeaders.append("Authorization", "Bearer {{API_KEY}}");
myHeaders.append("Content-Type", "application/json");

var raw = JSON.stringify({
  "order_ids": [
    "1",
    "2"
  ]
});

var requestOptions = {
  method: 'POST',
  headers: myHeaders,
  body: raw,
  redirect: 'follow'
};

fetch("{{BASE_URL}}/check-orders", requestOptions)
  .then(response => response.text())
  .then(result => console.log(result))
  .catch(error => console.log('error', error));
var request = require('request');
var options = {
  'method': 'POST',
  'url': '{{BASE_URL}}/check-orders',
  'headers': {
    'Authorization': 'Bearer {{API_KEY}}',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    "order_ids": [
      "1",
      "2"
    ]
  })

};
request(options, function (error, response) {
  if (error) throw new Error(error);
  console.log(response.body);
});
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => '%7B%7BBASE_URL%7D%7D/check-orders',
  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 =>'{
    "order_ids": ["1","2"]
}',
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer {{API_KEY}}',
    'Content-Type: application/json'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
import requests
import json

url = "{{BASE_URL}}/check-orders"

payload = json.dumps({
  "order_ids": [
    "1",
    "2"
  ]
})
headers = {
  'Authorization': 'Bearer {{API_KEY}}',
  'Content-Type': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Check Order

POST https://merchant.fcfpay.com/api/v1/check-order

Query Parameters

Name
Type
Description

order_ids*

array

The Order IDs you want to check

{
    "success": true,
    "data": {
        "1": {
            "deposited": false,
            "order_id": "1",
            "user_id": "1",
            "txid": "",
            "unique_id": "",
            "confirm_blocks": "",
            "status": "waiting",
            "fiat_amount": null,
            "fiat_currency": "USD",
            "amount": "",
            "currency": "",
            "fees": "",
            "decimal": "",
            "fee_decimal": ""
        },
        "162": {
            "deposited": true,
            "order_id": "162",
            "user_id": "",
            "txid": "0xfc896c0536f39bc7c0fe5e5c73231c3afa4805680427fca2fe24292f74f30a70",
            "unique_id": "0xfc896c0536f39bc7c0fe5e5c73231c3afa4805680427fca2fe24292f74f30a70_0",
            "confirm_blocks": 24,
            "status": "deposited",
            "fiat_amount": "10.77",
            "fiat_currency": "USD",
            "amount": "27548000000000000",
            "currency": "BSC",
            "fees": "210000000000000",
            "decimal": 18,
            "fee_decimal": 18
        }
    },
    "message": "Successfully fetched."
}
PreviousCheck Order

Last updated 2 years ago