1
0
Fork 0
arangodb/Documentation/Examples/RestTraversalMaxDepth.gener...

68 lines
1.6 KiB
Plaintext

shell> curl -X POST --data-binary @- --dump - http://localhost:8529/_api/traversal <<EOF
{ "startVertex": "persons/alice", "graphName" : "knows_graph", "direction" : "outbound", "maxDepth" : 1}
EOF
HTTP/1.1 200 OK
content-type: application/json; charset=utf-8
{
"result" : {
"visited" : {
"vertices" : [
{
"_id" : "persons/alice",
"_key" : "alice",
"_rev" : "938668939",
"name" : "Alice"
},
{
"_id" : "persons/bob",
"_key" : "bob",
"_rev" : "938865547",
"name" : "Bob"
}
],
"paths" : [
{
"edges" : [ ],
"vertices" : [
{
"_id" : "persons/alice",
"_key" : "alice",
"_rev" : "938668939",
"name" : "Alice"
}
]
},
{
"edges" : [
{
"_id" : "knows/939783051",
"_key" : "939783051",
"_rev" : "939783051",
"_from" : "persons/alice",
"_to" : "persons/bob"
}
],
"vertices" : [
{
"_id" : "persons/alice",
"_key" : "alice",
"_rev" : "938668939",
"name" : "Alice"
},
{
"_id" : "persons/bob",
"_key" : "bob",
"_rev" : "938865547",
"name" : "Bob"
}
]
}
]
}
},
"error" : false,
"code" : 200
}