Bump extension REST client LD-API-Version to 20240415 - #170
Merged
Conversation
The REST client hardcoded LD-API-Version: 20220603 on the non-beta path, which overrides the account/token default version and forces users onto the old API version in usage reports. Bump to 20240415 to match current API tooling. The beta code path is unchanged. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PAYYUEHtAerrpz2a1nDvH5
Andrewjeska
marked this pull request as ready for review
September 3, 2026 15:29
LindseyB
approved these changes
Sep 3, 2026
Andrewjeska
approved these changes
Sep 3, 2026
cspath1
pushed a commit
that referenced
this pull request
Sep 8, 2026
Bumps version 6.2.0 -> 6.2.1 and adds a CHANGELOG entry for the LD-API-Version header fix (#170) so a release can be cut. Claude-Session: https://claude.ai/code/session_01PAYYUEHtAerrpz2a1nDvH5 Co-authored-by: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by Leo Byeon, Michael Anderjaska · Slack thread
Before: The extension's REST client sends
LD-API-Version: 20220603on every request (src/api.ts). Because a request-level version header overrides the account/token default, any user on extension v4.0.0+ appears in the old-version API usage report even when their tokens default to a newer version.After: The client sends
LD-API-Version: 20240415, matching current API tooling, so it no longer forces users onto an old version. Thebetacode path is unchanged.One-line summary: bump the single hardcoded non-beta
LD-API-Versionliteral from20220603to20240415.Fixes #169.
Note: this PR does not change the bundled
ld-find-code-refsversion (src/coderefs/codeRefsVersion.tsstill pins 2.11.4, which sends20210729); bumping the bundled binary is a separate change and left to the team's judgement.🤖 Generated with Claude Code
https://claude.ai/code/session_01PAYYUEHtAerrpz2a1nDvH5
Generated by Claude Code
Note
Overview
Updates the default
LD-API-Versionheader on extension REST calls from20220603to20240415increateOptions(src/api.ts). Every non-beta LaunchDarkly API request from the VS Code extension uses this header, and a per-request version overrides account/token defaults—so v4.0.0+ users were previously counted as old-version API usage even when their tokens defaulted to newer versions.The
betabranch of the header is unchanged (betawhenbeta: true). Bundledld-find-code-refsstill uses its own version string and is out of scope for this change.Reviewed by Cursor Bugbot for commit 641efdc. Bugbot is set up for automated code reviews on this repo. Configure here.