Board Builder API

The Board Builder API lets external plugins push structured architecture data — nodes, edges, and insights — directly to your workboards. It's how the Claude Code plugin, VS Code extension, and custom integrations feed architecture into ContextDX.

Note

This is the API reference for building integrations. If you just want to use an existing plugin, see the Claude Code Plugin guide.

Base URL: https://your-instance.com/api/board-builder

Authentication

All plugin endpoints require two headers:

X-BoardBuilder-Token: <binding-token>
X-BoardBuilder-Secret: <api-secret>
HeaderFormatDescription
X-BoardBuilder-TokenBase64url stringEncoded orgId:bindingId — identifies the workspace and binding
X-BoardBuilder-Secretbb_* stringAPI secret generated when the board_builder source was created

Get credentials from the UI: Sources → your Board Builder source → Binding → Copy Credentials.

Or programmatically:

GET /api/board-builder/workspaces/:workspaceId/bindings/:bindingId/credentials

This requires a user session (not plugin headers).

Endpoints

Push Elements

Push nodes and edges to a workboard. Supports merge (upsert) or replace (clear then insert) modes.

POST /api/board-builder/push
JSON
{
  "boardSlug": "system-overview",
  "mode": "merge",
  "nodes": [
    {
      "slug": "api-gateway",
      "name": "API Gateway",
      "description": "Main entry point for all client requests",
      "primitiveType": "node",
      "archetypeName": "System",
      "parentNodeSlug": null,
      "tags": ["backend", "critical-path"]
    },
    {
      "slug": "user-service",
      "name": "User Service",
      "description": "Handles authentication and user profiles",
      "primitiveType": "node",
      "archetypeName": "System",
      "parentNodeSlug": null,
      "tags": ["backend"]
    }
  ],
  "edges": [
    {
      "sourceSlug": "api-gateway",
      "targetSlug": "user-service",
      "relation": "calls",
      "detailedDescription": "REST API calls for auth and user lookup"
    }
  ]
}

Node fields:

FieldTypeRequiredDescription
slugstringYesUnique identifier within the board (1-200 chars)
namestringYesDisplay name (2-100 chars)
descriptionstringNoBrief description (max 500 chars)
primitiveTypeenumYesnode, container, region, axis, callout, leader_annotation, text
archetypeNamestringNoElement archetype (e.g., "System", "Container", "Component")
parentNodeSlugstringNoParent node for hierarchy
layerBoardSlugstringNoChild board for drill-down
tagsstring[]NoContext tags for categorization

Edge fields:

FieldTypeRequiredDescription
sourceSlugstringYesSource node slug
targetSlugstringYesTarget node slug
relationstringNoRelationship type (e.g., "calls", "depends-on")
archetypeNamestringNoEdge archetype name
tagsstring[]NoContext tags

Get Archetypes

Retrieve available element archetypes so your plugin uses valid archetypeName values.

GET /api/board-builder/archetypes
JSON
{
  "archetypes": [
    {
      "name": "System",
      "description": "A software system or service",
      "visualPrimitiveType": "node",
      "canContain": ["Container", "Component"]
    }
  ]
}

Get Elements

Retrieve current nodes and edges from a board — useful for incremental updates.

GET /api/board-builder/elements?boardSlug=system-overview

List Boards

Discover all boards in the workspace (parent and child).

GET /api/board-builder/boards
JSON
{
  "boards": [
    {
      "boardSlug": "system-overview",
      "boardName": "System Overview",
      "isChildBoard": false,
      "parentBoardSlug": null,
      "parentNodeSlug": null
    }
  ]
}

Create Child Boards

Create layer boards for drill-down navigation. Idempotent — existing boards are skipped.

POST /api/board-builder/boards
JSON
{
  "boards": [
    {
      "boardSlug": "api-gateway-internals",
      "boardName": "API Gateway Internals",
      "parentBoardSlug": "system-overview",
      "parentNodeSlug": "api-gateway"
    }
  ]
}

Get Insight Skills

List available insight templates (lightweight — no instructions or references).

GET /api/board-builder/insight-skills

Get full template with instructions for execution:

GET /api/board-builder/insight-skills/:slug

Push Insights

Push analysis results from a plugin to a board.

POST /api/board-builder/insights
JSON
{
  "boardSlug": "system-overview",
  "rootBoardSlug": "master",
  "insightSkillSlug": "security-analysis",
  "title": "Security Analysis - April 2026",
  "insights": {
    "elementInsights": [
      {
        "elementSlug": "api-gateway",
        "signal": "risk",
        "priority": "high",
        "title": "No rate limiting configured",
        "description": "API Gateway has no rate limiting, vulnerable to DDoS"
      }
    ],
    "affectedElements": [],
    "paths": [],
    "graphSuggestions": []
  },
  "content": "## Security Analysis\n\nFull markdown report..."
}

Error Codes

Common error responses
StatusCodeCauseFix
400Branch mismatchPush branch doesn't match binding configUse the branch configured in the binding
400Invalid source typeSource isn't board_builderCreate a board_builder source, not a regular one
400Invalid token formatX-BoardBuilder-Token isn't valid base64urlRe-copy the token from the Credentials panel
401Invalid API secretX-BoardBuilder-Secret doesn't matchRegenerate the secret from the source settings
404Binding not foundToken references a deleted or non-existent bindingRe-create the source binding
404Board not foundboardSlug doesn't match any boardCheck available boards via GET /boards
404Template not foundinsightSkillSlug doesn't matchCheck available skills via GET /insight-skills

Integration Checklist

Verify your integration end-to-end:

  • board_builder source created in the workspace Sources catalog
  • Source is bound to a target board with the correct branch
  • Credentials copied (X-BoardBuilder-Token + X-BoardBuilder-Secret)
  • GET /archetypes returns valid archetype list
  • POST /push with a test node returns success: true
  • Node appears on the board in the UI
  • GET /elements?boardSlug=... returns the pushed node
Warning

Never hardcode credentials. Store X-BoardBuilder-Token and X-BoardBuilder-Secret in environment variables or a config file that's gitignored.

What's Next