Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion packages/proxy/schema/secrets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ export const BaseMetadataSchema = z

export const AnthropicMetadataSchema = BaseMetadataSchema.merge(
z.object({
auth_type: z.enum(["api_key", "oauth_bearer"]).default("api_key"),
auth_type: z
.enum(["api_key", "oauth_bearer", "workload_identity_federation"])
.default("api_key"),
Comment on lines +19 to +20
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Handle WIF auth_type as bearer auth

By adding "workload_identity_federation" to AnthropicMetadataSchema, secrets with that value now validate, but the runtime auth path in packages/proxy/src/proxy.ts still treats only auth_type === "oauth_bearer" as bearer and otherwise sends x-api-key (see isAnthropicOAuthBearerSecret/anthropicAuthHeaders). For Anthropic WIF tokens this will send the wrong header format and cause request authentication failures whenever users set the new enum value.

Useful? React with 👍 / 👎.

auth_source: z.string().nullish(),
}),
).passthrough();
Expand Down
Loading