Used to call the BlueKing Standard O&M (SOPS) API through the bk-cli sops system subcommands.
CRITICAL — Before starting, you MUST first use the Read tool to read ../bk-cli-shared/SKILL.md. The shared skill handles authentication, context, tenant, stage, dry-run, verbose, header/body, and general request rules; this skill only supplements the sops command's own semantics and input conventions.
Current coverage
This skill currently covers these commonly used commands:
get_template_listget_task_listget_task_statusget_task_detailcreate_taskstart_taskoperate_task
Commands
Template query
get_template_list
bk-cli sops get_template_list --bk_biz_id 2
bk-cli sops get_template_list --bk_biz_id 2 --keyword deploy
- Call path:
GET /get_template_list/{bk_biz_id}/
Task management
get_task_list
bk-cli sops get_task_list --bk_biz_id 2
bk-cli sops get_task_list --bk_biz_id 2 --keyword deploy --limit 50
- Call path:
GET /get_task_list/{bk_biz_id}/
create_task
bk-cli sops create_task --bk_biz_id 2 --template_id 100 --name "deploy-v1"
bk-cli sops create_task --bk_biz_id 2 --template_id 100 --name "deploy" --constants '{"${key}":"value"}'
- Create task from template
--constantsmust be a JSON object; the CLI will write it into the request body as a nested object- Call path:
POST /create_task/{template_id}/{bk_biz_id}/
start_task
bk-cli sops start_task --bk_biz_id 2 --task_id 100
- Start a created task
- Call path:
POST /start_task/{task_id}/{bk_biz_id}/
get_task_status
bk-cli sops get_task_status --task_id 100 --bk_biz_id 2
- Call path:
GET /get_task_status/{task_id}/{bk_biz_id}/
get_task_detail
bk-cli sops get_task_detail --task_id 100 --bk_biz_id 2
- Call path:
GET /get_task_detail/{task_id}/{bk_biz_id}/
operate_task
bk-cli sops operate_task --bk_biz_id 2 --task_id 100 --action pause
bk-cli sops operate_task --bk_biz_id 2 --task_id 100 --action resume
bk-cli sops operate_task --bk_biz_id 2 --task_id 100 --action revoke
- Operate task: pause, resume, or terminate
actionmust be one of pause / resume / revoke- Call path:
POST /operate_task/{task_id}/{bk_biz_id}/