| name | alibabacloud-cli-cost-estimation |
| description | Pre-execution cost estimation for Alibaba Cloud CLI operations. Use this skill whenever a user asks "how much will this cost", before executing any chargeable operation (create / resize / renew / bandwidth change), or when planning a multi-step workflow whose total cost should be known up front. Covers the --estimate-cost flag (quote without executing), --estimate-cost-context (usage assumptions and future-state overrides for multi-step workflows), reading the quote JSON correctly (pricingMode, pricingUnit, delta amounts), and reconciling quotes against actual bills.
|
| triggers | estimate cost, cost estimation, price quote, how much will it cost, 询价, 报价, 多少钱, 费用预估, 成本预估, 变配差价, 执行前费用, estimate-cost, PricingContext, 计费预览, 账单预览, price before execution, chargeable operation, upgrade cost, renewal cost, bandwidth cost
|
| license | Apache-2.0 |
| metadata | {"domain":"aliyun-cli","owner":"sdk-team","contact":"sdk-team@alibabacloud.com"} |
| allowed-tools | mcp__plugin_alibabacloud-core_alibabacloud-core__AlibabaCloud___CallCLI,mcp__plugin_alibabacloud-core_alibabacloud-core__AlibabaCloud___SearchApis,mcp__plugin_alibabacloud-core_alibabacloud-core__AlibabaCloud___GetApiDefinition,mcp__plugin_alibabacloud-core_alibabacloud-core__AlibabaCloud___GenerateCLICommand |
Alibaba Cloud CLI Cost Estimation
Get an exact price quote for a CLI operation without executing it. The quote
comes from the same pricing source as the trade system: for operations that
produce an immediate order, the quoted amount equals the order amount you would
actually pay (verified across new purchases, spec upgrades, and bandwidth
changes — quote and bill match to the cent).
This is the pre-execution half of cost management. The post-hoc half
(bills already incurred) is aliyun bssopenapi QueryAccountBill — see the
reconciliation section below.
Requirements
- Alibaba Cloud CLI ≥ 3.4.2 (
aliyun version)
- Product plugins up to date (
aliyun plugin update)
The Agent Rule: Quote Before Chargeable Execution
When you are about to execute an operation that creates, resizes, renews, or
otherwise changes billable resources:
- Check whether the API supports quoting (see Discovery below).
- Quote it by appending
--estimate-cost to the exact command you intend
to run.
- Present the amount to the user as part of the confirmation, e.g.
"This will execute
ModifyPrepayInstanceSpec — estimated charge ¥28.89
(prorated upgrade delta). Proceed?"
- Execute only after confirmation, by removing
--estimate-cost from the
same command.
Never silently execute a chargeable operation when a quote was obtainable.
--estimate-cost is always safe to add: it only quotes, never executes, and
changes nothing in the account.
Multi-step plans: quote everything first, confirm once. When the user's
request decomposes into multiple API calls (a workflow), do NOT interleave
execute-and-ask step by step. Instead:
- Quote all chargeable steps up front, before executing step 1 — use
--estimate-cost-context state overrides for steps that depend on the
state an earlier step will produce.
- Present one consolidated cost plan: each step's amount labelled by its
nature (immediate order / usage-based estimate with its assumption /
refund / free), plus the total of immediate charges.
- Ask for a single confirmation of the whole sequence, then execute the
steps in order.
- If a step fails or the account state changes mid-sequence, stop and
re-quote the remaining steps before continuing.
The Cost Plan Format
Present the consolidated plan in this fixed shape: