POST /api/v1/forward/schedules/{schedule_id}/run
立即创建一条 Schedule Run,不改变原有触发策略。接口返回时 Run 记录已创建,但执行不一定完成。
请求头
| Header | 是否必填 | 说明 |
|---|---|---|
| Authorization | 是 | Bearer <PAT> |
| Idempotency-Key | 否 | 有副作用请求可选的幂等键。 |
路径参数
| 参数 | 类型 | 是否必填 | 说明 |
|---|---|---|---|
| schedule_id | string | 是 | Forward Schedule ID。 |
示例请求
示例响应
HTTP 200 OK响应字段
| 字段 | 类型 | 说明 |
|---|---|---|
| 返回值 | object | 创建出的 Schedule Run 对象。 |
错误
| HTTP | Type | Code | 触发条件 |
|---|---|---|---|
| 404 | not_found_error | schedule_not_found | Schedule 不存在。 |
| 409 | invalid_request_error | schedule_archived | Schedule 已归档。 |
| 409 | invalid_request_error | schedule_not_active | Schedule 已暂停。 |
| 401 | authentication_error | authentication_required | PAT 无效或已过期。 |
注意事项
- 如果达到
execution.max_concurrent_runs,Forward 仍会创建一条status=skipped的 Run,并返回error.type=concurrency_limit_reached。 - 客户端应轮询 Get Schedule Run,直到
status进入completed、failed或skipped。