aws_gleam_runtime

Runtime core for the aws-gleam SDK. Provides everything that’s shared across every AWS service typed client:

Not directly consumed: import a typed service client instead (aws_s3, aws_sqs, aws_dynamodb, …) — each one declares this package as a dependency.

Example

import aws/credentials
import aws/region

pub fn debug_chain() {
  let resolved_region =
    region.resolve(profile: "default") |> result.unwrap("us-east-1")

  case credentials.default_chain() |> credentials.fetch() {
    Ok(creds) ->
      io.println("got creds in region " <> resolved_region <> " from "
        <> creds.source_name)
    Error(reason) ->
      io.println_error("no creds: " <> string.inspect(reason))
  }
}

In practice you don’t reach for these directly — service clients take care of the SigV4 + credentials wiring in their generated new() constructor. The exception is config tweaks; every service client exposes <service>.with_retry_strategy, .with_http_send, .with_endpoint_param, etc., which thread their argument through to this package’s types.

Documentation

Full docs at https://hexdocs.pm/aws_gleam_runtime.

License

Apache 2.0. See LICENSE.

Search Document