The VPS fresh install uses `(0, axios_1.default)({ method, url: endpoint, ... })`
instead of a separate `config` variable. Add Format B regex to match this
inline pattern and wrap it in an IIFE that injects the proxy agent.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Rewrite patch-clob-client.cjs to use regex instead of exact string
matching, so it works regardless of code formatting differences
between npm versions (fixes "Could not find request config line" on
fresh VPS install)
- Add multiple fallback patterns (config regex → fallback regex →
axios call injection) with debug output if all fail
- Add Polymarket geoblock API check (polymarket.com/api/geoblock)
for both VPS direct IP and proxy IP at startup
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The proxy patch in node_modules is lost on every fresh npm install.
This postinstall script automatically patches @polymarket/clob-client
http-helpers to inject HttpsProxyAgent for all polymarket.com requests.
Runs automatically after npm install — no manual patching needed on VPS deploy.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>