Skip to main content

ccaaws

A small uv-managed Python library for creating boto3 sessions and clients, including assumed-role clients.

Requires Python >= 3.14.

Install

uv add ccaaws

Usage

import ccaaws

# a plain boto3 session, optionally with a named CLI profile and/or region
sess = ccaaws.session(profile="myprofile", region="eu-west-1")

# a client for any AWS service, reusing a session if one is given
s3 = ccaaws.client("s3", sess=sess)

# or let it create its own session
ec2 = ccaaws.client("ec2", profile="myprofile", region="eu-west-1")

# a client built from temporary assumed-role credentials
sts_client = ccaaws.assumeRoleClient(
    "s3",
    "arn:aws:iam::123456789012:role/myrole",
    "mysession",
    profile="myprofile",
    region="eu-west-1",
)

API

  • session(profile=None, region=None) -> boto3.Session Creates a new boto3 session, optionally using a named CLI profile and/or region.

  • client(service_name, sess=None, profile=None, region=None, **kwargs) -> Any Creates a client for the given AWS service, reusing sess if provided, otherwise creating a new session from profile/region. Extra kwargs are passed through to Session.client().

  • assumeRoleClient(service_name, role_arn, role_session_name, sess=None, profile=None, region=None, duration_seconds=3600, **kwargs) -> Any Calls STS AssumeRole for role_arn and returns a client for service_name built from the resulting temporary credentials. Extra kwargs are passed through to Session.client().

Development

uv sync
uv run pytest

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ccaaws-1.0.0.tar.gz (1.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ccaaws-1.0.0-py3-none-any.whl (2.9 kB view details)

Uploaded Python 3

File details

Details for the file ccaaws-1.0.0.tar.gz.

File metadata

  • Download URL: ccaaws-1.0.0.tar.gz
  • Upload date:
  • Size: 1.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ccaaws-1.0.0.tar.gz
Algorithm Hash digest
SHA256 ad3ae74f37e0355f54e899ef33adf752c77bde333bb0c7e04182f03541df309e
MD5 660145bdae0499704e3fdc2910cb1ac2
BLAKE2b-256 ad36fb1fa1527ca1750770536de277406ed4bab6be2b09d49b90440090723652

See more details on using hashes here.

Provenance

The following attestation bundles were made for ccaaws-1.0.0.tar.gz:

Publisher: release.yaml on ccdale/ccaaws

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ccaaws-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: ccaaws-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 2.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ccaaws-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 45e77d2ae72097d191c46652ac68028f1118e85d635f8e1b1ff99cabd90cfa35
MD5 960af3ab4e238823fd9df9fea9614940
BLAKE2b-256 c4d73f43e6ea2ada77653e6af23cf81f5a3d65bd995dcd28dcb0780614b9263b

See more details on using hashes here.

Provenance

The following attestation bundles were made for ccaaws-1.0.0-py3-none-any.whl:

Publisher: release.yaml on ccdale/ccaaws

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

1.1.0

2 files

This release

1.0.0 This release

2 files

0.4.8

2 files

0.4.7

2 files

0.4.6

2 files

0.4.5

2 files

0.4.4

2 files

0.4.3

2 files

0.4.2

2 files

0.4.1

2 files

0.4.0

2 files

0.3.6

2 files

0.3.3

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

0.2.3

2 files

0.2.2

2 files

0.2.1

2 files

0.2.0

2 files

0.1.8

2 files

0.1.7

2 files

0.1.6

2 files

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page