Skip to main content

API Reference

The capability system is accessible through multiple interfaces. This page provides a quick overview of each — for full method signatures and examples, see the dedicated reference docs linked below.


Codebolt JS SDK

The primary way agents interact with capabilities. Import the SDK and use codebolt.capability.*:

import codebolt from '@codebolt/codeboltjs';

Available methods

MethodDescription
listCapabilities(filter?)List all capabilities, optionally filtered by type/tags/author
listCapabilitiesByType(type)List capabilities of a specific type
listSkills()List all skills
listPowers()List all powers
listTalents()List all talents
getCapabilityDetail(name, type?)Get full detail for a capability
getCapabilitiesByTag(tag)List capabilities with a specific tag
getCapabilitiesByAuthor(author)List capabilities by author
listExecutors()List all registered executors
startCapability(name, type, params?, timeout?)Start a capability execution
startSkill(name, params?, timeout?)Start a skill
startPower(name, params?, timeout?)Start a power
startTalent(name, params?, timeout?)Start a talent
stopCapability(executionId)Stop a running execution
getExecutionStatus(executionId)Check execution status

Full API reference: Capability API


Agent tools

The SDK also exposes capabilities as agent tools that LLMs can call directly:

Tool nameDescriptionRequired params
capability_listList all capabilities with optional filter
capability_list_skillsList all skills
capability_list_powersList all powers
capability_get_detailGet capability info (without executing)capabilityId
capability_detailStart a capability and return resultscapabilityId, capabilityType
skill_detailStart a skill and return resultsskillId
capability_get_statusGet status of a running executionexecutionId
capability_stopStop a running executioncapabilityId (execution ID)

REST API

All endpoints are under /api/capability/.

MethodEndpointDescription
GET/api/capability/listList capabilities (query: type, tags, author)
GET/api/capability/detail/:nameGet capability detail (query: type)
GET/api/capability/typesGet capability types in use
POST/api/capability/createCreate a new capability
DELETE/api/capability/capabilityDelete a capability (body: name, type)
GET/api/capability/executorsList all executors
POST/api/capability/executors/createCreate a new executor
DELETE/api/capability/executorDelete an executor (body: name)
POST/api/capability/refreshRe-scan filesystem and refresh registry
GET/api/capability/statsGet registry stats (counts, types, initialized)
POST/api/capability/downloadDownload capability from marketplace
POST/api/capability/download-executorDownload executor from marketplace

WebSocket events

Connect to the capability WebSocket for real-time updates. On connection, the server sends an initial message with all current data.

Server → Client

Event typeWhen
initialOn connection — sends capabilities, executors, types, activeExecutions
capabilityChangedCapability installed, removed, or updated
executorChangedExecutor installed, removed, or updated
capabilityExecutionStartedExecution begins
capabilityExecutionResultExecution completes or fails
registryRefreshedRegistry re-scanned

Client → Server

Send a JSON message with an action field:

ActionDescription
getCapabilitiesGet all capabilities (optional filter)
getExecutorsGet all executors
getCapabilityTypesGet types in use
refreshRe-scan and refresh registry
getActiveExecutionsGet currently running executions

See also