AWS_PROFILE, IAM Identity Center, instance/container roles).
Configure
BEDROCK_BASE_URL is empty, GoModel falls back to
AWS_REGION / AWS_DEFAULT_REGION.
To use an Amazon Bedrock API key instead of AWS credentials:
AWS_BEARER_TOKEN_BEDROCK. In the dashboard, add a provider of type bedrock,
set Region or endpoint, and paste the key into API Keys. Left empty, the
gateway uses AWS_BEARER_TOKEN_BEDROCK from its host when set, and the host’s
AWS credential chain otherwise.
Run GoModel
Verify
GET /v1/models returns Bedrock models with owned_by set to the originating
vendor (e.g. anthropic, amazon). Streaming (stream: true) and the
Responses API are bridged onto Converse internally.
Restrict or extend the model list
Without a configured list, GoModel queries Bedrock’s control plane and lists all on-demand text models the account has access to. To pin inference profile IDs or custom model ARNs, set a list; with the default models mode only those models are then served:config.yaml:
ListFoundationModels; how the configured list
combines with it follows the models mode
(by default only the configured models are served). To change the mode for
Bedrock only, set BEDROCK_MODELS_MODE (YAML: providers.<name>.models_mode).
Multiple Bedrock providers
Use suffixed env vars to register separate Bedrock instances:bedrock-us and bedrock-eu. Bedrock credentials
still come from the standard AWS credential chain.
Allowed tools
Bedrock Converse cannot limit a turn to a subset of the declared tools. For atool_choice of type allowed_tools, GoModel declares only the listed
functions, with toolChoice any when the mode is required and auto
otherwise. A subset that names no declared function is rejected with a 400.
allowed_tools exists so a client can send the same tool list on every turn and keep its prompt cache. Narrowing changes the tool definitions sent upstream, and on Claude models they come before the system prompt in the cached prefix, so a subset that changes between turns invalidates the cache.
Not yet integrated
- Bedrock embeddings — the
InvokeModelembedding path is model-specific and not wired up.
Troubleshooting
AccessDeniedException/403— the AWS principal lacks Bedrock permissions, or model access has not been granted in the Bedrock console.on-demand throughput isn't supported— the model requires an inference profile or provisioned throughput. SetBEDROCK_MODELSto the inference profile ID.model registry has no models— region has no on-demand text models, or the control-plane call failed. SetBEDROCK_MODELSor check IAM.- Wrong region inferred — pass
BEDROCK_BASE_URLexplicitly. With a full endpoint URL, GoModel only extracts the region segment when the host ends in.amazonaws.com; custom endpoints should pair withAWS_REGION.