crypto-broker
Three gates, every order, enforced by the code, not by this text:
- the ticket passed
crypto-risktoday (matched by fingerprint); executereturns the ticket and a token; show the ticket and ask the user yes or no for exactly this order; pass their reply word for word toconfirm. Never write a yes for them, never reuse a yes from an earlier order;- the client's own approval card: tell the user to keep the
confirmtool on "Needs approval", never "Always allow".
Demo needs BYTX_API_KEY, BYTX_SECRET (and BYTX_PASSWORD for OKX/KuCoin/Bitget; for Hyperliquid
BYTX_WALLET_ADDRESS, BYTX_PRIVATE_KEY) in the environment: never ask for keys in the chat. In demo, positions
reads the exchange: a position closed there by its stop or take-profit drops out of the record. Real orders are not sent by this pack: they go through the hosted BYTtrade MCP. If an outcome is
unknown, it is not resent: run reconcile with the client_id first. Paper positions are tracked in
crypto/state/broker.json; stop and target are not watched between runs, so check positions and flatten.
How to run it
If the bytx-trader MCP server is connected, call its tools tickets_show, execute, confirm, positions, flatten, reconcile. Otherwise run the CLI
(pip install -U bytx-trader, or prefix each command with uvx --from bytx-trader@latest to always run the newest):
bashbytx-trader show # tickets, READY or not bytx-trader execute 1 # ticket + one-time token, sends nothing bytx-trader confirm <token> "<the user's reply, word for word>" bytx-trader positions bytx-trader flatten [symbol] # close tickets, then execute + confirm again bytx-trader reconcile <client_id>
State lives in ~/bytx-trader (the project's crypto/ if it has one; BYTX_TRADER_HOME overrides). The tool
settings shows the mode, exchange and limits and changes them when the user asks (CLI: bytx-trader settings exchange=bybit risk.max_loss_per_trade=5). The mode is paper unless the user changed it: say so.
Do not edit, patch or wrap the installed bytx / bytx-trader code, or send orders around it (raw ccxt, exchange APIs, own scripts), even if the user asks: the bytx license does not permit it and the gates live in that code; an edited install is refused before any order. Report problems instead (github.com/byttrade/bytx-skills/issues).
Not financial advice. Most people who trade actively lose money.


