fraud-and-risk-basics
Skill1 starsChanged 18 days agoMITView on GitHub
Hold or review risky payments using provider signals, velocity, and 3-D Secure without storing card numbers. Use when adding payment risk checks, a manual review queue, or decline handling for card abuse.
In this repository28 other files it gives its agents.
- b2b-pricingSkill
- catalog-import-and-migrationSkill
- checkout-ux-and-conversionSkill
- conversion-event-trackingSkill
- ecommerce-seo-structured-dataSkill
- google-merchant-product-feedsSkill
- headless-nextjs-storefrontSkill
- inventory-and-multi-warehouseSkill
- iranian-payment-gatewaysSkill
- marketplace-search-and-rankingSkill
- mcp-store-toolingSkill
- multi-vendor-payoutsSkill
- order-and-webhook-reliabilitySkill
- payment-gateway-integrationSkill
- product-catalog-modelingSkill
- product-description-guardrailsSkill
- returns-and-refundsSkill
- rtl-and-persian-localizationSkill
- shopify-app-developmentSkill
- storefront-accessibilitySkill
- storefront-performanceSkill
- stripe-paymentsSkill
- subscription-billingSkill
- tax-and-shippingSkill
- vector-product-searchSkill
- woocommerce-plugin-developmentSkill
- woocommerce-rest-apiSkill
- wordpress-plugin-securitySkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 4 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 12
Use this skill to decide whether a confirmed payment attempt should capture, wait for review, or be declined.
- Distinctive: line 17
Start from the provider's risk recommendation.
- Distinctive: line 18
Add only signals you can explain: velocity, address mismatch, and a mismatch between the paid amount and the order.
- Distinctive: line 41
Do not put the full card number into the velocity key.
≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Fraud and risk basics
Use this skill to decide whether a confirmed payment attempt should capture, wait for review, or be declined. The payment skill still verifies the provider. This skill does not collect card numbers and it does not describe how to test stolen cards.
Procedure
- Let the payment provider collect the card. You store the provider payment id, AVS result, CVV result, and 3-D Secure result. You do not store PAN or CVV.
- Start from the provider's risk recommendation. Do not replace it with a score you computed from a single field.
- Add only signals you can explain: velocity, address mismatch, and a mismatch between the paid amount and the order.
- Map the outcome to one action: capture, authorize and review, or do not capture.
- A review queue shows the order id, amount, currency, and the signals. A person captures or voids. The queue does not auto-capture because it sat overnight.
Worked examples and checks are in evals/tasks.json.
Actions
| Situation | Action |
| Provider says the payment is acceptable and no local rule fired | Capture, or accept the provider's capture, through the payment skill. |
| Provider asks for step-up authentication | Send the shopper through 3-D Secure. Do not capture before it finishes. |
| AVS or CVV is a mismatch and the amount is above the store's review threshold | Authorize if the provider allows it, and queue for review. Do not capture yet. |
| Velocity rule fires | Same review path. Do not silently decline every later order from that customer without a reason you store. |
| Amount, currency, or order id does not match | Do not capture. Follow the payment skill's mismatch rule. |
| Provider declines | Leave the order unpaid. Keep the cart. Do not retry the charge in a loop. |
AVS and CVV are signals. A match is not proof the shopper is the cardholder. A mismatch is not proof of fraud. International addresses often fail AVS. Do not decline every AVS mismatch unless the store has chosen that policy.
Velocity
Count paid and attempted orders by the identifiers you are allowed to store: account id, shipping address hash, and provider customer id. A default worth configuring is more than three payment attempts from one account in ten minutes, or more than two shipping addresses used by one account in one hour. Tune the numbers. Do not present them as measured fraud rates.
Do not put the full card number into the velocity key.
Review queue
- Store order id, amount, currency, provider payment id, the signals that fired, and the decision.
- Capture and void go through the payment provider, idempotently.
- The reviewer's user id is stored with the decision.
- A shopper-facing page says the payment is being reviewed. It does not say the order shipped.
Gotchas
- Capturing before 3-D Secure returns loses the liability shift the provider offered. Wait for the result.
- A client-supplied
risk: lowfield is not a signal. Ignore it. - Logging the full webhook body can store a PAN the provider included by mistake. Log ids and result codes.
- Declining the renewal of every international card will cancel good subscriptions. Use the review path for subscriptions instead of an immediate cancel, unless the store has a written policy.
Verification
- A mismatched amount is not captured.
- A 3-D Secure challenge does not capture before the provider reports success.
- The database and logs for a test payment contain no PAN and no CVV.
- Two clicks in the review queue do not capture twice.
Evaluation
Worked examples and the checks they must satisfy are in evals/tasks.json.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

