Endpoints — Records, DELETE
Every call in this family: what the card records, the edge cases that live on the call, and the verdict of every entry that measured it. Each of those lines names the door holding that entry's rules. The map is corpus/INDEX.md.
DELETE /entity/<type>/<id>
Retires a row at 204 with an empty body. It is not erased: the row reads 404 normally and 200 under options[return_only]=retired, and a second delete is 404.
Retired, not erased. Anything counting rows has to decide which of those two it means, and the default for every read is live-only.
The correct spelling is
options[return_only]=retired.options[retired_only]=trueis accepted at 200 and silently ignored, which reads as "there are no retired rows".A second delete is 404, so delete is not idempotent in its status code even though it is in its effect.
Measured by
060_entity_dict_name(findings) — Thenamein an entity dict is the target'scached_display_name, filled on every type measured, single and multi alike. Read it, not the per-type identity field, and expect decoration.
rules:doors/findings-read024_read_after_write(findings) — Every write ignores ?fields. A create returns what you sent plus the server defaults, an update returns the whole record, and neither resolves a dotted path, so re-read for those and after an upload.
rules:doors/findings-write078_page_setting_write(findings) — A script cannot create a Page (HumanUser expected), a person can. settings_json writes only as a JSON string, reads back identical. DELETE on a PageSetting is 400: every created row is permanent.
rules:doors/findings-write084_task_template_reapply(findings) — Changingtask_templateto T creates a Task per T task no Task links bytemplate_task, duplicating a same-name hand-made one, and re-syncs the linked Tasks' fields and edges (probe 102).
rules:doors/findings-write089_task_delete_side_effects(findings) — Deleting a Task retires its TaskDependency rows, unlinks both neighbours without bridging them, and nullsVersion.sg_taskandPublishedFile.task. Revive restores all of it.
rules:doors/findings-write094_permission_preflight(findings) — Ask with a write that cannot land: a no-op PUT per field (update), a POST with a bad status (create), a _batch of [delete, 404 sentinel] (delete). Permission is checked first, and nothing is written.
rules:doors/findings-write095_dependency_remove_undo(findings) — Remove an edge withDELETEon its TaskDependency row: revive restores its type and offset. Aremoveonupstream_tasksordownstream_taskserases the row for good.
rules:doors/findings-write096_task_template_unmerge(findings) — A template write re-syncs every Task linked to it: fields but status reset, edges rewired. Undo: old template_task per Task first, then old task_template, then delete what B made.
rules:doors/findings-write098_template_merge_in_one_batch(findings) — Recipe 015's merge fits one_batch: requests run in order, so atask_templatewrite sees claims made earlier in the batch, andnullthenTon the same Shot re-runs the apply.
rules:doors/findings-write101_template_edge_conflict(findings) — On a claimed pair, a template apply replaces an existing edge of another type, or the reverse edge, with the template's edge: the old row is erased, not retired, and the PUT is a plain 200.
rules:doors/findings-write102_task_template_resync(findings) — Writing task_template T re-syncs every Task linked to T: T's non-empty values overwrite, status kept, dates and assignees kept or filled if empty; edges between linked Tasks reset to T's.
rules:doors/findings-write103_batch_delete_revive(findings) — Adeleteinside_batchretires a Task or TaskDependency exactly asDELETEdoes: same retired read-back, and revive returns the same id, fields, edges andVersion.sg_task.
rules:doors/findings-write104_template_unmerge_in_one_batch(findings) — Recipe 019's undo fits one_batchwith the same end state, if the batch skips edges its own task_template write removes: deleting one 404s and rolls back all. Undo to null deletes them.
rules:doors/findings-write105_offset_days_null_vs_zero(findings) — TaskDependencyoffset_daysnull and 0 are stored and compared as different: a template apply deletes an entity edge with null against a template 0 (or the reverse) and re-creates it with a new id.
rules:doors/findings-write106_template_task_linked_twice(findings) — With two Tasks linked to one template task, an apply re-syncs and wires only one of them, picked unpredictably (not by id, age or edges); the other is left as is. No error, nothing duplicated.
rules:doors/findings-write107_dependency_three_task_loop(findings) — A three-Task loop is a 400 on a direct create and inside_batch, which rolls back whole. A template apply deletes a claimed Task's upstream edge from a Task outside the template, loop or not.
rules:doors/findings-write108_task_template_resync_empties(findings) — Re-sync to T: a numeric 0 on T's task overwrites (est, duration); milestone false and "" (stored null) keep the Task's value; a Task with only start or only due keeps its null duration.
rules:doors/findings-write109_template_apply_outside_edge(findings) — A template apply erases an edge where a linked Task depends on a Task not linked to the template (root or not, other template, other Shot); it kept the edge with the outside Task downstream.
rules:doors/findings-write110_template_task_after_revive(findings) — Revive restorestemplate_task. A task_template write while the Task is retired re-creates it, so a later revive leaves two Tasks on one template task. Revive first, then write.
rules:doors/findings-write111_template_undo_outside_edge(findings) — An undo's write back to template A erases every edge whose downstream Task is A-linked and that A lacks, pre-merge edges included; recipe 022 DELETEs one such edge, 404s and rolls back.
rules:doors/findings-write112_template_unmerge_linked_twice(findings) — Undo relinking two Tasks to one template task: A wires either one (11 of 14 picked the loser), nothing is made. Relink the loser after the task_template write: then it matches the one-link undo.
rules:doors/findings-write113_batch_atomic_after_template_write(findings) — A_batchholding atask_templateapply is atomic: a later or earlier failing request left no Task, no claim, no field write, no edge and no EventLogEntry row.
rules:doors/findings-write136_unique_scope_retired(findings) — A deleted row frees itsuniquevalue: a new row may take it. Reviving the old row while another holds the value is a 400 code 104 PG transaction error, and the row stays retired.
rules:doors/findings-write143_nonadmin_rows(findings) — On the probed site an Artist may not create, edit or delete custom-entity rows (status only) and may create but not delete an Attachment, its own included. The group rights call predicts each answer.
rules:doors/findings-write156_action_menu_item(findings) — An ActionMenuItem creates from{}at 201 andurlis not checked; an Artist is refused. Run from the web interface, an httpurlgot a form POST in a new tab,jsonor not, with no token.
rules:doors/findings-write161_link_to_deleted_row(findings) — A link to a deleted row is hidden, not removed: it reads null or drops out, and returns on revive, even after a replace. A write naming a deleted row is 400 code 104Value is not legal.
rules:doors/findings-write164_vendor_writes(findings) — On the probed site a Vendor creates no Bid or Bid Line, by POST or_batch, and updates onlysg_status_list, each refusal 400 code 104. Both preflight reads predicted every answer.
rules:doors/findings-write168_group_create_rights(findings) — On the probed site a Manager or Admin person creates, renames, re-members and retires any Group; Artist and Vendor get 400 code 104. The person's own group rights on Group predict each answer.
rules:doors/findings-write025_event_log(findings) — meta.old_value and meta.new_value answer "what was this before", but meta is unfilterable and unsortable: narrow on entity, event_type and attribute_name, sort -id, read meta yourself.
rules:doors/findings-observe049_script_events(findings) — A script's writes reach the event log only while its ApiUser has generate_event_log_entries True. The default is False and nothing errors when off. One create logs one row per field plus one _New.
rules:doors/findings-observe013_publish_file_bytes(recipes) — Publish a file's bytes onto a PublishedFile when the caller has no LocalStorage root to write under
rules:doors/recipes018_remove_and_restore_a_dependency(recipes) — Remove one dependency between two Tasks and put it back on undo, with its type and offset
rules:doors/recipes019_undo_task_template_merge(recipes) — Undo a task template merge, returning an entity's Tasks, fields and dependencies to their state before it
rules:doors/recipes
Silent on this call
024_read_after_write— Every write ignores ?fields. A create returns what you sent plus the server defaults, an update returns the whole record, and neither resolves a dotted path, so re-read for those and after an upload.025_event_log— meta.old_value and meta.new_value answer "what was this before", but meta is unfilterable and unsortable: narrow on entity, event_type and attribute_name, sort -id, read meta yourself.049_script_events— A script's writes reach the event log only while its ApiUser has generate_event_log_entries True. The default is False and nothing errors when off. One create logs one row per field plus one _New.
corpus/endpoints/delete_entity_type_id.md