409 Conflict
The HTTP status meaning the request conflicts with the current state of the resource.
In more detail
Typical causes are a change that would break a uniqueness rule, an edit based on an outdated version, or a retry that arrives while the original request with the same idempotency key is still being processed. The client needs to resolve the conflict rather than simply repeat the request.
Example
In the APIs course: the service answers 409 when an idempotency key is reused with a different request body.Related terms
- idempotency key — A unique value a client sends with a non-idempotent request, such as a create, so the server can recognise a retry and return the original result instead of acting twice.
- request fingerprint — A value, often a hash, calculated from the important parts of a request so the server can tell whether a repeated request is really the same one.
- HTTP status code — The three-digit number at the start of a response, such as 200 or 404, that says how the server handled the request.
- Problem Details — A standard JSON shape for HTTP error responses, defined in RFC 9457, with members such as type, title, status, detail and instance.
Taught in
- Idempotency Keys — Modern API Architecture: REST, GraphQL & gRPC
- Global Exception Handling and Problem Details — Modern .NET Core, C# & Enterprise Microservices
- Exception Handling To Problem Details — Modern Java: Virtual Threads & High-Throughput Services