⚠ INTERNAL — Operator UX mock · Design preview of V2 development path · demo-wired ≠ production-live · back to dev guide
Polygon · pUSD 10
📓 Developer Guide 📋 Reason Codes 📈 Shadow Mode
JD John Doe · Admin

SignaturePreviewer

sec.signaturepreviewer
Security planned Spec started frozen

Render a plain-English summary of every EIP-712 signature before the wallet shows the modal.

What it does

Render a plain-English summary of every EIP-712 signature before the wallet shows the modal.

Pipeline placement

runs after: Strategy OrderIntent and contract/permission checks SignaturePreviewer runs before: Wallet signing modal is shown to user

Applies to: Every EIP-712 signing request before user confirmation

Why it matters

If this failsConsequence
User signs a phishing or misrouted order without understanding itFunds transferred to an unintended address or contract under user signature.
Domain separator not validated before displayA forged domain could cause a user to unknowingly sign for a different chain or contract.
Strategy deviates from declared envelopeUser signs an order outside the parameters they approved at strategy setup.

Inputs

Polymarket inputs

InputSourceRequiredUse
EIP-712 typed data for pending orderclob_authrequiredDecode and display the full typed data in plain English.
Market metadata (name, outcomes, expiry)gammarequiredResolve token IDs to human-readable market names in the preview.

Internal inputs

InputSourceRequiredUse
Strategy declared envelope (side, size, price range)StrategyConfigrequiredDiff the pending order against the declared envelope; flag deviations.
KillSwitch active flagKillSwitchrequiredBlock signing if kill switch is active.

Authority

What this bot is permitted to do

Reject Pause

State

Readiness

Spec started

Status

planned

Class

Guardrail

Default mode

shadow_only

Developer owner

Polytraders core

Capital impact

Direct

Reason codes emitted

CodeSeverityMeaningAction
KILL_SWITCH_ACTIVEHARD_REJECTGlobal kill switch is active.Immediately return DENY.
CONTRACT_GUARD_DOMAIN_MISMATCHHARD_REJECTEIP-712 domain version is not '2' or verifyingContract is not in V2 allow-list.Return DENY; emit security alert.
SIGNATURE_ENVELOPE_BREACHHARD_REJECTOrder parameters deviate more than 20% from strategy declared envelope.Return DENY; display explanation to user.
SIGNATURE_ENVELOPE_WARNWARNOrder deviates 10–20% from envelope.Display warning in preview; allow user to proceed.
MARKET_UNRESOLVEDINFOGamma API unavailable; market name could not be resolved.Show raw token ID with warning banner.

Used by

Reverse index — strategies that currently reference sec.signaturepreviewer. If you change this bot's authority or reason codes, these strategies must re-pass shadow.

StrategyStateActivity
Fed Rates — surprise driftfrozenlast triggered 37m ago
AI Frontier — release-day takerfrozenlast triggered 44m ago

Showing 2 of 2 · demo-wired ≠ production-live

Why this matters

Security bots does NOT propose or execute trades; only guards signing and wallet operations. Understanding the authority boundary prevents misuse and makes promotion-gate reviews faster and more reliable. View raw spec JSON →
Polytraders Operator UX Mock · INTERNAL · demo-wired ≠ production-live · the plan · reason codes · shadow-mode pipeline
⚙ Page Configuration
Current page settings
Loading configuration…