Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API Key system for Puter.js #758

Open
Zac0511 opened this issue Sep 8, 2024 · 0 comments
Open

API Key system for Puter.js #758

Zac0511 opened this issue Sep 8, 2024 · 0 comments
Labels
idea An idea for a feature/improvement planned work

Comments

@Zac0511
Copy link
Contributor

Zac0511 commented Sep 8, 2024

The way Puter.js currently works is very good (open authentication windows, etc...), but it only works if the user's browser can open popups. If Puter.js is used in a browser which don't support popups (such as browser on consoles), or simply if puter.js is used in something which won't run in a browser (example : a game).

So i thinked it would be useful if a new menu was added to Puter's settings for creating API keys, managing their permissions (use AI, read FS, write FS, etc...), and delete them, and add a Puter.js function that could be something like puter.auth.signInKey(api key) to auth with an API key instead of using an account.

Other ideas for API keys :

  • Allow users to set an expiration date to API keys
  • Allow users to set a limit to API keys (example : let API have 50 AI uses per month, or revoke API key when limit is reached)
@Zac0511 Zac0511 added the idea An idea for a feature/improvement label Sep 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
idea An idea for a feature/improvement planned work
Projects
None yet
Development

No branches or pull requests

2 participants