Time Picker
- 05 Jun 2024
- 2 Minutes to read
- Contributors
- Print
- DarkLight
- PDF
Time Picker
- Updated on 05 Jun 2024
- 2 Minutes to read
- Contributors
- Print
- DarkLight
- PDF
Article summary
Did you find this summary helpful?
Thank you for your feedback
Overview
With Time Picker, you can provide customers with a convenient tool for scheduling an appointment, meeting, or event.
For more information on Time Picker, go to the official documentation of Apple Messages for Business: Time Picker Message.
Example
Below, you can see the timePicker task reference in the Attachments State Diagram.
{
"abc": {
"type": "time_picker",
"time_picker": {
"event": {
"identifier": "1",
"location": {
"latitude": 37.7725,
"longitude": -22.4311,
"radius": "2",
"title": "Building One"
},
"timeslots": [
{
"duration": 3600,
"identifier": "5",
"startTime": "2020-04-01T15:30+0000"
},
{
"duration": 3600,
"identifier": "7",
"startTime": "2020-04-02T08:30+0000"
},
{
"duration": 3600,
"identifier": "9",
"startTime": "2020-04-03T21:30+0000"
}
],
"timezoneOffset": 0,
"title": "Schedule an Appointment"
},
"receivedMessage": {
"style": "icon",
"title": "Please pick a time",
"subtitle": "This should be 10:00am for -7h users"
},
"replyMessage": {
"style": "icon",
"title": "Thank you!"
}
}
}
}
Parameters
Parameter | Type | Required | Description |
---|---|---|---|
type | string | + | A type of an object to send. |
time_picker | object | + | An object in where all Time Picker Message parameters are described. |
time_picker.event | object | + | An object in which all events are described. |
time_picker.event.identifier | string | + | An item ID sent to Corezoid when it has been selected by the client. |
time_picker.event.location | object | An object in which an event location is described. | |
time_picker.event.location.latitude | double | Location latitude. | |
time_picker.event.location.longitude | double | Location longitude. | |
time_picker.event.location.radius | double | Location radius (in meters). This field is used whether there’s no latitude or longitude. | |
time_picker.event.location.title | string | + | An item’s title. |
time_picker.event.timeslots | array | An array of timeslots. | |
time_picker.event.title | string | + | An item’s title. |
time_picker.event.timeslots[].duration | integer | A time slot duration (in seconds). | |
time_picker.event.timeslots[].startTime | double | + | An event start time, a date in the UTC format (ISO 8601). An example: 2017-05-26T08:27:55+00:00, 2017-05-26T08:27:55+0000, or 2017-05-26T08:27:55Z |
time_picker.event.timeslots[].identifier | string | + | An item ID sent to Corezoid when it has been selected by the client. |
time_picker.event.event.timezoneOffset | integer | Minutes quantity from GMT, that settles an event location time zone. If it’s not defined, the time is displayed according to the current client’s time zone. If defined, the time is displayed according to the event time zone, independently from the client’s location. | |
time_picker.receivedMessage | object | + | An object that describes a received message from a list of items selected by the user. |
time_picker.receivedMessage.title | string | + | A title displayed when a client receives a message. |
time_picker.receivedMessage.subtitle | string | + | A subtitle displayed when a client receives a message. |
time_picker.receivedMessage.style | string | + | Defines an item style. The default is "icon". Available values: "icon", "small", and "large". |
time_picker.replyMessage | object | + | An object in which it is described how to display a message after a reply. |
time_picker.replyMessage.title | string | + | A title displayed when the message has been sent by the user. |
time_picker.replyMessage.subtitle | string | + | A subtitle displayed when the message has been sent by the user. |
time_picker.replyMessage.style | string | + | Defines an item style. The default is "icon". Available values: "icon", "small", and "large". |
Adding item
To add an item to Time Picker, the following object needs to be added to the timeslots
array:
"timeslots": [
{
"duration": 3600,
"identifier": "1",
"startTime": "2020-04-1T15:30+0000"
}
]
Was this article helpful?