Build a sanctions screening API workflow with GLEIF and four official lists
A sanctions screening API usually has two jobs: identify the legal entity you mean, then compare it with the relevant watchlists. A plain string search does neither reliably. Company names vary across jurisdictions, transliterations, suffixes, and corporate records. This tutorial uses a published Apify Actor that resolves names or Legal Entity Identifiers through GLEIF, then checks the resolved legal names against the US OFAC SDN, EU Consolidated, UN Consolidated, and UK FCDO lists. What the workflow returns For each resolved entity, the Actor returns fields including: lei and legalName from GLEIF registration jurisdiction, entityStatus, and leiStatus sanctionsHit, hitCount, and hitList per-hit list, matchedName, and similarity score checkedLists, so downstream logic can see which sources were attempted This is a first-pass filter, not a certified sanctions-screening system. A compliance professional should review potential matches before any adverse decision. 1. Start a sanctions screening run Create an Apify API token, then start a run with the Actor endpoint: curl -X POST \ "https://api.apify.com/v2/acts/gp005~gleif-sanctions-screener/runs?token=$APIFY_TOKEN" \ -H "Content-Type: application/json" \ -d '{ "names": ["Gazprom", "Sberbank"], "sanctionsLists": ["OFAC", "EU", "UN", "UK"], "fuzzyThreshold": 0.7, "gleifEnrich": true, "maxResultsPerEntity": 2 }' The body is the Actor input. Do not wrap it in an input object. Run options such as a specific build belong in query parameters. You can also supply an entities JSON array containing names, LEIs, or objects such as {"name":"Example Ltd","country":"GB"}. A direct 20-character LEI avoids ambiguity in name search. 2. Poll the run and read its dataset The start response contains a run ID. Poll the run until it reaches a terminal status: curl \ "https://api.apify.com/v2/actor-runs/$RUN_ID?token=$APIFY_TOKEN" After a successful run, fetch clean dataset items: curl \ "https://api.apify.com/v2/actor-runs/$RUN_ID/dataset/items?token=$APIFY_TOKEN&clean=true" A measured run on September 30, 2026 used two input names, allowed up to two GLEIF records per name, checked all four lists, and returned four records. One record was: { "inputName": "Gazprom", "lei": "529900CN8RY2Z01K0V60", "legalName": "Gazprom Austria GmbH", "jurisdiction": "AT", "entityStatus": "ACTIVE", "leiStatus": "LAPSED", "gleifStatus": "found", "sanctionsHit": false, "hitCount": 0, "hitList": [], "hits": [], "checkedLists": ["OFAC", "EU", "UN", "UK"] } That is measured output, not a claim that every similarly named entity is clear. The legal entity selected by GLEIF matters, and list data changes. 3. Tune fuzzy matching without automating decisions fuzzyThreshold accepts values from 0 to 1 and defaults to 0.7. Lower values increase recall and false positives. Higher values reduce noise but can miss aliases or transliteration variants. A safe integration pattern is: Treat sanctionsHit: false as one input to review, not universal clearance. Queue every positive hit for human assessment. Display the matched name, source list, and score to the reviewer. Preserve the input, resolved LEI, checked-list set, and run timestamp for auditability. Test representative names before changing thresholds. Do not turn a similarity score into an automatic rejection rule without legal and compliance review. 4. Use the billing events accurately The current free-tier catalog is $0.01 per Actor start plus $0.05 per emitted entity-screened event. Because a name can resolve to multiple GLEIF records, the number of charged screening events can exceed the number of input names. For example, the measured two-name run emitted four records, so the free-tier event formula is: $0.01 + (4 x $0.05) = $0.21 Apify compute usage is separate from Actor event charges. Use Apify's run budgets and limits to control spend; the Actor's maxTotalChargeUsd field is reserved and should not be treated as an enforced hard cap. 5. Connect it to an application Useful integration patterns include: Run during KYB onboarding, then route possible matches into a review queue. Schedule portfolio rescreening because official lists change. Send completed-run webhooks to a case-management service. Export JSON, CSV, or Excel from the Apify dataset. Trigger the Actor from Make, n8n, or the Apify API. Keep source availability visible. The Actor logs how many names it loads from each requested source; operational monitoring should alert if a list unexpectedly loads zero entries. FAQ What is OFAC sanctions screening? OFAC sanctions screening compares a person or organization with lists maintained by the US Treasury's Office of Foreign Assets Control, including the SDN list. This workflow adds EU, UN, and UK sources, but a returned match still requires human review in context. Can I screen by LEI instead of company name? Yes. Supply a 20-character LEI in leis or in an entities object. Direct LEI lookup is more deterministic than name search because it identifies a specific GLEIF record before sanctions names are compared. Does a clean result prove an entity is not sanctioned? No. A clean result means this run found no fuzzy-name match for the resolved records against the successfully loaded requested lists at that threshold. Entity resolution, source availability, aliases, ownership rules, and legal interpretation can all require additional checks. Where is the Actor? The published Actor and input documentation are at https://apify.com/gp005/gleif-sanctions-screener
This is a summary aggregated from Dev.to. Read the complete article on the original site:
Read full article at Dev.to