A private, terminal-first workspace for experimenting with the existing OlympTrade WebSocket client. The original olymptrade_ws package remains the foundation; the local tooling is tuned for safer configuration, quiet logs, and read-only examples by default.
- Credentials stay in your local environment or hidden terminal input.
- Raw WebSocket payloads are not written to disk.
- The default connection must use encrypted WebSockets and the official
ws.olymptrade.comhost. - Example scripts do not place orders.
- API event mappings are reverse-engineered and can change without notice.
pkg update
pkg install python
python -m venv .venv
. .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install -r requirements.txtThe safest approach is to enter the token only when prompted. To use an environment variable for the current shell session:
export OLYMPTRADE_ACCESS_TOKEN='paste-your-token-here'
python -m olymptrade_ws.mainAvoid putting a real token in shell history, screenshots, shared files, or source code. Clear the variable after use with unset OLYMPTRADE_ACCESS_TOKEN.
Run the read-only candle example with:
python simple_bot.pyThe example inspects the latest candle and reports a simple directional bias. It does not submit a trade.
python -m pytest -qTests are local and do not connect to OlympTrade or require a token.
The Python client connects to wss://ws.olymptrade.com/otp by default and sends the supplied token as the access_token cookie to that host. It cannot authenticate without sending the token to the broker. Custom hosts are rejected unless the caller explicitly opts in with allow_custom_endpoint=True; do not enable that option for an endpoint you do not control and trust. The documentation website may load third-party assets if opened in a browser; the Python runtime does not need those website assets.
No source review can guarantee that a third-party service or a reverse-engineered private API is safe or stable. Use a demo account first, inspect future changes, and never provide this client with credentials you cannot afford to revoke.
olymptrade_ws/core/— WebSocket transport, protocol encoding, and message dispatcholymptrade_ws/api/— balance, market, and trade API wrappersolymptrade_ws/main.py— safe interactive console entry pointsimple_bot.py— read-only candle exampleNOTE.md— local operating principles and project identity
This project is not affiliated with or endorsed by OlympTrade. It uses an undocumented/reverse-engineered protocol that may break at any time. No strategy or example guarantees a profit. Real-money orders should only be added deliberately and tested in demo mode first.