Skip to content
Ichnois
docs/api-reference

API Reference

Complete REST and webhook endpoint specifications for Server A Edge Gateway and Server B Core Platform.

Server A · Edge Gateway Ingestion Endpoints (Port 8001)

POST/api/v1/telemetry/ingest

Direct native telemetry crash ingestion. Accepts standard JSON error objects with stack trace frames and metadata. Returns HTTP 202 in < 25ms.

POST/api/{project_id}/envelope/

Drop-in Sentry SDK envelope endpoint. Parses newline-delimited envelope items and forwards sanitized crashes to Server B.

GET/healthz & /metrics

Liveness probes and operational guard telemetry (active rate limiters, body ceiling counters).

Server B · Core Triage & Management Endpoints (Port 8000)

POST/internal/v1/incidents/ingress

Internal transport from Server A Edge Gateway. Requires INTERNAL_GATEWAY_SECRET bearer token.

POST/api/v1/runs/{run_id}/gate1/approve

Advances an incident from Gate 1 (staged_raw) into forensic blame and AI explanation.

POST/api/v1/runs/{run_id}/gate2/approve

Approves Gate 2 draft sign-off and immediately publishes the structured issue to GitHub with suspect diff and blame tags.

HTTP API Request Examples
1# 1. Ingest telemetry crash (Server A Edge Gateway)
2POST /api/v1/telemetry/ingest
3Header: X-Ichnois-Token: pk_live_your_key
4Response: 202 Accepted {"id": "evt_9042", "status": "accepted"}
5
6# 2. Gate 1 Review (Staged Raw -> AI & Blame Analysis)
7POST /api/v1/runs/{run_id}/gate1/approve
8Response: 200 OK {"status": "analyzed", "state": "staged_draft"}
9
10# 3. Gate 2 Human Sign-off (Staged Draft -> Publish GitHub Issue)
11POST /api/v1/runs/{run_id}/gate2/approve
12Response: 200 OK {"status": "published", "issue_url": "https://github.com/org/repo/issues/42"}