[[rest-api-return-relationships-from-a-traversal]]
=== Return relationships from a traversal ===

.Final Graph
["dot", "Final-Graph-return-relationships-from-a-traversal.svg", "neoviz"]
----
  N4 [
    label = "{Node\[4\]|name = \'car\'\l}"
  ]
  N5 [
    label = "{Node\[5\]|name = \'you\'\l}"
  ]
  N6 [
    label = "{Node\[6\]|name = \'I\'\l}"
  ]
  N6 -> N5 [
    color = "#2e3436"
    fontcolor = "#2e3436"
    label = "know\n"
  ]
  N6 -> N4 [
    color = "#4e9a06"
    fontcolor = "#4e9a06"
    label = "own\n"
  ]
----

_Example request_

* *+POST+*  +http://localhost:7474/db/data/node/6/traverse/relationship+
* *+Accept:+* +application/json+
* *+Content-Type:+* +application/json+
[source,javascript]
----
{"order":"breadth_first","uniqueness":"none","return_filter":{"language":"builtin","name":"all"}}
----


_Example response_

* *+200:+* +OK+
* *+Content-Type:+* +application/json+
[source,javascript]
----
[ {
  "start" : "http://localhost:7474/db/data/node/6",
  "data" : {
  },
  "self" : "http://localhost:7474/db/data/relationship/1",
  "property" : "http://localhost:7474/db/data/relationship/1/properties/{key}",
  "properties" : "http://localhost:7474/db/data/relationship/1/properties",
  "type" : "know",
  "extensions" : {
  },
  "end" : "http://localhost:7474/db/data/node/5"
}, {
  "start" : "http://localhost:7474/db/data/node/6",
  "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" : "own",
  "extensions" : {
  },
  "end" : "http://localhost:7474/db/data/node/4"
} ]
----


