Skip to main content

Batch Screening

Screen multiple entities in a single request (up to 100).

Endpoint: POST /v1/screen/batch


Request​

Headers​

HeaderRequiredDescription
x-api-keyYesYour API key
Content-TypeYesapplication/json

Request Body​

FieldTypeRequiredDescription
entitiesarrayYesArray of entity objects (max 100)
optionsobjectNoScreening options for all entities

Entity Object​

FieldTypeRequiredDescription
namestringYesEntity name to screen
entity_typestringNoEntity type classification
identifiersobjectNoDocument numbers

Options Object​

FieldTypeDefaultDescription
thresholdnumber0.85Confidence threshold
listsarray["ofac_sdn"]Lists to screen against
max_results_per_entitynumber5Max matches per entity

Example Request​

curl -X POST "https://api.sanctionswise.orchestraprime.ai/v1/screen/batch" \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"entities": [
{"name": "Vladimir Putin", "entity_type": "individual"},
{"name": "Bank of Russia", "entity_type": "organization"},
{"name": "Sergey Lavrov", "entity_type": "individual"},
{"name": "John Smith", "entity_type": "individual"},
{"name": "Acme Corporation", "entity_type": "organization"}
],
"options": {
"threshold": 0.60,
"lists": ["ofac_sdn"],
"max_results_per_entity": 3
}
}'

Response​

{
"batch_id": "BATCH-20251210183031-DEBF51ED",
"status": "completed",
"results": [
{
"index": 0,
"query": {"name": "Vladimir Putin", "entity_type": "individual"},
"status": "potential_match",
"match_count": 3,
"matches": [
{
"entity_id": "sw_ofac_sdn_35096",
"matched_name": "VLADIMIR VLADIMIROVICH PUTIN",
"confidence_score": 0.762,
"match_type": "fuzzy"
}
]
},
{
"index": 1,
"query": {"name": "Bank of Russia", "entity_type": "organization"},
"status": "potential_match",
"match_count": 2,
"matches": [...]
},
{
"index": 2,
"query": {"name": "Sergey Lavrov", "entity_type": "individual"},
"status": "potential_match",
"match_count": 1,
"matches": [...]
},
{
"index": 3,
"query": {"name": "John Smith", "entity_type": "individual"},
"status": "clear",
"match_count": 0,
"matches": []
},
{
"index": 4,
"query": {"name": "Acme Corporation", "entity_type": "organization"},
"status": "clear",
"match_count": 0,
"matches": []
}
],
"summary": {
"total": 5,
"clear": 2,
"matches": 0,
"potential_matches": 3
},
"options_used": {
"threshold": 0.60,
"lists_screened": ["ofac_sdn"],
"max_results_per_entity": 3
},
"timestamp": "2025-12-10T18:30:31.000000Z",
"processing_time_ms": 49,
"entities_per_second": 102.04
}

Response Fields​

FieldTypeDescription
batch_idstringUnique identifier for this batch
statusstringcompleted or partial
resultsarrayResults for each entity
summaryobjectAggregate statistics
options_usedobjectOptions applied to all entities
timestampstringISO 8601 timestamp
processing_time_msnumberTotal processing time
entities_per_secondnumberThroughput metric

When to Use Batch Screening​

ScenarioRecommendedRationale
Less than 5 entitiesSingle requestsLower latency per entity
5-100 entitiesBatch requestAmortized setup cost
More than 100 entitiesMultiple batch requestsAPI limit is 100 per batch
Real-time paymentSingle requestImmediate response needed
Daily watchlist checkBatch requestThroughput over latency

Code Examples​

Python - Process Large List​

def screen_large_list(entities, batch_size=100):
"""Screen large entity lists efficiently."""
results = []

for i in range(0, len(entities), batch_size):
batch = entities[i:i + batch_size]

response = requests.post(
f"{BASE_URL}/screen/batch",
headers={"x-api-key": API_KEY, "Content-Type": "application/json"},
json={
"entities": batch,
"options": {"threshold": 0.85, "max_results_per_entity": 3}
}
)

batch_results = response.json()
results.extend(batch_results["results"])

# Log progress
print(f"Processed {min(i + batch_size, len(entities))}/{len(entities)}")

return results

JavaScript - Async Batch Processing​

async function screenBatch(entities, threshold = 0.85) {
const response = await axios.post(
`${BASE_URL}/screen/batch`,
{
entities,
options: { threshold }
},
{
headers: {
'x-api-key': API_KEY,
'Content-Type': 'application/json'
}
}
);
return response.data;
}

// Usage
const entities = [
{ name: 'John Smith', entity_type: 'individual' },
{ name: 'Acme Corp', entity_type: 'organization' }
];
const result = await screenBatch(entities);
console.log(`Clear: ${result.summary.clear}, Flagged: ${result.summary.potential_matches}`);