How would I connect two resources in Rest? Like putting a label on a document? create both /label and /document resource โ€ฆ and ?
3
@owehrens Depends on what your model actually is, but how about adding a label via POST to .../labels/ ?
1
@stilkov I got that but how to put the label on the document ?
1
Replying to @owehrens
@owehrens POST to ./labels to add one, PUT with a list of labels to replace them

Dec 12, 2012 ยท 5:47 AM UTC

1
Replying to @stilkov
@stilkov @owehrens So its documents/id/labels/? And you also have a resource for labels/ when you just work with labels?
2
@jacobfahrenkrug @owehrens If that's a use case, sure. I'm not sure whether your labels are just that - labels - or resources of their own