Runs API
Create Run
Create a new run.
POST /v1/runs
Request Body
{
"runId": "RUN-001",
"specId": "AUTH-001",
"content": "# Implementation\n\nCompleted authentication...",
"status": "completed"
}
Response
{
"run": {
"id": 1,
"runId": "RUN-001",
"specId": "AUTH-001",
"status": "completed",
"createdAt": "2025-12-08T...",
"updatedAt": "2025-12-08T..."
}
}
Example
curl -X POST \
-H "Authorization: Bearer sk_admin_xxx" \
-H "Content-Type: application/json" \
-d '{
"runId": "RUN-001",
"specId": "AUTH-001",
"content": "# Run Log\n\nImplemented features...",
"status": "completed"
}' \
http://localhost:3000/conduct/v1/runs
List Runs
Get all runs.
GET /v1/runs
Query Parameters
specId- Filter by specstatus- Filter by statuslimit- Results per pagecursor- Pagination cursor
Response
{
"runs": [
{
"id": 1,
"runId": "RUN-001",
"specId": "AUTH-001",
"status": "completed",
"createdAt": "2025-12-08T..."
}
],
"meta": {
"hasMore": false
}
}
Example
curl -H "Authorization: Bearer sk_admin_xxx" \
"http://localhost:3000/conduct/v1/runs?specId=AUTH-001"
Get Run
Get a specific run.
GET /v1/runs/:runId
Response
{
"run": {
"id": 1,
"runId": "RUN-001",
"specId": "AUTH-001",
"content": "# Run Log\n\nImplementation complete.",
"status": "completed",
"createdAt": "2025-12-08T...",
"updatedAt": "2025-12-08T..."
}
}
Example
curl -H "Authorization: Bearer sk_admin_xxx" \
http://localhost:3000/conduct/v1/runs/RUN-001
Update Run
Update a run.
PATCH /v1/runs/:runId
Request Body
{
"status": "completed",
"content": "Updated content..."
}
Response
{
"run": {
"id": 1,
"runId": "RUN-001",
"status": "completed",
"updatedAt": "2025-12-08T..."
}
}
Example
curl -X PATCH \
-H "Authorization: Bearer sk_admin_xxx" \
-H "Content-Type: application/json" \
-d '{"status": "completed"}' \
http://localhost:3000/conduct/v1/runs/RUN-001
Delete Run
Delete a run.
DELETE /v1/runs/:runId
Response
{
"message": "Run deleted successfully"
}
Example
curl -X DELETE \
-H "Authorization: Bearer sk_admin_xxx" \
http://localhost:3000/conduct/v1/runs/RUN-001
Link Features
Link features to a run.
POST /v1/runs/:runId/features
Request Body
{
"featureIds": [42, 43, 44]
}
Response
{
"message": "Features linked successfully",
"count": 3
}
Example
curl -X POST \
-H "Authorization: Bearer sk_admin_xxx" \
-H "Content-Type: application/json" \
-d '{"featureIds": [42, 43, 44]}' \
http://localhost:3000/conduct/v1/runs/RUN-001/features
Status Values
Valid status values:
pending- Not startedin_progress- Runningcompleted- Finishedfailed- Failed