When creating a PaymentIntent, attach relevant metadata fields that encode business-context signals: merchant category, customer account age, order risk tier, and whether the item is a digital good.
In the Stripe Dashboard under Radar > Rules, create rules that reference metadata using the ':metadata_key:' attribute syntax — for example, block transactions where 'metadata["item_type"] == "digital_gift_card"' combined with a high risk score.
Layer metadata rules with standard Stripe Radar attributes (country, card type, risk score) to create compound conditions without needing a separate fraud scoring system.
Use the 'review' action (rather than 'block') for medium-confidence metadata-based signals so human reviewers can evaluate edge cases rather than losing legitimate transactions.
Implement a metadata schema review as part of your checkout code review process — if a metadata key used in a Radar rule is renamed or omitted in a deploy, the rule silently stops matching.
Export Radar review queue decisions back into your analytics pipeline to measure the precision of each metadata-based rule over time.
Known gotchas
Metadata values in Radar rules are compared as strings — numeric comparisons require careful type handling; '10' > '9' is false in string comparison, so use numeric Radar attributes rather than metadata for amount-based thresholds.
Radar custom rules are evaluated on Stripe's infrastructure at authorization time; metadata must be present on the PaymentIntent before confirmation, not added afterward.
A/B testing Radar rules requires careful experiment design since blocking or reviewing payments is not easily reversible — use shadow mode to measure rule impact before promotion.
Give your agent this knowledge — and 200+ more routes
One MCP install gives any agent live access to the full route map, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp