Undo a soft collection delete
Restores a collection that is still inside its grace window (status=deletion_pending) back to active, cancelling the… (POST /v1/collections/{id}/restore)
/v1/collections/{id}/restore- Auth
- Bearer API key
- Billing
- free (0 credits).
Restores a collection that is still inside its grace window
(status=deletion_pending) back to active, cancelling the scheduled
purge. The collection keeps the same incarnation, and any batch work that
was paused by the delete resumes. Free and idempotent.
Returns 409 once the purge has actually started (status=deleting) —
vectors are being erased at that point, so a restore could not honestly
return the collection intact. Also 409 for a compliance-class erasure,
which is deliberately not restorable.
Example request
curl -X POST "https://api.sightradar.com/v1/collections/$ID/restore" \
-H "Authorization: Bearer $SR_API_KEY"Parameters
| Name | In | Type | Description |
|---|---|---|---|
id required | path | string | Collection id. |
Response body
| Field | Type | Description |
|---|---|---|
status | string | |
message | string |
Status codes
| Status | Meaning |
|---|---|
200 | Collection restored. |
401 | Missing or invalid API key. |
403 | Account is read-only. |
404 | Resource not found. |
409 | Not restorable — the purge has already started, or this was a compliance-class erasure. |
Delete a collection (soft by default, restorable)
Schedules a durable cascade delete — all faces and selfies are removed asynchronously. (DELETE /v1/collections/{id})
Undo a soft photo delete
Un-deletes a soft-deleted photo's faces so they are searchable again. (POST /v1/collections/{id}/photos/{photoId}/restore)