feat(provider): add NVIDIA endpoints origin header#27394
Merged
rekram1-node merged 1 commit intoMay 14, 2026
Conversation
Contributor
|
Thanks for updating your PR! It now meets our contributing guidelines. 👍 |
a599aac to
98fe39e
Compare
98fe39e to
fac76af
Compare
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.
Issue for this PR
N/A
Type of change
What does this PR do?
Adds
X-BILLING-INVOKE-ORIGIN: OpenCodeto NVIDIA provider requests so NVIDIA can identify requests originating from opencode. The header is added through the same provider-level header path used for existing NVIDIA/OpenRouter attribution headers.The default billing-origin header is applied for hosted NVIDIA and custom/local NVIDIA NIM
baseURLconfigurations so app-origin attribution is consistent across NVIDIA provider requests. Explicitly configuredX-BILLING-INVOKE-ORIGINvalues are preserved.How did you verify your code works?
git diff --checkbun typecheckfrompackages/corebun typecheckfrompackages/opencodebun test test/v2/plugin/provider-nvidia.test.tsfrompackages/core(4 pass)bun test test/provider/provider.test.ts --test-name-pattern nvidiafrompackages/opencode(3 pass, 78 filtered)bun turbo typechecksuccessfully (14 tasks)bun testfrompackages/core: 333 pass, 1 unrelated failure incross-spawn-spawner.test.tscaused by macOS temp path canonicalization (/var/...expected,/private/var/...received)bun testfrompackages/opencode: 2298 pass, 282 fail, 49 errors; failures were outside the NVIDIA provider path and dominated byFSEvents, port binding, and timeout issuesScreenshots / recordings
N/A. This is not a UI change.
Checklist