Customer phone not returned by order details API endpoint (GET /orders/{guid})
AnsweredHi, we have a custom app which needs a customer phone using the API response from request GET /orders/{guid}.
Originally, the orders are synced from Olo platform to Toasttab.
After an order is synced into Toasttab, I can see a customer phone linked to that order in Toasttab admin panel. However, the phone is not available in the response for the API request GET /orders/{guid}.
Per Toasttab docs, the phone is a mandatory field and should come under the GET /orders/{guid} response within the node checks > customer (https://doc.toasttab.com/Ie5QH/apiOrdersApiReference.html#/definitions/Customer), however a GUID is in this place instead. I am attaching below part of the response so you can see what I mean:
{
"guid": "a1502dc6-e352-4153-9087-cc807f8c6bdf",
"entityType": "Order",
...
"checks": [
{
...
"customer": {
"guid": "bd8127e7-cbbd-408d-8b5d-00538b4696cc"
}
}
],
...
}
As I said, the phone (among other customer details) exists in Toasttab admin panel and is linked to the order with GUID = a1502dc6-e352-4153-9087-cc807f8c6bdf correctly, however, as you can see in API response, such information is missing when calling Toasttab API request: GET /orders/{guid}
Do you know why phone is not returned correctly through the API response?
Thanks in advance
-
Hi Kristin,
We do not automatically expose personal information about restaurant guests via API, which is why you aren’t seeing it in the order JSON. The customer entity in the order JSON will only be populated if your access includes the guest.pi:read scope, which requires legal approval (see callout #6 in our developer guide document “Getting detailed information about one order”).
We are currently working on resolving a system issue that is preventing us from adding additional scopes to self-service users, but we expect a fix in the near future. In the meantime, please fill out this form, let us know when you do, and we'll ask our legal team to look over the request.
Thanks!
0 -
Our legal team approved your request, and the system issue has been resolved. I have added the guest.pi:read scope to your credentials. You should now see customer information in the customer entity.
Thanks!
0 -
Hello - I know this is an old thread, but we actually need the exact same scope added to our API account. I will complete the form for legal review as well.
Please let me know if there are any issues with adding the necessary scope(s) to our API access.
Thank you very much!!
Best,
Jamie Warden
0 -
Hi Jamie, thank you for completing the request form. I will reach out when the legal review is complete.
Thanks!
0 -
Thank you very much, Ann!
JW
0
Please sign in to leave a comment.
Comments
5 comments