I have a design of a person having a collection of subjects like Person ---> Subject (1 to many)
If I access a person with an Id of 1 (http://localhost/person/1
),
it will show all the person's details and the collection details.
How do I design a URL for just accessing the subjects for the person?
Should it be
http://localhost/person/1/subjects
?
Can I post to that URL to add subjects?
Can I put to that URL to update the subjects?
What handler should handle subjects of a person? Should it be a subject handler with Get and a personid parameter or a person handler returning a collection of subjects with a return method of subjects?