sec0-sdk/instrumentation is the decorator-first SDK for in-device tracing, agent state propagation, and hop-aware policy enforcement. Most integrations should start with sec0.config.yaml plus initializeSec0App(...), then decorate the methods that represent agent, orchestrator, gateway, server, middleware, tool, or skill boundaries.
Recommended path: sec0.config.yaml
StandardAppConfig
app
app.client
auth
controlPlane
Programmatic bootstrap: initSec0
Use initSec0(...) when you are not loading sec0.config.yaml:
app.hops
Each hop entry is keyed byClass.method or a custom string and must match the decorator used on that method.
HopConfig base fields
Agent hop
Orchestrator hop
Gateway hop
Server hop
Middleware hop
Tool hop
Skill hop
HopAutomationOptions
HopEnforcementOptions
When omitted, decorators fetch policy automatically from the control plane:gateway policy level for gateway hops and middleware policy level for all other hop types.
AgentStatePayload
Supported variable scopes:
AGENT, GATEWAY, SERVER, TOOL, ORCHESTRATOR.