We should allow users to set a lime limit on different applications that they using. This task is all about implementing this feature.(Create APIs for handling CRUD actions for time limits)
You can refer to Google's Digital Wellbeing app or ActivityWatch project to get some idea of the same.