Runs API
Execute tools and retrieve execution history.
Invoke Tool
Triggers a tool execution. This is the primary endpoint used by AI agents and HTTP clients.
POST /t/:slug
Headers:
Authorization: Bearer <tool_token>(Required for private tools)Accept: text/event-stream(Optional, to request streaming output)
Request Body:
{
"input": {
// JSON object matching the tool's input schema
"key": "value"
}
}
Response (Synchronous):
200 OK
{
"runId": "uuid",
"status": "completed",
"output": { ... }, // The return value of your function
"toolUrl": "...",
"streamUrl": "..."
}
Retention: By default, Dwizi retains audit events only. Output/log retention is configurable and can be disabled for compliance-sensitive workloads. See Data Retention.
Response (Streaming): If streaming is requested, the response will be a Server-Sent Events (SSE) stream. Events:
log: Console output from the tool.result: The final output of the function.error: Any execution errors.
List Runs
View execution history for a tool or organization.
GET /v1/runs
Query Parameters:
toolId: Filter by specific tool.status: Filter by status (running,completed,failed).limit: items per page.cursor: pagination cursor.
Get Run Details
Retrieve metadata for a specific run.
GET /v1/runs/:runId
Get Run Logs
Retrieve the console logs for a specific run.
GET /v1/runs/:runId/logs
If output/log retention is disabled, this endpoint returns no stored logs.
Response:
{
"logs": [
{
"level": "info",
"message": "Processing started...",
"timestamp": "..."
}
]
}