Should I POST to the collection when creating a resource with a known ID in my REST API? -


i'm implementing new rest api. in api typically post collections create resources. 1 of resources, id known before created. make more sense post collection id in body or post instance (as yet non-existent) id in url?

i'd keep existing endpoint , add id in body when posting collection, there's no point in adding new separate route what's same thing.


Comments

Popular posts from this blog

Ansible warning on jinja2 braces on when -

Parsing a protocol message from Go by Java -

javascript - Replicate keyboard event with html button -