Migrate to gateway for cost control dogfooding#974
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 56ecf6b632
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
| # https://www.braintrust.dev/docs/deploy/gateway | ||
| ANTHROPIC_BASE_URL: https://gateway.braintrust.dev | ||
| # Attribute gateway spend to the proxy-automations-spend-control project. | ||
| ANTHROPIC_CUSTOM_HEADERS: "x-bt-project-name: proxy-automations-spend-control" |
There was a problem hiding this comment.
Use a supported Braintrust project header
In these scheduled Claude Code workflows, this header is supposed to select/attribute the proxy-automations-spend-control gateway project, but Braintrust's gateway docs say project-level AI providers are selected with x-bt-project-id and logging uses x-bt-parent with project_name:/project_id:; x-bt-project-name is not a documented request header. When the Braintrust key relies on that project context, the requests will either fall back to org-level provider credentials/cost controls or fail instead of using the configured project, so the migration will not actually dogfood the spend-control setup. The same invalid header was added to the other two workflows.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
yeah this header is undocumented rn
…to-braintrust-gateway # Conflicts: # .github/workflows/sync-models.yaml
See spend setup here: https://www.braintrust.dev/app/BT%20Staging/p/proxy-automations-spend-control/configuration/gateway