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

fix: cli: don't store auth provider info #1459

Merged
merged 1 commit into from
Jan 27, 2025

Conversation

g-linville
Copy link
Contributor

There was no need for us to be storing info about auth providers here. Each time the user authenticates with a new Obot instance, they will go through the auth flow, and the token will be saved locally. We won't need to know which auth provider it used again.

@g-linville g-linville merged commit f1d1bde into obot-platform:main Jan 27, 2025
2 checks passed
@g-linville g-linville deleted the fix-cli branch January 27, 2025 20:09
@sangee2004
Copy link

sangee2004 commented Jan 28, 2025

When testing with 0.5.1 release , following error is seen when switch ing between otto servers configured with different auth providers

2025/01/28 12:39:17 failed to fetch token: failed to create login request: invalid character 'a' looking for beginning of value

Able to switch between otto servers configured with different auth providers as expected with Version: v0.0.0-dev-35929b57-dirty version.

sangeethahariharan@Sangeethas-MBP bin % ./obot agents

Authentication is needed
========================

GitHub is used for authentication using the browser. This can be bypassed by setting
the env var OBOT_API_KEY to your API key.

Press ENTER to continue (CTRL+C to exit)


Opening browser to http://localhost:8080/api/oauth/start/bc0b9846-a173-4016-bcc8-3607a44599ef/default/github-auth-provider. if there is an issue paste this link into a browser manually
ID        NAME      DESCRIPTION         INVOKE                                     CREATED
a1-obot   Obot      Default Assistant   http://localhost:8080/api/invoke/obot      16 minutes ago
a1jp576   my test                       http://localhost:8080/api/invoke/a1jp576   12 minutes ago
sangeethahariharan@Sangeethas-MBP bin % export OBOT_BASE_URL=https://main.acornlabs.com/api
sangeethahariharan@Sangeethas-MBP bin % ./obot agents                                      
Opening browser to https://main.acornlabs.com/api/oauth/start/3dc88c3e-deb1-40bc-87e1-ed3f374f9819/default/google-auth-provider. if there is an issue paste this link into a browser manually
ID        NAME                          DESCRIPTION         INVOKE                                              CREATED
a1-obot   Obot                          Default Assistant   https://main.acornlabs.com/api/invoke/obot          1 week ago

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants