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

make /api/import endpoint return HTTP 201 + Location header on creating new record #1243

Open
hornc opened this Issue Oct 3, 2018 · 0 comments

Comments

Projects
None yet
1 participant
@hornc
Collaborator

hornc commented Oct 3, 2018

Currently the import endpoints return HTTP 200 responses on success with a body like

{"edition": {"status": "created", "key": "/books/OL5M"}, "work": {"status": "created", "key": "/works/OL1W"}, "success": true}

This should be changed to a 201 response, and the response header should include a Location pointing to the newly created edition record.

If no item is created, but existing items are modified then the response should be 200.

@hornc hornc added the import label Oct 3, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment