...
- HTTP Verb: POST
- URL: /objects/$pid/fedora-system:SomeBuiltInSDef/updateDatastream?dsID=$dsID&type=sparql-update
- Body: A SPARQL/Update document (UTF-8?) to apply to the datastream
- Successful response:
- Code: 201 200
- Location header: URL to datastream version
- Content-type header: text/plain; charset=utf-8
- Body: URL to datastream version
- Failed response (bad request):
- Code: 400
- Content-type header: text/plain; charset=utf-8
- Body: (one-line message)
- Unrecognized update type: $type
- No such object: $pid
- No such datastream in $pid: $dsID
Notes:
...
- Adding or modifying the entire content of a datastream would still be possible via a POST or PUT, respectively, to the datastream URL as it is today.
- The syntax for invoking disseminations has not yet been decided for the REST API; the URL above with fedora-system:SomeBuiltInSDef assumes an obvious possible syntax.
Outstanding Issues:
- Does SPARQL Update have a mime type? If so that might make sense to use as the value of the type parameter
- The strawman does not yet include a way to get relationships. Perhaps this could also be a built-in function of SomeBuiltInSDef.
- Q: Would it require one to specify which datastream (e.g. RELS-EXT) the relationships reside in?
- Q: What form of query would it accept? A simple S,P,O style query, or SPARQL?
...