Skip to main content

kohala

Official Python client for the Kohala API — build, govern, run, and monetize AI agents. Zero third-party dependencies (standard library only). Every call is metered server-side; the client adds no tracking.

Install

pip install kohala

Requires Python 3.8+.

Quick start

from kohala import Kohala

kohala = Kohala(api_key="pk_...")  # a pk_ key from your Developer tab

# List your agents
agents = kohala.agents.list()

# Create one
agent = kohala.agents.create(
    name="Weekly digest",
    charter="Summarize this week's activity and publish a Koan.",
    industry="software",
    enabled=True,
)

# Trigger a run now (returns as soon as it's queued)
kohala.runs.trigger(agent["id"])

# Read run history
runs = kohala.runs.list(agent["id"], limit=10)

# Build a Koan embed URL for an iframe
src = kohala.koans.embed_url("my-koan-slug", view="detail")

Configuration

Kohala(
    api_key="pk_...",              # required
    base_url="https://kohala.ai",  # optional (default)
    timeout=30.0,                  # optional (seconds)
)

Resources

  • kohala.agents — CRUD plus health, get_quota/set_quota, skills, koans, reports, deployments.
  • kohala.runslist, get, trigger, retry.
  • kohala.workflowslist, get, create, update, delete, list_runs, run, get_run.
  • kohala.koansget, embed_url.

For anything else, kohala.request(method, path, query=..., body=...) calls any endpoint directly.

Errors

Non-2xx responses raise KohalaError with .status, .code, .details, and .request_id:

from kohala import KohalaError

try:
    kohala.agents.get(999)
except KohalaError as err:
    if err.status == 404:
        ...  # handle not found

License

MIT

Download files

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

Source Distribution

kohala-0.2.0.tar.gz (8.8 kB view details)

Uploaded Source

Built Distribution

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

kohala-0.2.0-py3-none-any.whl (11.0 kB view details)

Uploaded Python 3

File details

Details for the file kohala-0.2.0.tar.gz.

File metadata

  • Download URL: kohala-0.2.0.tar.gz
  • Upload date:
  • Size: 8.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for kohala-0.2.0.tar.gz
Algorithm Hash digest
SHA256 d420a1dd4dd09844b516c6ccc432366c5a22bd150522b151bd25848178d5af65
MD5 cb0582e73d5b20b64165ed763d98cc01
BLAKE2b-256 019ccc5ba5fce8ceb7b58bca5e364b3269951aaf0d3d13fb8b3fd26efadd852e

See more details on using hashes here.

File details

Details for the file kohala-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: kohala-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 11.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for kohala-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 60c41097e13f3670a4e85353c6cc26f4659a748d2a6e03bdc429f676aa994058
MD5 4d6275dd2b05ac8f8292451dff95ee77
BLAKE2b-256 fb3cb30c8663181c6f6190daa8407430249968daeaa0d2b163e71acacb60f009

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page