Versions Compared

Key

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

Resources

...

Note 3. This does not yet cover authorization.


POST /dataspaces/{dataspace-id}/queries

#OperationPayloadDescription

Modelling storage

1POST /dataspaces/{dataspace-id}/modulesFileCreate (and validate) a module set (upload a model file) for the given dataspace. Payload is a file containing 1 or more yang modules. This operation will also create a dataspace.
2GET /dataspaces/{dataspace-id}/modules
Read all modules in the store for the given dataspace
3GET /dataspaces/{dataspace-id}/modules?namespace="namespace-id"
Read all modules in the store for the given dataspace and namespace
4

GET /dataspaces/{dataspace-id}/modules?namespace="namespace-id"&revision="revision"


Read all modules in the store for the given dataspace, namespace and revision
5DELETE /dataspaces/{dataspace-id}/
Delete the given dataspace 

Anchor persistence

6POST /dataspaces/{dataspace-id}/anchorsJson Object 

Create a new anchor in the given dataspace (payload includes anchor name, module namespace and revision)

7GET /dataspaces/{dataspace-id}/anchors/{anchor-id}
Read an anchor and the associated attributes given a anchor ID and a dataspace.
8DELETE /dataspaces/{dataspace-id}/anchors/{anchor-id}

Delete an anchor given a anchor ID and a dataspace.  This will delete the whole tree

9GET /dataspaces/{dataspace-id}/anchors

Read all anchors in the given a dataspace.

Node persistence

10

POST /dataspaces/{dataspace-id}/nodes

File

Create a (root) node for a given anchor for the given dataspace, the node can have children. Their children will also be persisted as separate nodes in the system.

11GET /dataspaces/{dataspace-id}/anchors/{anchor-id}/nodes

Request body:

{ xpath: { xpath specification  }}

Get a node given an anchor for the given dataspace (return just one level with just xpath references to its children)

12

GET /dataspaces/{dataspace-id}/nodes

Request body:

{ xpath: { xpath specification  }}

Get a node (under any anchor) given a Xpath expression for the given dataspace

13

GET /dataspaces/{dataspace-id}/nodes

Request body:

{ schema_node_identifier: { schema_node_identifierspecification  }}

Get all the relevant nodes given a schema node identifier for the given dataspace
(not need to specify dataspace is schema-node-identifier is globally unique)

Queries
(Alternative for #10-#12 above, see open issue #4)
11POST /dataspaces/{dataspace-id}/anchors/{anchor-id}/queries

Request body:
{ xpath: { xpath specification  }}

Get a node given an anchor for the given dataspace (return just one level with just xpath references to its children)
12POST /dataspaces/{dataspace-id}/queriesRequest body:
{ xpath: { xpath specification  }}
Get a node (under any anchor) given a Xpath expression for the given dataspace
13

Request body:

{ schema_node_identifier: { schema_node_identifierspecification  }}

Get all the relevant nodes given a schema node identifier for the given dataspace
(not need to specify dataspace is schema-node-identifier is globally unique)