You are helping me migrate my Polymarket trading bot from CLOB V1 to CLOB V2 ahead of the April 28, 2026 ~11:00 UTC cutover. Before any code changes, do a read-only audit of this repo and report back, in a single response, the following:
1. The primary language(s) used (TypeScript, Python, Go, Rust, etc.) and the package/build files in use (package.json, requirements.txt, pyproject.toml, go.mod, Cargo.toml, etc.).
2. Whether I use the Polymarket SDK or sign orders directly via raw HTTP/EIP-712. Look for imports of `@polymarket/clob-client`, `py-clob-client`, `@polymarket/builder-signing-sdk`, or any custom EIP-712 signing code.
3. Every import site and constructor call for `ClobClient` / equivalents — list file paths and line numbers.
4. Every place where order objects are constructed — look for `feeRateBps`, `nonce`, `taker`, `expiration`, `salt`, `tokenID`, `makerAmount`, `takerAmount`.
5. Every place I reference USDC.e by address or symbol.
6. Every place I read the `POLY_BUILDER_*` env vars or send `POLY_BUILDER_*` HTTP headers.
7. Any hardcoded references to the V1 Exchange contract `0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E` or Neg Risk Exchange `0xC5d563A36AE78145C45a50134d48A1215220f80a`.
8. WebSocket / streaming code paths, if any.
9. The base URL the client points at (e.g. `https://clob.polymarket.com`).
10. Any manual fee-calculation logic (variables like `feeBps`, `FEE_RATE`, formulas resembling `rate * p * (1 - p)`).
Do not edit anything yet. Output a numbered checklist of what needs to change, ordered by file. I'll then walk you through each migration step.
You are helping me migrate my Polymarket trading bot from CLOB V1 to CLOB V2 ahead of the April 28, 2026 ~11:00 UTC cutover. This is a TypeScript / JavaScript codebase. Before any code changes, do a read-only audit and report back, in a single response:
1. Confirm the package manager from the lockfile (npm / yarn / pnpm), and read package.json + tsconfig.json.
2. Every import site for `@polymarket/clob-client` and `@polymarket/builder-signing-sdk`. File paths and line numbers.
3. Every `new ClobClient(...)` constructor call. File, line, full argument signature.
4. Every place where order objects are built — search for `feeRateBps`, `nonce`, `taker`, and the `UserOrder` / `UserMarketOrder` types.
5. Every reference to USDC.e by address or symbol.
6. Every read of `POLY_BUILDER_*` env vars or send of `POLY_BUILDER_*` HTTP headers.
7. Hardcoded V1 contract addresses: `0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E` (CTF) or `0xC5d563A36AE78145C45a50134d48A1215220f80a` (NegRisk).
8. WebSocket / streaming code paths.
9. The base URL the client points at.
10. Any manual fee-calculation logic (`feeBps`, `FEE_RATE`, formulas like `rate * p * (1 - p)`).
Don't edit anything yet. Output a numbered checklist of what needs to change, ordered by file.
You are helping me migrate my Polymarket trading bot from CLOB V1 to CLOB V2 ahead of the April 28, 2026 ~11:00 UTC cutover. This is a Python codebase. Before any code changes, do a read-only audit and report back, in a single response:
1. Confirm dependency tool in use (pip + requirements.txt, poetry + pyproject.toml, pipenv + Pipfile) and the Python version. Note env tool (venv / poetry / pipenv / conda).
2. Every `from py_clob_client...` import site. File paths and line numbers.
3. Every `ClobClient(...)` instantiation. File, line, full argument signature.
4. Every place where order objects are built — search for `fee_rate_bps`, `nonce`, `taker`, and `OrderArgs` / `MarketOrderArgs` (or equivalent dataclasses).
5. Every reference to USDC.e by address or symbol.
6. Every read of `POLY_BUILDER_*` env vars or send of `POLY_BUILDER_*` HTTP headers.
7. Hardcoded V1 contract addresses: `0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E` (CTF) or `0xC5d563A36AE78145C45a50134d48A1215220f80a` (NegRisk).
8. WebSocket / streaming code (look for `websockets`, `websocket-client`, `aiohttp.ClientSession.ws_connect`).
9. The base URL the client points at.
10. Any manual fee-calculation logic.
Don't edit anything yet. Output a numbered checklist of what needs to change, ordered by file.
You are helping me migrate my Polymarket trading bot from CLOB V1 to CLOB V2 ahead of the April 28, 2026 ~11:00 UTC cutover. This bot does NOT use the official Polymarket SDK — it signs orders directly via EIP-712 and posts them over raw HTTP. Before any code changes, do a read-only audit and report back, in a single response:
1. The primary language(s) and signing library in use (e.g. ethers.js, eth_account, go-ethereum, ethers-rs, ethereumjs-util, web3j).
2. Every place that constructs the EIP-712 typed-data domain — search for "Polymarket CTF Exchange", `verifyingContract`, `chainId: 137`, `version: "1"`.
3. Every place that defines or encodes the Order EIP-712 type / struct definition.
4. Every place that builds an order payload — search for `feeRateBps`, `nonce`, `taker`, `salt`, `tokenId`, `makerAmount`, `takerAmount`.
5. Every place that constructs the POST /order request body and the auth headers.
6. Every `POLY_BUILDER_*` env var read or HTTP header sent.
7. Hardcoded V1 contract addresses: `0x4bFb41d5B3570DeFd03C39a9A4D8dE6Bd8B8982E` (CTF) or `0xC5d563A36AE78145C45a50134d48A1215220f80a` (NegRisk).
8. Every reference to USDC.e by address or symbol.
9. WebSocket / streaming code paths.
10. The base URL the client points at.
Don't edit anything yet. Output a numbered checklist of what needs to change, ordered by file.