Skip to main content

Module bedrock

Module bedrock 

Source
Available on crate feature bedrock only.
Expand description

AWS Bedrock support: a RequestSigner that signs HTTP requests with sigv4.

claude-api is the Anthropic API client; this module exposes the signing primitive only. Users who want to talk to Bedrock Anthropic models still need to:

  1. Set Client::builder().base_url("https://bedrock-runtime.{region}.amazonaws.com"),
  2. Use Bedrock’s URL shape (/model/{model_id}/invoke),
  3. Inject anthropic_version: "bedrock-2023-05-31" and remove the model field from the body (Bedrock takes the model in the URL).

Mixing those concerns into the typed namespace handles is a v0.5+ design discussion; for now this module’s job is just to make the request signable.

Gated on the bedrock feature.

Structs§

BedrockCredentials
AWS access credentials. Carries the same fields as aws_credential_types::Credentials but is owned, Clone, and kept opaque – the underlying secret is moved into a fresh Credentials per call so this type is safe to share via Arc.
BedrockSigner
AWS sigv4 signer for the bedrock service.