One-hop neighbours of a notes graph node
GET
/api/v1/saga/graph/nodes/{id}/neighbors
const url = 'https://api.yggy.tech/api/v1/saga/graph/nodes/example/neighbors';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.yggy.tech/api/v1/saga/graph/nodes/example/neighbors \ --header 'Authorization: Bearer <token>'At most 50 neighbours of the node, with the edges between them and the node.
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” id
required
Graph node id
string
Graph node id
Responses
Section titled “ Responses ”Neighbours
Media type application/json
object
nodes
required
Array<object>
object
id
required
string
label
required
string
type
required
string
degree
integer
edges
required
Array<object>
object
id
required
string
source
required
string
target
required
string
predicate
required
string
omitted
integer
Example generated
{ "nodes": [ { "id": "example", "label": "example", "type": "example", "degree": 1 } ], "edges": [ { "id": "example", "source": "example", "target": "example", "predicate": "example" } ], "omitted": 1}Not a yggy notes workspace
Media type application/json
object
success
required
boolean
error
required
object
code
required
string
message
required
string
details
Example
{ "success": false}No such node in this workspace
Media type application/json
object
success
required
boolean
error
required
object
code
required
string
message
required
string
details
Example
{ "success": false}Too many graph requests
Media type application/json
object
success
required
boolean
error
required
object
code
required
string
message
required
string
details
Example
{ "success": false}