Smakoza App Integration with Your Website or CRM

The Smakoza application can be integrated with your website or CRM system. The following capabilities are available:
  • Menu synchronization (CRM → App)
  • Bonus points synchronization (CRM → App)
  • Order transmission (App → CRM)
All requests are sent via HTTP POST|PUT in JSON format to pre-agreed endpoints provided by your developers.

Menu Synchronization
The Smakoza app periodically requests the menu from your website. The website must respond with data in the following format:
{
  "categories": [
    {
      "id": "1",
      "name": "Pizza",
      "parent": "2",
      "modifiers": [
        {
          "type": "many_many",
          "category": "3",
          "required": "0",
          "products": [{ "id": "18" }]
        }
      ],
      "settings": {
        "isInMenu": true,
        "isModifier": true
      }
    },
    {
      "id": "2",
      "name": "Sushi",
      "isIncludedInMenu": "1"
    },
    {
      "id": "3",
      "name": "Sauces",
      "isIncludedInMenu": "1"
    }
  ],
  "products": [
    {
      "id": "1398",
      "category": "1",
      "additionalCategories": [
        { "id": "2", "pos": "15" }
      ],
      "isIncludedInMenu": "1",
      "name": "Margherita",
      "price": {
        "value": "8.50",
        "currency": "BYN"
      },
      "size": [
        { "value": "350", "unit": "g" },
        { "value": "30", "unit": "cm" }
      ],
      "description": "Olives, mozzarella, black olives",
      "picture": "https://your-site.com/margarita-1280x1280.jpg",
      "balance": 10,
      "modifiers": [
        {
          "type": "many_many",
          "category": "3",
          "required": "0",
          "products": [{ "id": "18" }]
        }
      ],
      "params": [
        { "id": "energy", "name": "Energy", "value": "585", "unit": "kcal" },
        { "id": "proteins", "name": "Proteins", "value": "15", "unit": "g" },
        { "id": "fats", "name": "Fats", "value": "25", "unit": "g" },
        { "id": "carbohydrates", "name": "Carbohydrates", "value": "30", "unit": "g" },
        { "id": "ingredients", "name": "Ingredients", "value": "Sugar, flour, salt" },
        { "id": "manufacturer", "name": "Manufacturer", "value": "Sugar, flour, salt" },
        { "id": "expire", "name": "Expiration", "value": "Sugar, flour, salt" },
        { "id": "temperature", "name": "Storage Conditions", "value": "Sugar, flour, salt" },
        { "id": "custom", "name": "Color", "value": "White" },
        { "id": "custom", "name": "Size", "value": "100x100" }
      ],
      "badges": ["hit"],
      "group": "00001"
    }
  ]
}
Order Transmission
Each order request includes a secret token — token (for the delivery service "Smakoza Demo", use bdac4d809bff6e172e754616526d3774). You must validate the token to ensure the order originates from our server. The request is sent via HTTP POST with content-type: application/json.
{
  "token": "bdac4d809bff6e172e754616526d3774",
  "order": {
    "id": "1",
    "date": "2025-05-06 10:32:08",
    "datePreorder": "2025-05-08 13:00:00",
    "client": {
      "name": "Dmitry",
      "phone": "+375 (29) 810-30-53"
    },
    "deliveryMethod": "courier",
    "paymentMethod": "cash",
    "source": "app",
    "address": {
      "city": "Minsk",
      "street": "Nezavisimosti Ave.",
      "house": "12, bldg. 5",
      "apartment": "5",
      "entrance": "1",
      "floor": "2",
      "name": "Minsk, Nezavisimosti Ave. 12, bldg. 5"
    },
    "zone": {
      "id": "153",
      "name": "Delivery Zone Description"
    },
    "restaurant": {
      "id": "b5711",
      "name": "Restaurant Name"
    },
    "dishes": [
      {
        "id": "1398",
        "category": "1",
        "count": "1",
        "name": "Margherita",
        "price": "8.50",
        "modifiers": [
          {
            "id": "18",
            "category": "3",
            "count": "1",
            "name": "Garlic Sauce",
            "price": "1.50"
          }
        ]
      },
      {
        "id": "1398",
        "count": "1",
        "name": "Margherita",
        "price": "8.50"
      }
    ],
    "notes": "Intercom doesn't work",
    "promocode": "MEGA",
    "fee": "2.00",
    "feePriority": "2.00",
    "discount": "5.00",
    "total": "17.50"
  }
}
Bonus Points Synchronization
The Smakoza app requests the bonus points from your site using the customer's phone number. The request is sent via HTTP POST with application/json:
Request:
{
  "phone": "+375295550505"
}
Expected Response:
{
  "totalPoints": 100
}
Order Status Update Notifications (Webhook)
When the order status changes, your site should send a webhook to a specific URL provided by your account manager. The request is sent via HTTP POST with application/json:
{
  "token": "bdac4d809bff6e172e754616526d3774",
  "typeHook": "order",
  "orderId": 1777,
  "status": "reported",
  "deliveryTime": 75
}
Status options:
  • unconfirmed — Not confirmed
  • reported — Accepted
  • inProgress — In progress
  • ready — Ready
  • onWay — On the way
  • checked — Completed
  • cancelled — Cancelled
Note: checked and cancelled are final statuses.
If a loyalty program is used, points are awarded only after a checked webhook is received.
{
  "success": true,
  "message": "Request processed successfully"
}