Look up a resource.
Retrieves the resource identified by entry. The result holds only the members named by the model
Template, and expands the linked resources the template reaches. Values are typed after the shape:
the template states which members are wanted, not what they are.
Multi-valued members are retrieved as collections. Filtering, ordering and pagination constraints are stated under the member name, next to its retrieval keys. A Projection stated there in place of a template returns rows of computed values, keyed by the names of its bindings. A collection with no matching item is omitted from the result, like any other member without a value.
shape and model are kept distinct so that a single shape can serve many retrieval templates. For
example, a server may wire one shape at startup and accept any admissible model decoded from each client
request. A template retrieving every member the shape declares MUST be written out explicitly.
By default, model templates support the full query language, including aggregate transforms and nested
expansion. When exposing retrieval to untrusted clients, restrict query complexity through the
scope: set plain to true, depth to 0 or a positive value, and/or limit to a
maximum result set size.
The resource to retrieve, the shape describing it and the template narrowing it
Optionalscope: StoreScopeThe retrieval scope, bounding model and setting the locale priority
A promise resolving to an immutable copy of the resource data narrowed to the members model names,
or to undefined if the resource is not present in the store; rejects with a RangeError if
entry is not an absolute IRI, a TraceError if model doesn't validate against the shape,
or a Problem on network, storage, or other processing errors
Create a resource.
Adds a new resource to a collection held by the resource identified by entry. The collecting property is the
single multi-valued property named by model, and the new resource is stored as described by the shape that
property ranges over. Nothing is created if a resource already exists under the identifier of the new one.
The new resource is identified by the id of its state, which must be nested under entry. If id is left
out, the store mints one under entry, following the identifier pattern declared
by the collected shape, if any. Each {name} slot is filled with the like-named member of state, which must
be a single path segment. Any other slot is filled with an opaque segment. A remote store may leave the choice
of identifier to the service holding the collection.
Specific reference kinds are handled as follows:
state is always validated at depth 0The shape driving the creation, describing the collecting resource
The collection slice, naming the collecting property
The resource collecting the new one, the shape describing it, the slice naming the collecting property and the initial state of the new resource
A promise resolving to the Reference identifying the created resource, or to undefined
if a resource already exists under that identifier; rejects with a RangeError if entry is
not an absolute IRI, if state carries an id not nested under entry or if a member filling an identifier
slot is not a single path segment, a TraceError if model or state doesn't validate
against the shape, or a Problem on network, storage, or other processing errors
Update a resource.
Replaces the resource's own data if the resource already exists, fully removing any previously existing embedded data. Specific reference kinds are handled as follows:
state is always validated at depth 0The shape driving the update, describing the state
The resource to update, the shape validating it and its replacement state
A promise resolving to the entry Reference of the updated resource, or to undefined
if the resource doesn't exist; rejects with a RangeError if entry is not an absolute IRI
or if state carries an id differing from entry, a TraceError if state doesn't validate
against the shape, or a Problem on network, storage, or other processing errors
Delete a resource.
Removes the resource's own data and clears references to it from other resources, if the resource exists. Specific reference kinds are handled as follows:
The shape driving the deletion, identifying the data cascaded with the resource
The resource to delete and the shape identifying the data cascade-deleted with it
A promise resolving to the entry Reference of the deleted resource, or to undefined
if the resource doesn't exist; rejects with a RangeError if entry is not an absolute IRI,
or a Problem on network, storage, or other processing errors
Insert a resource.
Unconditionally inserts or replaces the resource's own data, fully removing any previously existing embedded data. Specific reference kinds are handled as follows:
state is always validated at depth 0The shape driving the insertion, describing the state
The resource to insert, the shape validating it and its state
A promise resolving to the entry Reference of the inserted resource; rejects with a
RangeError if entry is not an absolute IRI or if state carries an id differing from
entry, a TraceError if state doesn't validate against the shape, or a Problem on
network, storage, or other processing errors
Remove a resource.
Unconditionally removes the resource's own data and clears references to it from other resources. Specific reference kinds are handled as follows:
The shape driving the removal, identifying the data cascaded with the resource
The resource to remove and the shape identifying the data cascade-removed with it
A promise resolving to the entry Reference of the removed resource; rejects with a
RangeError if entry is not an absolute IRI, or a Problem on network, storage, or
other processing errors
Model-driven resource CRUD operations.
Persists and retrieves linked data resources as shape-validated states and query projections. This is the data surface a connector implements against its backend, and the client a execute task works through.