Maps API Pro
The REST endpoints for reading and writing maps. Every call needs a
workspace token; responses are JSON unless noted.
Base URL: https://canopy.8starlabs.com/api/v1.
List maps
List every map in the workspace.
curl https://canopy.8starlabs.com/api/v1/maps \
-H "Authorization: Bearer $CANOPY_TOKEN"Responses
{
"maps": [
{
"id": "acme-platform",
"name": "8StarLabs Platform",
"isPublic": false,
"nodes": [
{ "id": "api", "label": "API", "tech": "node · trpc", "spend": "$2.1k", "x": 240, "y": 120 }
/* … */
],
"edges": [
{ "source": "web", "target": "api", "line": "bezier" }
/* … */
],
"createdAt": "2026-05-01T10:00:00.000Z",
"updatedAt": "2026-06-01T12:30:00.000Z"
}
/* … */
]
}Get a map
Fetch a single map with its nodes and edges.
curl https://canopy.8starlabs.com/api/v1/maps/acme-platform \
-H "Authorization: Bearer $CANOPY_TOKEN"Responses
{
"map": {
"id": "acme-platform",
"name": "8StarLabs Platform",
"isPublic": false,
"nodes": [
{ "id": "api", "label": "API", "tech": "node · trpc", "x": 240, "y": 120 }
],
"edges": [
{ "source": "web", "target": "api", "line": "bezier" }
],
"createdAt": "2026-05-01T10:00:00.000Z",
"updatedAt": "2026-06-01T12:30:00.000Z"
}
}Create a map
Create a new map. The body is the architecture JSON.
curl -X POST https://canopy.8starlabs.com/api/v1/maps \
-H "Authorization: Bearer $CANOPY_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "name": "8StarLabs Platform", "nodes": [], "edges": [] }'Responses
{
"map": {
"id": "acme-platform",
"name": "8StarLabs Platform",
"isPublic": false,
"nodes": [],
"edges": [],
"createdAt": "2026-06-09T09:00:00.000Z",
"updatedAt": "2026-06-09T09:00:00.000Z"
}
}Update a map
Update a map's name, nodes, edges, or metadata. Only the fields you send change.
curl -X PATCH https://canopy.8starlabs.com/api/v1/maps/acme-platform \
-H "Authorization: Bearer $CANOPY_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "name": "Acme Platform v2" }'Responses
{
"map": {
"id": "acme-platform",
"name": "Acme Platform v2",
"isPublic": false,
"nodes": [ /* … */ ],
"edges": [ /* … */ ],
"createdAt": "2026-05-01T10:00:00.000Z",
"updatedAt": "2026-06-09T09:05:00.000Z"
}
}Delete a map
Permanently delete a map.
curl -X DELETE https://canopy.8starlabs.com/api/v1/maps/acme-platform \
-H "Authorization: Bearer $CANOPY_TOKEN"Responses
{
"deleted": true,
"id": "acme-platform"
}Export a map
Export a map as markdown, claude, agents, png, figma, or notion.
curl https://canopy.8starlabs.com/api/v1/maps/acme-platform/export/claude \
-H "Authorization: Bearer $CANOPY_TOKEN" -o CLAUDE.mdResponses
The body is the exported artifact itself - text/markdown for markdown /
claude / agents, application/json for figma / notion, image/png for
png - not a JSON envelope.
# Acme Platform
> Architecture map exported from Canopy.
## Services
- **API** - node · trpc ($2.1k)
## Dependencies
- web → apiThe map object
A GET returns a map wrapped in { "map": … } (or { "maps": [ … ] } for the
list). The full object:
Node - id is always present; the rest appear only when set:
Edge - source and target are node ids; line is the curve style
(bezier · smoothstep · step · straight).
{
"map": {
"id": "acme-platform",
"workspaceId": "ws_8s7d6f5g",
"name": "8StarLabs Platform",
"isPublic": false,
"nodes": [
{
"id": "web",
"label": "Web",
"tech": "next.js",
"spend": "$1200",
"x": 0,
"y": 96
},
{
"id": "api",
"label": "API",
"tech": "node · trpc",
"spend": "$2100",
"billing": ["flat"],
"x": 240,
"y": 120
}
],
"edges": [{ "source": "web", "target": "api", "line": "bezier" }],
"createdAt": "2026-05-01T10:00:00.000Z",
"updatedAt": "2026-06-01T12:30:00.000Z"
}
}Request body
When you create or update a map you send only the editable fields -
name, nodes, edges, and optional isPublic. The server assigns id,
workspaceId, and the timestamps.
{
"name": "8StarLabs Platform",
"nodes": [{ "id": "web", "label": "Web", "tech": "next.js" }],
"edges": [{ "source": "web", "target": "api" }]
}