You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs(V2): document referential integrity guards for remaining DELETE endpoints
Add Referential integrity notes and 409 response examples to validation,
location, and project-methodology DELETE sections. Add Cascade delete notes
and stagedChildDeletes to verification and issuance DELETE sections. Fix
stale success message strings that said 'deletion' instead of 'delete'.
Copy file name to clipboardExpand all lines: docs/cadt_rpc_api_v2.md
+50-8Lines changed: 50 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2764,20 +2764,32 @@ Response
2764
2764
2765
2765
**Note**: The ID in the URL path is the `cadTrustValidationId`.
2766
2766
2767
+
**Referential integrity**: If any committed or staged (`INSERT`/`UPDATE`) `verification` records reference this validation via `cadTrustValidationId`, the request returns `409 Conflict` until those references are removed. References from any synced registry count the same.
**Note**: The ID in the URL path is the `cadTrustVerificationId`.
2939
2951
2952
+
**Cascade delete**: Deleting a verification automatically stages DELETE entries for all child issuances and their units. The `stagedChildDeletes` field in the response reports the total number of child rows staged.
**Note**: The ID in the URL path is the `cadTrustLocationId`.
3112
3127
3128
+
**Referential integrity**: If any committed or staged (`INSERT`/`UPDATE`) `issuance` records reference this location via `cadTrustLocationId`, the request returns `409 Conflict` until those references are removed. References from any synced registry count the same.
**Note**: The ID in the URL path is the `cadTrustIssuanceId`.
3278
3305
3306
+
**Cascade delete**: Deleting an issuance automatically stages DELETE entries for all child units and their unit labels. The `stagedChildDeletes` field in the response reports the total number of child rows staged.
**Note**: The ID in the URL path is the `cadTrustProjectMethodologyId`.
4505
4535
4536
+
**Referential integrity**: If any committed or staged (`INSERT`/`UPDATE`) `issuance` records reference this project-methodology link via `cadTrustProjectMethodologyId`, the request returns `409 Conflict` until those references are removed. References from any synced registry count the same.
"message": "Cannot delete project-methodology relationship: it is still referenced by 2 issuance records. Remove those references before deleting this project-methodology relationship.",
4557
+
"error": "Referenced records must be removed before deletion",
0 commit comments