Skip to main content

zizkadb-sdk

Python SDK for ZizkaDB — the operational database for AI agents.

Setup (managed cloud)

  1. Sign up at db.zizka.ai
  2. Dashboard → Create agent (e.g. my-bot) — you get an API key for that agent
  3. Use the same agent name in every db.log() call
  4. Set ZIZKADB_API_KEY (or pass the key to the constructor)

Important: The agent in db.log(agent="...", ...) must match the agent you created in the dashboard. A mismatch returns 403 AgentScopeError.

Install

pip install zizkadb-sdk

Note: There is an unrelated package called agentdb on PyPI. Install zizkadb-sdk. Import: from zizkadb import ZizkaDB.

Scaffold a project

pip install zizkadb-sdk
zizkadb init my-agent --template basic
cd my-agent && cp .env.example .env   # paste your key into ZIZKADB_API_KEY
pip install -r requirements.txt
python agent.py

Templates: basic, openai, langchain, crewai, mcp-cursor.

Quickstart

from zizkadb import ZizkaDB

# Key from Dashboard → Settings → API keys → create "my-bot" → copy key
db = ZizkaDB("zizkadb_live_xxxx")

async with db:
    result = await db.log(
        agent="my-bot",  # must match dashboard agent name
        event="tool_call",
        data={"tool": "search", "query": "billing"},
    )
    chain = await db.why(result.event_id)
    chain.print()

Multi-agent apps (one key, many agent names)

If your app logs to different agent ids per user (e.g. conv-alice, conv-bob), create a tenant-wide key in Settings → Tenant-wide API key. Per-agent keys only work for that one agent name.

Errors

Exception Meaning
AuthError Invalid or revoked API key
AgentScopeError Key is for agent A but you logged to agent B
NotFoundError Event or agent not found

Environment variables

Variable Purpose
ZIZKADB_API_KEY Your cloud API key (preferred)
AGENTDB_API_KEY Legacy alias for ZIZKADB_API_KEY
ZIZKADB_AGENT Default agent name (used in templates/examples)
ZIZKADB_HOST Self-hosted API URL
ZIZKADB_TELEMETRY Set false to opt out (anonymous ping after first log())

Self-host dashboard

  1. bash scripts/setup-local.sh (API + dashboard on port 3001)
  2. Open http://localhost:3001/login → Open my dashboard →

Links

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

zizkadb_sdk-0.2.6.tar.gz (25.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

zizkadb_sdk-0.2.6-py3-none-any.whl (27.8 kB view details)

Uploaded Python 3

File details

Details for the file zizkadb_sdk-0.2.6.tar.gz.

File metadata

  • Download URL: zizkadb_sdk-0.2.6.tar.gz
  • Upload date:
  • Size: 25.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.9

File hashes

Hashes for zizkadb_sdk-0.2.6.tar.gz
Algorithm Hash digest
SHA256 5dcb740c49962f44213bbd245888aad2264b5092c7becc335c806526072ecb0a
MD5 0fe6e3c1607936168d0d4f6895acca1c
BLAKE2b-256 d5978597bd3296347aba8da33e568677d0840c3a9af8d7e2248df9ca108b59f6

See more details on using hashes here.

File details

Details for the file zizkadb_sdk-0.2.6-py3-none-any.whl.

File metadata

  • Download URL: zizkadb_sdk-0.2.6-py3-none-any.whl
  • Upload date:
  • Size: 27.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.9

File hashes

Hashes for zizkadb_sdk-0.2.6-py3-none-any.whl
Algorithm Hash digest
SHA256 46ec85e4f0b1e51543436e4c4546aea32376b61960a40ac00f0c3c1a972d6278
MD5 2c76a252f9832a72f31d7a0666e37a1f
BLAKE2b-256 01f5084c8d1e88f96149077b66f8af257cb2978abb06e6ef6a94f1a256a96186

See more details on using hashes here.

Release history Release notifications | RSS feed

0.2.8

2 files

0.2.7

2 files

This release

0.2.6 This release

2 files

0.2.5

2 files

0.2.4

2 files

0.2.3

2 files

0.2.1

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page