Node History
Node History endpoints let you audit changes to nodes over time (who changed what, when), and support time-travel style inspection.
Endpoints
GET /nodes/:node_id/history
Get version history for a node.
Query parameters:
limit(default 100, max 1000)offset(default 0)include_snapshots(default false)start_date/end_date(ISO 8601)
GET /nodes/:node_id/history/:version
Get full snapshot for a specific version.
GET /nodes/:node_id/history/at-time
Get node snapshot at a specific timestamp (timestamp query param).
GET /nodes/:node_id/ledger
List unique agents that contributed to the node (derived from history).
GET /nodes/:node_id/contributions
List detailed contributions to a node (field-level).
Query parameters:
status(defaultactive):active,superseded,rejected,merged, orallcontributor_type(defaultall):agent,user, oralllimit(default 100, max 1000)offset(default 0)
Agent Contributions
GET /agents/:agent_id/contributions
Get all contributions by a specific agent (for current user's nodes).
Query parameters:
limit(default 100, max 1000)offset(default 0)status(defaultactive)
Response:
{
"agent_id": "agent_001",
"contributions": [
{
"node_id": "node_abc",
"node_title": "Meeting Notes",
"field_path": "title",
"contributed_value": "Team Planning Meeting",
"confidence_score": 0.92,
"contributed_at": "2024-01-15T10:30:00Z"
}
],
"total": 15,
"limit": 100,
"offset": 0
}
Parsing Sessions
GET /sessions
List parsing sessions for current user.
Query parameters:
status:created,processing,completed,failed, oralllimit(default 50, max 200)offset(default 0)
GET /sessions/:session_id
Get details of a specific parsing session.
Response includes:
- Session metadata
- Contribution statistics (total contributions, unique nodes, unique contributors)
Analytics
GET /analytics/agent-stats
Get agent performance statistics for current user's data.
Response:
{
"agent_stats": [
{
"agent_id": "agent_001",
"agent_name": "Memory Extractor",
"total_contributions": 150,
"nodes_affected": 45,
"avg_confidence": 0.88,
"active_contributions": 120,
"superseded_contributions": 30,
"first_contribution": "2024-01-01T10:00:00Z",
"last_contribution": "2024-01-15T14:30:00Z"
}
],
"total_agents": 3
}
GET /analytics/history-stats
Get history and contribution statistics overview.
Response:
{
"history_stats": {
"total_history_records": 1250,
"nodes_with_history": 300
},
"contribution_stats": {
"total_contributions": 850,
"agent_contributions": 700,
"user_contributions": 150
},
"session_stats": {
"total_sessions": 25,
"completed_sessions": 23,
"success_rate": 92.0
}
}
Notes
- These endpoints work with both JWT and API key authentication (for third-party apps) as long as the app is authorized for the user.