Skip to main content

Clockchain API

Base URL: https://clockchain.timepointai.com MCP Endpoint: https://clockchain.timepointai.com/mcp/ (Streamable HTTP, v1.26.0) Public endpoints require no authentication. Write endpoints require WRITER_TOKENS (per-writer identity tokens). Admin endpoints require X-Admin-Key.

Public Endpoints

GET /api/v1/stats

Graph statistics.
Response (illustrative snapshot — the graph grows continuously, so live totals will be larger):

GET /api/v1/moments

Paginated list of moments with filtering. Query Parameters:
Response:

GET /api/v1/moments/

Get a specific moment by canonical path, including its edges.

Authenticated Endpoints

Write endpoints require a valid writer token (from WRITER_TOKENS). Admin endpoints require X-Admin-Key.

Graph Traversal

Two endpoints power multi-hop navigation of the causal graph. Both require X-Service-Key. Agents without a service key can use the equivalent free MCP tools (traverse_moments, find_path).

GET /api/v1/graph/traverse/

Breadth-first subgraph expansion from an anchor moment — walk N hops into a moment’s causes and consequences. Query Parameters: Direction semantics (edges are stored source → target): Symmetric types (contemporaneous, same_era, same_location, same_conflict, same_figure, thematic, challenges) traverse in both directions and are only included when explicitly listed in edge_types.
Response:
The anchor node is always included with hop: 0; each other node carries the hop level at which BFS first reached it. truncated is true when limit clipped the expansion. Returns 404 if the anchor moment doesn’t exist.

GET /api/v1/graph/path

Shortest connection between two moments — bidirectional BFS treating edges as undirected for connectivity. Query Parameters:
Response:
Nodes and edges are ordered along the path (hop = position). When no path exists within max_hops, the response is 200 with "found": false404 is returned only when either endpoint moment doesn’t exist. Node objects use the same shape as traverse (abbreviated above).

MCP Endpoint

The Clockchain exposes its temporal causal graph via the Model Context Protocol (MCP) at:
Transport: Streamable HTTP (v1.26.0). See the MCP documentation for tools and integration details.

Interactive API Docs

The Clockchain provides built-in interactive documentation:
  • Swagger UI: /docs — try endpoints directly in the browser
  • ReDoc: /redoc — readable reference documentation

TDF Export

Add ?format=tdf to any moment endpoint to get TDF-formatted output: