Locks

Acquire a distributed lock

Changed on
post/api/v1/locks/acquire

Request

  • Base URL: http://localhost:8081
  • URL: http://localhost:8081/api/v1/locks/acquire
  • Auth: one of:
    • API key in header X-API-Key
    • HTTP bearer

Headers

X-Tenant-IDstring required

Tenant isolation header (required on all protected routes).

Request body

resourcestring required
ownerstring required
mode'EXCLUSIVE' | 'SHARED'
ttl_msinteger

Lock time-to-live in milliseconds

Response

Lock acquired

resourcestring
mode'EXCLUSIVE' | 'SHARED'
ownersstring[]
updated_atstring date-time
expires_atstring date-time

Changes

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status