anthropic_messages_to_vertexai_anthropic
Versions marked “overview” do not contain this page. Selecting one opens that version’s documentation overview.
On this page
Translates Anthropic Messages requests to Vertex AI rawPredict and Vertex responses back to the Anthropic dialect.
Configuration Notes
Activates after upstream selection only for clusters whose HTTP metadata declares application_provider: vertex. The earlier model_to_provider filter owns upstream selection and the exact target model, including snapshot suffixes. This adapter never selects a provider or maps model names.
Responses restore the original client model from model_to_provider.client_model metadata, falling back to the target model when no mapping recorded a public alias.
Streaming preserves SSE comments, event IDs, and retry fields. Oversized or incomplete frames emit an Anthropic error event after complete events and suppress the remaining stream.
Experimental: requires the vertex-anthropic-filter cargo feature, which is off by default and activates the experimental marker. This filter is a work in progress and its configuration surface may change between releases.
Configuration
| Field | Type | Required | Description |
|---|---|---|---|
project | string | yes | GCP project the upstream URL is built against. |
location | string | no | Vertex location; global routes through the multi-region endpoint and is the recommended default. |
beta_allowlist | string[] | no | Allowed anthropic-beta flag values. An empty list (the default) forwards the header untouched; a non-empty list keeps only the listed comma-separated flags and drops the header if nothing remains. |
max_body_bytes | integer | no | Maximum buffered request or JSON response size, and maximum in-flight SSE frame size, in bytes. |
Examples
Example 1
filter: anthropic_messages_to_vertexai_anthropic
project: my-gcp-project
Example 2
filter: anthropic_messages_to_vertexai_anthropic
project: my-gcp-project
location: global
beta_allowlist: [context-1m-2025-08-07, interleaved-thinking-2025-05-14]
max_body_bytes: 33554432