Create graph and grant access via REST

Hi,
we are just learning how to use the database server, especially interested in the RDF / SPARQL functionality.
A first and import use case is, that for a given user like “bob”, we can create a graph and give him permission to read or write to the graph. I read in the docs, that I can do via ISQL

sparql create graph <http:/mygraph.de/> ;
DB.DBA.RDF_GRAPH_USER_PERMS_SET ('http:/mygraph.de', 'bob', 2);

This works fine. My question is, can we execute the functionality also via a REST API so that it is possible to programmatically from our app? I could not find the information.

Thanks!

You can connect to Virtuoso via ODBC or JDBC and run the same commands run via isql.

Virtuoso VAL can also be used for setting up access roles to graphs an other resource in the database with the Virtuoso commercial edition.

Note also that you do not have to explicitly create graphs as they will be implicitly created if they don’t exist.

1 Like

Not by default. Naturally, you could expose this functionality as a Stored Procedure published for REST-ful interaction over HTTP, if need be.

1 Like

Thank you for guiding me! The VAL concept sounds very interesting.