Traversals are performed from a start node. The traversal is controlled by the URI and the body sent with the request.
The kind of objects in the response is determined by traverse/{returnType} in the URL.
returnType
can have one of these values:
node
relationship
path
- contains full representations of start and end node, the rest are URIs
fullpath
- contains full representations of all nodes and relationships
To decide how the graph should be traversed you can use these parameters in the request body:
Decides in which order to visit nodes. Possible values:
breadth_first
- see Breadth-first search
depth_first
- see Depth-first search
Decides which relationship types and directions should be followed. The direction can be one of:
all
in
out
Decides how uniqueness should be calculated. For details on different uniqueness values see the Java API on Uniqueness. Possible values:
node_global
none
relationship_global
node_path
relationship_path
built-in
none
prune evaluator.
Decides whether the current position should be included in the result. You can provide your own code for this (see Section 18.11.1, “Traversal using a return filter”), or use one of the built-in filters:
all
all_but_start_node
prune_evaluator
is specified instead of a max_depth
, no max depth limit is set.
The position
object in the body of the return_filter
and prune_evaluator
is a
Path
object representing the path from the start node to the current traversal position.
Out of the box, the REST API supports JavaScript code in filters and evaluators. The script body will be executed in a Java context which has access to the full Neo4j Java API. See the examples for the exact syntax of the request.
In this example, the none
prune evaluator is used and a return filter
is supplied in order to return all names containing "t".
The result is to be returned as nodes and the max depth is
set to 3.
Example request
POST
http://localhost:7474/db/data/node/17/traverse/node
Accept:
application/json
Content-Type:
application/json
{ "order" : "breadth_first", "return_filter" : { "body" : "position.endNode().getProperty('name').toLowerCase().contains('t')", "language" : "javascript" }, "prune_evaluator" : { "body" : "position.length() > 10", "language" : "javascript" }, "uniqueness" : "node_global", "relationships" : [ { "direction" : "all", "type" : "knows" }, { "direction" : "all", "type" : "loves" } ], "max_depth" : 3 }
Example response
200:
OK
Content-Type:
application/json
[ { "outgoing_relationships" : "http://localhost:7474/db/data/node/17/relationships/out", "data" : { "name" : "Root" }, "traverse" : "http://localhost:7474/db/data/node/17/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/17/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/17/properties/{key}", "self" : "http://localhost:7474/db/data/node/17", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/17/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/17/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/17/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/17/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/17/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/17/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/17/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/20/relationships/out", "data" : { "name" : "Mattias" }, "traverse" : "http://localhost:7474/db/data/node/20/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/20/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/20/properties/{key}", "self" : "http://localhost:7474/db/data/node/20", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/20/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/20/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/20/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/20/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/20/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/20/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/20/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/19/relationships/out", "data" : { "name" : "Peter" }, "traverse" : "http://localhost:7474/db/data/node/19/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/19/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/19/properties/{key}", "self" : "http://localhost:7474/db/data/node/19", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/19/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/19/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/19/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/19/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/19/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/19/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/19/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/18/relationships/out", "data" : { "name" : "Tobias" }, "traverse" : "http://localhost:7474/db/data/node/18/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/18/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/18/properties/{key}", "self" : "http://localhost:7474/db/data/node/18", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/18/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/18/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/18/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/18/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/18/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/18/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/18/relationships/in/{-list|&|types}" } ]
Example request
POST
http://localhost:7474/db/data/node/8/traverse/relationship
Accept:
application/json
Content-Type:
application/json
{"order":"breadth_first","uniqueness":"none","return_filter":{"language":"builtin","name":"all"}}
Example response
200:
OK
Content-Type:
application/json
[ { "start" : "http://localhost:7474/db/data/node/8", "data" : { }, "self" : "http://localhost:7474/db/data/relationship/2", "property" : "http://localhost:7474/db/data/relationship/2/properties/{key}", "properties" : "http://localhost:7474/db/data/relationship/2/properties", "type" : "know", "extensions" : { }, "end" : "http://localhost:7474/db/data/node/7" }, { "start" : "http://localhost:7474/db/data/node/8", "data" : { }, "self" : "http://localhost:7474/db/data/relationship/3", "property" : "http://localhost:7474/db/data/relationship/3/properties/{key}", "properties" : "http://localhost:7474/db/data/relationship/3/properties", "type" : "own", "extensions" : { }, "end" : "http://localhost:7474/db/data/node/6" } ]
Example request
POST
http://localhost:7474/db/data/node/11/traverse/path
Accept:
application/json
Content-Type:
application/json
{"order":"breadth_first","uniqueness":"none","return_filter":{"language":"builtin","name":"all"}}
Example response
200:
OK
Content-Type:
application/json
[ { "start" : "http://localhost:7474/db/data/node/11", "nodes" : [ "http://localhost:7474/db/data/node/11" ], "length" : 0, "relationships" : [ ], "end" : "http://localhost:7474/db/data/node/11" }, { "start" : "http://localhost:7474/db/data/node/11", "nodes" : [ "http://localhost:7474/db/data/node/11", "http://localhost:7474/db/data/node/10" ], "length" : 1, "relationships" : [ "http://localhost:7474/db/data/relationship/4" ], "end" : "http://localhost:7474/db/data/node/10" }, { "start" : "http://localhost:7474/db/data/node/11", "nodes" : [ "http://localhost:7474/db/data/node/11", "http://localhost:7474/db/data/node/9" ], "length" : 1, "relationships" : [ "http://localhost:7474/db/data/relationship/5" ], "end" : "http://localhost:7474/db/data/node/9" } ]
Here, all nodes at a traversal depth below 3 are returned.
Example request
POST
http://localhost:7474/db/data/node/24/traverse/node
Accept:
application/json
Content-Type:
application/json
{ "return_filter" : { "body" : "position.length()<3;", "language" : "javascript" }, "prune_evaluator" : { "name" : "none", "language" : "builtin" } }
Example response
200:
OK
Content-Type:
application/json
[ { "outgoing_relationships" : "http://localhost:7474/db/data/node/24/relationships/out", "data" : { "name" : "Root" }, "traverse" : "http://localhost:7474/db/data/node/24/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/24/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/24/properties/{key}", "self" : "http://localhost:7474/db/data/node/24", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/24/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/24/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/24/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/24/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/24/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/24/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/24/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/27/relationships/out", "data" : { "name" : "Mattias" }, "traverse" : "http://localhost:7474/db/data/node/27/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/27/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/27/properties/{key}", "self" : "http://localhost:7474/db/data/node/27", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/27/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/27/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/27/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/27/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/27/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/27/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/27/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/22/relationships/out", "data" : { "name" : "Johan" }, "traverse" : "http://localhost:7474/db/data/node/22/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/22/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/22/properties/{key}", "self" : "http://localhost:7474/db/data/node/22", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/22/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/22/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/22/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/22/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/22/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/22/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/22/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/23/relationships/out", "data" : { "name" : "Emil" }, "traverse" : "http://localhost:7474/db/data/node/23/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/23/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/23/properties/{key}", "self" : "http://localhost:7474/db/data/node/23", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/23/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/23/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/23/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/23/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/23/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/23/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/23/relationships/in/{-list|&|types}" } ]
Paged traversers are created by POST
-ing a
traversal description to the link identified by the paged_traverser
key
in a node representation. When creating a paged traverser, the same
options apply as for a regular traverser, meaning that node
, path
,
or fullpath
, can be targeted.
Example request
POST
http://localhost:7474/db/data/node/34/paged/traverse/node
Accept:
application/json
Content-Type:
application/json
{ "prune_evaluator" : { "language" : "builtin", "name" : "none" }, "return_filter" : { "language" : "javascript", "body" : "position.endNode().getProperty('name').contains('1');" }, "order" : "depth_first", "relationships" : { "type" : "NEXT", "direction" : "out" } }
Example response
201:
Created
Content-Type:
application/json
Location:
http://localhost:7474/db/data/node/34/paged/traverse/node/df8ef332894c4717a0d89d7be19453e8
[ { "outgoing_relationships" : "http://localhost:7474/db/data/node/35/relationships/out", "data" : { "name" : "1" }, "traverse" : "http://localhost:7474/db/data/node/35/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/35/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/35/properties/{key}", "self" : "http://localhost:7474/db/data/node/35", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/35/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/35/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/35/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/35/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/35/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/35/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/35/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/44/relationships/out", "data" : { "name" : "10" }, "traverse" : "http://localhost:7474/db/data/node/44/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/44/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/44/properties/{key}", "self" : "http://localhost:7474/db/data/node/44", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/44/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/44/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/44/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/44/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/44/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/44/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/44/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/45/relationships/out", "data" : { "name" : "11" }, "traverse" : "http://localhost:7474/db/data/node/45/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/45/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/45/properties/{key}", "self" : "http://localhost:7474/db/data/node/45", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/45/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/45/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/45/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/45/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/45/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/45/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/45/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/46/relationships/out", "data" : { "name" : "12" }, "traverse" : "http://localhost:7474/db/data/node/46/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/46/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/46/properties/{key}", "self" : "http://localhost:7474/db/data/node/46", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/46/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/46/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/46/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/46/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/46/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/46/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/46/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/47/relationships/out", "data" : { "name" : "13" }, "traverse" : "http://localhost:7474/db/data/node/47/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/47/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/47/properties/{key}", "self" : "http://localhost:7474/db/data/node/47", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/47/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/47/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/47/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/47/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/47/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/47/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/47/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/48/relationships/out", "data" : { "name" : "14" }, "traverse" : "http://localhost:7474/db/data/node/48/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/48/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/48/properties/{key}", "self" : "http://localhost:7474/db/data/node/48", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/48/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/48/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/48/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/48/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/48/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/48/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/48/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/49/relationships/out", "data" : { "name" : "15" }, "traverse" : "http://localhost:7474/db/data/node/49/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/49/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/49/properties/{key}", "self" : "http://localhost:7474/db/data/node/49", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/49/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/49/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/49/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/49/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/49/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/49/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/49/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/50/relationships/out", "data" : { "name" : "16" }, "traverse" : "http://localhost:7474/db/data/node/50/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/50/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/50/properties/{key}", "self" : "http://localhost:7474/db/data/node/50", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/50/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/50/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/50/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/50/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/50/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/50/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/50/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/51/relationships/out", "data" : { "name" : "17" }, "traverse" : "http://localhost:7474/db/data/node/51/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/51/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/51/properties/{key}", "self" : "http://localhost:7474/db/data/node/51", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/51/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/51/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/51/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/51/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/51/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/51/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/51/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/52/relationships/out", "data" : { "name" : "18" }, "traverse" : "http://localhost:7474/db/data/node/52/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/52/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/52/properties/{key}", "self" : "http://localhost:7474/db/data/node/52", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/52/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/52/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/52/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/52/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/52/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/52/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/52/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/53/relationships/out", "data" : { "name" : "19" }, "traverse" : "http://localhost:7474/db/data/node/53/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/53/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/53/properties/{key}", "self" : "http://localhost:7474/db/data/node/53", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/53/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/53/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/53/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/53/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/53/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/53/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/53/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/55/relationships/out", "data" : { "name" : "21" }, "traverse" : "http://localhost:7474/db/data/node/55/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/55/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/55/properties/{key}", "self" : "http://localhost:7474/db/data/node/55", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/55/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/55/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/55/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/55/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/55/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/55/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/55/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/65/relationships/out", "data" : { "name" : "31" }, "traverse" : "http://localhost:7474/db/data/node/65/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/65/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/65/properties/{key}", "self" : "http://localhost:7474/db/data/node/65", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/65/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/65/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/65/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/65/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/65/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/65/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/65/relationships/in/{-list|&|types}" } ]
Paged traversers hold state on the server, and allow clients to page through the results of a traversal. To progress to the next page of traversal results, the client issues a HTTP GET request on the paged traversal URI which causes the traversal to fill the next page (or partially fill it if insufficient results are available).
Note that if a traverser expires through inactivity it will cause a 404
response on the next GET
request. Traversers' leases are renewed on
every successful access for the same amount of time as originally
specified.
When the paged traverser reaches the end of its results, the client can expect a 404 response as the traverser is disposed by the server.
Example request
GET
http://localhost:7474/db/data/node/67/paged/traverse/node/1aaeb9712f974e7791e44a26ccb2d45c
Accept:
application/json
Example response
200:
OK
Content-Type:
application/json
[ { "outgoing_relationships" : "http://localhost:7474/db/data/node/398/relationships/out", "data" : { "name" : "331" }, "traverse" : "http://localhost:7474/db/data/node/398/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/398/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/398/properties/{key}", "self" : "http://localhost:7474/db/data/node/398", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/398/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/398/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/398/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/398/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/398/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/398/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/398/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/408/relationships/out", "data" : { "name" : "341" }, "traverse" : "http://localhost:7474/db/data/node/408/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/408/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/408/properties/{key}", "self" : "http://localhost:7474/db/data/node/408", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/408/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/408/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/408/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/408/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/408/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/408/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/408/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/418/relationships/out", "data" : { "name" : "351" }, "traverse" : "http://localhost:7474/db/data/node/418/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/418/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/418/properties/{key}", "self" : "http://localhost:7474/db/data/node/418", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/418/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/418/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/418/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/418/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/418/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/418/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/418/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/428/relationships/out", "data" : { "name" : "361" }, "traverse" : "http://localhost:7474/db/data/node/428/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/428/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/428/properties/{key}", "self" : "http://localhost:7474/db/data/node/428", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/428/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/428/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/428/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/428/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/428/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/428/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/428/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/438/relationships/out", "data" : { "name" : "371" }, "traverse" : "http://localhost:7474/db/data/node/438/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/438/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/438/properties/{key}", "self" : "http://localhost:7474/db/data/node/438", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/438/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/438/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/438/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/438/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/438/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/438/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/438/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/448/relationships/out", "data" : { "name" : "381" }, "traverse" : "http://localhost:7474/db/data/node/448/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/448/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/448/properties/{key}", "self" : "http://localhost:7474/db/data/node/448", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/448/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/448/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/448/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/448/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/448/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/448/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/448/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/458/relationships/out", "data" : { "name" : "391" }, "traverse" : "http://localhost:7474/db/data/node/458/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/458/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/458/properties/{key}", "self" : "http://localhost:7474/db/data/node/458", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/458/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/458/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/458/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/458/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/458/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/458/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/458/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/468/relationships/out", "data" : { "name" : "401" }, "traverse" : "http://localhost:7474/db/data/node/468/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/468/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/468/properties/{key}", "self" : "http://localhost:7474/db/data/node/468", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/468/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/468/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/468/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/468/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/468/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/468/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/468/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/477/relationships/out", "data" : { "name" : "410" }, "traverse" : "http://localhost:7474/db/data/node/477/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/477/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/477/properties/{key}", "self" : "http://localhost:7474/db/data/node/477", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/477/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/477/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/477/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/477/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/477/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/477/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/477/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/478/relationships/out", "data" : { "name" : "411" }, "traverse" : "http://localhost:7474/db/data/node/478/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/478/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/478/properties/{key}", "self" : "http://localhost:7474/db/data/node/478", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/478/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/478/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/478/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/478/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/478/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/478/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/478/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/479/relationships/out", "data" : { "name" : "412" }, "traverse" : "http://localhost:7474/db/data/node/479/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/479/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/479/properties/{key}", "self" : "http://localhost:7474/db/data/node/479", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/479/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/479/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/479/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/479/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/479/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/479/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/479/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/480/relationships/out", "data" : { "name" : "413" }, "traverse" : "http://localhost:7474/db/data/node/480/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/480/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/480/properties/{key}", "self" : "http://localhost:7474/db/data/node/480", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/480/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/480/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/480/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/480/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/480/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/480/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/480/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/481/relationships/out", "data" : { "name" : "414" }, "traverse" : "http://localhost:7474/db/data/node/481/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/481/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/481/properties/{key}", "self" : "http://localhost:7474/db/data/node/481", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/481/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/481/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/481/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/481/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/481/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/481/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/481/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/482/relationships/out", "data" : { "name" : "415" }, "traverse" : "http://localhost:7474/db/data/node/482/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/482/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/482/properties/{key}", "self" : "http://localhost:7474/db/data/node/482", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/482/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/482/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/482/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/482/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/482/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/482/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/482/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/483/relationships/out", "data" : { "name" : "416" }, "traverse" : "http://localhost:7474/db/data/node/483/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/483/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/483/properties/{key}", "self" : "http://localhost:7474/db/data/node/483", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/483/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/483/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/483/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/483/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/483/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/483/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/483/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/484/relationships/out", "data" : { "name" : "417" }, "traverse" : "http://localhost:7474/db/data/node/484/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/484/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/484/properties/{key}", "self" : "http://localhost:7474/db/data/node/484", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/484/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/484/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/484/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/484/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/484/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/484/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/484/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/485/relationships/out", "data" : { "name" : "418" }, "traverse" : "http://localhost:7474/db/data/node/485/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/485/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/485/properties/{key}", "self" : "http://localhost:7474/db/data/node/485", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/485/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/485/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/485/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/485/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/485/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/485/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/485/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/486/relationships/out", "data" : { "name" : "419" }, "traverse" : "http://localhost:7474/db/data/node/486/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/486/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/486/properties/{key}", "self" : "http://localhost:7474/db/data/node/486", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/486/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/486/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/486/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/486/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/486/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/486/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/486/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/488/relationships/out", "data" : { "name" : "421" }, "traverse" : "http://localhost:7474/db/data/node/488/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/488/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/488/properties/{key}", "self" : "http://localhost:7474/db/data/node/488", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/488/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/488/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/488/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/488/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/488/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/488/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/488/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/498/relationships/out", "data" : { "name" : "431" }, "traverse" : "http://localhost:7474/db/data/node/498/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/498/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/498/properties/{key}", "self" : "http://localhost:7474/db/data/node/498", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/498/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/498/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/498/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/498/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/498/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/498/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/498/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/508/relationships/out", "data" : { "name" : "441" }, "traverse" : "http://localhost:7474/db/data/node/508/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/508/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/508/properties/{key}", "self" : "http://localhost:7474/db/data/node/508", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/508/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/508/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/508/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/508/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/508/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/508/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/508/relationships/in/{-list|&|types}" } ]
The default page size is 50 items, but
depending on the application larger or smaller pages sizes might be
appropriate. This can be set by adding a pageSize
query parameter.
Example request
POST
http://localhost:7474/db/data/node/544/paged/traverse/node?pageSize=1
Accept:
application/json
Content-Type:
application/json
{ "prune_evaluator" : { "language" : "builtin", "name" : "none" }, "return_filter" : { "language" : "javascript", "body" : "position.endNode().getProperty('name').contains('1');" }, "order" : "depth_first", "relationships" : { "type" : "NEXT", "direction" : "out" } }
Example response
201:
Created
Content-Type:
application/json
Location:
http://localhost:7474/db/data/node/544/paged/traverse/node/e184d56d31704f05ae2239626473f505
[ { "outgoing_relationships" : "http://localhost:7474/db/data/node/545/relationships/out", "data" : { "name" : "1" }, "traverse" : "http://localhost:7474/db/data/node/545/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/545/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/545/properties/{key}", "self" : "http://localhost:7474/db/data/node/545", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/545/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/545/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/545/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/545/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/545/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/545/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/545/relationships/in/{-list|&|types}" } ]
The default timeout for a paged traverser is 60
seconds, but depending on the application larger or smaller timeouts
might be appropriate. This can be set by adding a leaseTime
query
parameter with the number of seconds the paged traverser should last.
Example request
POST
http://localhost:7474/db/data/node/577/paged/traverse/node?leaseTime=10
Accept:
application/json
Content-Type:
application/json
{ "prune_evaluator" : { "language" : "builtin", "name" : "none" }, "return_filter" : { "language" : "javascript", "body" : "position.endNode().getProperty('name').contains('1');" }, "order" : "depth_first", "relationships" : { "type" : "NEXT", "direction" : "out" } }
Example response
201:
Created
Content-Type:
application/json
Location:
http://localhost:7474/db/data/node/577/paged/traverse/node/ccb6c40a67c54f448220400fe3c8ee65
[ { "outgoing_relationships" : "http://localhost:7474/db/data/node/578/relationships/out", "data" : { "name" : "1" }, "traverse" : "http://localhost:7474/db/data/node/578/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/578/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/578/properties/{key}", "self" : "http://localhost:7474/db/data/node/578", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/578/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/578/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/578/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/578/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/578/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/578/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/578/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/587/relationships/out", "data" : { "name" : "10" }, "traverse" : "http://localhost:7474/db/data/node/587/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/587/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/587/properties/{key}", "self" : "http://localhost:7474/db/data/node/587", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/587/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/587/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/587/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/587/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/587/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/587/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/587/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/588/relationships/out", "data" : { "name" : "11" }, "traverse" : "http://localhost:7474/db/data/node/588/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/588/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/588/properties/{key}", "self" : "http://localhost:7474/db/data/node/588", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/588/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/588/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/588/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/588/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/588/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/588/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/588/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/589/relationships/out", "data" : { "name" : "12" }, "traverse" : "http://localhost:7474/db/data/node/589/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/589/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/589/properties/{key}", "self" : "http://localhost:7474/db/data/node/589", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/589/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/589/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/589/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/589/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/589/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/589/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/589/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/590/relationships/out", "data" : { "name" : "13" }, "traverse" : "http://localhost:7474/db/data/node/590/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/590/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/590/properties/{key}", "self" : "http://localhost:7474/db/data/node/590", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/590/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/590/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/590/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/590/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/590/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/590/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/590/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/591/relationships/out", "data" : { "name" : "14" }, "traverse" : "http://localhost:7474/db/data/node/591/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/591/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/591/properties/{key}", "self" : "http://localhost:7474/db/data/node/591", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/591/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/591/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/591/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/591/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/591/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/591/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/591/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/592/relationships/out", "data" : { "name" : "15" }, "traverse" : "http://localhost:7474/db/data/node/592/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/592/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/592/properties/{key}", "self" : "http://localhost:7474/db/data/node/592", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/592/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/592/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/592/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/592/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/592/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/592/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/592/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/593/relationships/out", "data" : { "name" : "16" }, "traverse" : "http://localhost:7474/db/data/node/593/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/593/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/593/properties/{key}", "self" : "http://localhost:7474/db/data/node/593", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/593/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/593/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/593/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/593/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/593/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/593/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/593/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/594/relationships/out", "data" : { "name" : "17" }, "traverse" : "http://localhost:7474/db/data/node/594/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/594/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/594/properties/{key}", "self" : "http://localhost:7474/db/data/node/594", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/594/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/594/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/594/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/594/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/594/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/594/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/594/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/595/relationships/out", "data" : { "name" : "18" }, "traverse" : "http://localhost:7474/db/data/node/595/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/595/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/595/properties/{key}", "self" : "http://localhost:7474/db/data/node/595", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/595/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/595/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/595/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/595/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/595/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/595/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/595/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/596/relationships/out", "data" : { "name" : "19" }, "traverse" : "http://localhost:7474/db/data/node/596/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/596/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/596/properties/{key}", "self" : "http://localhost:7474/db/data/node/596", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/596/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/596/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/596/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/596/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/596/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/596/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/596/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/598/relationships/out", "data" : { "name" : "21" }, "traverse" : "http://localhost:7474/db/data/node/598/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/598/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/598/properties/{key}", "self" : "http://localhost:7474/db/data/node/598", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/598/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/598/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/598/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/598/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/598/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/598/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/598/relationships/in/{-list|&|types}" }, { "outgoing_relationships" : "http://localhost:7474/db/data/node/608/relationships/out", "data" : { "name" : "31" }, "traverse" : "http://localhost:7474/db/data/node/608/traverse/{returnType}", "all_typed_relationships" : "http://localhost:7474/db/data/node/608/relationships/all/{-list|&|types}", "property" : "http://localhost:7474/db/data/node/608/properties/{key}", "self" : "http://localhost:7474/db/data/node/608", "outgoing_typed_relationships" : "http://localhost:7474/db/data/node/608/relationships/out/{-list|&|types}", "properties" : "http://localhost:7474/db/data/node/608/properties", "incoming_relationships" : "http://localhost:7474/db/data/node/608/relationships/in", "extensions" : { }, "create_relationship" : "http://localhost:7474/db/data/node/608/relationships", "paged_traverse" : "http://localhost:7474/db/data/node/608/paged/traverse/{returnType}{?pageSize,leaseTime}", "all_relationships" : "http://localhost:7474/db/data/node/608/relationships/all", "incoming_typed_relationships" : "http://localhost:7474/db/data/node/608/relationships/in/{-list|&|types}" } ]
Copyright © 2012 Neo Technology