method
RiduClient.acquireDocumentLock
Acquire or renew a document lock, optionally taking over an eligible lease.
Arguments
| Argument | Type | Description |
|---|---|---|
collection | Slug | The collection value. |
id | string | The id value. |
takeover | boolean | | The takeover value. |
options | RequestOptions | | The options value. |
Returns
The declared result.
Promise<DocumentLockEnvelope>Full signature
RiduClient.acquireDocumentLock<Slug extends CollectionSlug<Config>>(
collection: Slug,
id: string,
takeover?: boolean,
options?: RequestOptions,
): Promise<DocumentLockEnvelope>Related types
CollectionSlugThe generated union of collection slugs.
RequestOptionsOptions shared by every request.
DocumentLockEnvelopeThe current lease and whether this request owns or acquired it.