← ARCHAI Live Status

ARCHAI Governance API

Three endpoints, one governed request path. Every call to /api/govern/request passes through IDENTARCH, INTENTUM, AGENTUM, MNEMARCH, and ACCOUNTUM before an AI provider is ever reached — and every step is logged to an immutable, hash-chained ledger.

Endpoints

GET /api/govern/status

Live health of the five mechanisms, the ledger, and the AI binding.

POST /api/govern/request

Submit a governed AI request. Runs the full mechanism chain, then forwards to your AI provider.

GET /api/govern/audit

Read the last 50 entries of the accountability ledger, with chain-integrity status.

GET /api/govern/status

No auth, no body. Returns the operational state of every mechanism.

curl https://archai.systems/api/govern/status
{
  "status": "OPERATIONAL",
  "version": "2.3.0",
  "chain": [
    { "mechanism": "IDENTARCH", "status": "ACTIVE", "version": "1.0.0" },
    { "mechanism": "INTENTUM",  "status": "ACTIVE", "version": "1.0.0" },
    { "mechanism": "AGENTUM",   "status": "ACTIVE", "version": "1.0.0" },
    { "mechanism": "MNEMARCH",  "status": "ACTIVE", "version": "1.0.0" },
    { "mechanism": "ACCOUNTUM", "status": "ACTIVE", "version": "1.0.0" }
  ],
  "ledger": { "entries": 13, "chainHash": "...", "integrity": "CHAIN_INTACT" },
  "router": "LIVE",
  "storage": "KV_PERSISTENT",
  "ai": "CONNECTED",
  "aiModel": "@cf/meta/llama-3.3-70b-instruct"
}

POST /api/govern/request

The core governance call. Requires a node identity, a justified intent, and the request payload itself.

curl -X POST https://archai.systems/api/govern/request \
  -H "Content-Type: application/json" \
  -d '{
    "node": {
      "id": "agent-01",
      "role": "customer-support-agent",
      "authority": "Acme Corp"
    },
    "intent": {
      "action": "answer-support-query",
      "justification": "Responding to an inbound customer support ticket."
    },
    "request": {
      "prompt": "Summarize this customer complaint."
    }
  }'

Fields

FieldRequiredNotes
node.id / role / authorityYesIdentity anchor for this request — who is asking, in what capacity, under whose authority.
intent.actionYesShort label for what's being attempted.
intent.justificationYesMinimum 20 characters. Rejected below that.
requestYesString or object. If an object, prompt or message is used as the model input.
providerNoOmit to route to Workers AI. Include to govern your own AI stack instead — see below.

Bringing your own AI provider

By default, governed requests are forwarded to Cloudflare Workers AI. To govern your own OpenAI-compatible endpoint instead, add a provider object:

"provider": {
  "baseUrl": "https://api.openai.com/v1",
  "model": "gpt-4o",
  "apiKeyEnvVar": "OPENAI_API_KEY"
}

apiKeyEnvVar names an environment variable bound in your Pages project settings — the key itself is never sent in the request body.

Response

{
  "success": true,
  "governanceId": "...",
  "version": "2.3.0",
  "governed": true,
  "chain": {
    "IDENTARCH": { "status": "PASSED", "nodeId": "agent-01", "claimId": "..." },
    "INTENTUM":  { "status": "PASSED", "action": "answer-support-query" },
    "AGENTUM":   { "status": "PASSED", "stepsCompleted": 4 },
    "MNEMARCH":  { "status": "PASSED", "memoryId": "..." },
    "ACCOUNTUM": { "status": "PASSED", "sequence": 14, "totalEntries": 14 }
  },
  "ai": { "model": "gpt-4o", "response": "...", "governed": true },
  "message": "Request fully governed and AI response returned."
}

If any mechanism in the chain fails, the request halts there — no downstream mechanism runs, and the AI provider is never called. The response includes which mechanism failed and why.

GET /api/govern/audit

No auth, no body. Returns the most recent ledger entries and chain-integrity status.

curl https://archai.systems/api/govern/audit
{
  "entries": 14,
  "total": 14,
  "chainHash": "...",
  "integrity": "CHAIN_INTACT",
  "ledger": [
    { "sequence": 14, "nodeId": "agent-01", "action": "answer-support-query", "outcome": "SUCCESS", "recordedAt": "...", "entryHash": "..." }
  ]
}

Each entry's hash is computed from the previous entry's chain hash, so any tampering with an earlier entry invalidates every entry after it — that's what integrity: "CHAIN_INTACT" is verifying.

The Five Mechanisms

IDENTARCH

Identity anchoring and claim verification.

INTENTUM

Intent capture and justification validation.

AGENTUM

Pipeline routing and execution.

MNEMARCH

Governed memory writes with schema and decay.

ACCOUNTUM

Immutable, hash-chained accountability ledger.