Graph
Graph traversal and path-finding
Find paths between entities
Authorization
bearerAuth Supabase JWT token
In: header
Query Parameters
Entity expansion mode. Omit for preview (default), "full" for complete manifests, "none" to disable
"preview" | "full" | "none"Request Body
application/json
Starting entity PIs
1 <= itemsTarget entity PIs
1 <= itemsMaximum path depth (1-4)
41 <= value <= 4Relationship traversal direction
"both""outgoing" | "incoming" | "both"Maximum number of paths to return
1001 <= value <= 1000Response Body
application/json
application/json
curl -X POST "https://arke-v1.arke.institute/graph/paths" \ -H "Content-Type: application/json" \ -d '{ "source_pis": [ "01KE4ZY69F9R40E88PK9S0TQRQ" ], "target_pis": [ "01KE506KZGD8M2P1XK3VNQT4YR" ] }'{
"paths": [
{
"source_pi": "01KDETYWYWM0MJVKM8DK3AEXPY",
"target_pi": "01KDETYWYWM0MJVKM8DK3AEXPY",
"length": 0,
"edges": [
{
"subject_pi": "01KE4ZY69F9R40E88PK9S0TQRQ",
"subject_label": "Project Folder",
"subject_type": "folder",
"subject_preview": {
"id": "01KE4ZY69F9R40E88PK9S0TQRQ",
"type": "folder",
"label": "Project Folder",
"collection_pi": "01JCOLLECTION123456789ABCD",
"description_preview": "Main project folder containing research documents...",
"created_at": "2025-01-10T08:00:00.000Z",
"updated_at": "2025-01-18T16:45:00.000Z"
},
"predicate": "contains",
"object_pi": "01KE506KZGD8M2P1XK3VNQT4YR",
"object_label": "Research Paper.pdf",
"object_type": "file",
"object_preview": {
"id": "01KE506KZGD8M2P1XK3VNQT4YR",
"type": "file",
"label": "Research Paper.pdf",
"collection_pi": "01JCOLLECTION123456789ABCD",
"description_preview": "Analysis of entity management patterns and best practices...",
"created_at": "2025-01-15T10:00:00.000Z",
"updated_at": "2025-01-20T14:30:00.000Z"
}
}
]
}
],
"truncated": true
}{
"error": "Validation failed",
"details": {
"issues": [
{
"path": [
"properties",
"label"
],
"message": "Required"
}
]
}
}Find reachable entities (exhaustive)
Authorization
bearerAuth Supabase JWT token
In: header
Query Parameters
Entity expansion mode. Omit for preview (default), "full" for complete manifests, "none" to disable
"preview" | "full" | "none"Request Body
application/json
Starting entity PIs
1 <= itemsTarget entity type to find
1 <= lengthMaximum path depth (1-4)
41 <= value <= 4Relationship traversal direction
"both""outgoing" | "incoming" | "both"Maximum number of results to return
1001 <= value <= 1000Response Body
application/json
application/json
curl -X POST "https://arke-v1.arke.institute/graph/reachable" \ -H "Content-Type: application/json" \ -d '{ "source_pis": [ "01KE4ZY69F9R40E88PK9S0TQRQ" ], "target_type": "file" }'{
"results": [
{
"source_pi": "01KE4ZY69F9R40E88PK9S0TQRQ",
"target_pi": "01KE506KZGD8M2P1XK3VNQT4YR",
"target_label": "Research Paper.pdf",
"target_type": "file",
"length": 1,
"edges": [],
"target_preview": {
"id": "01KE506KZGD8M2P1XK3VNQT4YR",
"type": "file",
"label": "Research Paper.pdf",
"collection_pi": "01JCOLLECTION123456789ABCD",
"description_preview": "Analysis of entity management patterns and best practices...",
"created_at": "2025-01-15T10:00:00.000Z",
"updated_at": "2025-01-20T14:30:00.000Z"
}
}
],
"truncated": true
}{
"error": "Validation failed",
"details": {
"issues": [
{
"path": [
"properties",
"label"
],
"message": "Required"
}
]
}
}Get entity from graph
Authorization
bearerAuth Supabase JWT token
In: header
Path Parameters
Entity ID (ULID)
^(?:II[0-9A-HJKMNP-TV-Z]{24}|[FC][0-9A-HJKMNP-TV-Z]{25}|[0-9A-HJKMNP-TV-Z]{26})$Query Parameters
Entity expansion mode. Omit for preview (default), "full" for complete manifests, "none" to disable
"preview" | "full" | "none"Response Body
application/json
application/json
curl -X GET "https://arke-v1.arke.institute/graph/entity/01KDETYWYWM0MJVKM8DK3AEXPY"{
"pi": "01KE4ZY69F9R40E88PK9S0TQRQ",
"type": "folder",
"label": "Project Folder",
"collection_pi": "01JCOLLECTION123456789ABCD",
"created_at": "2025-01-10T08:00:00.000Z",
"updated_at": "2025-01-18T16:45:00.000Z",
"relationships": [
{
"direction": "outgoing",
"predicate": "contains",
"peer_pi": "01KE506KZGD8M2P1XK3VNQT4YR",
"peer_type": "file",
"peer_label": "Research Paper.pdf",
"properties": {},
"peer_preview": {
"id": "01KE506KZGD8M2P1XK3VNQT4YR",
"type": "file",
"label": "Research Paper.pdf",
"collection_pi": "01JCOLLECTION123456789ABCD",
"description_preview": "Analysis of entity management patterns and best practices...",
"created_at": "2025-01-15T10:00:00.000Z",
"updated_at": "2025-01-20T14:30:00.000Z"
}
}
]
}{
"error": "Entity not found"
}