agent-contracts API
由
scripts/generate-api-docs.ts自动生成 —— 请勿手改 共 3 个端点
GET /agent-contracts/{agentId}
查看 profile 的契约与已编译订阅
请求参数
| 参数名 | 位置 | 类型 | 必填 | 说明 |
|---|---|---|---|---|
agentId | path | string | ✅ |
响应
| 状态码 | 说明 |
|---|---|
| 200 |
POST /agent-contracts/{agentId}/compile
编译单个 profile 的契约(可 dry-run)
请求参数
| 参数名 | 位置 | 类型 | 必填 | 说明 |
|---|---|---|---|---|
agentId | path | string | ✅ |
请求体
json
{
"$ref": "#/components/schemas/CompileContractDto"
}响应
| 状态码 | 说明 |
|---|---|
| 201 |
POST /agent-contracts/compile
编译所有带 stateContract 的 profile
请求体
json
{
"$ref": "#/components/schemas/CompileAllContractsDto"
}响应
| 状态码 | 说明 |
|---|---|
| 201 |