Where the gate belongs
The gate should run after token identity is known but before funds are committed. That gives it the exact contract address while still allowing a hard stop with no trade side effect.
Keep the gate separate from alpha or price logic. Security screening answers whether execution should proceed under safety policy, not whether the trade is expected to be profitable.
Recommended control flow
Reject malformed addresses, wrong-chain assets, non-200 API responses, and invalid schemas. Stop on BLOCK. Send WARN to additional policy checks or human review. Let PASS continue only if slippage, position-size, price, and other trading rules also pass.
Cache cautiously. Token permissions and market conditions can change, so an old verdict should not be treated as durable authorization.
Auditability
Store the token address, decision, key evidence fields, source status, and observation time with the bot's decision log. If a permanent Jepeta evidence page exists, store its canonical URL as an external verification reference.
Do not copy paid-only evidence into public logs unless your own data policy explicitly allows it.
Practical checklist
- Gate before signing
- Exact contract only
- Schema validation
- Fail closed
- Separate risk from alpha
- Persist timestamped decision evidence