Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

huawei-cloud-eip-list

БесплатноЗапускает вложенные скриптыНе проверен

1. List Huawei Cloud Elastic IP (EIP) instances in a tenant region through KooCLI (hcloud EIP ListPublicips — read-only GET /v3/{project_id}/eip/publicips)…

wlc-devот wlc-dev469 установок в других каталогах

Об этом скилле

Huawei Cloud Elastic IP (EIP) Instance List

Overview

Query the Elastic IP (EIP) instance list of a tenant through KooCLI hcloud EIP ListPublicips (official read-only GET /v3/{project_id}/eip/publicips, verified in the huaweicloudsdkeip v3 client _list_publicips_http_info metadata). The skill is aimed at EIP inventory inspection, daily operations patrol, and as a pre-query step for other skills that need an EIP id or a bound resource.

Architecture:

agent → python3 scripts/list_eip.py → hcloud EIP ListPublicips --cli-region=<region>
      → Huawei Cloud EIP OpenAPI (vpc.<region>.myhuaweicloud.com) → parsed JSON
      → table / --json / --names-only / Markdown .md export

(hcloud binary missing) → fallback: huaweicloudsdkeip v3 EipClient.list_publicips

Key properties:

  • Read-only by design — the only API ever invoked is ListPublicips (GET). A write-intent guard scans user arguments and validates the operation name; mutating intents (create / delete / update / associate / disassociate / attach / detach / release / change) are rejected with an explicit message before any command runs.
  • CLI first, SDK fallback — KooCLI is the primary execution path; when the KooCLI binary is absent, the script falls back to the official huaweicloudsdkeip v3 SDK (list_publicips). Credentials are always read by the CLI profile / SDK environment — never handled by the script.
  • Full-field table output — the default table renders the union of all fields returned by ListPublicips, with the nested bandwidth / vnic objects expanded into flat columns.
  • Archivable Markdown export — --markdown / -o <path> renders the same query into a self-contained .md report (title + region/time/count + fixed header table), written atomically to the requested path. The default behavior without an export flag is unchanged.
  • Offline-testable — every code path (marker paging, filters, error classification, guard, SDK fallback) is covered by unit tests that mock the hcloud subprocess.

Out of scope: every mutating EIP action (create / update / delete an EIP, associate / disassociate an EIP, bind / unbind a bandwidth, change bandwidth). Those require a dedicated write-capable skill and explicit user confirmation.

Prerequisites

  1. KooCLI (hcloud) installed — see references/cli-installation-guide.md. Alternative: pip install huaweicloudsdkeip to enable the SDK fallback path.
  2. Active credential profile — configure credentials out-of-band (run the KooCLI configure command in your terminal, or set credential environment variables). Never paste AK/SK into chat; the script never reads, echoes, or stores secrets itself — authentication is delegated entirely to the hcloud profile / SDK environment.
  3. project_id (SDK fallback only) — the EIP REST path is /v3/{project_id}/eip/publicips; when falling back to the SDK, supply the project id via --project-id or the HUAWEICLOUD_SDK_PROJECT_ID / HUAWEI_PROJECT_ID environment variables. The KooCLI path resolves it from the profile automatically.
  4. IAM permission — read-only vpc:publicIps:list; least-privilege policy in references/iam-policies.md.
  5. Python 3.8+ (standard library only — argparse / json / subprocess).
  6. Outbound HTTPS access to vpc.cn-north-4.myhuaweicloud.com.

Workflow

  1. Confirm the target region (default cn-north-4).
  2. Confirm KooCLI readiness (optional, read-only) by listing the active credential profile.
  3. Run the list script with the desired output mode and filters.
  4. Read the result — table for humans, --json for downstream tooling, --names-only for a compact inventory, --markdown / -o <path.md> for an archivable report file.
  5. Handle the empty / error cases per the Edge Cases table below (the script prints an explicit hint for empty region, 403, and missing AK/SK). Empty queries still produce a Markdown file marked 「无数据」 with exit 0.

Core Commands

# Full-field table (default)
python3 scripts/list_eip.py --region cn-north-4

# Raw JSON of every returned field
python3 scripts/list_eip.py --json

# Compact EIP alias / public-IP list only
python3 scripts/list_eip.py --names-only

# Filter by EIP status (server-side query parameter)
python3 scripts/list_eip.py --status ACTIVE

# Filter by exact EIP id / public IP
python3 scripts/list_eip.py --id eip-0001
python3 scripts/list_eip.py --public-ip 1.2.3.4

# Combine filters
python3 scripts/list_eip.py --region cn-north-4 --status ACTIVE --names-only

# Export an archivable Markdown report (default filename eip_list_<region>_<timestamp>.md)
python3 scripts/list_eip.py --region cn-north-4 --markdown

# Export to an explicit path (implies Markdown mode; parent dirs are created)
python3 scripts/list_eip.py --region cn-north-4 -o /data/reports/eip_lis
Полный SKILL.md на ClawHub

Установить huawei-cloud-eip-list в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

FAQ

Что делает скилл huawei-cloud-eip-list?

1. List Huawei Cloud Elastic IP (EIP) instances in a tenant region through KooCLI (hcloud EIP ListPublicips — read-only GET /v3/{project_id}/eip/publicips), with an automatic fallback to the official huaweicloudsdkeip v3 SDK when hcloud is not installed. 2. Four output modes: full-field table (default, every returned field including 名称/别名/ID/公网IP/带宽/状态/绑定资源), --json (raw response array), --names-only (compact EIP alias/public-IP list), and Markdown export (--markdown or -o/--output <path.md>). 3. Markdown export writes an archivable `.md` report in one query: title 「华为云 EIP 列表」, query region / generated time / record count, and a full fixed-header table (公网IP、EIP ID、别名、状态、类型、绑定实例类型/ID、 带宽名称/大小、计费方式、企业项目 ID、创建时间); missing fields render as `-`. Empty results still produce a `.md` marked 「无数据」 and exit 0. 4. Supports --id / --status / --public-ip filtering (all real server-side ListPublicips query parameters), region override, and automatic marker paging. 5. Explicit error hints for empty EIP lists (「当前区域无弹性公网IP(EIP)」), 403 / insufficient IAM permission (「无权限访问弹性公网IP(EIP)」), missing or invalid AK/SK credentials, missing project_id on the SDK fallback, and hcloud not installed. 6. Built-in write-intent guard: any mutating intent (create / delete / update / associate / disassociate / attach / detach / release / change) or any operation other than ListPublicips is rejected before execution — this skill is strictly read-only. 7. Triggers include: "list EIPs", "eip list", "弹性公网IP列表", "查询 EIP", "查询弹性公网IP", "EIP 实例列表", "elastic ip inventory", "list public ips", "华为云 EIP", "公网IP列表", "导出 EIP Markdown", "EIP 列表导出 md". 8. Offline unit tests (mocked hcloud subprocess) cover output modes, filters, marker paging, error scenarios, SDK fallback, Markdown export, and the write-intent guard.

Как установить скилл huawei-cloud-eip-list?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл huawei-cloud-eip-list запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить huawei-cloud-eip-list с