How to Override Order and Book/Reserve Fields on POI Cards¶
When we select a POI card to add Additional Details, you may have noticed that for Order and Book/Reserve fields, there is an option to Override Mode (No URL):
When these modes are activated, you can no longer enter them through the dashboard as regular URLs:
If a custom implementation is required for these buttons, here is how to do them via Pointr Cloud API:
-
First you need to find the featureInternalIdentifier (fid) for your POI and do a GET ../features/
to return its full contents. Please refer to the API documentation for details of the GET request -
This will return an array of Features with a single Feature indicated with fid in it.
- In the JSON contents of the Feature under “properties”, find the section named as “buttons”. It should be an array of objects with a name, action, intent and iconURL field.
For example, for a POI with Website entered, Order and Book/Reserve fields chosen as overridden shall look like the below data:
"buttons": [
{
"name": "Order",
"action": "custom",
"intent": "",
"iconUrl": "https://pointrmapstorage.blob.core.windows.net/pointr-assets/products/pointrmaps/poiCard/order.png"
},
{
"name": "Book",
"action": "custom",
"intent": "",
"iconUrl": "https://pointrmapstorage.blob.core.windows.net/pointr-assets/products/pointrmaps/poiCard/book-reserve.png"
},
{
"name": "Website",
"action": "href",
"intent": "https://eu.louisvuitton.com/eng-e1/homepage",
"iconUrl": "https://pointrmapstorage.blob.core.windows.net/pointr-assets/products/pointrmaps/poiCard/website.png"
}
]
To override the Order and Book/Reserve fields, you should fill out the “intent” part of this data according to your implementation and keep other fields of name, action and iconURL as is. In other words;
- “name” is either “Order” or “Book”
- “action” must be “custom”
- “iconUrl” should be “https://pointrmapstorage.blob.core.windows.net/pointr-assets/products/pointrmaps/poiCard/order.png” OR “https://pointrmapstorage.blob.core.windows.net/pointr-assets/products/pointrmaps/poiCard/book-reserve.png“
Once you construct the necessary JSON content which also includes your implementation for Order and/or Book/Reserve fields, then you should send this JSON back to Pointr Cloud using PUT ../features/
Note
Do not forget to Publish your changes after modifying your Feature’s contents for them to be reflected on SDKs!