HTTP Adapter
The http adapter calls an HTTP endpoint once per Heartbeat, posting the run context as a JSON payload.
Type key: http
note
The http adapter is an infrastructure adapter for webhook-driven external runtimes. For AI coding agents, use claude_local, codex_local, gemini_local, cursor, or opencode_local instead.
Configuration
Config fields
| Field | Type | Default | Description |
|---|---|---|---|
url | string | required | Endpoint URL to invoke |
method | string | POST | HTTP method |
headers | object | — | Request headers |
payloadTemplate | object | — | Base JSON object merged into the request body |
timeoutMs | number | 15000 | Request timeout in milliseconds |
Request body
SLAW always includes the following fields in the request body, merged with any payloadTemplate values:
| Field | Description |
|---|---|
agentId | The agent's SLAW ID |
runId | The current run ID |
context | The run context object (issue, squad, etc.) |
Example
{
"adapterType": "http",
"adapterConfig": {
"url": "https://my-runtime.example.com/slaw-heartbeat",
"method": "POST",
"headers": {
"Authorization": "Bearer my-token"
},
"payloadTemplate": {
"source": "slaw"
},
"timeoutMs": 30000
}
}
Notes
- The HTTP adapter returns exit code
0on a2xxresponse and throws on non-2xxresponses. - The adapter does not manage sessions — each Heartbeat is an independent HTTP invocation.
- For timeout-sensitive endpoints, set
timeoutMsexplicitly; the default is 15 seconds.