Equos.ai official Python SDK.
Project description
Equos Python SDK
Equos.ai official Python SDK.
Prerequisites
- Go to Equos Studio.
- Create an organization.
- Create an API Key.
Installation
pip install equos
Features
- Official Python SDK for Equos.ai
- High-level
EquosClientgrouped by resource (brains,characters,faces,voices,conversations,knowledge_bases,organizations,tokens,health) - Sync and async variants for every endpoint
- Type-safe generated models for all request / response bodies
- Escape hatch to the low-level generated client for full
httpxcustomization
Quick Start
import os
from equos import EquosClient
client = EquosClient(api_key=os.environ["EQUOS_API_KEY"])
# Health check
print(client.health.check())
# List the first 20 brains
print(client.brains.list())
You don't have an API key? Create one here.
Configuration
By default the client targets https://api.equos.ai. Override the endpoint via EquosOptions:
from equos import EquosClient, EquosOptions
client = EquosClient(
api_key=os.environ["EQUOS_API_KEY"],
options=EquosOptions(endpoint="https://develop-api.equos.ai"),
)
API Groups
Every group is available on the EquosClient instance. Each method has an async counterpart suffixed with _async.
client.brains
| Method | Description |
|---|---|
list(take=20, skip=0, client_query=UNSET) |
List brains |
get(id) |
Get a brain by id |
create(body) |
Create a brain (CreateEquosBrainRequest) |
update(id, body) |
Update a brain (CreateEquosBrainRequest) |
delete(id) |
Delete a brain |
client.characters
| Method | Description |
|---|---|
list(take=20, skip=0, client_query=UNSET) |
List characters |
get(id) |
Get a character |
create(body) |
Create a character (CreateEquosCharacterRequest) |
update(id, body) |
Update a character (UpdateEquosCharacterRequest) |
delete(id) |
Delete a character |
client.faces
| Method | Description |
|---|---|
list(take=20, skip=0, client_query=UNSET) |
List faces |
get(id) |
Get a face |
create(body) |
Create a face (CreateEquosFaceRequest) |
delete(id) |
Delete a face |
client.voices
| Method | Description |
|---|---|
list(take=20, skip=0, client_query=UNSET) |
List voices |
get(id) |
Get a voice |
create(body) |
Create a voice (CreateEquosVoiceRequest) |
update(id, body) |
Update a voice (CreateEquosVoiceRequest) |
delete(id) |
Delete a voice |
client.conversations
| Method | Description |
|---|---|
list(take=20, skip=0, client_query=UNSET) |
List conversations |
get(id) |
Get a conversation |
start(body) |
Start a conversation (CreateEquosConversationRequest) |
stop(id) |
Stop a conversation |
client.knowledge_bases
| Method | Description |
|---|---|
list(take=20, skip=0, client_query=UNSET) |
List knowledge bases |
get(id) |
Get a knowledge base |
create(body) |
Create a knowledge base (CreateKnowledgeBaseRequest) |
delete(id) |
Delete a knowledge base |
add_document(id, body) |
Add a document (CreateDocumentRequest) |
index_document(id, doc) |
Index a document |
delete_document(id, doc) |
Delete a document |
client.organizations
| Method | Description |
|---|---|
get_freemium_usage() |
Get the freemium usage for the current org |
client.tokens
| Method | Description |
|---|---|
create(body) |
Create a short-lived access token (CreateEquosTokenRequest) |
client.health
| Method | Description |
|---|---|
check() |
Health check |
Examples
Create and Fetch a Brain
from equos import EquosClient
from equos.models import CreateEquosBrainRequest
client = EquosClient(api_key="YOUR_API_KEY")
created = client.brains.create(CreateEquosBrainRequest(name="My Brain"))
print(created.id, created.name)
fetched = client.brains.get(created.id)
print(fetched)
Start a Conversation
from equos import EquosClient
from equos.models import CreateEquosConversationRequest
client = EquosClient(api_key="YOUR_API_KEY")
conversation = client.conversations.start(
CreateEquosConversationRequest(character_id="chr_...")
)
print(conversation.id, conversation.token)
Async Usage
Every method has an _async variant that returns a coroutine:
import asyncio
from equos import EquosClient
async def main():
client = EquosClient(api_key="YOUR_API_KEY")
brains = await client.brains.list_async(take=50)
print(brains)
asyncio.run(main())
Pagination and Filtering
list* endpoints accept take, skip, and client_query:
page = client.characters.list(take=50, skip=0, client_query="external-user-123")
Models and Types
All generated request / response models are re-exported for convenience:
from equos.models import (
CreateEquosBrainRequest,
CreateEquosCharacterRequest,
CreateEquosConversationRequest,
CreateEquosFaceRequest,
CreateEquosVoiceRequest,
CreateKnowledgeBaseRequest,
CreateDocumentRequest,
CreateEquosTokenRequest,
# ...and all response models
)
from equos.types import UNSET, Unset, Response
Low-Level Client
For fine-grained control or endpoints not yet surfaced on EquosClient, use the generated client directly:
from equos.client import AuthenticatedClient
from equos.client.api.brain import get_brain
auth_client = AuthenticatedClient(
base_url="https://api.equos.ai",
token="YOUR_API_KEY",
auth_header_name="x-api-key",
prefix="",
)
with auth_client as c:
brain = get_brain.sync(id="brain_id", client=c)
print(brain)
Each generated endpoint module exposes four callables:
sync(...)— parsed response, orNonesync_detailed(...)—Response[Parsed]with status / headers / contentasyncio(...)/asyncio_detailed(...)— async variants
Advanced httpx Customization
import httpx
from equos.client import AuthenticatedClient
auth_client = AuthenticatedClient(
base_url="https://api.equos.ai",
token="YOUR_API_KEY",
auth_header_name="x-api-key",
prefix="",
httpx_args={"timeout": 30.0, "proxies": "http://localhost:8030"},
)
# Or swap in your own httpx.Client
auth_client.set_httpx_client(httpx.Client(base_url="https://api.equos.ai"))
Changelog
See Releases for version history.
Other Equos SDKs
| SDK | Platform | Package |
|---|---|---|
| @equos/browser-sdk | Browser (vanilla JS/TS) | npm |
| @equos/react | Browser (React) | npm |
| @equos/node-sdk | Node.js (server-side only) | npm |
| equos | Python (server-side only) | PyPI |
Reach Us
- Equos Slack Community: Join Equos Community Slack
- Support: Support Form
Documentation
- Official Documentation: https://docs.equos.ai
- Equos NodeJS Examples: https://github.com/EquosAI/equos-examples/tree/main/examples/equos-nextjs-integration
- Equos React Examples: https://github.com/EquosAI/equos-examples/blob/main/examples/equos-react-integration/README.md
Authors
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 equos-3.1.5.tar.gz.
File metadata
- Download URL: equos-3.1.5.tar.gz
- Upload date:
- Size: 32.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0ebbb76f9063b55e60dba1b8fb279e61c2a9970746ea9bbd60f5453a0babb181
|
|
| MD5 |
37550008ea575bfcbe7f2da1fa2188dd
|
|
| BLAKE2b-256 |
555ced1fc0b44cd55bf82867fc6e17e843aebe53a468d5eefaf7ee778d5b7cf2
|
Provenance
The following attestation bundles were made for equos-3.1.5.tar.gz:
Publisher:
publish.yml on EquosAI/equos-python-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
equos-3.1.5.tar.gz -
Subject digest:
0ebbb76f9063b55e60dba1b8fb279e61c2a9970746ea9bbd60f5453a0babb181 - Sigstore transparency entry: 1349854647
- Sigstore integration time:
-
Permalink:
EquosAI/equos-python-sdk@418216027a8f0728844f4511c0d618e3b59cbe62 -
Branch / Tag:
refs/tags/v3.1.5 - Owner: https://github.com/EquosAI
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@418216027a8f0728844f4511c0d618e3b59cbe62 -
Trigger Event:
release
-
Statement type:
File details
Details for the file equos-3.1.5-py3-none-any.whl.
File metadata
- Download URL: equos-3.1.5-py3-none-any.whl
- Upload date:
- Size: 96.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eba367405c6953b7c64b2f4428b286086319ad97be79e0a577900d2fedc24815
|
|
| MD5 |
094a07ca0dd336d3dc9e8e4bd648068e
|
|
| BLAKE2b-256 |
0664517fd19c0452f89e5bbef3473363a7431bcef53d23ae7ee051879fc4714d
|
Provenance
The following attestation bundles were made for equos-3.1.5-py3-none-any.whl:
Publisher:
publish.yml on EquosAI/equos-python-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
equos-3.1.5-py3-none-any.whl -
Subject digest:
eba367405c6953b7c64b2f4428b286086319ad97be79e0a577900d2fedc24815 - Sigstore transparency entry: 1349854716
- Sigstore integration time:
-
Permalink:
EquosAI/equos-python-sdk@418216027a8f0728844f4511c0d618e3b59cbe62 -
Branch / Tag:
refs/tags/v3.1.5 - Owner: https://github.com/EquosAI
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@418216027a8f0728844f4511c0d618e3b59cbe62 -
Trigger Event:
release
-
Statement type: