pub.techne.draft.permissioned.deleteRecord

Delete one of your own permissioned records (or a collective's or circle's whose own member space you manage). One key holds one record per space: `space` names which goes; without it, the key's one record, Conflict when there are several. A tombstone stays in listChanges so readers drop their copies. Deleting a missing record is a no-op unless swapCid is given (InvalidSwap), or it names an app's space the caller may not delete in (Forbidden). When the call's token carries space scopes from Techne's ePDS, the delete must name its `space`, and one the scopes do not cover is refused 403 Forbidden. A record written for an app's space is deleted only under `space:` scopes covering it or with no scope claim: anyone else is 403 Forbidden. Draft tier.

Details · procedure
Kindprocedure
Authoritypermissioned.draft.techne.pub
Commit rev3n3iob6o5tw2u
Indexed

Procedure

procedure · POST

Input

application/json

collection

requiredstring · nsid

repo

requiredstring · did

The caller's own DID.

rkey

requiredstring · record-key
  • maxLength: 512

space

string · at-uri

The space the record was written for (its putRecord space). One key holds one record per space (the 0016 record address), so this names which one goes. Absent: the record at the key whatever its space, refused as Conflict when the key holds records for more than one space.

swapCid

string · cid

Delete only if the record's current CID is this one.

Output

application/json

rev

string · tid

The repo revision of the delete. Absent when there was nothing to delete.

Errors

InvalidRequest

HTTP 400. Malformed parameters. Also HTTP 413, 415, 400 or 422 for a request body that is not the method's input (see the description).

Forbidden

HTTP 403. repo is not the caller's own (or a collective's or circle's the caller may write as, see the description); or the call's `space:` scopes do not cover the delete; or the record was written for an app's space (pub.techne.draft.space.private) under `space:` scopes that do not cover a delete there. Nothing is deleted.

LastManager

HTTP 409. The write, as a circle, would leave it with members and nobody at role >= 30. Make someone else manager first. Nothing is written.

AccountDeleting

HTTP 403. The caller's account is being deleted, or is deleted. Nothing is written.

InvalidSwap

HTTP 409. swapCid did not match the current version.

Conflict

HTTP 409. No space was given and the key holds records for more than one space.

AuthenticationRequired

HTTP 401. No credential, or one that fails verification (for a service-auth JWT: wrong aud or lxm, expired, replayed, or an issuer whose key does not resolve right now; retry later in that case).

RateLimitExceeded

HTTP 429. The caller has written faster than its per-DID write limit allows (by default 20 writes a second, a burst of 200; putRecord and deleteRecord each spend one, and putRecords one per call whatever the number of writes it carries; counted per AppView instance). Retry later.

Similar lexicons

semantic match

Lexicons whose schemas describe something close to this one. Check them before publishing a new one that overlaps.

  • Write a record into the caller's own repo, as a permissioned record (the generic private write). The caller authenticates with its own credential: a session from any sign-in lane (OAuth included), or an atproto service-auth JWT (iss = the caller, aud = the AppView's service DID, lxm = this method). repo must be the caller, or a collective or circle the platform holds the credential of whose own member space (`space.collective.member/self`) the caller manages (that space's manage leg alone hands

  • Delete a repository record, or ensure it doesn't exist. Requires auth, implemented by PDS.

  • Delete one of the person's records a frame app writes.

  • Write up to 200 records into the caller's own repo in one call: each write is applied in order, exactly as putRecord applies it (the same admission, receipts, no-op re-put and swapCid), each in its own transaction. NOT atomic: a write that is refused does not undo the writes before it or stop the ones after it, and each write's result says what happened to it. That is why this is not called applyWrites: atproto's com.atproto.repo.applyWrites commits all of its writes or none, and this does not (

  • Delete a record from a space. Callers can delete their own records; the space owner can delete any record (via a separate admin path).