# Capability for time-of-day setting

**URL:** <https://community.homey.app/t/capability-for-time-of-day-setting/102360>\
**Category:** Developers\
**Tags:** devices\
**Created:** [January 26, 2024, 2:00pm UTC](https://community.homey.app/t/capability-for-time-of-day-setting/102360 "2024-01-26T14:00:08Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jan\_Sparud](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jan_sparud/32/29921_2.png) [@Jan\_Sparud](https://community.homey.app/u/Jan_Sparud)\
**Post date:** [January 26, 2024, 2:00pm UTC](https://community.homey.app/t/capability-for-time-of-day-setting/102360/1 "2024-01-26T14:00:08Z")

</div>

I have a need for setting a time-of-day value in a device. I can’t find a capability type / uiComponent suitable for this. I am only interested in HH:MM, so I guess I could represent it as a number (minutes since midnight), but using a slider uicomponent for that is not very nice. Am I missing something?

---

<div class="post-metadata">

**Author:** ![Adrian\_Rockall](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/adrian_rockall/32/13209_2.png) [@Adrian\_Rockall](https://community.homey.app/u/Adrian_Rockall)\
**Post date:** [January 26, 2024, 3:29pm UTC](https://community.homey.app/t/capability-for-time-of-day-setting/102360/2 "2024-01-26T15:29:20Z")

</div>

You are not missing anything, there is no UI for that.

---

<div class="post-metadata">

**Author:** ![RonnyW](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/ronnyw/32/10879_2.png) [@RonnyW](https://community.homey.app/u/RonnyW)\
**Post date:** [January 27, 2024, 10:45pm UTC](https://community.homey.app/t/capability-for-time-of-day-setting/102360/3 "2024-01-27T22:45:37Z")

</div>

Would a flow action also be ok?  
I used two numeric arguments, hh with range 0…23 step 1 and mm with range 0…59 step 1. Then you get two input fields with a slider.  
For a device, there is no UI component for this use case.  
In device settings, you could add two numeric fields, but you have to check valid input in onSettings( ).

---

<div class="post-metadata">

**Author:** ![Jan\_Sparud](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jan_sparud/32/29921_2.png) [@Jan\_Sparud](https://community.homey.app/u/Jan_Sparud)\
**Post date:** [January 29, 2024, 8:44am UTC](https://community.homey.app/t/capability-for-time-of-day-setting/102360/4 "2024-01-29T08:44:31Z")

</div>

I am a bit surprised that there is no such thing, but maybe that’s typically too high-level for a device. I can use a custom picker with entries for 00:00, 00:10, 00:20 and so on and map that to time in the code using the entry ID, but it is a bit cumbersome.
