How to add a countdown timer?

I have this website blocker which does a countdown for the period I set to block distracting websites. I was wondering if it's possible when I start a session I can create a widget that shows the countdown on my touchbar?

If this is not possible, how can I create a widget for a count down? I have a custom button I made to trigger the app, I just need to figure out a way to change the state of the button to a count down timer.