Skip to content

Migrate to gateway for cost control dogfooding#974

Merged
Erin McNulty (erin2722) merged 3 commits into
mainfrom
migrate-ai-workflows-to-braintrust-gateway
Jul 15, 2026
Merged

Migrate to gateway for cost control dogfooding#974
Erin McNulty (erin2722) merged 3 commits into
mainfrom
migrate-ai-workflows-to-braintrust-gateway

Conversation

@erin2722

Copy link
Copy Markdown
Contributor

@vercel

vercel Bot commented Jul 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
ai-proxy Ready Ready Preview, Comment Jul 15, 2026 3:22pm

Request Review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 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"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge 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 👍 / 👎.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah this header is undocumented rn

…to-braintrust-gateway

# Conflicts:
#	.github/workflows/sync-models.yaml
@erin2722
Erin McNulty (erin2722) merged commit c1bbdf5 into main Jul 15, 2026
7 of 8 checks passed
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.

2 participants