OlaClick offers a services for POS to be notified through a WebHook of each order event. The description bellow explains how to create the WebHook that will be called on every oder event.

Untitled

Requirement to become Partner

Send an email to api@olaclick.com titled [Partner] API Integration with the requirements elements below.

Attribute Description
name (Required) Partner's full name.
Webhook URL (Required) Partner's Webhook to be notified of order events.
Webhook Header (Optional) Additional headers that you want Olaclick to send to the partner's webhook.
Merchant Id (Required) Partner Company ID. This is your internal identification number. You as partner have to provide this. Can be alphanumeric
Acknowledgement Sync / Async

WebHook Notifications

OlaClick will send 3 tips of notifications, each depending on a different stage of an order.

Event type Description
order_created When an order has been created. (Webapp or PDV)
order_updated When an order has been updated. (Panel Olaclick o Webapp)
order_deleted When an order has been deleted. (Panel Olaclick)

Event sent:

{
  "event_type": "order_created",
  "event_id": "7573920b-5558-4455-ae73-d8628aba6609",
  "merchant_id": "777",
  "data": {
    "client": {
      "country_calling_code": "51",
      "email": null,
      "name": "Aldo Perez",
      "phone_number": "123456",
      "longitude": -70.02314926295166,
      "latitude": -15.841847854130933,
      "address": null
    },
    "comment": null,
    "coupon": {
      "code": null,
      "discount_type": null,
      "end_date": null,
      "start_date": null,
      "value": 0
    },
    "cost_details": {
      "coupon_discount": 0,
      "currency": "PEN",
      "delivery_price": 7,
      "packaging_price": 6,
      "products_discount": 10,
      "products_price": 50,
      "tip": 7,
      "toppings_discount": 0,
      "toppings_price": 20,
      "total": 80,
      "amount_received": 0
    },
    "created_at": "2022-03-02 22:41:00",
    "order_id": "PE-7222853393",
    "last_product_added_at": "2022-03-02 22:41:46",
    "order_details": [
      {
        "comment": null,
        "quantity": 1,
        "total": 40,
        "product": {
          "name": "Hamburguesa",
          "sku": "123456",
          "toppings": [
            {
              "discount": 0,
              "name": "Bien cocida",
              "quantity": 1,
              "sku": "456",
              "unit_price": 5,
              "unit_regular_price": 5
            },
            {
              "discount": 0,
              "name": "Ketchup",
              "quantity": 2,
              "sku": "567",
              "unit_price": 2,
              "unit_regular_price": 2
            },
            {
              "discount": 0,
              "name": "Ají",
              "quantity": 2,
              "sku": "789",
              "unit_price": 3,
              "unit_regular_price": 3
            }
          ],
          "unit_discount": 5,
          "unit_price": 25,
          "unit_regular_price": 30,
          "toppings_price": 15
        }
      },
      {
        "comment": null,
        "quantity": 1,
        "total": 20,
        "product": {
          "name": "Pizza Margarita",
          "sku": null,
          "toppings": [
            {
              "discount": 0,
              "name": "Trisabor",
              "quantity": 1,
              "sku": null,
              "unit_price": 5,
              "unit_regular_price": 5
            }
          ],
          "unit_discount": 5,
          "unit_price": 15,
          "unit_regular_price": 20,
          "toppings_price": 5
        }
      }
    ],
    "order_type": "delivery",
    "payment_method": "card",
    "payment_status": "payment_pending",
    "source": "inbound",
    "status": "pending",
    "table_number": null
  }
}

Acknowledgement Logic

OlaClick provides two work flow in order to acknowledge the notification.