I've been wrestling with the problem of representing a checkout / checkin system via a REST api.
To give you a small example our system handles nodes and we need a way for one user to be able to lock this node and then make changes to it and then commit it.
So I was thinking something like
/nodeId
(this is the base location for a node and provides an up to date checked in revision read only view of the node)/nodeId/edited
(posting to here creates an edited version of the doc this is checkout, gettting gets the edited version, and putting makes a change)
Now I want to represent checkin, im tempted to say that POSTing to /nodeId/edited
again will commit the edited document but then we are, giving post two distinct meanings. I could create another checkin endpoint but that seems messy? Another alternative is having a POST to /nodeId which creates the edited version but again this seems confused.