The Inference of AI Agents. Drain-proof wallets, signed AgentCards (JWS), hash-chained AuditChains — out of the box.
Project description
ainfera — Python SDK for Ainfera
The Inference of AI Agents. Signed AgentCards, x402-ready Wallets, hash-chained AuditChains — out of the box.
Install
pip install ainfera
Requires Python 3.10+.
Quickstart
from ainfera import AinferaClient
# api_key also reads from the AINFERA_API_KEY environment variable
client = AinferaClient(api_key="ak_...")
agent = client.agents.register(name="my-agent")
agent.wallet.topup(amount_usd=10)
response = agent.inference(
model="claude-opus-4-7",
messages=[{"role": "user", "content": "Hello"}],
)
print(response.text)
print(response.receipt.audit_url)
What is Ainfera?
The Inference of AI Agents. Drain-proof wallet for AI agents. Your agent's wallet survives prompt injection. One Agent Card across Anthropic, OpenAI, and Together — more Providers in v1.7. Every call cryptographically audited. See ainfera.ai.
Features
- Signed AgentCards per Agent (JWS, RFC 7515)
- Provider-neutral routing across Anthropic, OpenAI, Together (more soon)
- Atomic per-call settlement out of an Agent-scoped Wallet
- Tamper-evident hash-chained AuditChain for every Agent
- Local verification — auditors can verify a chain offline, no Ainfera trust required
- Sync + async clients sharing one resource surface
Concepts
Compose, don't invent
This SDK is a thin wrapper around the Ainfera API. The underlying primitives align with — and link to — public standards work:
- Open Agent Identity (OAI) Spec — Autonomy Next, Inc., draft v1.0.5 (Feb 2026)
- Mastercard Verifiable Intent — open agentic-commerce trust layer (March 2026)
- x402 Foundation — HTTP-native payments protocol, Linux Foundation (April 2026)
- NIST AI Agent Standards Initiative — NIST CAISI (Feb 2026)
- EU AI Act Annex IV — technical documentation for high-risk AI systems (Regulation 2024/1689)
- JWS, RFC 7515 — used internally for AgentCard signing
License
Apache 2.0. See LICENSE.
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 ainfera-1.1.0.tar.gz.
File metadata
- Download URL: ainfera-1.1.0.tar.gz
- Upload date:
- Size: 24.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
427247e393aa806017b415347ec2e9553a5881bc00d09dfe3108bea0bec02ddd
|
|
| MD5 |
a32db1bcd4fb4743aa4d810f5fc3357b
|
|
| BLAKE2b-256 |
a186b4ee398356007fd7dca1f911ad57a6367b2803d01f4369b80cdf166da314
|
File details
Details for the file ainfera-1.1.0-py3-none-any.whl.
File metadata
- Download URL: ainfera-1.1.0-py3-none-any.whl
- Upload date:
- Size: 31.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
14e4fcd926f1053950c9f0cb6fc9910078bdb69566ee724237c8dd88fd2cfc09
|
|
| MD5 |
ca0479df735b87fd547319f5f9f31d7b
|
|
| BLAKE2b-256 |
1f01b31baa9e09f7e27d77285e54ea5121337b1230f7b46199f3f84ef2a49c6f
|