How to make: A button press to register my coffee intake

I have a button and every time I press it I want the Home Assistant to register this. So i can see on card (for example) how much coffee I’ve drunk. and that the counter reset its self to 0 at the end of the day.

so I can see if my coffee addiction grows during the month.

any idea how i can achieve this?
Tips and tricks are welcom!

For now i use a Mi wireless switch.

Home Assistant 2022.9.7
Supervisor 2022.09.1
Operating System 9.0
Frontend 20220907.2 - latest

You could create a helper type number and then a button :

type: button
  action: call-service
  service: input_number.increment
  data: {}
    entity_id: input_number.count_coffee

And an automation that resets this number at 0:00

I am a newbie when it comes to Home Assistant.
Can you make it a little harder because this is too easy :wink:
Thank you.

I’m going to try this and find out to see if this is the solution for me

The counter works, but the reset not yet.

I have the following automation made in the UI :

alias: "register: reset: cup of tea a day"
description: ""
  - platform: time
    at: "00:00:00"
condition: []
  - service: counter.reset
    data: {}
      entity_id: input_number.input_number_count_thee
mode: single

When I run de automation my counter is NOT resetted to 0 (NULL)