Integrations
OpenClaw
Give OpenClaw agents long-term memory via the CortexDB SDK or REST API.
OpenClaw has no dedicated adapter — integrate CortexDB through the Python / TypeScript SDKs or the REST API. The pattern is recall-before, capture-after around each agent turn.
Install
pip install cortexdbai # or: npm install cortexdbaiRecall + capture
from cortexdb.v1 import V1Client
client = V1Client(api_url="https://api-v1.cortexdb.ai", actor="agent:claw",
bearer=os.environ["CORTEX_TOKEN"])
scope = "org:acme/agent:claw"
# Before the turn
pack = client.recall(scope=scope, view="holistic", query=user_input, diagnostics="none")
context = pack.get("context_block", "")
# After the turn
client.experience(scope=scope, text=user_input, role="user",
observed_at=_now(), idempotency_key=_idem(user_input))