Conduct

Checks API

Create Check

Create a new check.

POST /v1/checks

Request Body

{
  "checkId": "CHECK-001",
  "runId": "RUN-001",
  "content": "# Verification\n\nAll tests passed.",
  "result": "pass"
}

Response

{
  "check": {
    "id": 1,
    "checkId": "CHECK-001",
    "runId": "RUN-001",
    "result": "pass",
    "createdAt": "2025-12-08T..."
  }
}

Example

curl -X POST \
  -H "Authorization: Bearer sk_admin_xxx" \
  -H "Content-Type: application/json" \
  -d '{
    "checkId": "CHECK-001",
    "runId": "RUN-001",
    "content": "# Check Results\n\nAll criteria met.",
    "result": "pass"
  }' \
  http://localhost:3000/conduct/v1/checks

List Checks

Get all checks.

GET /v1/checks

Query Parameters

  • runId - Filter by run
  • result - Filter by result (pass/fail/warn)
  • limit - Results per page
  • cursor - Pagination cursor

Response

{
  "checks": [
    {
      "id": 1,
      "checkId": "CHECK-001",
      "runId": "RUN-001",
      "result": "pass",
      "createdAt": "2025-12-08T..."
    }
  ]
}

Example

curl -H "Authorization: Bearer sk_admin_xxx" \
  "http://localhost:3000/conduct/v1/checks?runId=RUN-001"

Get Check

Get a specific check.

GET /v1/checks/:checkId

Response

{
  "check": {
    "id": 1,
    "checkId": "CHECK-001",
    "runId": "RUN-001",
    "content": "# Check Results\n\nVerification complete.",
    "result": "pass",
    "createdAt": "2025-12-08T..."
  }
}

Example

curl -H "Authorization: Bearer sk_admin_xxx" \
  http://localhost:3000/conduct/v1/checks/CHECK-001

Update Check

Update a check.

PATCH /v1/checks/:checkId

Request Body

{
  "result": "fail",
  "content": "Updated verification..."
}

Response

{
  "check": {
    "id": 1,
    "checkId": "CHECK-001",
    "result": "fail",
    "updatedAt": "2025-12-08T..."
  }
}

Example

curl -X PATCH \
  -H "Authorization: Bearer sk_admin_xxx" \
  -H "Content-Type: application/json" \
  -d '{"result": "fail"}' \
  http://localhost:3000/conduct/v1/checks/CHECK-001

Delete Check

Delete a check.

DELETE /v1/checks/:checkId

Response

{
  "message": "Check deleted successfully"
}

Example

curl -X DELETE \
  -H "Authorization: Bearer sk_admin_xxx" \
  http://localhost:3000/conduct/v1/checks/CHECK-001

Result Values

Valid result values:

  • pass - All criteria met
  • fail - Some criteria not met
  • warn - Partial success

On this page