Skip to main content
POST
Revoke a direct-share link (owner or mod)
Invalidates the token. Existing acceptances stay until removed separately. Withdrawal is always allowed.

Authorizations

Authorization
string
header
required

Organisation API key from Settings → API / /api/keys/. The secret is shown once. Send Authorization: Bearer sk-abacus-…. One active key per organisation. Ingest (/api/v2/ingest/*) refuses API keys — that surface is Auth0-only with ingest:read / ingest:write scopes.

Path Parameters

id
integer
required

Response

Output projection for a :class:DirectShareLink row.

Composed for the list endpoint (owner-side roster) and as the response body of every mutation endpoint.

The acceptances field carries the roster — recipients do NOT see other users' acceptances (Decision 33), so the view layer is responsible for nulling this out (or using a different serializer class entirely) on recipient-facing endpoints.

The url field is the fully-qualified token-landing URL, built from the request's build_absolute_uri when available. Falls back to a relative path otherwise.

id
integer
required
read-only
content_type
string
required
read-only
object_id
integer
required
read-only
content_object_summary
object | null
required

Tiny shape: just enough to render a share row in the UI.

Mirrors :class:deckmonkey.api_v2.library.serializers._ContentObjectSummarySerializer so the SPA's orval client gets a stable shape between org-library and direct-share surfaces. For Struct rows: {"id", "slug", "name", "status", "kind"}; for Batch rows: {"id", "name", "status", "kind"}.

Named with a _DirectShare prefix to avoid a drf-spectacular component-name collision with the org-library serializer of the same role (same shape, but spectacular keys components by Python class name).

token
string
required
read-only
url
string | null
required
read-only
created_by
object | null
required

Compact user projection for created_by / revoked_by / accepted_by.

Named with a _DirectShare prefix to avoid a drf-spectacular component-name collision with :class:deckmonkey.api_v2.library.serializers._ActorSerializer.

created_at
string<date-time>
required
read-only
revoked_at
string<date-time> | null
required
read-only
revoked_by
object | null
required

Compact user projection for created_by / revoked_by / accepted_by.

Named with a _DirectShare prefix to avoid a drf-spectacular component-name collision with :class:deckmonkey.api_v2.library.serializers._ActorSerializer.

is_revoked
boolean
required
read-only
note
string
required
read-only
acceptances
object[]
required
read-only