You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|`CLOPOS_CLIENT_ID`| Client ID given by Clopos (used only for auth) |`-`|`-`|
75
+
|`CLOPOS_CLIENT_SECRET`| Client Secret given by Clopos (used only for auth) |`-`|`-`|
76
+
|`CLOPOS_BRAND`| Brand that you want to request |`x-brand`|`-`|
77
+
|`CLOPOS_VENUE_ID`| Venue/Branch id that you want to request |`x-venue`|`-`|
78
+
79
+
Note that, these values MIGHT be unset. In this case, you should send it in header of each request. Let's say you want to request menu categories of two venues separately:
80
+
81
+
```python
82
+
# CLOPOS_CLIENT_ID, CLOPOS_CLIENT_SECRET and CLOPOS_BRAND have been set as env variables
|`CLOPOS_CLIENT_ID`| Client ID given by Clopos (used only for auth) |`-`|`-`|
8
+
|`CLOPOS_CLIENT_SECRET`| Client Secret given by Clopos (used only for auth) |`-`|`-`|
9
+
|`CLOPOS_BRAND`| Brand that you want to request |`x-brand`|`-`|
10
+
|`CLOPOS_VENUE_ID`| Venue/Branch id that you want to request |`x-venue`|`-`|
11
+
12
+
Note that, these values MIGHT be unset. In this case, you should send it in header of each request. Let's say you want to request menu categories of two venues separately:
13
+
14
+
```python
15
+
# CLOPOS_CLIENT_ID, CLOPOS_CLIENT_SECRET and CLOPOS_BRAND have been set as env variables
|`auth`| Authenticate, get token |`/open-api/auth`|
15
+
|`get_venues`| Get list of venues/branches |`/open-api/venues`|
16
+
|`get_users`| Get list of users |`/open-api/users`|
17
+
|`get_user_by_id`| Get user by id |`/open-api/users/{id}`|
18
+
|`get_customers`| Get list of customers |`/open-api/customers`|
19
+
|`get_customer_by_id`| Get customer by id |`/open-api/customers/{id}`|
20
+
|`get_customer_groups`| Get list of customer groups |`/open-api/customer-group`|
21
+
|`get_categories`| Get list of menu categories |`/open-api/categories`|
22
+
|`get_category_by_id`| Get menu category by id |`/open-api/categories/{id}`|
23
+
|`get_stations`| Get list of stations |`/open-api/stations`|
24
+
|`get_station_by_id`| Get station by id |`/open-api/stations/{id}`|
25
+
|`get_products`| Get list of products |`/open-api/products`|
26
+
|`get_product_by_id`| Get product by id |`/open-api/products/{id}`|
27
+
|`get_sale_types`| Get list of sale types |`/open-api/sale-types`|
28
+
|`get_payment_methods`| Get list of payment methods |`/open-api/payment-methods`|
29
+
|`get_orders`| Get list of orders |`/open-api/orders`|
30
+
|`get_order_by_id`| Get order by id |`/open-api/orders/{id}`|
31
+
|`create_order`| Create new order |`/open-api/orders`|
32
+
|`get_receipts`| Get list of receipts |`/open-api/receipts`|
33
+
|`get_receipt_by_id`| Get receipt by id |`/open-api/receipts/{id}`|
34
+
|`create_receipt`| Create a new receipt |`/open-api/receipts`|
35
+
|`delete_receipt`| Delete a receipt |`/open-api/receipts/{id}`|
36
+
37
+
## Usage
38
+
39
+
First of all, one should use `auth` method to acquire token. This token is used in all future API calls. Bear in mind that, these tokens are active for one hour. After one hour, token automatically expires, and you should again use `auth` to get a new one. This workflow responsibility falls on user.
40
+
41
+
After acquiring token, for any subsequent call, just use `headers={'token': token}` argument for any call. For other arguments that specific APIs might need, please check [API reference](api-reference/client.md).
0 commit comments