ietf-wg-httpapi / idempotency

Repository for "The Idempotency-Key HTTP Header Field"
Other
17 stars 10 forks source link

Reuse of idempotency key #22

Closed hartmark closed 1 year ago

hartmark commented 1 year ago
   If there is an attempt to reuse an idempotency key with a different
   request payload, the resource server SHOULD reply with a HTTP "422"
   status code with body containing a link pointing to relevant
   documentation.  The status code "422" is defined in Section 11.2 of
   [RFC4918].

There's no mention if "request payload" includes the URI of the request.

For example having a rest-API where the client sends a JSON-payload like { "user" : "hartmark" } it would be undesirable if it wouldn't respond 422 if that JSON-payload is used at another URI.

sdatspun2 commented 1 year ago

@hartmark Sorry I don't understand. Can you elaborate with 2 requests here? Thanks.

hartmark commented 1 year ago

I don't even myself understand what I posted 😀

I'll close this and reply if I remember what I was thinking