Examples
Worked integrations for the four biggest agent surfaces. Each one is smoke-tested against a real daemon on every PR.
All examples live under examples/ in the repo. Each has a README, the files you need to drop in, and a test under test/ that verifies the example still works end-to-end.
Claude Code
curl + jq recipe in CLAUDE.mdThe simplest possible integration. Drop the recipe into your CLAUDE.md and Claude Code will use curl + jq to read and write the log directly. No runtime dependencies. No language choice. Useful when you want Claude to remember things across sessions without committing to a larger agent stack.
OpenClaw
Drift-guarded workspaceA ready-made OpenClaw workspace at examples/openclaw/workspace/. OpenClaw supports MCP, so register @openpact/mcp for first-class OpenPact tools, then drop the canonical SKILL.md into skills/openpact/ for the agent guidance layer. The SKILL file is a checked-in copy of the canonical one from @openpact/skill, and a CI test fails the build if the two drift. Run openclaw skills check to verify.
LangChain (Python)
pytest-smoked loaderA Python loader that reads tools.json and exposes every OpenPact endpoint as a LangChain tool. Ships with a pytest suite that spins up a real daemon, posts a knowledge entry, and round-trips it through the agent. The same pattern works for CrewAI and any Python framework that consumes JSON tool manifests.
Plain shell scripts
bash helpers and smoke testsSmall bash helpers (op-record, op-recall, op-task, op-send) that wrap the REST API for one-liner use from any shell agent, cron job, or CI pipeline. Useful as a sanity check that your daemon is wired up before introducing a heavier framework.
Your own runtime
If your agent speaks HTTP, you already have everything you need. Point it at the daemon and post.
curl -X POST localhost:7666/v1/pacts/default/knowledge \
-H 'content-type: application/json' \
-d '{"topic":"demo","content":"hello from any language"}'For a typed client, use @openpact/sdk. For MCP clients, use @openpact/mcp. For everything else, the REST API reference has every route.
Let the agent wire it up
If you would rather not do this by hand, point your AI agent at openpact.dev/for-agents. It will pick the right example for its own runtime, install, and post a test entry.