Skip to content

API Endpoints

At the moment Merchant API has 4 endpoints, and they provide full scope of functionality to successfully integrates with our system.

Retrieve single delivery order

Endpoint: id = DeliveryOrder ID

js
GET: `/v1/delivery-orders/${id}`
GET: `/v1/delivery-orders/${id}`

Response:

json
{
    "data": DeliveryOrder
}
{
    "data": DeliveryOrder
}

Retrieve list of all delivery orders for trading point

Endpoint: id = Trading-Point ID

js
GET: `/v1/clients/auth/trading-points/${id}/delivery-orders`
GET: `/v1/clients/auth/trading-points/${id}/delivery-orders`

Response:

json
{
    "data": [
      DeliveryOrder,
      ...
      DeliveryOrder,
    ]
}
{
    "data": [
      DeliveryOrder,
      ...
      DeliveryOrder,
    ]
}

Calculate price of order before create them

Endpoint: id = Trading-Point ID

js
POST: `/v1/clients/auth/trading-points/${id}/delivery-orders/get-price`
POST: `/v1/clients/auth/trading-points/${id}/delivery-orders/get-price`

Request:

json
{
    DeliveryOrder,

    "origin": DeliveryOrderPlace,

    "destinations": [
      DeliveryOrderPlace,
      ...
      DeliveryOrderPlace,
    ]
}
{
    DeliveryOrder,

    "origin": DeliveryOrderPlace,

    "destinations": [
      DeliveryOrderPlace,
      ...
      DeliveryOrderPlace,
    ]
}

Response:

json
{
    "data": {
      DeliveryOrder,

      "origin": DeliveryOrderPlace,

      "destinations": [
        DeliveryOrderPlace,
        ...
        DeliveryOrderPlace,
      ]
    }
}
{
    "data": {
      DeliveryOrder,

      "origin": DeliveryOrderPlace,

      "destinations": [
        DeliveryOrderPlace,
        ...
        DeliveryOrderPlace,
      ]
    }
}

Create delivery order

Endpoint: id = Trading-Point ID

js
POST: `/v1/clients/auth/trading-points/${id}/delivery-orders`
POST: `/v1/clients/auth/trading-points/${id}/delivery-orders`

Request:

json
{
    DeliveryOrder,

    "origin": DeliveryOrderPlace,

    "destinations": [
      DeliveryOrderPlace,
      ...
      DeliveryOrderPlace,
    ]
}
{
    DeliveryOrder,

    "origin": DeliveryOrderPlace,

    "destinations": [
      DeliveryOrderPlace,
      ...
      DeliveryOrderPlace,
    ]
}

Response:

json
{
    "data": {
      DeliveryOrder,

      "origin": DeliveryOrderPlace,

      "destinations": [
        DeliveryOrderPlace,
        ...
        DeliveryOrderPlace,
      ]
    }
}
{
    "data": {
      DeliveryOrder,

      "origin": DeliveryOrderPlace,

      "destinations": [
        DeliveryOrderPlace,
        ...
        DeliveryOrderPlace,
      ]
    }
}

All rights reserved.