question

eingfilip avatar image
eingfilip asked hanzala answered

Webhooks for orders

We have an app as a kitchen display screen where we will show all orders from clover. We set up a webhook(https://docs.clover.com/docs/webhooks) for showing orders on our tablet as the kitchen display screen.. Hook gives only a list of Order IDS that are created/updated, how can we get full order(all order details) based on these ids(because we want to show them on the kitchen screen as new orders). For example, it might happen that waiters created 10 orders at the same time, webhook will trigger our endpoint with a list of order ids but in order to show those orders(item name, price...) we need to fetch those orders from Clover, how can we do that without firing 10/100/1000 requests is that possible to be done in a single request?

Webhooks
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

parquet76 avatar image
parquet76 answered

The answer from Clover is incorrect. Yes, it is possible to obtain multiple items by id in a single request, see the REST API documentation - https://docs.clover.com/docs/using-filters-to-retrieve-multiple-results-from-an-endpoint.

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

chakerr avatar image
chakerr answered

Hello ,

I have no answer for you but I have a question ,

So I'm developing something similar to what you described , screen that shows orders in real time , however for me I have no problem fetching the order ID when I get it from the webhook , I'm just wondering about something , when a worker that creates orders using the clover device does it really trigger the api endpoint if not than how are you triggering it .

Thank you

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

kishoresukumaran avatar image
kishoresukumaran answered

Hi eingfilip,

The webhook is notifying you that a particular order with orderID xxxxx has been created or updated. When recieved this notification, you will have to query this orderID to get the detailed information on that order.

https://docs.clover.com/docs/webhooks

Webhooks allow your application to receive notifications when merchants who have installed your app perform certain actions. 


So, it is just the notification and to get more detail, you will have to query the orderID.

You can use the orders rest API to query the orderID and send the details to the Kitchen display:

https://docs.clover.com/docs/printing-orders-rest-api#will-online-orders-fire-to-my-kitchen-display-system-if-the-kds-is-configured-as-the-order-printer-for-the-default-firing-device

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

nesterno avatar image
nesterno answered

Hello! I recently wrote a term paper and decided to take a break. I wanted to find something interesting for entertainment, so I decided to look for an online casino. I came across skycrown in social networks, which turned out to be Australian. I liked the large selection of games, the convenient interface and many interesting options. There are both classic slots and new games with various bonuses and promotions. Had a lot of fun playing on this site and even won some money. It is very convenient that you can play from any device and at any time. I recommend it to anyone looking for a quality online casino for entertainment.

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

preeti123 avatar image
preeti123 answered

Railscarma team loved it!


10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

hanzala avatar image
hanzala answered

Patrolling services are essential for maintaining security and ensuring safety across a range of properties. This involves regular, systematic checks by trained security personnel who monitor and protect the area. Their presence not only deters criminal activities but also enables a swift response to emergencies. By being visible and active, patrolling helps prevent theft, vandalism, and other security breaches. These services can be tailored to fit specific security requirements, providing thorough and effective protection. For more detailed information on how these services can safeguard your property, visit Patrolling Services.

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community