Skip to content
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

Changing HTTP Statuscode from 200 to 204 for endpoints with not defined response bodies #87

Open
janpmeyer opened this issue Apr 12, 2023 · 4 comments

Comments

@janpmeyer
Copy link

In the specification for the HTTP-Bindings of the Contract Negotiation and TransferProcess exists some endpoints with no specified response body. (Endpoints are listed at the bottom, Contract Negotiation, Transfer Process)
A clean solution is to introduce an empty response body and change the expected status code from 200 to 204.

Contract Negotiation Provider:
negotiations/:id/request
negotiations/:id/events
negotiations/:id/agreement/verification
negotiations/:id/termination

Contract Negotiation Consumer:
negotiations/:id/offers
negotiations/:id/agreement
negotiations/:id/events

Transfer Process:
transfers/:id/start
transfers/:id/completion
transfers/:id/termination
transfers/:id/suspension

@sebbader-sap
Copy link
Contributor

Thanks @janpmeyer for raising this topic, we have discussed it in our working group call today. We agree that 204 is better and will change the document accordingly soon.

@sebbader-sap
Copy link
Contributor

We just need to figure out if the descriptions in https://www.rfc-editor.org/rfc/rfc9110#name-204-no-content conflict with the intended state transitions.

@sebbader-sap
Copy link
Contributor

It's a little bit late to introduce such changes (our fault), however, I have prepared an PR for it to speed up the discussion.

@sebbader-sap
Copy link
Contributor

Any reason why a response body (and thereby 200) would be required? If not, a 204 certainly reduces confusion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants