Skip to content

Comments

fix(responses): send stable beta header#362

Closed
zemaj wants to merge 2 commits intojust-every:mainfrom
zemaj:fix/responses-v1-header
Closed

fix(responses): send stable beta header#362
zemaj wants to merge 2 commits intojust-every:mainfrom
zemaj:fix/responses-v1-header

Conversation

@zemaj
Copy link

@zemaj zemaj commented Oct 28, 2025

Summary

  • switch our Responses requests to OpenAI-Beta: responses=v1 and share the value across both Rust clients
  • add a regression test that checks the header value on the responses request builder
  • align the local proxy comment with the new default

Fixes #331

Testing

  • ./build-fast.sh

Risks

  • minimal: requests now match the documented v1 header; verified by unit test

@zemaj zemaj force-pushed the fix/responses-v1-header branch from d68c71e to c6532b2 Compare October 28, 2025 07:05
@zemaj
Copy link
Author

zemaj commented Oct 28, 2025

Updated the header logic so public api.openai.com requests use , backend/azure/default hosts stay on , and provider-specific headers win. If there are additional backend host patterns we should encode (beyond ), please let me know so we can pin them explicitly.

@zemaj
Copy link
Author

zemaj commented Oct 28, 2025

Recap of the amended logic:

  • Public OpenAI hosts () get by default.
  • Backend / Azure endpoints (name or URLs containing / existing Azure pattern) stay on .
  • Provider-defined headers always win—we only add the beta header if one isn’t already set.

Unit coverage exists for each branch in both and . Please let me know if there are any additional backend host patterns we should codify explicitly.

@zemaj
Copy link
Author

zemaj commented Oct 28, 2025

CI note: the preview build is still hitting on the musl/darwin legs. This matches the toolchain-target gap addressed in #356, so we’ll rerun once that merges.

@zemaj
Copy link
Author

zemaj commented Oct 28, 2025

Preview Build rerun triggered after #364 merged; watching for green checks.

@zemaj
Copy link
Author

zemaj commented Oct 28, 2025

Fresh Preview Build queued with updated toolchain after #364 merged; watching for green checks.

@zemaj
Copy link
Author

zemaj commented Oct 28, 2025

Preview Build rerun queued with Rust 1.90.0 plus MUSL targets after #370 merged. Tracking run: https://github.com/just-every/code/actions/runs/18870460099

@zemaj zemaj force-pushed the main branch 2 times, most recently from 804b5ad to b7927a2 Compare October 28, 2025 23:57
@zemaj zemaj closed this in #364 Oct 29, 2025
@zemaj
Copy link
Author

zemaj commented Oct 29, 2025

Heads-up: the changes from this PR have already landed on main via commit 245617c (Merge pr362). Closing remains accurate.

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.

stream error: unexpected status 400 Bad Request

1 participant