aviz85 / aviz-bot

A comprehensive solution for creating, deploying, and maintaining chatbots across various platforms.
0 stars 0 forks source link

tokens system #5

Open aviz85 opened 4 days ago

aviz85 commented 4 days ago

we want to give access people to use the chatbot with a limit so the is to generate tokens we can share with external users each user will enter the system, enter his token and then the token will be saved on his cookies so next time it won't nessecery to enter it again. each token will have limit of api calls for /chat (for example: 50, but it can be also infinite) and also limit to time - expiration (for example: a month, can be also infinite) we can use sqlite for saving this details about the tokens, we need also a dashboard to manage all this: create new tokens, view existing tokents (details: the token, how many credits left, expiration date), delete tokens. we need also login screen to enter the token (it appear only the first time when user don't have valid token in the cookies). the dashboard will be locked with password that written in .env file (dotenv) every /chat call will check whether the token is valid (from the db) and count -1 for how many tokens left (and update the db). make a messages for each scenario

@mentatbot can you do that?

mentatbot[bot] commented 4 days ago

I will start working on this issue

aviz85 commented 4 days ago

@mentatbot tell me whats your progress?

mentatbot[bot] commented 4 days ago

I will start working on this issue