Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

To create a new EditorialObject, use class instance, send a POST request using the following curl command to send a POST request. Ensure that the namedGraph key and value (namedGraph specifies the graph in the triplestore where your information is preserved), are included in the post POST body with the information you want to create. Passing the namedGraph is necessary when using ENAPSO together with the free version. Additionally, you can include an optional namespace variable, which is used to create a unique IRI by attaching it to the IRI before the UUID.

Code Block
languagebash
curl -X POST "http://localhost/enapso-dev/view-management/v1/editorialObject" -H "Content-Type: application/json" -d "{\"namedGraph\": \"http://ontwww.enapso.comebu.ch/metadata/ontologies/ebucoreplus/demoDatademodata\",\"variablesnamespace\": {\"iri\": \"http://ont.www.ebu.ch/metadata/ontologies/ebucoreplus/demodata/custom\",\"variables\": {\"iri\": \"http://ont.enapso.com/sparql-template#EditorialObject_2f9b1462-e937-4416-8c23-ce96fc42dc55\", \"title\": \"Never Look Away\", \"shotLog\": \"Visual storytelling that captures the protagonist artistic journey and the tumultuous history of Germany.\"}}"

...

To retrieve information about EditorialObject instances with limit and offset parameters, The limit parameter specifies the maximum number of results to return, while the offset parameter specifies the starting point in the list of results, effectively skipping the first offset number of results offset number of results. you can use the following curl command:

Code Block
curl --get "http://localhost/enapso-dev/view-management/v1/editorialObject?limit=10&offset=10"

...

Passing namedGraph Parameters

To retrieve information about EditorialObject instances with namedGraph parameters, The namedGraphparameter retrieves the class instances from a specific namedGraph of the graph database repository. you can use the following curl command:

Code Block
curl --get "http://localhost/enapso-dev/view-management/v1/editorialObject?limit=10&offset=10""   --data-urlencode "namedGraph=http://www.ebu.ch/metadata/ontologies/ebucoreplus/demodata"

...

Passing Filters

You can pass filters using the filter.propertyName=value format in the query parameters. For example, if the property IRI is http://www.ebu.ch/metadata/ontologies/ebucoreplus#title, you will use the property name title after the hash.

...

Code Block
languagebash
curl -X PATCH "http://localhost/enapso-dev/view-management/v1/editorialObject" -H "Content-Type: application/json" -d "{\"namedGraph\": \"http://ontwww.enapso.comebu.ch/metadata/ontologies/ebucoreplus/demoDatademodata\",\"variables\": {\"iri\": \"http://ont.enapso.com/sparql-template#EditorialObject_2f9b1462-e937-4416-8c23-ce96fc42dc55\", \"productionSynopsis\": \"Directed by Florian Henckel von Donnersmarck, this sweeping historical drama delves into themes of art, love, tragedy, and the inescapable impact of politics on personal lives.\"}}"

...

Code Block
languagebash
curl -X DELETE "http://localhost/enapso-dev/view-management/v1/editorialObject" -H "Content-Type: application/json" -d "{\"namedGraph\": \"http://ontwww.enapso.comebu.ch/metadata/ontologies/ebucoreplus/demoDatademodata\",\"variables\": {\"iri\": \"http://ont.enapso.com/sparql-template#EditorialObject_2f9b1462-e937-4416-8c23-ce96fc42dc55\"}}"

...