$npx -y skills add gate/gate-skills --skill gate-exchange-vipfeeGate VIP tier and trading fee query skill. Use when the user asks about their fee rates or VIP level. Triggers on 'VIP level', 'trading fee', 'fee rate', 'spot fee', 'futures fee'.
| 1 | ### Resolving `gate-cli` (binary path) |
| 2 | |
| 3 | Resolve **`gate-cli`** in order: **(1)** **`command -v gate-cli`** and **`gate-cli --version`** succeeds; **(2)** **`${HOME}/.local/bin/gate-cli`** if executable; **(3)** **`${HOME}/.openclaw/skills/bin/gate-cli`** if executable. Canonical rules: [`exchange-runtime-rules.md`](https://github.com/gate/gate-skills/blob/master/skills/exchange-runtime-rules.md) §4 (or [`gate-runtime-rules.md`](https://github.com/gate/gate-skills/blob/master/skills/gate-runtime-rules.md) §4). |
| 4 | |
| 5 | |
| 6 | # Gate VIP & Fee Query Assistant |
| 7 | |
| 8 | ## General Rules |
| 9 | |
| 10 | ⚠️ STOP — You MUST read and strictly follow the shared runtime rules before proceeding. |
| 11 | Do NOT select or call any tool until all rules are read. These rules have the highest priority. |
| 12 | → Read [gate-runtime-rules.md](https://github.com/gate/gate-skills/blob/master/skills/gate-runtime-rules.md) |
| 13 | - **Only use the `gate-cli` commands explicitly listed in this skill.** Commands not documented here must NOT be run for these workflows, even if other interfaces expose them. |
| 14 | |
| 15 | ## Skill Dependencies |
| 16 | |
| 17 | |
| 18 | ### gate-cli commands used |
| 19 | |
| 20 | **Query Operations (Read-only)** |
| 21 | |
| 22 | - `gate-cli cex account detail` |
| 23 | - `gate-cli cex wallet market trade-fee` |
| 24 | |
| 25 | ### Authentication |
| 26 | - **Interactive file setup:** when **`GATE_API_KEY`** and **`GATE_API_SECRET`** are **not** both set on the host, run **`gate-cli config init`** to complete the wizard for API key, secret, profiles, and defaults (see [gate-cli](https://github.com/gate/gate-cli)). |
| 27 | - **Env / flags:** **`gate-cli config init`** is **not** required when credentials are already supplied — e.g. **both** **`GATE_API_KEY`** and **`GATE_API_SECRET`** set on the host, or **`--api-key`** / **`--api-secret`** where supported — never ask the user to paste secrets into chat. |
| 28 | - **Permissions:** Account:Read, Wallet:Read |
| 29 | - **Portal:** create or rotate keys outside the chat: https://www.gate.com/myaccount/profile/api-key/manage |
| 30 | |
| 31 | ### Installation Check |
| 32 | - **Required:** `gate-cli` (run `sh ./setup.sh` from this skill directory if missing; optional `GATE_CLI_SETUP_MODE=release`). |
| 33 | - Add `$HOME/.openclaw/skills/bin` to **`PATH`** if you invoke `gate-cli` by name (or the directory where [`setup.sh`](./setup.sh) installs it). |
| 34 | - **Credentials:** When **`GATE_API_KEY`** and **`GATE_API_SECRET`** are both set (non-empty) for the host, **do not** require **`gate-cli config init`** — that is equivalent valid config for `gate-cli`. When **both** are unset or empty, **remind** the operator to run **`gate-cli config init`** **or** to configure **`GATE_API_KEY`** / **`GATE_API_SECRET`** in the **matching skill** from the skill library (never ask the user to paste secrets into chat). |
| 35 | - **Sanity check:** Do not proceed with authenticated calls until the CLI behaves as expected (e.g. **`gate-cli --version`** or a read-only **`gate-cli cex ...`** command from this skill); confirm credentials resolve before mutating operations. |
| 36 | |
| 37 | ## Execution mode |
| 38 | |
| 39 | **Read and strictly follow** [`references/gate-cli.md`](./references/gate-cli.md), then execute this skill's VIP/fee query workflow. |
| 40 | |
| 41 | - `SKILL.md` keeps intent routing and rendering rules. |
| 42 | - `references/gate-cli.md` is the authoritative `gate-cli` execution contract for account/fee data retrieval and safe output behavior. |
| 43 | |
| 44 | ## Quick Start |
| 45 | |
| 46 | Below are the most common prompts to get started quickly: |
| 47 | |
| 48 | 1. **Query VIP tier** |
| 49 | > What is my VIP level? |
| 50 | |
| 51 | 2. **Query trading |