Getting Started
Installation
pip install capo-uxc
Usage
from capo_uxc import AsyncuxcClient
async def main():
async with AsyncuxcClient() as uxc:
# Example: call the get_account_customizations operation
response = await uxc.get_account_customizations()
print(response["account_color"])
Pagination
Some operations in this SDK support pagination. If the operation supports pagination it will have an iter_ prefixed method that returns an async iterator.
from capo_uxc import AsyncuxcClient
async def main():
async with AsyncuxcClient() as uxc:
# Example: paginate over list_services
async for item in uxc.iter_list_services():
print(item)
Error Handling
The SDK raises exceptions for errors returned by the API. Catch them to handle failures gracefully.
from capo_uxc import AsyncuxcClient
from capo_uxc.error import AccessDeniedException
async def main():
async with AsyncuxcClient() as uxc:
try:
await uxc.get_account_customizations()
except AccessDeniedException as e:
print(f"Error: {e}")
print(e.data) # additional error data
Retrying
The SDK retries failed operations automatically. Retry behaviour follows the Smithy specification: errors are retried based on their is_retryable and is_throttling_error attributes. Throttling errors use a longer base delay. Network-level failures (connection errors and timeouts) are also retried. Non-retryable errors, such as client errors without the @retryable trait, are raised immediately without further attempts.
The number of attempts defaults to 3 and can be changed at the client level via retry_max_attempts, or per call via config_overrides.
from capo_uxc import AsyncuxcClient
async def main():
async with AsyncuxcClient() as uxc:
# Default: 3 attempts for every operation
response = await uxc.get_account_customizations()
# Override per operation
response = await uxc.get_account_customizations(config_overrides={"retry_max_attempts": 5})
# Disable retries for this call
response = await uxc.get_account_customizations(config_overrides={"retry_max_attempts": 1})
Release files for capo-uxc 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| capo_uxc-0.1.0.tar.gz | 47.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| capo_uxc-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 110.8 kB
Release files / capo_uxc-0.1.0.tar.gz
| Download URL | capo_uxc-0.1.0.tar.gz |
|---|---|
| Size | 47.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1ef2bf29745cd39654efe09b05429f94dfe8868cb50e30f2ba4e2d2670c3c40d
|
|
BLAKE2b-256 checksum How to use checksums |
e1a75b4a3e83e8986fa1b1fe1f229cdc43b3aa8632fe3ee8ac365f5884c0520d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.12.20 {"installer":{"name":"uv","version":"0.12.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / capo_uxc-0.1.0-py3-none-any.whl
| Download URL | capo_uxc-0.1.0-py3-none-any.whl |
|---|---|
| Size | 63.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b0ca4a661f92dd9be9af8c6d3ea6b33a365820c96add7e48e186e7cf7f64d087
|
|
BLAKE2b-256 checksum How to use checksums |
dbd6c98131cbf4faa1eda419bb5858b8e01a61b84350a580b0ecae3e45bc3685
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.12.20 {"installer":{"name":"uv","version":"0.12.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|