Review endpoints
DELETE /api/v1/projects/{project_id}/review-policy
Section titled “DELETE /api/v1/projects/{project_id}/review-policy”Delete the review policy
Delete the policy; the selection history stays.
| Parameter | In | Type | Required | Notes |
|---|---|---|---|---|
project_id |
path | string (uuid) | yes |
| Status | Description | Body |
|---|---|---|
| 204 | Successful Response | none |
| 422 | Validation Error | application/json: HTTPValidationError |
GET /api/v1/projects/{project_id}/review-policy
Section titled “GET /api/v1/projects/{project_id}/review-policy”Get the review policy
The project’s policy with its next run and last selection. 404 when it has none.
| Parameter | In | Type | Required | Notes |
|---|---|---|---|---|
project_id |
path | string (uuid) | yes |
| Status | Description | Body |
|---|---|---|
| 200 | Successful Response | application/json: ReviewPolicyOut |
| 422 | Validation Error | application/json: HTTPValidationError |
PUT /api/v1/projects/{project_id}/review-policy
Section titled “PUT /api/v1/projects/{project_id}/review-policy”Set the review policy
Create or replace the policy; omitted fields take their defaults. 404 when the queue
is not this project’s, 422 QUEUE_LACKS_FAILURE_CATEGORY, 422 NOTHING_SELECTED.
| Parameter | In | Type | Required | Notes |
|---|---|---|---|---|
project_id |
path | string (uuid) | yes |
Request body (application/json, required): ReviewPolicyIn
| Status | Description | Body |
|---|---|---|
| 200 | Successful Response | application/json: ReviewPolicyOut |
| 422 | Validation Error | application/json: HTTPValidationError |
POST /api/v1/projects/{project_id}/review-policy/runs
Section titled “POST /api/v1/projects/{project_id}/review-policy/runs”Select a day now
Queue the selection of a completed UTC day, yesterday to 7 days back.
422 DAY_NOT_COMPLETE, 422 DAY_TOO_OLD, 409 ALREADY_SELECTED.
| Parameter | In | Type | Required | Notes |
|---|---|---|---|---|
project_id |
path | string (uuid) | yes |
Request body (application/json, required): RunRequest
| Status | Description | Body |
|---|---|---|
| 202 | Successful Response | application/json: RunRequestedOut |
| 422 | Validation Error | application/json: HTTPValidationError |
GET /api/v1/projects/{project_id}/review-policy/selections
Section titled “GET /api/v1/projects/{project_id}/review-policy/selections”List selections
Newest day first; the history outlives the policy and its queue (queue_id is null
once the queue is gone).
| Parameter | In | Type | Required | Notes |
|---|---|---|---|---|
project_id |
path | string (uuid) | yes | |
limit |
query | integer | no | min 1, max 30 Default 30. |
cursor |
query | string or null | no | max length 512 |
| Status | Description | Body |
|---|---|---|
| 200 | Successful Response | application/json: Page_SelectionOut_ |
| 422 | Validation Error | application/json: HTTPValidationError |