Files
proxmox/forge-verification-proxy
defiQUG b8613905bd
Some checks failed
Deploy to Phoenix / validate (push) Failing after 15s
Deploy to Phoenix / deploy (push) Has been skipped
chore: sync workspace — configs, docs, scripts, CI, pnpm, submodules
- Submodule pins: dbis_core, cross-chain-pmm-lps, mcp-proxmox (local, push may be pending), metamask-integration, smom-dbis-138
- Atomic swap + cross-chain-pmm-lops-publish, deploy-portal workflow, phoenix deploy-targets, routing/aggregator matrices
- Docs, token-lists, forge proxy, phoenix API, runbooks, verify scripts

Made-with: Cursor
2026-04-21 22:01:33 -07:00
..

Forge Verification Proxy

Purpose: Bridges Forge's Etherscan-style verify-contract to Blockscout (Chain 138).

Problem: Forge sends JSON body only; Blockscout's Etherscan API expects module and action in the query string. Direct calls fail with "Params 'module' and 'action' are required parameters".

Solution: This proxy accepts Forge's POST, adds ?module=contract&action=verifysourcecode, forwards to Blockscout, and falls back to Blockscout v2 API if needed.


Usage

Preferred: orchestrated script (starts proxy if needed):

source smom-dbis-138/.env 2>/dev/null
./scripts/verify/run-contract-verification-with-proxy.sh

Manual (proxy + verify):

# 1. Start the proxy (from project root)
BLOCKSCOUT_URL=http://192.168.11.140:4000 node forge-verification-proxy/server.js

# 2. Verify via proxy (script defaults to http://127.0.0.1:3080/)
./scripts/verify-contracts-blockscout.sh

# Or from another host:
BLOCKSCOUT_URL=http://192.168.11.140:4000 node forge-verification-proxy/server.js
# Then: FORGE_VERIFIER_URL="http://192.168.11.140:3080/" ./scripts/verify-contracts-blockscout.sh

Direct Forge:

forge verify-contract <ADDR> <PATH> \
  --chain-id 138 \
  --verifier blockscout \
  --verifier-url "http://<proxy-host>:3080/" \
  --rpc-url "http://192.168.11.211:8545"

Environment

Variable Default Description
PORT 3080 Proxy listen port
BLOCKSCOUT_URL http://192.168.11.140:4000 Blockscout API base URL (IP:port)