Skip to main content
POST
/
orders
Create order
curl --request POST \
  --url https://integrations.clopos.com/open-api/orders \
  --header 'Content-Type: application/json' \
  --header 'x-brand: <api-key>' \
  --header 'x-token: <api-key>' \
  --header 'x-venue: <api-key>' \
  --data '
{
  "customer_id": 123,
  "payload": {
    "auto_accept_terminal": 123,
    "auto_order_accept": true,
    "auto_order_sent_to_station": true
  }
}
'
{
  "error": "<string>",
  "message": "<string>",
  "details": {}
}

Purpose

Converts line items, customer information, and amounts from your POS integrations into a Clopos order in a single request.

HTTP Request

POST https://integrations.clopos.com/open-api/orders

Authorization

Send the following headers for all fields:
  • x-token: Your OAuth access token
  • x-brand: Your brand code
  • x-venue: Your branch ID
  • Idempotency-Key: A unique value to prevent duplicate calls with the same body (recommended)

Prerequisites

  • The top-level customer_id must be provided.
  • Service context is required in payload.service:
    • sale_type_id — a valid sale type ID from List Sale Types
    • sale_type_name — human-readable sale type name
    • venue_id and venue_name — the venue where the order will be fulfilled
  • Product and modifier identifiers must exist in the POS catalog. Include the meta.order_product data returned by catalog APIs for accurate reconciliation.
  • Totals and discounts are recalculated by the platform; send the raw values shown to operators.

Request Example

curl --location 'https://integrations.clopos.com/open-api/orders' \
  -H 'x-token: oauth_example_token' \
  -H 'x-brand: openapitest' \
  -H 'x-venue: 1' \
  -H 'Idempotency-Key: 0fe7bc1e-9972-4c2f-bf03-4e0f09ba9d9d' \
  -H 'Content-Type: application/json' \
  -d '{
        "customer_id": 9,
        "payload": {
          "auto_accept_terminal": 1,
          "auto_order_accept": true,
          "auto_order_sent_to_station": true,
          "delivery_fee": 5,
          "service": {
            "sale_type_id": 2,
            "sale_type_name": "Delivery",
            "venue_id": 1,
            "venue_name": "Main"
          },
          "customer": {
            "id": 9,
            "phone": "+994705401040",
            "address": null,
            "customer_discount_type": 1,
            "name": "Rahid Akhundzada"
          },
          "products": [
            {
              "product_id": 1,
              "count": 1,
              "portion_size": 0.5,
              "product_modificators": [
                { "modificator_id": 187, "count": 1 },
                { "modificator_id": 201, "count": 1 }
              ],
              "meta": {
                "price": 88,
                "order_product": {
                  "product": {
                    "id": 1,
                    "name": "Mega Dürüm Menü Alana Çiğ Köfte Dürüm",
                    "price": 0
                  },
                  "count": 1,
                  "status": "completed",
                  "product_modificators": [
                    {
                      "modificator": {
                        "id": 187,
                        "name": "yyy",
                        "price": 3
                      },
                      "count": 1
                    },
                    {
                      "modificator": {
                        "id": 201,
                        "name": "S-bb",
                        "price": 15
                      },
                      "count": 1
                    }
                  ],
                  "product_hash": "MTExODcsMTEyMDE="
                }
              }
            }
          ],
          "meta": {
            "comment": "",
            "discount": {
              "discount_type": 1,
              "discount_value": 10
            },
            "orderTotal": "16.2000",
            "apply_service_charge": true,
            "customer_discount_type": 1,
            "service_charge_value": 0
          }
        }
      }'

Full payload example

{
  "customer_id": 9,
  "payload": {
    "auto_accept_terminal": 1,
    "auto_order_accept": true,
    "auto_order_sent_to_station": true,
    "delivery_fee": 5,
    "service": {
      "sale_type_id": 2,
      "sale_type_name": "Delivery",
      "venue_id": 1,
      "venue_name": "Main"
    },
    "customer": {
      "id": 9,
      "name": "Rahid Akhundzada",
      "customer_discount_type": 1,
      "phone": "+994705401040",
      "address": null
    },
    "products": [
      {
        "product_id": 1,
        "count": 1,
        "portion_size": 0.5,
        "product_modificators": [
          { "modificator_id": 187, "count": 1 },
          { "modificator_id": 201, "count": 1 }
        ],
        "meta": {
          "price": 88,
          "order_product": {
            "product": {
              "id": 1,
              "name": "Mega Dürüm Menü Alana Çiğ Köfte Dürüm",
              "price": 0
            },
            "count": 1,
            "status": "completed",
            "product_modificators": [
              { "modificator_id": 187, "count": 1 },
              { "modificator_id": 201, "count": 1 }
            ],
            "product_hash": "MTExODcsMTEyMDE="
          }
        }
      }
    ],
    "meta": {
      "comment": "",
      "discount": {
        "discount_type": 1,
        "discount_value": 10
      },
      "orderTotal": "16.2000",
      "apply_service_charge": true,
      "customer_discount_type": 1,
      "service_charge_value": 0
    }
  }
}
New orders are created in the PENDING state. Subsequent operational flows progress the status to RECEIVED (accepted by the POS and in preparation), DELIVERED when fulfillment is complete, or IGNORE if the order is cancelled.

Automation options

The following optional fields inside payload control automatic order processing on terminals:
  • auto_accept_terminal (number): Terminal ID that will handle automatic acceptance.
  • auto_order_accept (boolean): When true, the order is accepted without staff interaction.
  • auto_order_sent_to_station (boolean): When true, after acceptance the terminal creates a receipt and sends items to stations (kitchen, bar, etc.) automatically.

Delivery Fee

The delivery_fee field allows you to specify a delivery charge for the order.
payload.delivery_fee
number
The delivery fee amount to apply to the order. This field should only be used when the order is placed through a Delivery sale type channel (e.g., sale_type_id: 2).
The delivery_fee field is only applicable for Delivery channel orders. Do not send this field for other sale types (Dine-in, Takeaway, etc.).

Portion Size

The portion_size field allows you to specify fractional portions of a product.
payload.products[].portion_size
number
default:"1"
The portion multiplier for the product. Defaults to 1 if not provided.Price Calculation: final_price = product_price × portion_size × count
Example: If a product has a price of 88 and portion_size is set to 0.5 with count of 1, the POS will calculate the total product price as: 88 × 0.5 × 1 = 44

Response

201 Created — Order created

{
  "success": true,
  "message": "Order created",
  "data": {
    "status": "PENDING",
    "payload": {
      "updated_at": "2026-01-08T06:28:23.000000Z",
      "created_at": "2026-01-08T06:28:23.000000Z",
      "id": 295,
      "venue_id": 1
    }
  }
}

Authorizations

x-token
string
header
required

Access token obtained from /auth endpoint

x-brand
string
header
required

Brand identifier

x-venue
string
header
required

Venue identifier

Body

application/json

Order details

customer_id
integer
required

Customer identifier

payload
object
required

Order content and processing directives

Response

Order created successfully