@onebullex-group/cli 1.3.1 → 1.5.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 +123 -61
- package/README.md +304 -243
- package/dist/chunk-6DC55RF7.js +16 -0
- package/dist/{chunk-PEVZEMJG.js → chunk-NMW73ILO.js} +49 -1
- package/dist/chunk-SGLPG2FL.js +39 -0
- package/dist/{chunk-NKWXNVLA.js → chunk-YE5LER6U.js} +86 -19
- package/dist/core/bill-no.d.ts +19 -0
- package/dist/core/bill-no.js +9 -0
- package/dist/core/download.d.ts +41 -0
- package/dist/core/download.js +15 -0
- package/dist/core/http-client.d.ts +32 -1
- package/dist/core/http-client.js +9 -5
- package/dist/index.js +217 -83
- package/dist/lint-api.d.ts +1 -1
- package/dist/lint-api.js +27 -6
- package/dist/registry.js +1 -1
- package/package.json +3 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,61 +1,123 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
All notable changes to `@onebullex-group/cli` (formerly briefly published as `@onemore-group/cli`).
|
|
4
|
-
|
|
5
|
-
## 1.1.2 — 2026-05-16
|
|
6
|
-
|
|
7
|
-
Rename only — no functional changes from 1.1.1.
|
|
8
|
-
|
|
9
|
-
- Package renamed from `@onebullex/cli` → `@onebullex-group/cli`. The
|
|
10
|
-
CLI binary remains `onebullex` (unchanged), the README still
|
|
11
|
-
describes "OneBullEx Open API V2" — only the npm package name moved.
|
|
12
|
-
- A short-lived `@onemore-group/cli@1.1.2` was published earlier the
|
|
13
|
-
same day and has been unpublished. If you installed it, switch to
|
|
14
|
-
`@onebullex-group/cli@1.1.2` (identical contents).
|
|
15
|
-
- Existing 1.1.0 / 1.1.1 were never published.
|
|
16
|
-
|
|
17
|
-
##
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
-
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to `@onebullex-group/cli` (formerly briefly published as `@onemore-group/cli`).
|
|
4
|
+
|
|
5
|
+
## 1.1.2 — 2026-05-16
|
|
6
|
+
|
|
7
|
+
Rename only — no functional changes from 1.1.1.
|
|
8
|
+
|
|
9
|
+
- Package renamed from `@onebullex/cli` → `@onebullex-group/cli`. The
|
|
10
|
+
CLI binary remains `onebullex` (unchanged), the README still
|
|
11
|
+
describes "OneBullEx Open API V2" — only the npm package name moved.
|
|
12
|
+
- A short-lived `@onemore-group/cli@1.1.2` was published earlier the
|
|
13
|
+
same day and has been unpublished. If you installed it, switch to
|
|
14
|
+
`@onebullex-group/cli@1.1.2` (identical contents).
|
|
15
|
+
- Existing 1.1.0 / 1.1.1 were never published.
|
|
16
|
+
|
|
17
|
+
## 1.5.0 — 2026-10-07
|
|
18
|
+
|
|
19
|
+
Syncs V2 doc updates since 1.4.0 (Java SDK: cursor bills, async position
|
|
20
|
+
export, system user-info/download, public index-price). Registry 65 → 68.
|
|
21
|
+
|
|
22
|
+
- `position history-async` — GET `/v2/position/history/async`. Returns
|
|
23
|
+
`downloadId`. Local 1-year range check so an over-wide request cannot burn
|
|
24
|
+
one of the 5 monthly export slots.
|
|
25
|
+
- `system user-info` — GET `/v2/system/user/info`. New `system` command group.
|
|
26
|
+
- `system download <downloadId>` — GET `/v2/system/download`. Writes the Excel
|
|
27
|
+
stream to disk (`--out` file or directory; default `~/.onebullex/downloads/`)
|
|
28
|
+
and prints `{path, bytes, downloadId}`. New `core/download.ts`.
|
|
29
|
+
- `HttpClient.getPrivateBinary` — JSON business errors (`file_not_ready`, …)
|
|
30
|
+
still throw `OneBullExError`; a file stream is returned as bytes. Matches
|
|
31
|
+
Java `BaseClientV2.executeGetBytes`.
|
|
32
|
+
- `balance bills` switched from `page`/`size` to cursor `id`/`direction`/`limit`
|
|
33
|
+
plus optional `--symbol`.
|
|
34
|
+
- `index-price get` is public again (docs dropped the auth requirement).
|
|
35
|
+
- Breaking: ticker commands renamed `--time-range` → required
|
|
36
|
+
`--time-range-type` (API field `timeRangeType`). The old flag name was never
|
|
37
|
+
sent as `timeRangeType` on the MCP path, so live calls got `invalid param`.
|
|
38
|
+
- `HttpClient` upper-cases the `direction` query param before signing. The
|
|
39
|
+
server is case-sensitive (`next` → `invalid_direction`); done in the client so
|
|
40
|
+
MCP calls, which skip commander actions, get it too.
|
|
41
|
+
- `depth get --level` and `order list-unfinished --direction` are now required
|
|
42
|
+
(the API already rejected the request without them).
|
|
43
|
+
- `entrust create-plan --stop-price` is required (server always demanded it).
|
|
44
|
+
- Help text: `positionSide` is LONG/SHORT (no BOTH/NET); plan trigger types
|
|
45
|
+
are MARK_PRICE/LATEST_PRICE; origQty is integer contracts.
|
|
46
|
+
- Fix: `config init --yes --api-key/--secret/--base-url` silently dropped those
|
|
47
|
+
values (commander bound them to the same-named root options). Added
|
|
48
|
+
`--no-set-default` so a second profile can be added without changing the
|
|
49
|
+
default.
|
|
50
|
+
- Docs: README "多个 API Key(多 profile)" section.
|
|
51
|
+
- Coverage lint: CRLF-safe `parseDocParams` (Windows checkouts were silently
|
|
52
|
+
skipping the parameter lint); scoped `CLI_ONLY_PARAMS` (`--out`) and
|
|
53
|
+
positional aliases (`plan-get <id>` → `entrustId`).
|
|
54
|
+
|
|
55
|
+
## 1.4.0 — 2026-08-26
|
|
56
|
+
|
|
57
|
+
Syncs the three V2 endpoints added to the Java SDK since 1.3.1 (commits
|
|
58
|
+
`566645a`, `f684e52`). Registry now covers 65 documented endpoints.
|
|
59
|
+
|
|
60
|
+
- `balance funding` — GET `/v2/balance/funding`, funding (USDT) wallet balance.
|
|
61
|
+
- `bot redeeming-info` — GET `/v2/bot/redeeming-info`, redemption queue summary.
|
|
62
|
+
Introduces a new top-level `bot` command group.
|
|
63
|
+
- `balance transfer` — POST `/v2/balance/transfer`, moves funds between the
|
|
64
|
+
funding and contract wallets. **The first command in this CLI that moves real
|
|
65
|
+
money rather than trading state.** Default dry-run applies as with every write.
|
|
66
|
+
- New `core/bill-no.ts` (exported as `@onebullex-group/cli/core/bill-no`):
|
|
67
|
+
generates the `obe-<uuid>` idempotency key that `balance transfer` requires.
|
|
68
|
+
`--bill-no` is therefore optional at the CLI boundary even though the API
|
|
69
|
+
marks it required. Retrying a transfer MUST reuse the original billNo — a
|
|
70
|
+
fresh one is treated as a second transfer by the exchange.
|
|
71
|
+
- The coverage lint gained a scoped `CLI_DEFAULTED_PARAMS` exception so a
|
|
72
|
+
doc-required param may be a plain `--option` when the CLI defaults it. Scoped
|
|
73
|
+
per `METHOD path`; deliberately not added to `GLOBAL_FLAGS`, which would have
|
|
74
|
+
dropped billNo from the derived MCP input schema.
|
|
75
|
+
- Docs: README endpoint counts corrected to the registry-derived 65
|
|
76
|
+
(21 public / 23 private read / 21 write). The previous "60" had been stale
|
|
77
|
+
since two endpoints were added without updating it.
|
|
78
|
+
|
|
79
|
+
## Unreleased
|
|
80
|
+
|
|
81
|
+
- ci(cli): nightly `cli-e2e-nightly` job in `.gitlab-ci.yml`, runs the full
|
|
82
|
+
`tests/e2e/` suite when triggered by a Pipeline Schedule. Reads
|
|
83
|
+
`ONEBULLEX_E2E_API_KEY` / `_SECRET` from GitLab CI variables. Marked
|
|
84
|
+
`allow_failure: true` with one retry so testnet flakes don't block the
|
|
85
|
+
schedule.
|
|
86
|
+
- test(cli): testnet write e2e suite covering all 20 V2 write endpoints,
|
|
87
|
+
organized into 4 business-flow blocks (configuration / limit orders /
|
|
88
|
+
plan + order-entrust / position + TP-SL). Gated on `ONEBULLEX_E2E=1`
|
|
89
|
+
with separate `ONEBULLEX_E2E_API_KEY` / `_SECRET` env vars. Default-
|
|
90
|
+
skipped. Each block has best-effort cleanup so consecutive runs leave
|
|
91
|
+
the testnet account state-clean.
|
|
92
|
+
|
|
93
|
+
## 1.1.0 — 2026-05-15
|
|
94
|
+
|
|
95
|
+
Adds Phase 2: 20 write operations covering order placement / cancellation,
|
|
96
|
+
plan + TP/SL entrust management, and position margin / leverage / type changes.
|
|
97
|
+
|
|
98
|
+
- 5 order write commands (create, create-batch, cancel, cancel-batch, cancel-all)
|
|
99
|
+
- 7 entrust write commands (create-plan, create-profit, cancel-plan,
|
|
100
|
+
cancel-profit, update-profit, cancel-all-plan, cancel-all-profit)
|
|
101
|
+
- 2 order-entrust write commands (cancel, cancel-all)
|
|
102
|
+
- 6 position write commands (adjust-leverage, margin, auto-margin, close-all,
|
|
103
|
+
merge, change-type)
|
|
104
|
+
- New `executeWrite` helper guards every write with a default dry-run; `--confirm`
|
|
105
|
+
is required for the actual POST. Dry-run preview goes to stdout, the
|
|
106
|
+
`--confirm` hint goes to stderr.
|
|
107
|
+
- Drift-detection lint now covers all 60 V2 endpoints; the `PHASE1_DEFERRED`
|
|
108
|
+
whitelist is empty.
|
|
109
|
+
- Adds 21 new write command integration tests verifying both the dry-run path
|
|
110
|
+
(no fetch, structured preview) and the confirm path (camelCase body shape).
|
|
111
|
+
|
|
112
|
+
## 1.0.0 — 2026-05-15
|
|
113
|
+
|
|
114
|
+
Initial release. Covers OneBullEx Open API V2:
|
|
115
|
+
|
|
116
|
+
- 22 public endpoints (server time, symbol/ticker/depth/kline/funding/...)
|
|
117
|
+
- 18 private read-only endpoints (balance/order/entrust/position/...)
|
|
118
|
+
- HMAC-SHA256 auth aligned byte-for-byte with `SignatureUtilsV2.java`
|
|
119
|
+
- 6 config commands with multi-profile support, `--stdin` enforcement on
|
|
120
|
+
api-key/secret, and 0600 file mode
|
|
121
|
+
- Drift-detection lint comparing CLI registry against V2 markdown docs
|
|
122
|
+
(endpoint coverage + parameter coverage + write-safety)
|
|
123
|
+
- 155 unit / integration tests + 5 testnet e2e smoke tests
|