POST /api/v1/questions/{questionId}/cancel
Cancels a to_do question. The reason is visible to the member; an
existing published video of the school can be suggested instead. Cancelling is
final: a cancelled question is never reopened, and stays in the member's history.
| Role in the organization | This endpoint |
|---|---|
OWNER | Allowed |
ADMIN | Allowed |
MEMBER | Allowed for an assigned coach, whatever the scope; otherwise refused — 403 |
| Requirement | Rule for this endpoint |
|---|---|
| Business role | coach (any scope) for a MEMBER; a reviewer is refused |
| Resource scope | Question and linked video of the key's organization |
| Participation | None |
| Resource state | The question is to_do; the linked video is published |
| Parameter | Type | Required | Description |
|---|---|---|---|
questionId | UUID | yes | Question identifier |
| Header | Required | Description |
|---|---|---|
x-api-key | yes | API key created for this organization |
Idempotency-Key | yes | Stable key for this cancellation; a replay returns the first result |
X-Correlation-Id | no | Caller correlation id, returned or generated |
| Field | Type | Required | Nullable | Description |
|---|---|---|---|---|
reason | string | yes | no | 1 to 2000 characters, visible to the member |
linkVideoResourceId | UUID | no | yes | A published resource of the school's video library |
{
"reason": "Already answered in the video on services.",
"linkVideoResourceId": "6f2b1c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d"
}curl -X POST "$COHORTE_API_BASE_URL/api/v1/questions/8c1d2e3f-4a5b-4c6d-8e7f-9a0b1c2d3e4f/cancel" \
-H "x-api-key: $COHORTE_API_KEY" \
-H "Idempotency-Key: cancel-validation-001" \
-H "Content-Type: application/json" \
-d '{"reason":"Already answered in the video on services."}'200 OK — the question, cancelled; replayed: true when the key was already used.400 Bad Request — missing Idempotency-Key, invalid JSON, a missing or too long reason, or a linked video that is not a published resource of the school.401 Unauthorized — missing, unknown or expired key.403 Forbidden — the bearer is neither OWNER, ADMIN nor an assigned coach.404 Not Found — no such question in this organization.409 Conflict — the question is already answered or cancelled.The fields of one item of List received questions.
{
"success": true,
"replayed": false,
"data": {
"id": "8c1d2e3f-4a5b-4c6d-8e7f-9a0b1c2d3e4f",
"programId": "3a1f7c2e-5b6d-4e8f-9a0b-1c2d3e4f5a6b",
"programName": "Agentic AI Developer",
"title": "Where should validation live?",
"body": "I hesitate between the server action and the service.",
"status": "cancelled",
"authorUserId": "1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"authorName": "Léa Vasseur",
"assigneeUserId": "0b1c2d3e-4f5a-4b6c-8d7e-9f0a1b2c3d4e",
"assigneeName": "Mike Codeur",
"answer": null,
"cancellation": {
"reason": "Already answered in the video on services.",
"cancelledAt": "2026-10-18T11:00:00.000Z",
"cancelledByName": "Mike Codeur",
"linkVideoResourceId": "6f2b1c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d"
},
"createdAt": "2026-10-18T10:00:00.000Z",
"updatedAt": "2026-10-18T11:00:00.000Z"
},
"correlationId": "c0ffee00-1111-4222-8333-444455556666"
}video_question.cancelled event. No email and no in-app notification are sent.