跳转到主要内容
监控与采集相关接口/自动修复

触发修复

立即触发修复策略执行特定代理。

POST/api/v1/monitoring/remediation-policies/{policyId}/trigger

操作 ID

TriggerRemediation

起始版本

1.0.0

执行模式

同步

认证信息

需要认证

认证信息

调用该 API 时需要在请求头中携带以下认证信息。

Authorizationstring必填

Bearer 令牌

X-Tenant-IDstring

X-Tenant-ID

请求参数

application/json

路径参数

  • policyId
    String必填

    策略ID。

请求体字段

  • agentId
    String必填

    代理ID。

    示例: agent-001-xyz

响应状态

200 OK
200 OK

该 API 成功时返回以下响应结构。

  • id
    String

    资源ID。

    示例: exec-001-abc

  • policyId
    String

    策略ID。

    示例: policy-001-abc

  • agentId
    String

    代理ID。

    示例: agent-001-xyz

  • triggeredAt
    String

    已触发时间。

    示例: 2026-01-15T08:00:00Z

  • action
    String

    动作名称。

    示例: restart_service

  • status
    String

    状态信息。

    示例: succeeded

  • verifiedAt
    String

    已验证时间。

    示例: 2026-01-15T08:00:00Z

  • error
    String

    错误码。操作成功时为 null,失败时返回具体错误信息。

    示例: connection refused

  • retryCount
    Integer

    重试数量。

    示例: 20