-
Notifications
You must be signed in to change notification settings - Fork 5.5k
add rawAccessToken() to BackendClient #16729
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
add rawAccessToken() to BackendClient #16729
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 3 Skipped Deployments
|
|
Caution Review failedThe pull request is closed. """ WalkthroughA new public getter, Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant BackendClient
Client->>BackendClient: Call rawAccessToken()
alt Static token exists
BackendClient-->>Client: Return static access token
else No static token
BackendClient->>BackendClient: ensureValidOauthAccessToken()
BackendClient-->>Client: Return OAuth access token
end
Poem
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
packages/sdk/src/server/index.tsOops! Something went wrong! :( ESLint: 8.57.1 Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'jsonc-eslint-parser' imported from /eslint.config.mjs Note ⚡️ AI Code Reviews for VS Code, Cursor, WindsurfCodeRabbit now has a plugin for VS Code, Cursor and Windsurf. This brings AI code reviews directly in the code editor. Each commit is reviewed immediately, finding bugs before the PR is raised. Seamless context handoff to your AI code agent ensures that you can easily incorporate review feedback. Note ⚡️ Faster reviews with cachingCodeRabbit now supports caching for code and dependencies, helping speed up reviews. This means quicker feedback, reduced wait times, and a smoother review experience overall. Cached data is encrypted and stored securely. This feature will be automatically enabled for all accounts on May 16th. To opt out, configure 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
packages/sdk/CHANGELOG.md (1)
5-10: Consider using consistent terminology between implementation and documentationThe changelog refers to
rawAccessTokenas a "getter", but it's implemented as a method, not a getter property. This could lead to confusion for API consumers.Either modify the changelog to refer to it as a method:
- Added `rawAccessToken` getter to `BackendClient` + Added `rawAccessToken()` method to `BackendClient`Or consider implementing it as an actual getter:
/** * Gets the raw access token without Authorization header formatting. */ public get rawAccessToken(): string | Promise<string> { if (this.staticAccessToken) { return this.staticAccessToken; } return this.ensureValidOauthAccessToken(); }Note that in version 1.6.1, you added a similar feature called
rawTokentoBrowserClient, so maintaining consistency is important.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
Cache: Disabled due to data retention organization setting
Knowledge Base: Disabled due to data retention organization setting
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (3)
packages/sdk/CHANGELOG.md(1 hunks)packages/sdk/package.json(1 hunks)packages/sdk/src/server/index.ts(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
- GitHub Check: pnpm publish
- GitHub Check: test
- GitHub Check: Lint Code Base
🔇 Additional comments (1)
packages/sdk/package.json (1)
4-4: Looks good: Version increment is appropriateThe version bump from 1.6.2 to 1.6.3 correctly follows semantic versioning for adding a new feature without breaking changes.
WHY
Summary by CodeRabbit
New Features
Documentation
Chores