Time picker
A dropdown list for choosing a time of day, rendered like Slack's timepicker.
timepicker opens a scrollable list of times in 30-minute increments. Use it in an actions
block or a section’s accessory for a quick pick, or in an input block to collect a time in a
modal.
Fields
typestring
Always `timepicker`.
stringaction_id?string
Identifies this element in the `block_actions` payload. Must be unique within a block.
stringinitial_time?string
The time selected when the element loads, as 24-hour `HH:mm`, e.g. `22:25` for 10:25pm.
stringtimezone?string
An IANA time zone, e.g. `America/Chicago`. Shown as hint text under the control and passed back on interaction.
stringplaceholder?PlainTextElement
Text shown when no time is selected. Slack limits it to 150 characters.
PlainTextElementconfirm?ConfirmationDialog
A confirmation dialog shown before the pick takes effect.
ConfirmationDialogfocus_on_load?boolean
Focuses this element when its modal or Home tab loads. Only one element per view. Slack ignores it in messages.
booleanfalseExamples
Without an initial value
The closed control shows the placeholder text, or “Select time” if none is given, until a time
is picked. Then it reads e.g. “1:37 PM”.
With an initial value
Inside an input block
With a time zone
Setting timezone shows a hint underneath the control naming it:
timezone is a display hint only: it labels the picker but doesn’t shift initial_time or the
options list, which are always plain HH:mm wall-clock values. It’s unrelated to the timeZone
prop on BlockKitProvider, which controls how other elements (like datetimepicker) format
their values for display.
With a confirmation dialog
Interactivity
Picking an option fires an action with selected_time:
{
"type": "timepicker",
"action_id": "select_time",
"block_id": "meeting",
"selected_time": "14:30"
}
The same shape lands in state.values[block_id][action_id]:
{
"type": "timepicker",
"selected_time": "14:30"
}
When initial_time is set, that value is reported as state as soon as the element mounts, before
any interaction.