Skip to main content

API Integration

Merchant Status

Retrieves the status of a specific merchant by ID.

Endpoint:

GET /company/merchants/{id}
Authorization: Bearer <ACCESS_TOKEN>

Response:

{
"success": true,
"data": {
"id": "<id>",
// id provided by the provider
"external_id": "<provided-id>",
// the last time data was updated, if no data this field will be `undefined`
"latest_update": "2008-01-10T11:00:00Z",
// true only if one or more stores have ongoing fetch at the moment.
"is_fetching": true,
"stores": [
{
"id": "507f191e810c19729de860c1",
// the store type "SHOPIFY" | "AMAZON" | ...
"type": "SHOPIFY",
"name": "shop abc",
// one of: 'QUEUED' | 'FETCHING' | 'READY' | 'DISCONNECTED' | 'ERRORED'
"status": "READY"
},
{
"id": "7f97823810c1629de191e0ea",
"type": "AMAZON",
"name": "shop xyz",
"status": "QUEUED"
}
]
}
}

Merchant Orders

Retrieves the details of a specific merchant by ID.

Endpoint:

GET /company/merchants/{id}/orders
Authorization: Bearer <ACCESS_TOKEN>

Response:

{
"success": true,
"data": {
"id": "<id>",
"external_id": "<provided-id>",
"orders": [
{
"integration": "shopify",
"store_id": "abc123.shopify.com",
"channel":"web",
"id": "abc123",
"confirmed": true,
"created_at": "2008-01-10T11:00:00+02:00",
"updated_at":"2008-01-10T11:00:00-05:00",
"currency":"EGP",
"subtotal_price":"195.67",
"total_discounts":"3.00",
"total_price":"192.67",
"financial_status":"paid",
"fulfillment_status":"shipped",
"payment_gateway_names":"gateway_abc",
"processed_at":"2008-01-10T11:00:00-05:00",
"customer_id": "207119551",
"shipping_address": {
"country_code": "EGY",
"address_line": "Cairo, New Cairo, Ahmed Shawqi St. 21"
}
},
...
]
}
}

Merchants List

Retrieves a paginated list of all merchants.

GET /company/merchants?page=1&size=50
Authorization: Bearer <ACCESS_TOKEN>

Response:

{
"success": true,
"data": {
"page": 1,
"size": 50,
"total_count": 1639,
"data":[
{
"id": "<id>",
"external_id": "<provided-id>",
"latest_update": "2008-01-10T11:00:00Z",
"is_fetching": true,
"stores": [{
"id": "507f191e810c19729de860c1",
"type": "SHOPIFY",
"name": "shop abc",
"status":"READY",
},{
"id": "7f97823810c1629de191e0ea",
"type": "AMAZON",
"name": "shop xyz",
"status": "QUEUED",
}]
},
...
]
}
}