Public Python SDK and CLI for the ctxd platform.
Project description
ctxd
Public Python SDK and CLI for the ctxd platform.
Install:
pip install ctxd
The SDK exposes sync and async clients:
ClientAsyncClient
Authentication:
- Preferred for headless and scripts: create a user-bound API key through the authenticated application backend
- Provide it with
Client(api_key=...)orCTXD_API_KEY - The SDK sends that key as the bearer token directly to the MCP server
ctxd login --api-key ...validates and stores an API key for future CLI and SDK usagectxd loginwithout--api-keyonly validates an existing API key fromCTXD_API_KEYor the secure store
Base URL resolution order:
base_url=passed to the clientCTXD_BASE_URL~/.ctxd/config.jsonhttps://mcp.ctxd.dev
Example:
from ctxd import Client
client = Client(api_key="297e24c4-4ee9-4739-828f-48f57f48ce11")
results = client.search("text:deployment application:slack")
profile = client.get_profile()
document = client.fetch_document("doc-123")
API key example:
from ctxd import Client
client = Client(api_key="297e24c4-4ee9-4739-828f-48f57f48ce11")
results = client.search("text:deployment application:slack")
Async example:
from ctxd import AsyncClient
async with AsyncClient(api_key="297e24c4-4ee9-4739-828f-48f57f48ce11") as client:
results = await client.search("text:deployment")
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
ctxd-0.1.8.tar.gz
(9.9 kB
view details)
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
ctxd-0.1.8-py3-none-any.whl
(12.3 kB
view details)
File details
Details for the file ctxd-0.1.8.tar.gz.
File metadata
- Download URL: ctxd-0.1.8.tar.gz
- Upload date:
- Size: 9.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.5.26
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4f81e2aaf5c55f35da0897993c5b494f4618f9513e7cc3a24bab69507b65fed8
|
|
| MD5 |
878068fea0170c4e6820b5abd5e33655
|
|
| BLAKE2b-256 |
255613500949b8528e6a2c7e6f0355665919c5f963da3ed9485d2cd08f88763a
|
File details
Details for the file ctxd-0.1.8-py3-none-any.whl.
File metadata
- Download URL: ctxd-0.1.8-py3-none-any.whl
- Upload date:
- Size: 12.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.5.26
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d636628c104ae2feb290f898d85c61d71a33dacda5c36788312cab35b1dab08a
|
|
| MD5 |
bc630b4ed08476967cd544c66a66bb96
|
|
| BLAKE2b-256 |
bdffc33642ea2ef169f0447502b7aa37395150da80d566b805484dab6ca25e3d
|