Skip to content

feat: add OAuth Device Flow login command#13

Merged
designcode merged 2 commits into
mainfrom
feat/oauth-login
Apr 22, 2026
Merged

feat: add OAuth Device Flow login command#13
designcode merged 2 commits into
mainfrom
feat/oauth-login

Conversation

@designcode
Copy link
Copy Markdown
Collaborator

@designcode designcode commented Apr 21, 2026

Summary

  • OAuth Device Flow: login command authenticates via Auth0 (same endpoints as @tigrisdata/cli)
  • Org selection: single org auto-selects, multiple orgs show numbered prompt
  • Auto-mount: first bucket mounted at /workspace after login
  • Browser-safe: shows helpful message in browser (CORS blocks device flow)
  • README: Quick Start now leads with interactive shell (npx @tigrisdata/agent-shell), shows configure, login, and CLI flags
  • Release workflow: added test job

Test plan

  • 122 tests passing
  • npm run build — builds cleanly
  • npx @tigrisdata/agent-shelllogin → authorize in browser → org selection → bucket mounted
  • npx @tigrisdata/agent-shell --key ... --secret ... → auto-configure

🤖 Generated with Claude Code


Note

High Risk
Adds a new OAuth-based authentication path (device flow) and updates session/mount behavior, which can affect access control and how user credentials/tokens are handled. Also changes default mount points, which may break assumptions in existing scripts and tests.

Overview
Adds an interactive login command to the REPL that runs an Auth0 OAuth Device Authorization flow, prompts for organization selection, and then initializes a session using the resulting sessionToken/organizationId.

Refactors REPL session setup to share bucket listing + auto-mount logic across configure and login, changes the default auto-mount point from always /workspace to /<bucket> when auto-selecting buckets (and updates TigrisShell so ShellOptions.cwd also determines the auto-mount path).

Updates docs to highlight npx @tigrisdata/agent-shell interactive usage and OAuth login, and updates GitHub workflows by removing CI runs on push to main and adding npm test to the release workflow.

Reviewed by Cursor Bugbot for commit b33b419. Bugbot is set up for automated code reviews on this repo. Configure here.

@designcode designcode force-pushed the feat/oauth-login branch 2 times, most recently from 48705aa to e1914ea Compare April 21, 2026 15:36
Comment thread src/repl/auth.ts
Comment thread src/repl/session.ts Outdated
Comment thread src/repl/session.ts
Comment thread src/repl/session.ts
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit e6d6612. Configure here.

Comment thread src/repl/session.ts
- src/repl/auth.ts: Device Flow implementation against Auth0
  (same endpoints and client as @tigrisdata/cli)
- login command in ReplSession: auth, org selection, auto-mount
- Supports single org (auto-select) and multi-org (numbered prompt)
- Exported via @tigrisdata/agent-shell/repl

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@designcode designcode merged commit 77c14d6 into main Apr 22, 2026
3 checks passed
@designcode designcode deleted the feat/oauth-login branch April 22, 2026 08:50
@github-actions
Copy link
Copy Markdown

🎉 This PR is included in version 0.3.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants