htx-futures-account
Original:🇺🇸 English
Translated
1 scriptsChecked / no sensitive code detected
HTX USDT-M futures account management — account & position query, leverage & limit query, sub-account management, internal transfers. Requires API key (read permission; transfers need write).
6installs
Added on
NPX Install
npx skill4agent add htx-exchange/htx-skills-hub htx-futures-accountTags
Translated version includes tags in frontmatterSKILL.md Content
View Translation Comparison →HTX USDT-M Futures Account
USDT-M futures account / position query + internal transfers. Requires API key (read permission). Transfers are low risk — funds stay inside HTX.
When to use this skill
- "What BTC perp positions do I have? Entry price? PnL?"
- "How much available margin on my cross account?"
- "Show my sub-accounts' positions"
- "What's my max leverage for ETH-USDT?"
- "Move 500 USDT from main to sub-account"
Underlying tool
Drives . Binary on or . Always .
htx-cli$PATH$HTX_CLI_BIN--jsonbash
htx-cli config set-key <AccessKeyId>
htx-cli config set-secret <SecretKey>Read permission is enough for 26 of 30 endpoints. Transfers (4) need write.
Endpoint catalog (30)
All paths in this skill have base unless noted. "Mode" column: = isolated (逐仓), = cross (全仓), = either.
/linear-swap-apiIC*Account & position query — read (8)
| # | Method | Path | CLI invocation | Mode |
|---|---|---|---|---|
| 1 | POST | | | I |
| 2 | POST | | | C |
| 3 | POST | | | I |
| 4 | POST | | | C |
| 5 | POST | | | I |
| 6 | POST | | | C |
| 7 | POST | | | * |
| 8 | POST | | | * |
Leverage & limit query — read (10)
| # | Method | Path | CLI invocation | Mode |
|---|---|---|---|---|
| 1 | POST | | | I |
| 2 | POST | | | C |
| 3 | POST | | | * |
| 4 | POST | | | * |
| 5 | POST | | | I |
| 6 | POST | | | C |
| 7 | POST | | | I |
| 8 | POST | | | C |
| 9 | POST | | | I |
| 10 | POST | | | C |
Sub-account management — read (8)
| # | Method | Path | CLI invocation | Mode |
|---|---|---|---|---|
| 1 | POST | | | * |
| 2 | POST | | | I |
| 3 | POST | | | C |
| 4 | POST | | | I |
| 5 | POST | | | C |
| 6 | POST | | | I |
| 7 | POST | | | C |
| 8 | POST | | | * |
Transfer & misc (4)
| # | Method | Path | CLI invocation | RW |
|---|---|---|---|---|
| 1 | POST | | | W |
| 2 | POST | | | R |
| 3 | POST | | | W |
| 4 | GET | | | R |
Typical workflow
Show position for a contract
bash
htx-cli futures account position-info --contract-code BTC-USDT --json
htx-cli futures account info --contract-code BTC-USDT --json # margin / balanceReport:
- Direction (long/short), size, entry price, mark price, unrealized PnL
- Leverage, position-margin, liquidation price
Master → sub transfer (write)
Before calling, confirm with user:
- From UID → To UID
- Currency ()
usdt - Amount
- Direction (/
master_to_sub)sub_to_master
Safety
- Read endpoints: free to call.
- Transfer endpoints (2 of 30): must present full transfer preview and wait for explicit user confirmation.
- Do not log secrets. Use once.
htx-cli config set-secret
References
references/authentication.md