PUT/api/orgs/{org_id}/retention/keeps/{kind}/{target}

Keep or release an item

A kept request (or every request of a kept session) is not deleted by expiry. Only stored content can be kept. Turning storage off or deleting content still removes it. Any member or key.

Authentication: Bearer API key in the Authorization header

Path parameters

  • org_idstringrequired

    Your organization id (uuid). GET /api/whoami returns it.

  • kindenumrequired

    request or session.

    "request""session"
  • targetstringrequired

    The request id or session id.

Request body

  • keepbooleanrequired

Responses

  • 200

    Keep state.

    Response
    • kindenum
      "request""session"
    • idstring
    • keptboolean
    • kept_atstring | null
    • kept_by_emailstring | null
    • expires_atstring | null

      When its content expires; null while it is kept or has no expiry.

    • storedboolean

      Whether content is stored for it.

  • 401

    Missing, unknown or revoked API key.

    Response
    • errorstringrequired

      Human-readable message.

    • codestring

      Stable machine reason, when the route defines one (for example pro_required).

    • actionstring

      Stable remediation action, when the route defines one.

    • detailsobject

      Customer-safe string facts the caller needs to act (for example a suggested identifier).

  • 404

    The resource does not exist or belongs to another organization.

    Response
    • errorstringrequired

      Human-readable message.

    • codestring

      Stable machine reason, when the route defines one (for example pro_required).

    • actionstring

      Stable remediation action, when the route defines one.

    • detailsobject

      Customer-safe string facts the caller needs to act (for example a suggested identifier).

  • 409

    Nothing is stored for this item (not_stored), or a contract fixes expiry.

    Response
    • errorstringrequired

      Human-readable message.

    • codestring

      Stable machine reason, when the route defines one (for example pro_required).

    • actionstring

      Stable remediation action, when the route defines one.

    • detailsobject

      Customer-safe string facts the caller needs to act (for example a suggested identifier).

Request

curl -X PUT 'https://api.experientiallabs.ai/api/orgs/3f6c2a1e-8b7d-4c2a-9e51-6a0d4b2f7c10/retention/keeps/request/req_01JD8ZK4M2Q7V9X3N5T6B8C0EF' \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
  "keep": true
}'

Response

{
  "kind": "request",
  "id": "req_01JD8ZK4M2Q7V9X3N5T6B8C0EF",
  "kept": true,
  "kept_at": "2026-11-18T14:40:00Z",
  "kept_by_email": "ana@example.com",
  "expires_at": null,
  "stored": true
}

https://api.experientiallabs.ai/api/orgs/3f6c2a1e-8b7d-4c2a-9e51-6a0d4b2f7c10/retention/keeps/request/req_01JD8ZK4M2Q7V9X3N5T6B8C0EF