Skip to content

Commit

Permalink
XS✔ ◾ ✏️ Changed POST to GET (#9513)
Browse files Browse the repository at this point in the history
* ✏️ Changed POST to GET

* Update rules/rest-api-design/rule.md

Co-authored-by: Daniel Mackay [SSW] <[email protected]>

---------

Co-authored-by: Daniel Mackay [SSW] <[email protected]>
  • Loading branch information
jeoffreyfischer and danielmackay authored Oct 31, 2024
1 parent fd9cfef commit 2e38da7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion rules/rest-api-design/rule.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@ This provides a much more consistent API structure when querying both collection

### 3. Idempotent requests

Design `POST`, `PUT`, and `DELETE` operations as idempotent, where repeating an action yields the same result as performing it once. This avoids unintended actions from repeated requests.
Design requests as idempotent operations, where repeating an action yields the same result as performing it once. This avoids unintended actions from repeated requests.

Typically, `GET`, `PUT` and `DELETE` are idempotent by default, but special handling needs to be added to make `POST` requests idempotent.

::: greybox
If a `DELETE` request removes a record, re-sending it should not throw errors if the record is already deleted.
Expand Down

0 comments on commit 2e38da7

Please sign in to comment.