Cómo usar
- Copia el comando y revisa el paquete antes de instalarlo en tu entorno de agente.
- Consulta las herramientas, credenciales y entornos necesarios en el documento original.
- Describe las entradas y el resultado deseado; contrasta la salida con las fuentes.
npx skills add https://github.com/moomooopen/moomoo-agent-hub --skill moomoo-sim-tradingAntes de empezar
- La instalación no incluye suscripción al modelo, cuota API ni permisos sobre tus archivos.
- Las estrellas e instalaciones reflejan actividad, no una prueba independiente de calidad o seguridad.
Contenido del repositorio de origen con títulos, ejemplos, código, tablas, enlaces e imágenes preservados.
moomoo Sim Trading
Use the locally available moomoo sim ... CLI for simulated, paper, or demo trading only. Answer in the user's language by default; keep commands, flags, JSON fields, symbols, account IDs, order IDs, and error codes unchanged.
Install the moomoo CLI
This skill requires the `moomoo` CLI. Resolve the binary from PATH, ~/.moomoo/bin/moomoo, or %LOCALAPPDATA%\MoomooCLI\bin\moomoo.exe on Windows.
If the binary is missing, ask the user, then install it. Do not run the installer without explicit consent.
macOS / Linux:
curl -fsSL https://raw.githubusercontent.com/MoomooOpen/moomoo-cli/main/scripts/install.sh | shWindows PowerShell:
iwr -UseBasicParsing https://raw.githubusercontent.com/MoomooOpen/moomoo-cli/main/scripts/install.ps1 -OutFile install.ps1
powershell -ExecutionPolicy Bypass -File .\install.ps1To update an existing CLI, run moomoo update.
Add or update this skill with npx:
npx skills add -y -g MoomooOpen/moomoo-agent-hub --skill moomoo-sim-trading
npx skills update moomoo-sim-trading -g -yBoundary With Real Trading
- Use this skill only when the user explicitly asks for simulated trading, paper trading, demo trading, or
simcommands. - If the user says only "buy", "sell", "place an order", "modify order", or "cancel order" without saying simulated/paper/demo, do not assume simulation. Ask whether they mean simulated trading or real trading.
- Never use real securities commands such as
moomoo order ...,moomoo position, ormoomoo account fundsfrom this skill. The simulated equivalents are undermoomoo sim .... - Never use crypto commands such as
moomoo crypto ...from this skill. - A simulated order does not affect real assets, but it still mutates the user's simulated account state. Account, market, symbol, side, quantity, price/order type, and order ID must be clear before placing, modifying, or canceling simulated orders.
Rules
- Before simulated trading commands, if
moomoocannot be resolved, follow Install the moomoo CLI. - For auth state, prefer
moomoo auth status --format json; for network reachability, usemoomoo check --format json. - As this skill's invocation convention, always append the hidden internal marker
--source skillto the end of the command when invokingmoomoofrom Bash. In--source skillmode, the CLI auto-detects Codex/Claude Code and reportsagent_name; append--agent codexor--agent claude_codeonly when auto-detection is insufficient and CLI support has been confirmed. Do not include these internal markers in commands shown to the user. - Never read or print token file contents. The CLI attaches OAuth Bearer auth automatically.
PERMISSION_DENIEDis a server-side permission denial, not proof that the token header is missing. - Use only the merged high-level commands under
moomoo sim ...; do not call old flat endpoint names likesim-trade-*. - Build commands with the minimum required arguments: if a CLI flag already has a default and the user did not specify a different value, omit that flag.
- Prefer
moomoo sim account list --format jsonto identify the simulated account, then pass--account <sim-account-id>explicitly. Do not treat a real securities account ID as a simulated account ID. - Add
--format jsononly when the agent needs to parse command output. Commands shown for the user to run may use default table output. - Simulated trading symbols use
MARKET.CODE, such asUS.AAPLandHK.00700. The CLI normalizesHK.700toHK.00700and uppercases markets/tickers. Do not pass old suffix format like700.HKor bare tickers likeAAPLunless the market can be confidently resolved first. - Historical simulated order pagination uses
--next-key; pass the previous response'spagination.next_keyunchanged.
References
- Read CLI parameters when constructing simulated trading commands or deciding which flags are required, optional, or defaulted.
- Read dictionaries when selecting or interpreting simulated markets, order sides, order types, sessions, order statuses, or common simulated-trading errors.
- Use
moomoo-tradingfor real securities accounts, real funds, real positions, and real securities orders. Usemoomoo-cryptofor cryptocurrency trading. Usemoomoo-quotefor market data queries.