-
Notifications
You must be signed in to change notification settings - Fork 196
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
isn't it should be M2 to M3 instead of to M2 to N3? #57
Comments
409 "indicates that the request could not be completed due to a conflict with the current state of the resource." as per https://tools.ietf.org/html/rfc7231#section-6.5.8
You are conflating "state of the resource" with state in general, i believe. In this case of the diagram, the request is meant to create a new resource, thus it cannot logically hit a 409 because there is no resource state to conflict with.
It may conflict with the general state e.g. POST /mygarage/cars -> 409 "garage is already full" but that can (should, by some API patterns) be a two-requests step: 1. Create the car (POST /cars -> 201 /cars/id123; will work no matter how full the garage is) 2. Add it to the garage (POST /mygarage add car id123 to my garage), and this time the request goes via the process section of the diagram and may return 409 "garage is already full". Did i lose you or do you understand the difference?
I must note though that all the 500 blocks in the diagram mean "anything goes, i cannot come up with a generic logical flow so you know better from here on", not "you must return 500". I think i mentioned that somewhere, if not - i should.
… On 15 Jan 2020, at 22:15, Septian Wibisono ***@***.***> wrote:
How if i create with method POST and endpoint create (create_path) but has conflict or duplicate. isn't it should be M2 to M3 instead of to M2 to N3?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Understood. According to this diagram, how to prevent conflict when posting same content of field?
I don't know whats inside, so i can't afford PUT. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
How if i create with method POST and endpoint create (create_path) but has conflict or duplicate. isn't it should be M2 to M3 instead of to M2 to N3?
The text was updated successfully, but these errors were encountered: