Skip to main content

Fraud Detection With Graph Databases: How-To for 2026

Use Didit transaction and device signals to model a fraud graph, test a structuring rule, and trace accounts that share a device. Includes API examples and published prices.

Fraud Detection With Graph Databases: How-To for 2026

Contents

In this guide

Jump to the part you need.

This guide is for fraud and AML teams that need relationship-level detection, not just single-transaction rules. We show how to produce linked-entity signals with Didit and model them as a graph you query. Prices: transaction monitoring $0.001 per transaction beyond your plan allowance, device and IP analysis $0.03 per check, separate customer AML screening $0.20. Caveat: we do not ship a graph database. We return identifiers, rule results and device signals to model as nodes and edges.

Last updated: November 26, 2026. Prices checked against the live Didit price feed on November 26, 2026.

What graph-based fraud detection needs, and where it comes from in Didit
What you needDidit mechanismPublished priceReference
A key that survives sessionsvendor_data on the subject and optional counterparty, linked to an existing user or business profileIncluded with transaction monitoringSubmit Transactions API
Velocity and structuring rulesRule engine with windows, ratios and sequences$0.001 per transaction beyond the monthly allowanceTransaction Monitoring overview
Shared device and shared IPDevice and IP Analysis, returned in ip_analyses[]$0.03 per checkDevice and IP overview
Counterparty screening inside transaction monitoringAML screening on counterparties and linked usersSeparate transaction AML screening line. See Didit pricing.Transaction Monitoring overview
Wallet relationship graphCounterparty connections and an interactive network graph in the console for cryptoWallet screening $0.15 per screeningTransaction Monitoring overview
Storing nodes and edges for your own traversalsYour graph database, populated from Didit API resultsYour own costNot a Didit product

Start free in the sandbox at https://business.didit.me/, no sales call. The product is on the Didit Transaction Monitoring page. The integration details are in the Transaction Monitoring overview, with the setup steps in the Transaction Monitoring quickstart and the payload reference in the Submit Transactions API. Every price is on Didit pricing, and developers who want an AI assistant to drive the API can connect it through Didit MCP.

What a fraud detection graph database is for

A graph database stores entities as nodes and relationships as edges. A traversal follows one or more edges, such as account to device to another account. In fraud work the nodes are people, companies, devices, IP addresses, phone numbers, email addresses, bank accounts, wallets and documents. The edges are the facts that connect them: signed up from, paid, received from, officer of, shares a device with.

For example, an analyst uses pathfinding to show how two accounts are connected. Betweenness centrality identifies nodes that lie on many shortest paths. Community detection groups nodes that cluster together and gives you leads for investigation, not proof. Pattern matching looks for a known typology such as fan-out, fan-in or a circular flow.

Start with stable identifiers. For users and businesses, vendor_data is the identifier you attach to the subject and optional counterparty. When it matches an existing user or business record, we link the transaction to that profile, which enables cross-session rule evaluation and velocity checks. Next, use evidence that links records to the same entity: device fingerprint, IP address, wallet address, phone, email, document number. Then analyze the linked records over time windows.

Academy lesson cover showing a live transaction feed and a risk score built from rules
The rule engine that scores each transaction against every active rule, which is where the velocity signals for your graph come from.

Where graph analysis fits anti-money laundering work

The anti-money laundering questions that graph analysis answers are concrete: which five accounts share a device and a payout destination identifier, whether there is a path between a screened counterparty and the applicant, and which customers sent funds to the same cluster of addresses in the last 30 days. Look for repeated transfers below a configured threshold and review the pattern for possible structuring. The €10,000 figure in this walkthrough is a test condition for the preset.

We can evaluate transaction velocity and structuring with rules. The event-rule builder also supports ratios and ordered sequences. Use the graph to trace shared-device and payout relationships or to find indirect connections to a screened counterparty. A velocity window catches cumulative volume and count, for example more than $10,000 in 24 hours. A ratio rule compares two reducers over the same window: deposit 1,000 and wager 20 gives a wager-to-deposit ratio of 0.02. A sequence rule is an ordered list of predicates inside a window, which is how a failed-login burst, an MFA change, a withdrawal address change and a withdrawal request get caught as one pattern rather than four unrelated events.

For a general AML graph database the structure looks the same whatever vendor you use: customers, accounts, instruments, devices, counterparties and addresses as nodes; transfers, logins, ownership and shared attributes as edges. The scenarios above are illustrative. When you evaluate a vendor, run two checks: whether the API returns stable IDs for each entity, and whether each relationship carries a timestamp and a source record. We return vendor_data on parties and return both parties in a parties array with roles APPLICANT and COUNTERPARTY when a counterparty is supplied.

Use the graph to follow links between accounts, devices and counterparties. Event rules can also correlate records by device fingerprint within a configured window. Device and IP analysis checks whether the current session matches previous sessions from another vendor_data across duplicated IP, exact device fingerprint and recovered device. AML screening runs on counterparties. For crypto investigations, the console also shows an interactive wallet network graph. Build your own traversals from the documented transaction and verification fields.

For all four cases, set transaction_details.currency_kind to crypto. Screening follows the application setting unless you override it with the top-level include_crypto_screening field. Use true to force screening or false to skip it.

Which wallet field to send for crypto screening
TimingDirectionWallet fieldWhat you send
Before a transfer, no hash yetInboundcounterparty.payment_method.account_idSender wallet, with currency_kind set to crypto
Before a transfer, no hash yetOutboundcounterparty.payment_method.account_idDestination wallet, with currency_kind set to crypto
After a transfer, hash existsInboundtransaction_details.payment_reference_id plus subject.payment_method.account_idBlockchain hash plus your service deposit address
After a transfer, hash existsOutboundtransaction_details.payment_reference_id plus counterparty.payment_method.account_idBlockchain hash plus destination wallet
Session overview screen in the Didit Business Console listing the warnings raised for one verification
A session overview with its warnings. Device and IP warnings arrive in the LOCATION bucket, including duplicate device and duplicate IP matches.

Worked example: two accounts, one shared device

Use two synthetic subjects with separate stable IDs and one shared device ID. Account A has vendor_data user-a-1001. Account B has vendor_data user-b-2002. For the synthetic transaction example, use the submitted party-level device_context.fingerprint, dev-shared-9f2c, on both transactions. Join the transaction record to the hosted verification record by vendor_data. For the payout check, send two outbound transfers from distinct subject IDs with the same counterparty.payment_method.account_id, acct-shared-777. Call that a shared payout destination identifier.

Plain-language traversal: user-a-1001 to dev-shared-9f2c to user-b-2002 returns the two vendor_data values. The path uses two edges and one shared device node. If you also model the shared payout destination identifier, user-a-1001 to acct-shared-777 to user-b-2002 is a second path. The transaction path shows that both subjects submitted the same fingerprint value. Check the hosted verification results separately for evidence of device reuse. The shared payout destination match adds a second shared identifier. Neither proves common ownership. Together they justify review, not automatic blocklisting.

Path one uses the submitted transaction record as the source for the device edge: user-a-1001 to dev-shared-9f2c to user-b-2002. Path two uses the submitted outbound transfer records as the source for the shared payout destination edge: user-a-1001 to acct-shared-777 to user-b-2002. For time-window analysis, use the time the transfer occurred from your source transaction record. For hosted device evidence, use the time of the verification session. Keep the source time with each relationship.

Field map for the worked example
Node or edgeStable identifierSource recordEvent time
Account nodevendor_dataTransaction record: subject.vendor_data or counterparty.vendor_dataUnderlying transaction event time
Device nodedevice_context.fingerprintSubmitted transaction party: device_context.fingerprintUnderlying transaction event time
Hosted duplicate-device evidenceFingerprint ID and duplicate-device matches in ip_analyses[]Hosted verification decision from ip_analyses[], joined by vendor_dataUnderlying session event time
Transaction nodetransaction_idSubmitted transaction recordUnderlying transaction event time
Submitted-device edgedevice_context.fingerprintSubmitted transaction party: device_context.fingerprintUnderlying transaction event time
Shared payout destination edgecounterparty.payment_method.account_idSubmitted outbound transfer recordUnderlying transaction event time

Prerequisites

  • A Didit application with Transaction Monitoring enabled, under Settings, Transaction Monitoring, Enable.
  • An API key for that application.
  • A webhook endpoint reachable from the internet if you want real-time events.
  • For crypto screening, currency_kind set to crypto and the wallet address in account_id on the relevant payment method.
  • Optional: your own graph database. We do not provide one, so Cypher or Gremlin queries run on your side.

How to run graph-based fraud detection with Didit, step by step

  1. Enable transaction monitoring and keep the API key server side. Open Settings, Transaction Monitoring, Enable. Every call that follows uses the x-api-key header.

  2. Submit one baseline transaction. This is the quickstart call, unchanged. Use a stable synthetic vendor_data in the sandbox, because that value is the node key your graph will join on. A rerun needs fresh transaction IDs and a fresh subject to avoid carrying prior submissions into the test window.

    curl -X POST https://verification.didit.me/v3/transactions/ \
      -H "x-api-key: YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
        "transaction_id": "baseline-0001",
        "transaction_category": "finance",
        "transaction_details": {
          "direction": "outbound",
          "amount": "500.00",
          "currency": "EUR"
        },
        "subject": { "entity_type": "person", "vendor_data": "user-42", "full_name": "Jane Doe" },
        "counterparty": { "entity_type": "company", "full_name": "Acme Supplier" }
      }'
  3. Read the fields that become nodes and edges. The response returns status (APPROVED means the transaction was approved; inspect rule_runs to see which rules evaluated it and whether any matched. IN_REVIEW, DECLINED and AWAITING_USER are the other statuses), score as an integer from 0 to 100 and above, and rule_runs, an array of every rule that evaluated the transaction. Store the transaction ID for the transaction node, a stable vendor_data for each known party, and use the counterparty name as a display label only. The parties array returns the subject as APPLICANT and, when you sent one, the counterparty as COUNTERPARTY.

  4. Enable one preset rule. In the Business Console go to Transactions, Rules, Library and enable Structuring (outbound). It triggers when the same user sends 20 or more outbound transfers under EUR 10,000 within 30 days. One rule per run keeps the expected output easy to read.

  5. Submit a burst that fires the rule. Use a fresh synthetic subject with no qualifying transaction history. Keep the same subject across all 20 submissions, each under EUR 10,000, with a distinct counterparty each time. This is the documented loop from the quickstart.

    for i in $(seq 1 20); do
      curl -X POST https://verification.didit.me/v3/transactions/ \
      -H "x-api-key: YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d "{
        \"transaction_id\": \"struct-$i\",
        \"transaction_category\": \"finance\",
        \"transaction_details\": {
          \"direction\": \"outbound\",
          \"amount\": \"9500.00\",
          \"currency\": \"EUR\"
        },
        \"subject\": { \"entity_type\": \"person\", \"vendor_data\": \"user-77-structuring\", \"full_name\": \"Sam Synthetic\" },
        \"counterparty\": { \"entity_type\": \"company\", \"full_name\": \"Shell Co $i\" }
      }"
    done

    This fresh subject has no qualifying transaction history. The expected IN_REVIEW assumes the documented preset and no other matching rule that changes the outcome.

  6. Subscribe a webhook endpoint and verify signatures. Register the destination once. The endpoint receives the events listed in subscribed_events. The example subscribes to transaction.created and transaction.status.updated. Save the returned secret_shared_key immediately, then verify the X-Signature-V2 HMAC on every incoming webhook before you trust it: recompute HMAC-SHA256 over the canonicalised body, compare in constant time, reject stale timestamps.

    curl -X POST https://verification.didit.me/v3/webhook/destinations/ \
      -H "x-api-key: YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
        "label": "TM events",
        "url": "https://yourapp.com/webhooks/didit-tm",
        "subscribed_events": ["transaction.created", "transaction.status.updated"]
      }'

    After registration, submit a fresh sandbox transaction with a new transaction ID and confirm that a signed transaction.created event arrives.

  7. Create a hosted verification session for the device and IP signals. Use the same vendor_data values from the worked example. The session is where the SDK collects the device fingerprint and IP in the hosted flow.

    curl -X POST 'https://verification.didit.me/v3/session/' \
    -H 'x-api-key: YOUR_API_KEY' \
    -H 'Content-Type: application/json' \
    -d '{
    "workflow_id": "YOUR_WORKFLOW_ID",
    "vendor_data": "user-a-1001",
    "callback": "https://yourapp.com/post-kyc"
    }'

    Open the returned session.url and complete the hosted flow. Complete both hosted sessions in the same browser on the same device, with browser storage intact and a different vendor_data for each session. Inspect the second session's ip_analyses[] for a duplicate-device match. If the result is empty or contains no match, record that outcome and check collection before proceeding.

  8. Read ip_analyses[] from the decision. Call GET /v3/session/{sessionId}/decision/ for each session. Each entry in ip_analyses[] carries resolved geography, ASN, VPN, proxy and Tor flags, the device fingerprint id, duplicate-device matches and a warnings array. If the array is empty, no device and IP analysis result is present. A content blocker can prevent collection.

  9. Review a shared-device match. Compare the two profiles and their source records. Two accounts can legitimately share a device. Require independent evidence before merging accounts or blocklisting a device. A system blocklist entry automatically declines future matching checks where that list applies. If two outbound transfers from distinct subject IDs share the same counterparty.payment_method.account_id, treat that as a shared payout destination identifier and review the payout history.

  10. If independent evidence confirms abuse, add the device to the system blocklist and fetch the transaction for the case file. Add the value to the matching system blocklist through POST /v3/lists/{list_uuid}/entries/, either passing the value directly or passing reference_session_id so Didit extracts the right value and links the entry back to the session. Then fetch the transaction to attach the evidence.

    curl https://verification.didit.me/v3/transactions/{transaction_id}/ \
      -H "x-api-key: YOUR_API_KEY"

    The response returns score, matched rules, party enrichment and AML screening.

