Inspiration - There is so much demand to passively trade Polymarket but its too difficult to actually create the bots even if you have a technical background.
What it does - Allows non-dev users to create and deploy real trading bots with a couple clicks. The bots are prompted by Tradingview webhooks allowing customizable strategies.
How we built it - We built BotMarket as a full-stack TypeScript monorepo.
FRONTEND: We used Next.js 14 with the App Router for a modern React experience. RainbowKit and wagmi v2 handle wallet connections to Base Mainnet. TailwindCSS powers the dark-themed UI with real-time balance updates and bot management.
BACKEND: Express.js serves our REST API with endpoints for bot CRUD, webhook processing, and CCTP bridging. PostgreSQL (via Prisma ORM) stores bots, users, orders, and bridge transactions. Redis + BullMQ handle async job processing for trade signals and bridge attestation polling.
SMART CONTRACTS: We wrote BotRegistry.sol in Solidity and deployed to Base Mainnet using Foundry. The contract handles bot creation, forking with lineage tracking, and visibility controls. Gas costs are minimal (~$0.01 per registration) thanks to Base's L2 efficiency.
CCTP INTEGRATION: We integrated Circle's Cross-Chain Transfer Protocol to bridge USDC from Base to Polygon. The flow: user deposits on Base → platform burns via TokenMessenger → polls Circle's attestation API → mints on Polygon via MessageTransmitter. This gives users native USDC on Polygon for Polymarket trading.
TRADINGVIEW WEBHOOKS: Each bot gets a unique webhook URL. TradingView alerts POST signals (LONG/SHORT/CLOSE) which our API validates, queues via BullMQ, and processes through the trade worker for Polymarket order execution.
PROXY WALLET SYSTEM: We generate dedicated Polygon wallets for each user, encrypted and stored in our database, enabling secure Polymarket trading without users managing multiple chains.
Challenges we ran into - The circle bridge takes a long time to transfer the funds which really delayed our testing.
Accomplishments that we're proud of - We're happy we actually made it mainnet rather than just staying on testnet.
What we learned - We need to leave more time to record and submit at the end
What's next for BotMarket - We want to add support for all markets eventually and allow people to build bots with ai reasoning for trading. We also want to make much better documentation on how to actually create the tradingview alerts to make it as easy as possible for everyone.
Built With
- batchfile
- solidity
- typescript
Log in or sign up for Devpost to join the conversation.