Has something like this been considered?

{
  "_id": "abc123",
  "foo": { "bar": [1,2,{ "baz": 3 }] }
}


GET /db/abc123/foo/bar/2/baz

3

PUT /db/abc123/foo/durr [4,5,6]

GET /db/abc123

{
  "_id": "abc123",
  "foo": {
    "bar": [1,2,{ "baz": 3 }],
    "durr": [4,5,6]
  }
}


You'd need a few rules for resolving ambiguities and attachments would probably have to use a different url (_attachment/file?) but it would be very convenient and RESTful.

Reply via email to