Expected output

What you send, what comes back and how to read it
StepYou sendYou get backHow to read it
2One transaction with subject vendor_data, amount, currency, directionBaseline status, score, rule_runsAPPROVED means the transaction was approved. Inspect rule_runs to see which rules evaluated it and whether any matched. For this control, use an isolated sandbox test with no other active rules affecting the result.
5Twenty transactions, same fresh subject, distinct counterpartiesIN_REVIEW with the structuring delta appliedMatching rules contribute to the score. The cumulative score and highest-severity match help determine status.
6Webhook URL and subscribed_eventssecret_shared_key, then a signed transaction.created for a new transactionThe endpoint receives the events listed in subscribed_events.
8Session id for each subjectip_analyses[] with fingerprint, duplicates and warningsDuplicate device and duplicate IP matches feed entity resolution.
9Two profiles and their source recordsA shared-device path with two vendor_data valuesDevice reuse alone does not prove common ownership.
10List entry, then transaction idA blocklist entry and the full transaction recordThe response returns score, matched rules, party enrichment and AML screening.

Failure cases and recovery

Known failure modes from the documentation and what to do
FailureWhy it happensRecovery
ip_analyses[] is emptyNo device and IP analysis result is present. A content blocker can prevent collection.Decide in advance whether that fails closed or falls back to softer signals, and apply the same policy every time
VPN_DETECTED, PROXY_DETECTED, TOR_DETECTEDConnection is maskedRoute by your own fraud policy: decline, manual review or an extra liveness step
DUPLICATED_DEVICESame device previously enrolled under a different vendor_dataReview a shared-device match. Two accounts can legitimately share a device. Require independent evidence before merging accounts or blocklisting a device.
LOCATION_MISMATCH_WITH_DOCUMENTIP country does not match the document issuing countrySend to review, not to automatic decline
An aggregation never matchesA "__current__" filter with no value on the record being evaluated, or a ratio with no denominatorExpected behaviour: records without the grouped value are never grouped together, and no deposits is no evidence rather than a ratio of zero
Lists API add entry 400Invalid value, duplicate entry, or referenced session missing data for this entry type.Validate the value, check for an existing entry, and confirm that any referenced session contains data for the selected entry type.
Lists API 401Key is invalid, revoked or expiredCheck whether the key is invalid, revoked or expired
Lists API 403Header or permissions problemCheck the x-api-key header and permissions
Lists API 404The list is not foundConfirm the list exists in the same application
Status AWAITING_USERA rule requires more verification from the userWe create a linked remediation session and return a verification URL, so the flow continues inside the transaction workspace

