@bitget-ai/bitget-agent-skill 3.3.1 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +47 -0
- package/README.md +110 -123
- package/VERSION +1 -1
- package/package.json +7 -11
- package/scripts/install.js +123 -123
- package/scripts/validate-skills.mjs +240 -0
- package/skills/bitget-agentic/SKILL.md +122 -0
- package/skills/bitget-agentic/references/authorization.md +95 -0
- package/skills/bitget-agentic/references/first-time-setup.md +85 -0
- package/skills/bitget-agentic/references/legacy-migration.md +38 -0
- package/skills/bitget-agentic/references/troubleshooting.md +34 -0
- package/references/auth-setup.md +0 -54
- package/references/commands.md +0 -2387
- package/references/demo-trading.md +0 -58
- package/references/discover-guide.md +0 -112
- package/references/error-codes.md +0 -118
- package/references/trading-safety.md +0 -163
- package/scripts/gen-references.js +0 -266
- package/skills/agentic/SKILL.md +0 -195
- package/skills/uta/SKILL.md +0 -189
|
@@ -1,266 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// Generates references/commands.md from @bitget-ai/bitget-agent-sdk by walking
|
|
3
|
-
// the SDK's own `discover` surface — the same progressive disclosure an agent
|
|
4
|
-
// uses at runtime. Driving discover (not raw catalog reads) guarantees the
|
|
5
|
-
// static catalog never drifts from what `bgc` actually exposes.
|
|
6
|
-
//
|
|
7
|
-
// Output is the v3 intent surface: 16 curated verbs (incl. the hidden to-B
|
|
8
|
-
// broker/inst_loan), each action's required/optional contract, plus the meta
|
|
9
|
-
// tools. The CLI grammar / global-flags block is the stable `bgc` contract.
|
|
10
|
-
import { writeFileSync, mkdirSync } from "node:fs";
|
|
11
|
-
import { join, dirname } from "node:path";
|
|
12
|
-
import { fileURLToPath } from "node:url";
|
|
13
|
-
|
|
14
|
-
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
15
|
-
const refsDir = join(__dirname, "..", "references");
|
|
16
|
-
mkdirSync(refsDir, { recursive: true });
|
|
17
|
-
|
|
18
|
-
const {
|
|
19
|
-
loadConfig,
|
|
20
|
-
buildTools,
|
|
21
|
-
MODULES,
|
|
22
|
-
HIDDEN_MODULES,
|
|
23
|
-
HIGH_RISK_OPERATIONS,
|
|
24
|
-
DISCOVER_TOOL_NAME,
|
|
25
|
-
RAW_TOOL_NAME,
|
|
26
|
-
SERVER_VERSION,
|
|
27
|
-
CATALOG_SPEC_VERSION,
|
|
28
|
-
CATALOG_OPERATION_COUNT,
|
|
29
|
-
API_VARIANT,
|
|
30
|
-
} = await import("@bitget-ai/bitget-agent-sdk");
|
|
31
|
-
|
|
32
|
-
// All modules incl. hidden to-B verbs, intent surface — exactly what `bgc`
|
|
33
|
-
// exposes with `--modules all` plus the explicitly-named hidden ones.
|
|
34
|
-
const config = loadConfig({ modules: MODULES.join(","), surface: "intent", readOnly: false });
|
|
35
|
-
const tools = buildTools(config);
|
|
36
|
-
const discover = tools.find((t) => t.name === DISCOVER_TOOL_NAME);
|
|
37
|
-
const call = async (args) => (await discover.handler(args, {})).data;
|
|
38
|
-
|
|
39
|
-
const hidden = new Set(HIDDEN_MODULES);
|
|
40
|
-
const highRisk = new Set(HIGH_RISK_OPERATIONS);
|
|
41
|
-
const DESC_CAP = 220;
|
|
42
|
-
|
|
43
|
-
// Collapse OpenAPI paragraph descriptions to a single, table-safe line.
|
|
44
|
-
function cell(text) {
|
|
45
|
-
if (text === undefined || text === null) return "";
|
|
46
|
-
let s = String(text).replace(/\s+/g, " ").trim().replace(/\|/g, "\\|");
|
|
47
|
-
if (s.length > DESC_CAP) s = s.slice(0, DESC_CAP - 1) + "…";
|
|
48
|
-
return s;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
function enumCell(param) {
|
|
52
|
-
if (!Array.isArray(param.enum) || param.enum.length === 0) return "";
|
|
53
|
-
return param.enum.map((v) => `\`${v}\``).join(" \\| ");
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
function paramTable(params) {
|
|
57
|
-
if (!params || params.length === 0) return ["_No parameters._", ""];
|
|
58
|
-
const out = ["| Param | Type | Enum | Description |", "|-------|------|------|-------------|"];
|
|
59
|
-
for (const p of params) {
|
|
60
|
-
out.push(`| \`${p.name}\` | ${p.type ?? "any"} | ${enumCell(p)} | ${cell(p.description)} |`);
|
|
61
|
-
}
|
|
62
|
-
out.push("");
|
|
63
|
-
return out;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
function anchor(name) {
|
|
67
|
-
return name.toLowerCase().replace(/[^a-z0-9]+/g, "-");
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
function exampleFor(verb, action, required) {
|
|
71
|
-
const parts = [`bgc ${verb}`];
|
|
72
|
-
if (action) parts.push(`--action ${action}`);
|
|
73
|
-
for (const p of required) {
|
|
74
|
-
if (p.name === "action") continue;
|
|
75
|
-
parts.push(`--${p.name} <${p.name}>`);
|
|
76
|
-
}
|
|
77
|
-
return parts.join(" ");
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
const lines = [];
|
|
81
|
-
lines.push("# bgc Command Reference (UTA / v3)");
|
|
82
|
-
lines.push("");
|
|
83
|
-
lines.push(
|
|
84
|
-
`Auto-generated from \`@bitget-ai/bitget-agent-sdk\` v${SERVER_VERSION} ` +
|
|
85
|
-
`(OpenAPI spec ${CATALOG_SPEC_VERSION}, ${CATALOG_OPERATION_COUNT} operations, ${API_VARIANT}).`,
|
|
86
|
-
);
|
|
87
|
-
lines.push("Do not edit by hand — run `npm run gen-references`.");
|
|
88
|
-
lines.push("");
|
|
89
|
-
lines.push(
|
|
90
|
-
"This catalog is the **static** mirror of the live surface. For a verb's exact, " +
|
|
91
|
-
"doc-grounded contract at any moment, run `bgc discover --tool <verb> --action <name>`.",
|
|
92
|
-
);
|
|
93
|
-
lines.push("");
|
|
94
|
-
|
|
95
|
-
// ── CLI grammar (the stable `bgc` contract) ─────────────────────────────
|
|
96
|
-
lines.push("## Grammar");
|
|
97
|
-
lines.push("");
|
|
98
|
-
lines.push("```");
|
|
99
|
-
lines.push("bgc <tool> [--action <name>] [--<param> <value> ...] [global flags]");
|
|
100
|
-
lines.push("bgc discover [--domain <d> | --tool <t> [--action <a>] | --search <q>]");
|
|
101
|
-
lines.push("bgc raw --operationId <id> [--args '<json>']");
|
|
102
|
-
lines.push("```");
|
|
103
|
-
lines.push("");
|
|
104
|
-
lines.push(
|
|
105
|
-
"One verb per call. `--action` selects the intent for action-routed verbs. " +
|
|
106
|
-
"Values coerce by shape: `true`/`false` → boolean, a value starting with `[` or `{` → JSON " +
|
|
107
|
-
"(e.g. `--orders '[{...}]'`), everything else stays a string. Output is JSON on stdout " +
|
|
108
|
-
"(exit 0); errors are a JSON payload on stderr (exit 1).",
|
|
109
|
-
);
|
|
110
|
-
lines.push("");
|
|
111
|
-
|
|
112
|
-
// ── Global flags ─────────────────────────────────────────────────────────
|
|
113
|
-
lines.push("## Global flags");
|
|
114
|
-
lines.push("");
|
|
115
|
-
lines.push("| Flag | Effect |");
|
|
116
|
-
lines.push("|------|--------|");
|
|
117
|
-
lines.push("| `--action <name>` | Action for an action-routed verb |");
|
|
118
|
-
lines.push("| `--modules <list>` | Modules to enable (CLI default: `all`). Name a hidden to-B module to expose it, e.g. `--modules broker` |");
|
|
119
|
-
lines.push("| `--surface <mode>` | `intent` (default) or `full` (also expose the 1:1 generated operations) |");
|
|
120
|
-
lines.push("| `--full` | Shorthand for `--surface full` |");
|
|
121
|
-
lines.push("| `--read-only` | Block all writes (mutually exclusive with `--paper-trading`) |");
|
|
122
|
-
lines.push("| `--paper-trading` | Route writes to the Bitget demo environment (needs demo credentials) |");
|
|
123
|
-
lines.push("| `--dry-run` | Preview a write without sending it (maps to `dryRun`) |");
|
|
124
|
-
lines.push("| `--confirm` | Required to execute destructive (high-risk) writes |");
|
|
125
|
-
lines.push("| `--base-url <url>` | Override API base URL (else `BITGET_API_BASE_URL`) |");
|
|
126
|
-
lines.push("| `--timeout <ms>` | Per-request timeout (else `BITGET_TIMEOUT_MS`, default 15000) |");
|
|
127
|
-
lines.push("| `--pretty` | Pretty-print JSON output |");
|
|
128
|
-
lines.push("| `--help`, `--version` | Help / version |");
|
|
129
|
-
lines.push("");
|
|
130
|
-
|
|
131
|
-
// ── Write safety ───────────────────────────────────────────────────────
|
|
132
|
-
lines.push("## Write safety");
|
|
133
|
-
lines.push("");
|
|
134
|
-
lines.push(
|
|
135
|
-
"Every operation is graded **read** < **write** < **high**. Reads run freely. Writes honor " +
|
|
136
|
-
"`--dry-run`, `--read-only`, and `--paper-trading`. **High-risk** operations refuse to run " +
|
|
137
|
-
"without `--confirm` — without it the call returns `{ confirmationRequired: true }` (a normal " +
|
|
138
|
-
"result on stdout, not an error).",
|
|
139
|
-
);
|
|
140
|
-
lines.push("");
|
|
141
|
-
lines.push(`High-risk operations (require \`--confirm\`): ${[...highRisk].map((o) => `\`${o}\``).join(", ")}.`);
|
|
142
|
-
lines.push("");
|
|
143
|
-
lines.push(
|
|
144
|
-
"Common params available on most verbs (not repeated in the tables below): `dryRun`, `confirm` " +
|
|
145
|
-
"(writes); `view` (`summary`|`full`) and `fields` (read normalization / token economy); " +
|
|
146
|
-
"`fetchAll`, `cursor`, `limit` (paginated reads).",
|
|
147
|
-
);
|
|
148
|
-
lines.push("");
|
|
149
|
-
|
|
150
|
-
// ── Walk the surface ─────────────────────────────────────────────────────
|
|
151
|
-
const overview = await call({});
|
|
152
|
-
const verbsByDomain = new Map();
|
|
153
|
-
for (const d of overview.domains) {
|
|
154
|
-
const list = await call({ domain: d.domain });
|
|
155
|
-
verbsByDomain.set(d.domain, list.tools);
|
|
156
|
-
}
|
|
157
|
-
|
|
158
|
-
// Table of contents
|
|
159
|
-
lines.push("## Domains");
|
|
160
|
-
lines.push("");
|
|
161
|
-
for (const d of overview.domains) {
|
|
162
|
-
const verbs = verbsByDomain.get(d.domain);
|
|
163
|
-
const names = verbs.map((v) => `[\`${v.name}\`](#${anchor(v.name)})`).join(", ");
|
|
164
|
-
lines.push(`- **${d.domain}** — ${names}`);
|
|
165
|
-
}
|
|
166
|
-
lines.push(`- **meta** — [\`${RAW_TOOL_NAME}\`](#raw), [\`${DISCOVER_TOOL_NAME}\`](#discover)`);
|
|
167
|
-
lines.push("");
|
|
168
|
-
|
|
169
|
-
// Per domain → per verb
|
|
170
|
-
for (const d of overview.domains) {
|
|
171
|
-
lines.push(`## Domain: ${d.domain}`);
|
|
172
|
-
lines.push("");
|
|
173
|
-
for (const v of verbsByDomain.get(d.domain)) {
|
|
174
|
-
const tool = await call({ tool: v.name });
|
|
175
|
-
lines.push(`### \`${v.name}\``);
|
|
176
|
-
lines.push("");
|
|
177
|
-
const badges = [`risk: **${v.riskLevel}**`, `write: ${v.isWrite ? "yes" : "no"}`, `auth: ${tool.auth}`];
|
|
178
|
-
lines.push(badges.join(" · "));
|
|
179
|
-
lines.push("");
|
|
180
|
-
// Hidden to-B modules have domain === module id (broker, instloan); name the
|
|
181
|
-
// module id in the opt-in hint, not the verb name (inst_loan ≠ instloan).
|
|
182
|
-
if (hidden.has(d.domain)) {
|
|
183
|
-
lines.push(`> Hidden to-B verb — opt in with \`--modules ${d.domain}\` (not in \`--modules all\`).`);
|
|
184
|
-
lines.push("");
|
|
185
|
-
}
|
|
186
|
-
lines.push(cell(tool.description));
|
|
187
|
-
lines.push("");
|
|
188
|
-
|
|
189
|
-
if (tool.actions) {
|
|
190
|
-
lines.push(`**Actions:** ${tool.actions.map((a) => `\`${a}\``).join(", ")}`);
|
|
191
|
-
lines.push("");
|
|
192
|
-
for (const action of tool.actions) {
|
|
193
|
-
const c = await call({ tool: v.name, action });
|
|
194
|
-
const danger = highRisk.has(c.operationId) ? " — **[DANGER] requires `--confirm`**" : "";
|
|
195
|
-
lines.push(`#### \`bgc ${v.name} --action ${action}\`${danger}`);
|
|
196
|
-
lines.push("");
|
|
197
|
-
lines.push(`\`${c.method} ${c.path}\` · ${c.auth}${c.isWrite ? " · write" : ""}`);
|
|
198
|
-
lines.push("");
|
|
199
|
-
if (c.summary) {
|
|
200
|
-
lines.push(cell(c.summary));
|
|
201
|
-
lines.push("");
|
|
202
|
-
}
|
|
203
|
-
if (c.required.length > 0) {
|
|
204
|
-
lines.push("Required:");
|
|
205
|
-
lines.push("");
|
|
206
|
-
lines.push(...paramTable(c.required));
|
|
207
|
-
}
|
|
208
|
-
if (c.optional.length > 0) {
|
|
209
|
-
lines.push("Optional:");
|
|
210
|
-
lines.push("");
|
|
211
|
-
lines.push(...paramTable(c.optional));
|
|
212
|
-
}
|
|
213
|
-
if (c.required.length === 0 && c.optional.length === 0) {
|
|
214
|
-
lines.push("_No business parameters._");
|
|
215
|
-
lines.push("");
|
|
216
|
-
}
|
|
217
|
-
lines.push("```bash");
|
|
218
|
-
lines.push(exampleFor(v.name, action, c.required));
|
|
219
|
-
lines.push("```");
|
|
220
|
-
lines.push("");
|
|
221
|
-
}
|
|
222
|
-
} else {
|
|
223
|
-
// Action-less verb (composite fan-out or 1:1 op): explicit param split.
|
|
224
|
-
if (tool.params.required.length > 0) {
|
|
225
|
-
lines.push("Required:");
|
|
226
|
-
lines.push("");
|
|
227
|
-
lines.push(...paramTable(tool.params.required));
|
|
228
|
-
}
|
|
229
|
-
lines.push("Optional:");
|
|
230
|
-
lines.push("");
|
|
231
|
-
lines.push(...paramTable(tool.params.optional));
|
|
232
|
-
lines.push("```bash");
|
|
233
|
-
lines.push(exampleFor(v.name, null, tool.params.required));
|
|
234
|
-
lines.push("```");
|
|
235
|
-
lines.push("");
|
|
236
|
-
}
|
|
237
|
-
}
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
// ── Meta tools ─────────────────────────────────────────────────────────
|
|
241
|
-
lines.push("## Meta tools");
|
|
242
|
-
lines.push("");
|
|
243
|
-
lines.push("### `discover`");
|
|
244
|
-
lines.push("");
|
|
245
|
-
lines.push(
|
|
246
|
-
"Progressive introspection of the live surface. `bgc discover` lists domains; " +
|
|
247
|
-
"`--domain <d>` lists a domain's verbs; `--tool <t>` returns one verb's full schema; " +
|
|
248
|
-
"`--tool <t> --action <a>` returns one action's exact required/optional contract; " +
|
|
249
|
-
"`--search <q>` keyword-searches the whole surface.",
|
|
250
|
-
);
|
|
251
|
-
lines.push("");
|
|
252
|
-
lines.push("### `raw`");
|
|
253
|
-
lines.push("");
|
|
254
|
-
lines.push(
|
|
255
|
-
"Escape hatch to any catalog operation by id, bypassing the intent layer: " +
|
|
256
|
-
"`bgc raw --operationId <id> --args '<json>'`. Use when no verb fronts the operation you need.",
|
|
257
|
-
);
|
|
258
|
-
lines.push("");
|
|
259
|
-
|
|
260
|
-
writeFileSync(join(refsDir, "commands.md"), lines.join("\n"), "utf8");
|
|
261
|
-
|
|
262
|
-
const verbCount = [...verbsByDomain.values()].reduce((n, v) => n + v.length, 0);
|
|
263
|
-
console.log(
|
|
264
|
-
`Generated references/commands.md — ${overview.domains.length} domains, ${verbCount} verbs ` +
|
|
265
|
-
`(SDK ${SERVER_VERSION}, spec ${CATALOG_SPEC_VERSION}, ${CATALOG_OPERATION_COUNT} ops).`,
|
|
266
|
-
);
|
package/skills/agentic/SKILL.md
DELETED
|
@@ -1,195 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: bitget-agentic
|
|
3
|
-
description: >
|
|
4
|
-
Use for Bitget Agentic account (AI Agent OAuth path, not manual API keys).
|
|
5
|
-
Invoke when the user connects an Agentic account, re-authorizes, says Connect Agent,
|
|
6
|
-
reports Key invalid/expired, cannot trade, asks about MCP auth status, or trades
|
|
7
|
-
inside an Agentic account via @bitget-ai/bitget-agent-mcp — even without saying
|
|
8
|
-
"Bitget". Chinese triggers: 连接 Agent、重新授权、Agentic 账户、Agent 子账户、Agentic
|
|
9
|
-
子账户、Agent 账户、AI 账户、智能交易账户、Key 失效、连不上、Connect Agent、帮我下单、
|
|
10
|
-
查 Agentic 余额/持仓. Do NOT use for generic UTA trading
|
|
11
|
-
with env API keys (@bitget-ai/bitget-agent-skill). After OAuth, use this skill for
|
|
12
|
-
runtime auth and trading safety.
|
|
13
|
-
metadata:
|
|
14
|
-
version: 1.3.0
|
|
15
|
-
author: Bitget
|
|
16
|
-
updated: 2026-09-17
|
|
17
|
-
requires:
|
|
18
|
-
bins: ["node", "npx"]
|
|
19
|
-
node: ">=20"
|
|
20
|
-
packages:
|
|
21
|
-
mcp: "@bitget-ai/bitget-agent-mcp"
|
|
22
|
-
license: MIT
|
|
23
|
-
---
|
|
24
|
-
|
|
25
|
-
# Bitget Agentic · 本地 Skill
|
|
26
|
-
|
|
27
|
-
**Agentic 账户专用** · OAuth + `@bitget-ai/bitget-agent-mcp` · **不是** `@bitget-ai/bitget-agent-skill`
|
|
28
|
-
|
|
29
|
-
**分工:** 本 Skill 负责 OAuth 成功后的运行时授权状态、重新授权、交易确认与安全边界。
|
|
30
|
-
|
|
31
|
-
**Rule Priority:** Safety > 状态诚实 > 响应速度
|
|
32
|
-
|
|
33
|
-
---
|
|
34
|
-
|
|
35
|
-
## 产品约束(内化即可)
|
|
36
|
-
|
|
37
|
-
- 1 MCP = 1 Agentic 账户 = 1 套凭证(OAuth 落盘,**禁止** env 手填 Key)
|
|
38
|
-
- 多 Key 并存;再 OAuth 发新 Key、不删旧 Key;本机绑定被**覆盖**(其他 Agent/设备不受影响)
|
|
39
|
-
- Web 只读 Key 数 → Agent **不得**声称知道 Web 有几把 Key
|
|
40
|
-
- 断链 / Key 失效 → **完整 OAuth**;无一键重发、无静默重链
|
|
41
|
-
- Scope 外:提币、主账户、主→子划转 → Agent **不做**
|
|
42
|
-
- OAuth 仅 MCP/SDK 监听 callback;**禁止** LLM 拼 URL / 监听端口 / 收粘贴三件套
|
|
43
|
-
- 凭证落盘后可**立即**交易,**无需重启 Agent**
|
|
44
|
-
- 未授权时行情等无需 Key 的公开能力仍可用;交易类能力不可用
|
|
45
|
-
|
|
46
|
-
---
|
|
47
|
-
|
|
48
|
-
## 1. 授权状态
|
|
49
|
-
|
|
50
|
-
先 `get_auth_status`,再说话。
|
|
51
|
-
|
|
52
|
-
| 状态 | 交易 | 用户提示与下一步 |
|
|
53
|
-
|------|------|------|
|
|
54
|
-
| 未授权 | 否(`market` 除外) | 提示「需要先完成 Agentic 授权,我来打开浏览器」→ 调授权 tool |
|
|
55
|
-
| 已授权 | 是 | 确认状态与交易工具可用后再交易 |
|
|
56
|
-
| 凭证失效 | 否 | 提示「凭证已失效,需重新授权」→ 调授权 tool |
|
|
57
|
-
|
|
58
|
-
API 鉴权失败但 status 仍「已授权」→ 按**失效**处理。access token 24h 过期**不影响**已有交易 Key。
|
|
59
|
-
|
|
60
|
-
---
|
|
61
|
-
|
|
62
|
-
## 2. 重新授权(核心)
|
|
63
|
-
|
|
64
|
-
**触发:** 重新授权 / Connect / Key 失效 / 连不上 / 帮我连接 Bitget
|
|
65
|
-
|
|
66
|
-
```
|
|
67
|
-
get_auth_status → 一句告知会替换本机绑定、Web 旧 Key 仍保留
|
|
68
|
-
→ 立即调 MCP authorize_start → 用 Bash 打开 authorizeUrl(勿只贴文本让用户复制)
|
|
69
|
-
→ 调 MCP authorize_wait → App 设备鉴权 → 确认已授权
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
**打开 authorizeUrl:** 拿到 `authorize_start` 返回的 `authorizeUrl` 后,立即用 Bash 打开,不等用户手动复制粘贴:
|
|
73
|
-
- macOS: `open "<authorizeUrl>"`
|
|
74
|
-
- Linux: `xdg-open "<authorizeUrl>"`
|
|
75
|
-
- Windows: `start "" "<authorizeUrl>"`
|
|
76
|
-
|
|
77
|
-
若 Bash 打开失败(无 GUI/无浏览器/命令不存在),才回退成把链接文本发给用户自行打开。**URL 本身必须原样使用 MCP 返回值,禁止 LLM 自行拼接或修改。**
|
|
78
|
-
|
|
79
|
-
**成功判定:** 只有 MCP 明确返回已授权且凭证已保存,才算成功;打开浏览器 ≠ 授权成功。否则提示「授权未完成」。
|
|
80
|
-
|
|
81
|
-
**提示(二次 OAuth 前):** 「再次授权会更新本机凭证;Web 上旧 Key 默认保留;其他 Agent/设备不受影响。」
|
|
82
|
-
|
|
83
|
-
**禁止:** 只给说明链接/文字而不真正调 MCP 授权 tool · 让用户粘贴 Key · 承诺一键重发
|
|
84
|
-
|
|
85
|
-
**后端要点:** 成功 = MCP 已授权 + 浏览器走完;仅浏览器成功 → 再调 OAuth。Web 点「绑定更多 Agent」≠ 本机已连,须本机 MCP callback。
|
|
86
|
-
|
|
87
|
-
---
|
|
88
|
-
|
|
89
|
-
## 3. 边界 Case
|
|
90
|
-
|
|
91
|
-
### 3a. 用户主动操作(用户明说即可感知,不是失败)
|
|
92
|
-
|
|
93
|
-
| 场景 | 动作 | 提示(对用户,可改写) |
|
|
94
|
-
|------|------|------------------------|
|
|
95
|
-
| H 只问行情 | `market` | 不强迫 OAuth |
|
|
96
|
-
| J 要断链 | 引导 Web 删 Key | 「请到 Agentic 账户 API 管理删 Key;先处理挂单/持仓。删除 Key 会取消该 Agent 的交易权限,不会自动平仓,也不会自动撤销挂单。」 |
|
|
97
|
-
| F 二次 OAuth | 告知 + 调 OAuth | 见 §2 |
|
|
98
|
-
|
|
99
|
-
### 3b. 失败处理(只按错误码归因,无错误码一律兜底)
|
|
100
|
-
|
|
101
|
-
**错误码 → 动作:** 调用授权/交易 tool 返回明确错误码时,按错误码处理,Agent 不需要猜背后原因:
|
|
102
|
-
|
|
103
|
-
| 错误码 | 动作 | 提示 |
|
|
104
|
-
|--------|------|------|
|
|
105
|
-
| `NOT_AUTHORIZED`(A 未授权要交易) | 调 OAuth | 「需要先完成 Agentic 授权,我来打开浏览器。」 |
|
|
106
|
-
| `AUTH_CANCELLED`(B 用户取消) | 再调 OAuth | 「这次没保存凭证,要我再试一次吗?」 |
|
|
107
|
-
| `CREDENTIALS_INVALID`(D Web 删 Key / Key 失效) | 调 OAuth | 「Key 已在服务端失效,需重新授权。」 |
|
|
108
|
-
| `RATE_LIMITED`(N 限流) | 退避 | 「请求过快,稍后再试。」**勿** OAuth |
|
|
109
|
-
| `INSUFFICIENT_BALANCE`(O 余额不足) | 引导 Web 划转 | 「请在 Web 从主账户划转到 Agentic 账户。」 |
|
|
110
|
-
| `MCP_CONNECTION_ERROR`(M MCP 未启动) | 排查 MCP | 「MCP 未运行,请检查 Node 20+ 与 MCP 配置。」 |
|
|
111
|
-
| 配额错误码(K 配额满) | Use existing | 「Agentic 账户已满,请选已有账户。」 |
|
|
112
|
-
| KYC 错误码(L KYC 未完成) | 完成后再 OAuth | 「请先完成 KYC。」 |
|
|
113
|
-
| 工具不存在 / 方法不存在(M2 MCP 未安装/未注册) | 引导安装并注册 | 「MCP 工具不存在:请运行 npm i -g @bitget-ai/bitget-agent-mcp 安装,再在客户端注册(如 Claude Code 执行 claude mcp add bitget-agentic -- npx -y @bitget-ai/bitget-agent-mcp),然后重启会话或用 /mcp 重连。」 |
|
|
114
|
-
|
|
115
|
-
**兜底(无明确错误码):** 通用失败 / 超时 / 回调未收到 / 浏览器状态不确定时,Agent 无法知道具体原因(是取消、是没点完、是页面关了),**不猜原因**,统一:
|
|
116
|
-
> 「授权未完成。请确认浏览器授权步骤已完成,要我再发起一次吗?」
|
|
117
|
-
|
|
118
|
-
并重新走一遍授权流程(§2)。
|
|
119
|
-
|
|
120
|
-
**其他错误码归因:** 设备鉴权失败 → 不发 Key → 查 App 同账号 → 再 OAuth(**不是** Key 失效);`MCP 缺失 vs 未启动`:报"工具不存在/方法不存在"是未安装或未注册(走 M2),不是未启动,两者都不是授权问题,不要引导重新授权。
|
|
121
|
-
|
|
122
|
-
### 3c. 其他状态(非错误)
|
|
123
|
-
|
|
124
|
-
| 场景 | 动作 | 说明 |
|
|
125
|
-
|------|------|------|
|
|
126
|
-
| C 浏览器成功但 MCP 未收到 | 再调 OAuth | Agent 只能看到"回调未收到",不能确认浏览器是否真成功;无明确错误码时走兜底 |
|
|
127
|
-
| E Web 有 Key 本机无 | 调 OAuth | 「Web 已连上不等于本机 Agent;请重新授权,不要复制 Key。」 |
|
|
128
|
-
| G Key 归零 | 调 OAuth | 「Agentic 账户已断链,需完整重新授权。」 |
|
|
129
|
-
| P 云端 Agent | 告知用户后结束,不触发 OAuth | 「云端流程暂未开放,`[待填:resource endpoint]` 定义中;请先使用本地客户端。」 |
|
|
130
|
-
| Q 历史户 / V Playbook / W 手填 Key / T 多 Agent / X 0 余额 | `[待填:各场景处理规则]` | 规则待补充,运行时不要自行假设处理方式 |
|
|
131
|
-
| R bitget.com 网络不可达 | 排查代理后 OAuth | 「当前网络可能无法访问 bitget.com。我先检查本机 VPN/代理…」→ §5 |
|
|
132
|
-
|
|
133
|
-
---
|
|
134
|
-
|
|
135
|
-
## 4. 交易(已授权)
|
|
136
|
-
|
|
137
|
-
```
|
|
138
|
-
get_auth_status → discover → dryRun → 主网确认卡 → 用户确认「是/确认」→ 执行(高-risk + confirm)
|
|
139
|
-
```
|
|
140
|
-
|
|
141
|
-
**确认卡必含:** 交易对 · 方向 · 数量 · 价格类型 · 账户 · `[主网]` · 「确认执行?」
|
|
142
|
-
「直接帮我做」≠ 预授权。用户必须明确回复确认后才执行。
|
|
143
|
-
|
|
144
|
-
**要点:** 平仓先查仓 · hedge 要 posSide · Spot 市价买 qty=USDT · 持仓须带**强平价** · risk 类错误勿加仓
|
|
145
|
-
|
|
146
|
-
**首次交易:** 用户表达交易意图时先确认 Agentic 账户资金、先查余额;资金不足引导用户手动入金后再交易;Agent 不操作主账户。
|
|
147
|
-
|
|
148
|
-
**提币(必拒):** 「Agentic 账户不含提币;请 Web 主账户操作,Agentic 账户资金须先划转到主账户。」提币、主账户操作、主→子划转均需用户手动完成,Agent 不代办。
|
|
149
|
-
|
|
150
|
-
**错误 category:** auth→OAuth(D/E) · balance→O · rate→N · risk→停 · param→改参 · network→§5
|
|
151
|
-
|
|
152
|
-
---
|
|
153
|
-
|
|
154
|
-
## 5. 网络与代理(bitget.com)
|
|
155
|
-
|
|
156
|
-
重新授权(§2)或 OAuth 换 Key 时,MCP/SDK 需访问 **bitget.com**。部分地区无法直连,表现为授权 tool 超时、连接失败、回调未收到。
|
|
157
|
-
|
|
158
|
-
**Agent 必须主动处理:**
|
|
159
|
-
|
|
160
|
-
1. **识别网络问题:** 错误含 timeout / ECONNREFUSED / ENOTFOUND / network / fetch failed / 无法连接 bitget.com,或用户表示地区受限。
|
|
161
|
-
2. **主动探测本机代理:** 查 `HTTP_PROXY` / `HTTPS_PROXY` / `ALL_PROXY`、系统代理、常见 VPN 本地端口(如 `127.0.0.1:7890`)。**有代理** → 配置 MCP/shell 走代理后**重新走 §2 授权流程**。
|
|
162
|
-
3. **无可用代理** → 提示用户开 VPN/代理访问 bitget.com;**等用户确认已开好**后再重新授权。
|
|
163
|
-
4. **禁止:** 未排查网络就反复 OAuth · 拼 URL 绕过 MCP · 让用户手填 Key。
|
|
164
|
-
|
|
165
|
-
§3 Case **R**(地区网络)→ 本节。
|
|
166
|
-
|
|
167
|
-
---
|
|
168
|
-
|
|
169
|
-
## 6. 补充组件(一并安装,可选)
|
|
170
|
-
|
|
171
|
-
除 `@bitget-ai/bitget-agent-mcp`(OAuth + 交易)外,有两个可选组件。**禁止** `upgrade-all`(会连带装上 `bitget-signal`/datahub);行情用 **B**,终端 `bgc` 用 **A**(勿与 Agentic Skill 混为同一 Skill)。
|
|
172
|
-
|
|
173
|
-
**A · 终端交易工具链(需 API Key / 或与 MCP 并存,无 signal)**
|
|
174
|
-
|
|
175
|
-
```bash
|
|
176
|
-
npm i -g @bitget-ai/bitget-agent-cli
|
|
177
|
-
npx @bitget-ai/bitget-agent-installer upgrade @bitget-ai/bitget-agent-cli --target all
|
|
178
|
-
npx @bitget-ai/bitget-agent-installer upgrade @bitget-ai/bitget-agent-skill --target all
|
|
179
|
-
```
|
|
180
|
-
|
|
181
|
-
安装 `bgc` CLI 与 UTA 交易 Skill(`~/.claude/skills` 等);**不含** `bitget-signal`。`--target all` 指 installer 支持的 claude / codex / openclaw;Cursor 用户已装 Agentic Skill,交易以交易 MCP 为主,A 为可选(终端跑 `bgc`)。安装后重启客户端或新开会话。
|
|
182
|
-
|
|
183
|
-
**B · 云端 Market MCP(HTTP,无需 Key)**
|
|
184
|
-
|
|
185
|
-
- **Claude Code:** `claude mcp add bitget-mcp-server --transport http https://agent.bitget.com/mcp`
|
|
186
|
-
- **Cursor:** MCP 设置新增 HTTP server,URL `https://agent.bitget.com/mcp`
|
|
187
|
-
- **其他客户端:** 按 HTTP MCP 方式注册,endpoint `https://agent.bitget.com/mcp`
|
|
188
|
-
|
|
189
|
-
与 stdio 交易 MCP **并存**,不要替换。安装后重启会话或 MCP 重连。
|
|
190
|
-
|
|
191
|
-
---
|
|
192
|
-
|
|
193
|
-
## 7. 禁止(违反即错)
|
|
194
|
-
|
|
195
|
-
静默重链 / 粘贴或 env 配 Key / 代删 Web Key / 失效仍交易 / 限流当失效 / 只给链接不调 OAuth / LLM 监听 callback / 无法确认失败原因时猜测归因 / 网络问题未排查代理就反复 OAuth
|
package/skills/uta/SKILL.md
DELETED
|
@@ -1,189 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: bitget
|
|
3
|
-
description: >
|
|
4
|
-
Use this skill whenever the user wants to check prices, pull candlesticks / K-line
|
|
5
|
-
(OHLCV) history, the orderbook or other market data, manage account balances,
|
|
6
|
-
place or cancel orders, manage futures/spot/margin positions, set leverage or
|
|
7
|
-
margin/position mode, transfer funds, deposit or withdraw, check funding rates,
|
|
8
|
-
use demo/paper trading, take loans, or do anything else on the Bitget exchange.
|
|
9
|
-
Invoke this skill even when the user doesn't say "Bitget" by name — action phrases
|
|
10
|
-
like "check my open orders", "cancel my BTC position", "move USDT to futures",
|
|
11
|
-
"what's my P&L", "place a market sell", "how much can I withdraw", "show my
|
|
12
|
-
positions", "set leverage to 10x", "what's the funding rate", "show me BTC daily
|
|
13
|
-
candles", "pull the 4h K-line" all require this skill. Also invoke for
|
|
14
|
-
Chinese-language trading requests such as "查看我的账户",
|
|
15
|
-
"下一个限价单", "查看持仓盈亏", "转账到合约账户", "BTC现在多少钱", "看下K线", "查历史K线",
|
|
16
|
-
"设置杠杆", "提币" —
|
|
17
|
-
these are Bitget operations even without the exchange name. Always invoke this
|
|
18
|
-
skill before attempting any exchange trading task from scratch.
|
|
19
|
-
---
|
|
20
|
-
|
|
21
|
-
# Bitget Skill (Unified Trading Account / v3)
|
|
22
|
-
|
|
23
|
-
Drive the Bitget exchange through the `bgc` CLI — one Unified Trading Account (UTA)
|
|
24
|
-
covering spot, margin, and futures, plus funds, sub-accounts, loans, and broker
|
|
25
|
-
operations. The CLI is a thin shell over the Bitget Agent SDK: the SDK owns action
|
|
26
|
-
dispatch, input validation, write-safety, and discovery, so this skill teaches you
|
|
27
|
-
the **grammar** and the **safe workflow**, then points you at the reference docs.
|
|
28
|
-
|
|
29
|
-
Reference docs live in this skill's `references/` directory (alongside this file).
|
|
30
|
-
|
|
31
|
-
## Step 1: Check prerequisites
|
|
32
|
-
|
|
33
|
-
```bash
|
|
34
|
-
bgc --version
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
If not found → tell the user: `npm install -g @bitget-ai/bitget-agent-cli`
|
|
38
|
-
|
|
39
|
-
Public market data needs no credentials. Everything else (account, trading,
|
|
40
|
-
transfers, withdrawals) needs API credentials as environment variables. See
|
|
41
|
-
`references/auth-setup.md`.
|
|
42
|
-
|
|
43
|
-
## Step 2: The grammar (this replaced the old v2 grammar)
|
|
44
|
-
|
|
45
|
-
```
|
|
46
|
-
bgc <tool> [--action <name>] [--<param> <value> ...] [global flags]
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
- **One verb per call.** There are 14 intent verbs (e.g. `market`, `order`,
|
|
50
|
-
`position`, `account_overview`, `transfer_funds`, `withdraw`).
|
|
51
|
-
- **`--action`** picks the intent for an action-routed verb
|
|
52
|
-
(`bgc order --action place`, `bgc position --action closeAll`).
|
|
53
|
-
A few verbs take no action (e.g. `account_overview` is a single-shot snapshot).
|
|
54
|
-
- **Values coerce by shape:** `true`/`false` → boolean, a value starting with `[`
|
|
55
|
-
or `{` → JSON (e.g. `--orders '[{...}]'`), everything else stays a string.
|
|
56
|
-
|
|
57
|
-
> The old v2 form `bgc <module> <tool_name>` (e.g. `bgc spot spot_get_ticker`) is
|
|
58
|
-
> **gone**. There are no separate spot/futures modules — one `--category` param
|
|
59
|
-
> (`SPOT`, `MARGIN`, `USDT-FUTURES`, `COIN-FUTURES`, `USDC-FUTURES`) selects the market.
|
|
60
|
-
|
|
61
|
-
## Step 3: Discover before you assemble a call
|
|
62
|
-
|
|
63
|
-
Don't guess parameters. The CLI introspects its own live surface:
|
|
64
|
-
|
|
65
|
-
```bash
|
|
66
|
-
bgc discover # list domains + verb counts
|
|
67
|
-
bgc discover --domain trade # verbs in a domain
|
|
68
|
-
bgc discover --tool order # one verb: actions + full schema
|
|
69
|
-
bgc discover --tool order --action place # exact required/optional contract
|
|
70
|
-
bgc discover --search "funding rate" # keyword-search the whole surface
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
`bgc discover --tool <verb> --action <name>` is the authoritative, always-current
|
|
74
|
-
parameter contract. **Read it before constructing any non-trivial command**, especially
|
|
75
|
-
for trading. Full guide: `references/discover-guide.md`.
|
|
76
|
-
|
|
77
|
-
A complete **static** catalog of every verb, action, and parameter is in
|
|
78
|
-
`references/commands.md` (auto-generated from the SDK — navigate by its domain TOC).
|
|
79
|
-
|
|
80
|
-
## Output contract
|
|
81
|
-
|
|
82
|
-
All output is JSON.
|
|
83
|
-
|
|
84
|
-
- **Success** → stdout, exit 0: `{ endpoint, requestTime, data }` — `data` is the result.
|
|
85
|
-
- **Error** → stderr, exit 1: `{ ok: false, error: { type, category, message, suggestion, retryable }, timestamp }`.
|
|
86
|
-
- **`--dry-run`** → stdout, exit 0: `{ dryRun: true, operationId, wouldSend, ... }` — the would-send request, nothing sent.
|
|
87
|
-
- **Confirmation gate** → stdout, exit 0: `{ confirmationRequired: true, operationId, hint, ... }` — a high-risk write that was NOT executed because `--confirm` was absent. This is a **normal result, not an error.**
|
|
88
|
-
|
|
89
|
-
On error, branch on `error.category`: `auth`/`param` → fix the request and resend;
|
|
90
|
-
`balance`/`risk` → surface to the user (cannot self-heal); `rate`/`network` → back
|
|
91
|
-
off and retry; `config` → check account mode / credentials. See `references/error-codes.md`.
|
|
92
|
-
|
|
93
|
-
## The 14 verbs
|
|
94
|
-
|
|
95
|
-
| Domain | Verb | Use for |
|
|
96
|
-
|--------|------|---------|
|
|
97
|
-
| market | `market` | Tickers, orderbook, candles, instruments, funding rate, open interest (public) |
|
|
98
|
-
| trade | `order` | Place/cancel/modify orders (single or batch), open/history/fills, max-openable |
|
|
99
|
-
| trade | `position` | Current/history positions, ADL rank, **close** (one, by symbol) / **closeAll** |
|
|
100
|
-
| trade | `strategy_order` | Trigger/plan orders: place/cancel/modify/open/history |
|
|
101
|
-
| account | `account_overview` | One-call snapshot: assets, settings, funding assets, (opt.) positions + fee rate |
|
|
102
|
-
| account | `account_config` | Account settings: leverage, position/holding mode (one-way/hedge), account mode (basic/advanced) |
|
|
103
|
-
| account | `repayment` | Repay liabilities |
|
|
104
|
-
| funds | `transfer_funds` | Transfer between accounts / sub-accounts |
|
|
105
|
-
| funds | `deposit` | Deposit address & records |
|
|
106
|
-
| funds | `withdraw` | **Withdraw** (high-risk) & records |
|
|
107
|
-
| funds | `funds_records` | Funding/transfer/deposit/withdraw history |
|
|
108
|
-
| subaccount | `subaccount` | Create/list sub-accounts, manage their API keys & assets |
|
|
109
|
-
| loan | `loan` | Crypto loans: borrow, repay, orders, collateral |
|
|
110
|
-
| tax | `tax` | Tax/transaction records |
|
|
111
|
-
|
|
112
|
-
Use `discover` for the actions and exact params of any verb.
|
|
113
|
-
|
|
114
|
-
## Write safety: two different "confirms" — don't conflate them
|
|
115
|
-
|
|
116
|
-
Operations are graded **read < write < high**. There are TWO separate confirmation
|
|
117
|
-
concepts here, and mixing them up is the single biggest source of trading mistakes:
|
|
118
|
-
|
|
119
|
-
1. **Confirm with the USER — for every write.** Before running ANY write (placing or
|
|
120
|
-
cancelling orders, transfers, withdrawals, setting leverage, borrowing, repaying),
|
|
121
|
-
summarize what it will do and get the user's go-ahead. This is your *behavior*, not
|
|
122
|
-
a CLI flag. Never silently execute a write.
|
|
123
|
-
> Example: "This places a limit BUY of 0.01 BTC at $70,000 on BTCUSDT (SPOT). OK to send?"
|
|
124
|
-
|
|
125
|
-
2. **The `--confirm` flag — for high-risk ops only.** This is a CLI gate that ONLY four
|
|
126
|
-
operations require: `closeAllPositions`, `cancelAllOrders`, `withdrawal`,
|
|
127
|
-
`brokerSubaccountWithdrawal`. Without `--confirm` they return
|
|
128
|
-
`{ confirmationRequired: true }` and send nothing (a normal result, not an error).
|
|
129
|
-
|
|
130
|
-
**Ordinary writes do NOT take `--confirm`.** A plain `order --action place`, a single
|
|
131
|
-
`cancel`, a `transfer_funds`, a leverage change — these execute **live** the moment you
|
|
132
|
-
omit `--dry-run`. `--confirm` is not their gate and adding it changes nothing; the
|
|
133
|
-
user's go-ahead (concept 1) is what authorizes them.
|
|
134
|
-
|
|
135
|
-
**Don't guess which kind an action is — read its contract.**
|
|
136
|
-
`bgc discover --tool <verb> --action <name>` reports `riskLevel` (`read`|`write`|`high`)
|
|
137
|
-
and `requiresConfirm` (`true` only for the four high-risk ops).
|
|
138
|
-
|
|
139
|
-
Safety flags:
|
|
140
|
-
- `--dry-run` — preview the would-send request without sending it (great for showing the user exactly what will happen).
|
|
141
|
-
- `--confirm` — execute a **high-risk** operation. No effect on an ordinary write or a read.
|
|
142
|
-
- `--read-only` — block all writes for the session.
|
|
143
|
-
- `--paper-trading` — route writes to the Bitget demo environment (see below).
|
|
144
|
-
|
|
145
|
-
**Recommended patterns:**
|
|
146
|
-
- *Ordinary write:* preview with `--dry-run` (or just summarize the effect), get the user's OK, then run it — no `--confirm`.
|
|
147
|
-
- *High-risk write:* `--dry-run` to preview → show the user the `wouldSend` payload → on their OK, re-run with `--confirm`.
|
|
148
|
-
|
|
149
|
-
## Trading specifics — read before trading
|
|
150
|
-
|
|
151
|
-
Before constructing futures close / TP-SL / withdrawal commands, read
|
|
152
|
-
`references/trading-safety.md`. Critical rules:
|
|
153
|
-
|
|
154
|
-
- **Close ONE position at market: `position --action close --symbol <PAIR>`.** High-risk →
|
|
155
|
-
needs `--confirm`; in hedge mode add `--posSide long|short`. It hard-requires `--symbol`, so it
|
|
156
|
-
can never flatten the whole category by omission.
|
|
157
|
-
- **Close EVERYTHING in a category: `position --action closeAll --category <CAT>`** (optionally
|
|
158
|
-
narrowed by `--symbol`) — also high-risk, needs `--confirm`.
|
|
159
|
-
- **Close at YOUR price instead of market:** `order --action place` with the OPPOSITE side — one-way
|
|
160
|
-
mode add `--reduceOnly yes`; hedge mode set `--posSide` to the side you're closing. (Selling to
|
|
161
|
-
"close" a short actually opens more short — check `position --action info` first.)
|
|
162
|
-
- **Limit orders require `--price`** (market orders take none); in hedge mode `--posSide` is required
|
|
163
|
-
too. `discover --tool order --action place` reports these under `conditionalRequired`.
|
|
164
|
-
- **TP/SL:** preset `--takeProfit` / `--stopLoss` on the opening order, or manage after entry via `strategy_order`.
|
|
165
|
-
- **Spot market BUY `qty` is in quote coin (USDT), not base coin** — confirm intent to avoid mis-sized orders.
|
|
166
|
-
- **Withdrawals:** always show the chain and destination address in the confirmation; wrong chain is irreversible.
|
|
167
|
-
|
|
168
|
-
## Demo / paper trading
|
|
169
|
-
|
|
170
|
-
When the user wants to practice or says "demo"/"paper"/"simulated", add `--paper-trading`
|
|
171
|
-
to writes (needs separate demo credentials; mutually exclusive with `--read-only`). Keep
|
|
172
|
-
the whole session in one mode — never mix live and demo. See `references/demo-trading.md`.
|
|
173
|
-
|
|
174
|
-
## Output presentation
|
|
175
|
-
|
|
176
|
-
- **Prices/tickers:** symbol, last price, 24h change, volume — readable summary, not raw JSON.
|
|
177
|
-
- **Order lists:** table with orderId, symbol, side, price, qty, status.
|
|
178
|
-
- **Balances:** coin, available, frozen; skip dust (< 0.0001).
|
|
179
|
-
- **Positions:** symbol, side (long/short), size, entry, mark, unrealized PnL, **liquidation price**, leverage. Never omit liquidation price.
|
|
180
|
-
- **Funding rates:** current rate, annualized, next settlement time.
|
|
181
|
-
- For raw data the user didn't ask to see: summarize, don't dump full JSON. Use `--view summary` (default) and `--fields` to trim large payloads.
|
|
182
|
-
|
|
183
|
-
## Escape hatch
|
|
184
|
-
|
|
185
|
-
If no verb fronts the operation you need, reach any catalog operation by id:
|
|
186
|
-
|
|
187
|
-
```bash
|
|
188
|
-
bgc raw --operationId <id> --args '{"category":"SPOT","symbol":"BTCUSDT"}'
|
|
189
|
-
```
|