Computational APIs•Endpoint Specification
POST
/v1/query
Submits an analytical inquiry to the AION reasoning engine. Performs multi-hop relational evidence traversals, temporal filtering, contradiction extraction, and returns the strict 13-field Answer Contract.
Request Headers & Body
Headers
X-AION-Key: aion_live_... (Required)
Content-Type: application/json
| Property | Type | Description |
|---|---|---|
| question | string | The natural language question to interrogate across the substrate. (Required). |
| domain | string (enum) | Target domain: education, economy, health, politics, governance, or all. Default: education. |
| timeRange | object | Explicit temporal observation window: { start: ISOString, end: ISOString }. |
| requireContradictions | boolean | Whether to enforce bilateral contradiction detection between opposing claims. Default: true. |
| sync | boolean | If true, waits up to 8000ms for synchronous resolution before falling back to HTTP 202. |
HTTP Response Status Codes
200 OK•Synchronous Analytical Synthesis
Query completed immediately. Response body contains the full 13-field Answer Contract.
202 Accepted•Asynchronous Computation Dispatched
Query dispatched to background reasoning engine. Includes Location header and resultUrl for polling.
422 Unprocessable Entity•Epistemic Failure
Triggered when a query violates constitutional laws (e.g. asking for population claims without census data, or asking outside temporal bounds).
GET
/v1/query/{queryId}/result
Poll this endpoint to retrieve completed results for asynchronous queries. Returns { status: "processing" } until ready, followed by the complete Answer Contract.
Next Reference
Longitudinal Change & Signals API