Sandbox testing is free. In production, the costs below depend on which checks you run and your plan's transaction allowance.

Transaction monitoring is $0.001 per transaction beyond your monthly allowance, which is 1,000 on Free, 10,000 on Growth and 100,000 on Scale, with the allowance resetting on the 1st of each month. Device and IP analysis is $0.03 per check and, inside a verification session, is part of the full ID check at $0.33. A separate customer AML screening check is $0.20 per check. Wallet screening is $0.15 per screening, or you can bring your own screening provider and run it inside Didit.

Conditions in your rules send a transaction to review or trigger an automatic action. We do not decide your risk appetite for you: soft signals such as a VPN, a duplicated IP or a location mismatch only act the way your rules and policies say they act. We surface shared-device matches for review. Your team decides whether to add a device to the system blocklist. Once listed, future matching checks can be declined automatically where the list applies. Treat IN_REVIEW as a queue for an analyst, and keep the matched rules and linked parties attached to the case so the decision is auditable later.

Transaction alert review screen in the Didit Business Console with the alert and its context
Alert review in the console. This is the boundary where a human decides, with the score, the matched rules and the linked parties in view.

Worked cost example

Take a mid-size fintech with 2,000 new customers a month, each receiving a full ID check and a separate customer AML screening check at onboarding, and 120,000 monitored transactions a month. The first calculation uses published list prices and the Growth transaction allowance. The second applies Growth's published rates, monthly credit and plan fee.

  • Full ID check: 2,000 x $0.33 = $660.00
  • Onboarding customer AML screening check: 2,000 x $0.20 = $400.00
  • Transactions: 120,000 minus 10,000 included on Growth = 110,000 x $0.001 = $110.00
  • List-price usage with the Growth transaction allowance: $660.00 + $400.00 + $110.00 = $1,170.00

On Growth the same usage is 2,000 x $0.3168 = $633.60 for ID checks, 2,000 x $0.192 = $384.00 for onboarding customer AML screening, and $110.00 for transactions, because the $0.001 transaction price is the same on every plan. That totals $1,127.60. Growth costs $99 a month and adds $115 of credit each month, so $115.00 of that total is covered and you top up $1,012.60 if this is your only usage. Add the $99 plan fee and total monthly spend is $1,111.60, assuming no existing prepaid balance and no other usage.

Sources

Next step: open the sandbox at https://business.didit.me/, submit the baseline transaction from step 2, and confirm the score and rule runs before you connect a graph store. No sales call is required.

Try it

Try this in the sandbox

Run the check this guide describes, free.

ID Verification

The product this post is about, taken from its topic. Run it free in the sandbox.

$0.15 per checkStart free

Author

Alberto Rosas

Co-founder and CEO

Alberto Rosas

Alberto Rosas

Co-founder and CEO

About Didit

Questions

Frequently asked questions

What is a fraud detection graph database?

A graph database stores entities as nodes and relationships as edges. A traversal follows one or more edges, such as account to device to another account, so a query can ask who else is connected to this device, wallet or phone number. Fraud teams use it for fraud rings, mule accounts and money-flow tracing, where the signal is the connection rather than the individual record.

Does Didit provide a graph database?

No. We expose transaction parties and identifiers in the API and duplicate-device evidence in hosted verification decisions. For crypto investigations, the console also shows an interactive wallet network graph. We serve 4,000+ companies and run identity and fraud checks without you operating a graph store; build your own traversals from the documented transaction and verification fields.

How do I use a graph database for anti-money laundering?

Model customers, accounts, devices, wallets and counterparties as nodes and their interactions as edges, then run four query types: velocity and structuring checks over time windows, community detection for mule rings, pathfinding between an applicant and a screened counterparty, and pattern matching for known typologies. In practice the velocity and structuring part usually works better as rules on the transaction stream, and the graph is kept for the connection questions.

What should an AML graph database contain?

At minimum: customers and beneficial owners, accounts and instruments, devices and IP addresses, phone numbers and email addresses, wallet addresses and counterparties. Edges should record transfers, logins, ownership and shared attributes, each with a timestamp and a source record. Without a stable identifier per entity, graph queries return clusters that look connected but are not.

