A Python framework for building high-quality, type-safe API SDKs with comprehensive error handling and retry logic
Project description
Elusion Kit
A modern Python framework for building high-quality, type-safe API SDKs with comprehensive error handling and retry logic.
What is Elusion Kit?
Elusion Kit is a framework that provides the infrastructure needed to build professional API SDKs. It handles the common patterns like HTTP clients, authentication, retry logic, error handling, and data validation, so you can focus on implementing your specific API's business logic.
Key Features
- Type Safe: Full type hints with strict mypy configuration
- Robust Error Handling: Comprehensive exception hierarchy with detailed context
- Automatic Retries: Configurable retry strategies with exponential backoff
- Flexible Authentication: Extensible authentication patterns for any API
- Modern Python: Built for Python 3.13+ with latest features
- Well Tested: High test coverage with comprehensive test utilities
- Developer Friendly: Meaningful naming patterns and clear abstractions
Quick Start
from elusion._core import BaseServiceClient, HTTPClient
from elusion._core.authentication import APIKeyAuthenticator
from elusion._core.configuration import ClientConfiguration, ServiceSettings
class MySDKClient(BaseServiceClient):
def __init__(self, api_key: str):
config = ClientConfiguration(timeout=30.0, max_retries=3)
settings = ServiceSettings(base_url="https://api.example.com")
authenticator = APIKeyAuthenticator(api_key)
super().__init__(
config=config,
service_settings=settings,
authenticator=authenticator
)
def _get_service_name(self) -> str:
return "MyAPI"
def _get_base_url(self) -> str:
return "https://api.example.com"
# Usage
client = MySDKClient("your-api-key")
Installation
pip install elusion-kit
Documentation
- Getting Started - Build your first SDK
- Core Concepts - Understanding the framework
- Configuration - Client and service configuration
- Authentication - Authentication patterns
- HTTP Client - Making requests with retry logic
- Models - Data models and validation
- Error Handling - Exception handling patterns
- Testing - Testing your SDKs
- Examples - Complete SDK examples
- API Reference - Detailed API documentation
Who Should Use Elusion Kit?
- SDK Developers: Building client libraries for REST APIs
- API Providers: Creating official SDKs for your services
- Enterprise Teams: Standardizing API client patterns across projects
- Open Source Maintainers: Building high-quality community SDKs
Example SDKs Built with Elusion
- elusion-jokes - Sample APIs Jokes SDK
Contributing
We welcome contributions! Please see our Contributing Guide for details.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Support
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file elusion_kit-0.0.4.tar.gz.
File metadata
- Download URL: elusion_kit-0.0.4.tar.gz
- Upload date:
- Size: 31.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f45ead988e0dac013dd659c83b53c661355a3c2c55e90bd9db88005296f93107
|
|
| MD5 |
8dc9153038ce166b876fb2df7db6cb61
|
|
| BLAKE2b-256 |
f3cbf1e4578d3cd5962c6b4614ea6174a93a5a518f7a8ab5ec9eaf3630411139
|
Provenance
The following attestation bundles were made for elusion_kit-0.0.4.tar.gz:
Publisher:
release.yaml on elusionhub/elusion-kit
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
elusion_kit-0.0.4.tar.gz -
Subject digest:
f45ead988e0dac013dd659c83b53c661355a3c2c55e90bd9db88005296f93107 - Sigstore transparency entry: 346314523
- Sigstore integration time:
-
Permalink:
elusionhub/elusion-kit@45b8f2d581d4d48679656ebcd8ed6cfc80ad27ca -
Branch / Tag:
refs/tags/0.0.4 - Owner: https://github.com/elusionhub
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yaml@45b8f2d581d4d48679656ebcd8ed6cfc80ad27ca -
Trigger Event:
push
-
Statement type:
File details
Details for the file elusion_kit-0.0.4-py3-none-any.whl.
File metadata
- Download URL: elusion_kit-0.0.4-py3-none-any.whl
- Upload date:
- Size: 17.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e4fe8cff8fc279a888c4f05a9058a7b41c6b67fe1c561d70bd2e38f4a6fb638e
|
|
| MD5 |
3db1184364726c070e212d0a3b7bfe3c
|
|
| BLAKE2b-256 |
5edbff0e33c522551c29a23c7384a98e1dc2be61e9392e89c4fd49ab4e3a0f9b
|
Provenance
The following attestation bundles were made for elusion_kit-0.0.4-py3-none-any.whl:
Publisher:
release.yaml on elusionhub/elusion-kit
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
elusion_kit-0.0.4-py3-none-any.whl -
Subject digest:
e4fe8cff8fc279a888c4f05a9058a7b41c6b67fe1c561d70bd2e38f4a6fb638e - Sigstore transparency entry: 346314525
- Sigstore integration time:
-
Permalink:
elusionhub/elusion-kit@45b8f2d581d4d48679656ebcd8ed6cfc80ad27ca -
Branch / Tag:
refs/tags/0.0.4 - Owner: https://github.com/elusionhub
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yaml@45b8f2d581d4d48679656ebcd8ed6cfc80ad27ca -
Trigger Event:
push
-
Statement type: