Create a legal hold
⚠️
Preview — this feature is being built; the design below is the spec.
POST https://app.syntic.ai/v1/compliance/legal_holdsPreserve records for named people from a date onward, overriding retention and deletion until the hold is released. Holds apply within a minute and are themselves recorded as activities. Requires compliance:write.
For how this fits into a full workflow, see Compliance API.
Headers
| Header | Required | Value |
|---|---|---|
Authorization | Yes | Bearer <admin key>: an Admin API key (sk_admin_...) that carries the compliance:read scope (plus compliance:write for deletions and holds). Enterprise plans only. See Compliance API. |
syntic-beta | Yes, while in preview | compliance-2026-12-01. Without it the call fails with 400 beta_required. See Versioning. |
Content-Type | Yes | application/json |
Idempotency-Key | No | Up to 255 characters. Retrying with the same key within 24 hours returns the first result instead of acting twice. See Idempotency. |
Body parameters
| Parameter | Type | Required | Notes |
|---|---|---|---|
name | string | Yes | Up to 120 characters, such as a matter number. |
user_ids | array of strings | Yes | 1 to 1,000 people. |
kinds | array of strings | No | Default: all four kinds. |
starting_at | string | No | Default: everything still stored. |
ending_at | string | No |
Response
201 Created, Content-Type: application/json
{
"id": "hold_01JD02A4C6E8G0J2L4N6",
"type": "legal_hold",
"name": "Matter 2026-117",
"user_ids": [
"user_01J9Y0A2C4E6G8J0L2N4"
],
"kinds": [
"chats",
"projects",
"code_sessions",
"files"
],
"starting_at": "2026-06-01T00:00:00Z",
"ending_at": null,
"status": "active",
"created_by": "adminkey_01JC0Z2B4D6F8H0K2M4P",
"created_at": "2026-11-05T10:00:00Z",
"released_at": null
}| Field | Type | Description |
|---|---|---|
kinds | array | Record kinds kept under hold. |
ending_at | string or null | null covers records created up to the moment the hold is released. |
status | string | active or released. While active, matching records are not deleted by retention, by the person, or by the delete calls above. |
Examples
curl -sS "https://app.syntic.ai/v1/compliance/legal_holds" \
-H "Authorization: Bearer $SYNTIC_ADMIN_KEY" \
-H "syntic-beta: compliance-2026-12-01" \
-H "Idempotency-Key: 8d6f0c1e-4b2a-4a57-9f0e-2f1d3c4b5a69" \
-H "Content-Type: application/json" \
-d '{
"name": "Matter 2026-117",
"user_ids": [
"user_01J9Y0A2C4E6G8J0L2N4"
],
"starting_at": "2026-06-01T00:00:00Z"
}'Errors
Errors use the error envelope and carry a request_id. Codes specific to this operation:
| Status | type | code | When |
|---|---|---|---|
| 400 | invalid_request_error | beta_required | The syntic-beta header is missing. |
| 401 | authentication_error | invalid_api_key | The admin key is missing, unknown, revoked or expired. |
| 403 | permission_error | admin_key_required | An inference key was used. |
| 403 | permission_error | scope_missing | The admin key lacks the compliance:read (or, for writes, compliance:write) scope. |
| 429 | rate_limit_error | rate_limited | Too many requests; wait for Retry-After. See Rate-limit headers. |
Was this page helpful?