How much does graph-based fraud detection cost with Didit?

Transaction monitoring is $0.001 per transaction beyond your monthly allowance, device and IP analysis is $0.03 per check, a separate customer AML screening check is $0.20 and wallet screening is $0.15 per screening. Free includes $10 in monthly credit for the first organization created with an eligible work email for a company domain, and unused credit expires each month. Growth is $99 a month with 4% off Didit prices, Scale is $299 a month with 10% off, and Enterprise is a custom annual contract. Any graph database you run yourself is a separate cost from your own vendor.

Can I detect fraud rings without a dedicated graph database?

Partly. Duplicate device and duplicate IP matching inside Didit, plus velocity and sequence rules over windows, catch common ring patterns without you storing anything. You need a graph store when the question spans several hops, such as which of these 300 customers are connected through a shared bank account to a counterparty already under review.

How do I link transactions to the same user across sessions?

Send the same vendor_data on the subject party every time. When it matches an existing user or business record, we link the transaction to that profile automatically, which is what enables cross-session rule evaluation and velocity checks. In graph terms, vendor_data is your entity resolution key for users and businesses, so treat changes to it as a breaking change.

Which signals show that two accounts share a device?

During hosted verification, DUPLICATED_DEVICE indicates exact reuse of a persistent device identity associated with a different vendor_data. The device analysis can also report recovered-device matches based on the fingerprint signal vector. Read the warnings under LOCATION and check the duplicate-device matches in ip_analyses[].

What happens when a transaction is flagged IN_REVIEW?

The transaction waits for an analyst, and the console shows the score, the matched rules and the linked parties. You can open an investigation case, link the alert and the transaction, and assign an analyst, and the transaction.status.updated webhook fires when the status changes. If a rule instead needs more from the user, the status is AWAITING_USER and we return a verification URL for the remediation session.

Do I need a webhook endpoint to run this?

No, but without one you have to poll the API for status. With one, the endpoint receives the events you list in subscribed_events, such as transaction.created and transaction.status.updated. If you register an endpoint, verify the X-Signature-V2 HMAC on every request before you act on it.

Compliance built in

Audited, certified and attested.

We hold the certifications and build each country's rules into your flows, so you can launch anywhere without worrying. Security and Compliance center

  • Regulation encoded into your flows

    Tell us what you do and where. Didit lists the rules that apply to you, with sources, and builds the checks each country needs into one workflow.

  • Ready for AMLR

    Every requirement of the new EU anti-money laundering rules, from checking customers to human review, is already covered by a Didit check.

  • Tested in Spain's Treasury sandbox

    Spain's Treasury published its supervised sandbox report on Didit's NFC plus active liveness onboarding; SEPBLAC took part and valued the added measures positively.

  • Audited, not self-declared

    iBeta Level 1 and Level 2. Liveness tested under ISO/IEC 30107-3.

Compliance assistant

Your obligations · 3 regions

EU · AMLRCustomer due diligence, human reviewCovered
Illinois, Texas, ColoradoExplicit biometric consentCovered
Germany · Youth protectionVerified adults only (JMStV)Covered
Workflow checked. Every obligation is met
  • SOC 2 Type 2
  • ISO 27001
  • iBeta Level 1 and Level 2
  • EU regulator attestation
  • FSM youth protection
  • GDPR
  • EBA remote onboarding
  • MiCA compatible
  • FIDO Alliance member
  • AMLREU AML Regulation ready

Integration · Didit MCP

Run Didit from your own AI agent

Connect Didit to Claude, Cursor, VS Code or ChatGPT and just ask in plain words. Your agent can do anything you can do in the console, with the same permissions you have.

Add to ClaudeChatGPT
Didit Academy · Lesson 04 · Use Didit with MCP
  • Build workflowsDescribe the checks you need. The agent creates and publishes the flow.
  • Run investigationsAsk why a session was declined, review cases, search people and companies.
  • Change rulesCreate payment rules, test them on past data and switch them on.
  • Pull reportsAsk for numbers, exports or the audit log.

Verify your first user today.

Start free

Free sandbox. Credit applies to work-email sign-ups.