Trading-GPT/Polymarket-trading-bot — reverse-engineered prompt

Reverse engineered prompt

GitHub

Build me a Node.js trading bot for Polymarket that runs on Polygon and focuses on the recurring BTC 5 minute Up Down markets. I want it to connect to my wallet, handle the Polymarket trading login, watch the live order book, and trade both sides when there is a clear arbitrage opportunity.

It should be configurable from an env file with my private key, proxy wallet, Polygon RPC, spend limits, and safety settings. Please include risk controls so it can stop trading if it spends too much, gets too imbalanced, or the market is close to ending. It should also cancel open orders cleanly, merge matched positions back to USDC when it makes sense, and redeem winning positions after resolution.

I also want an optional copy trading mode where I can enter a target Polymarket wallet and have the bot mirror new buys with caps, price checks, and slippage limits. Add clear console and file logs so I can see what it is doing. Look up current Polymarket docs if needed.

Want more depth? Deep Reverse