Skip to main content

Python SDK for Nexus — simple, affordable agent observability

Project description

keylightdigital-nexus

Python SDK for Nexus — simple, affordable AI agent observability.
The Plausible of AI agents. $9/month. No self-hosting.

Install

pip install keylightdigital-nexus

No dependencies beyond the Python standard library.

Quickstart

from nexus_agent import NexusClient

client = NexusClient(api_key="nxs_...", agent_id="my-agent")

trace = client.start_trace("process-invoice")
span = trace.add_span("call-llm", input={"prompt": "..."}, output={"text": "..."})
trace.end("success")

Get your API key at nexus.keylightdigital.dev.

API

NexusClient(api_key, agent_id, base_url?)

Parameter Type Description
api_key str API key from the Nexus dashboard (nxs_…)
agent_id str Human-readable agent name (groups traces in the dashboard)
base_url str Override API endpoint (default: https://nexus.keylightdigital.dev)

client.start_trace(name, metadata?) → Trace

Creates a new trace with status running. Call trace.end() when your agent finishes.

trace.add_span(name, input?, output?, error?) → Span

Records a unit of work. Timing is captured automatically at call time.

trace.end(status)

Finalizes the trace. status must be one of: "success", "error", "timeout".

Error handling

All network errors are caught internally and logged via Python's logging module.
Methods never raise — your agent keeps running even if Nexus is unreachable.

Python version support

Python 3.8 and above. No third-party dependencies.

License

MIT — see LICENSE.

Project details


Download files

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

Source Distribution

keylightdigital_nexus-0.1.0.tar.gz (6.3 kB view details)

Uploaded Source

Built Distribution

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

keylightdigital_nexus-0.1.0-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file keylightdigital_nexus-0.1.0.tar.gz.

File metadata

  • Download URL: keylightdigital_nexus-0.1.0.tar.gz
  • Upload date:
  • Size: 6.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for keylightdigital_nexus-0.1.0.tar.gz
Algorithm Hash digest
SHA256 cf4073a09f6af5d395b047468537884869e3dfc7b71f4995486cff2f6330b4c2
MD5 7c1e7fff547253ffe83d41e92dcf7ff1
BLAKE2b-256 8d5af94b0326fdfb47ffc6ae273d6105aa2ef106a4648bfab0861028243d45b5

See more details on using hashes here.

File details

Details for the file keylightdigital_nexus-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for keylightdigital_nexus-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 48b4744831e412f4d6bc6c366901cf33eb09ee068a0865ba6cc4328d2b230488
MD5 1c7343a88abae59bf6507f39a3a89217
BLAKE2b-256 58fb38615c173e75b96a26764fefdc44b2712e0574c7c8b50151856e28900fb8

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