AccessGate AML API Reference

Real-time sanctions screening and PEP checks for financial institutions. Screen customers against global sanctions lists, detect relationships to sanctioned individuals, and integrate with AI agents for intelligent compliance workflows.

Base URL: https://ag-aml.runloci.com

## Authentication

All API requests require an API key passed in the header:

bash
X-API-Key: your_api_key_here

Keep your API key secure. Do not expose it in client-side code or public repositories.

---

Screening Endpoints

Screen Customer

:::api POST /v1/aml/screen Screen Customer Real-time screening against all sanctions lists with relationship detection.

Headers:

  • X-API-Key (required) — Your API key
  • Content-Type: application/json

Request Body:

  • name (string, required) — Full name to screen
  • dob (string, optional) — Date of birth (YYYY-MM-DD)
  • nationality (string, optional) — ISO 2-letter country code
  • customer_id (string, optional) — Your internal customer ID
  • amount (number, optional) — Transaction amount
  • currency (string, optional) — ISO currency code

Response: 200 OK :::

json
{
  "name": "John Smith",
  "dob": "1985-03-15",
  "nationality": "US",
  "customer_id": "cust_12345",
  "amount": 50000,
  "currency": "USD"
}

Response — No Match:

json
{
  "decision": "CLEAR",
  "audit_id": "aud_7f8a9b2c",
  "match": null,
  "relationship_match": null,
  "processing_time_ms": 32,
  "list_version": "abc123@2026-01-24T03:00:00Z"
}

Response — Direct Match:

json
{
  "decision": "BLOCK",
  "audit_id": "aud_7f8a9b2c",
  "match": {
    "entity_id": "ofac-12345",
    "entity_name": "SANI ABACHA",
    "source": "OFAC",
    "score": 0.97,
    "list_type": "sanctions"
  },
  "processing_time_ms": 35
}

Response — Relationship Match:

json
{
  "decision": "REVIEW",
  "audit_id": "aud_7f8a9b2c",
  "match": null,
  "relationship_match": {
    "related_to": {
      "entity_id": "ofac-12345",
      "entity_name": "SANI ABACHA",
      "source": "OFAC"
    },
    "relationship": {
      "type": "family_member",
      "detail": "child of",
      "confidence": "stated"
    },
    "score": 0.94
  },
  "processing_time_ms": 38
}

Decision Values

Decision Meaning Recommended Action
CLEAR No match found Proceed with transaction
REVIEW Potential match or relationship Manual review required
BLOCK High-confidence sanctions match Block transaction

Batch Screening

:::api POST /v1/aml/screen/batch Batch Screen Screen multiple names in a single request (up to 100).

Headers:

  • X-API-Key (required) — Your API key

Request Body:

  • names (array, required) — Array of names to screen

Response: 200 OK :::

json
{
  "names": [
    "John Smith",
    "Jane Doe",
    "Acme Corporation"
  ]
}

Response:

json
{
  "results": [
    { "name": "John Smith", "decision": "CLEAR", "match": null },
    { "name": "Jane Doe", "decision": "CLEAR", "match": null },
    { "name": "Acme Corporation", "decision": "REVIEW", "match": {...} }
  ],
  "count": 3,
  "processing_time_ms": 145
}

Agent/RAG Endpoints

Agent Lookup

:::api POST /v1/aml/agent/lookup Agent Lookup Retrieve detailed entity information for AI agent consumption. Returns rich context including markdown profiles, relationship graphs, and citations.

Headers:

  • X-API-Key (required) — Your API key

Request Body:

  • query (string, required) — Name to look up
  • include_related (boolean, optional) — Include related entities. Default: true
  • include_reverse_relationships (boolean, optional) — Include entities related TO this person. Default: false
  • format (string, optional) — Response format: markdown or json. Default: markdown
  • max_results (number, optional) — Max related entities (1-20). Default: 10

Response: 200 OK :::

json
{
  "query": "Sani Abacha",
  "include_related": true,
  "include_reverse_relationships": false,
  "format": "markdown",
  "max_results": 10
}

Response — Direct Match:

json
{
  "match": true,
  "direct_match": true,
  "entity_id": "ofac-12345",
  "confidence": 0.97,
  "entity": {
    "id": "ofac-12345",
    "name": "Sani ABACHA",
    "source": "OFAC",
    "list_type": "sanctions"
  },
  "markdown_profile": "# [INDIVIDUAL] Sani ABACHA\n\n**ID:** ofac-12345...",
  "related_entities": [
    {
      "id": "related_1",
      "name": "Mohammed ABACHA",
      "relationship": "child of",
      "relationship_type": "family_member",
      "confidence": "stated",
      "source": "OFAC",
      "direction": "outbound"
    }
  ],
  "relationship_summary": "Sani ABACHA (OFAC): Known family members: Mohammed ABACHA, Abba ABACHA.",
  "relationship_match": null,
  "citations": [
    "OFAC Consolidated List, Entry 12345 (accessed 2026-01-24)"
  ],
  "processing_time_ms": 42
}

Response — Relationship Match:

json
{
  "match": false,
  "direct_match": false,
  "entity_id": null,
  "confidence": null,
  "markdown_profile": null,
  "relationship_match": {
    "query_name": "Amina Abacha",
    "matched_name": "Amina ABACHA",
    "match_score": 0.94,
    "sanctioned_entity": {
      "entity_id": "ofac-12345",
      "entity_name": "Sani ABACHA",
      "source": "OFAC",
      "markdown_profile": "# [INDIVIDUAL] Sani ABACHA..."
    },
    "relationship": {
      "type": "family_member",
      "detail": "child of",
      "extraction_confidence": "stated"
    }
  },
  "relationship_summary": "\"Amina Abacha\" is not directly sanctioned, but matches \"Amina ABACHA\" who is a known child of Sani ABACHA (OFAC).",
  "citations": [
    "OFAC Consolidated List, Entry 12345 (accessed 2026-01-24)"
  ],
  "processing_time_ms": 38
}

Response — No Match:

json
{
  "match": false,
  "direct_match": false,
  "entity_id": null,
  "confidence": null,
  "markdown_profile": null,
  "relationship_match": null,
  "relationship_summary": null,
  "related_entities": [],
  "citations": [],
  "processing_time_ms": 25
}

Batch Agent Lookup

:::api POST /v1/aml/agent/lookup/batch Batch Agent Lookup Look up multiple names with relationship detection (up to 20).

Headers:

  • X-API-Key (required) — Your API key

Request Body:

  • queries (array, required) — Array of names to look up

Response: 200 OK :::

json
{
  "queries": ["Sani Abacha", "Amina Abacha", "John Smith"]
}

Response:

json
{
  "results": [
    { "query": "Sani Abacha", "match": true, "entity_id": "ofac-12345", "confidence": 0.97 },
    { "query": "Amina Abacha", "match": false, "relationship_match": true, "related_to": "Sani ABACHA" },
    { "query": "John Smith", "match": false }
  ],
  "count": 3,
  "direct_matches": 1,
  "relationship_matches": 1,
  "processing_time_ms": 95
}

Relationship Endpoints

Search Relationships

:::api POST /v1/aml/relationships/search Search Relationships Search for potential relationships to sanctioned entities by name.

Headers:

  • X-API-Key (required) — Your API key

Request Body:

  • name (string, required) — Name to search
  • min_score (number, optional) — Minimum match score (0-1). Default: 0.85

Response: 200 OK :::

json
{
  "name": "Viktor Bout",
  "min_score": 0.85
}

Response:

json
{
  "query": "Viktor Bout",
  "has_matches": true,
  "match_count": 2,
  "matches": [
    {
      "matched_name": "Viktor BOUT",
      "score": 0.98,
      "related_to": {
        "entity_id": "ofac-11111",
        "entity_name": "Alla BOUT",
        "source": "OFAC"
      },
      "relationship": {
        "type": "family_member",
        "detail": "spouse of",
        "confidence": "stated"
      }
    }
  ],
  "processing_time_ms": 12
}

Get Entity Relationships

:::api GET /v1/aml/entity/{id}/relationships Get Entity Relationships Retrieve all known relationships for a specific sanctioned entity.

Parameters:

  • id (path, required) — The entity ID (e.g., ofac-12345)

Response: 200 OK :::

Response:

json
{
  "entity": {
    "id": "ofac-12345",
    "name": "Sani ABACHA",
    "type": "individual",
    "source": "OFAC"
  },
  "total_relationships": 5,
  "relationships": {
    "family_member": [
      {
        "target_entity_name": "Mohammed ABACHA",
        "relationship_detail": "parent of",
        "confidence": "stated"
      }
    ],
    "owner": [
      {
        "target_entity_name": "ABACHA HOLDINGS LTD",
        "relationship_detail": "beneficial owner of",
        "confidence": "stated"
      }
    ]
  }
}

Relationship Statistics

:::api GET /v1/aml/relationships/stats Relationship Statistics Get statistics about the relationship graph.

Response: 200 OK :::

Response:

json
{
  "total_relationships": 1523,
  "by_type": {
    "family_member": 456,
    "associate": 312,
    "owner": 234,
    "employee": 189,
    "agent_of": 156,
    "linked_to": 176
  },
  "by_source": {
    "OFAC": 892,
    "UN": 234,
    "EU": 197,
    "HMT": 200
  }
}

Data Types Reference

Relationship Types

Type Description Example Patterns
family_member Blood relative or spouse son, daughter, wife, husband, sibling
associate Known business/personal associate business partner, close associate
owner Owns or controls shareholder, beneficial owner
owned_by Owned or controlled by subsidiary, controlled entity
employee Employment relationship director, CEO, works for
agent_of Acts on behalf of representative, nominee, agent
linked_to Generic connection linked to, connected to

Confidence Levels

Level Meaning
stated Explicitly stated in source data
inferred Derived from context patterns
weak Low confidence, needs verification

Error Responses

All endpoints may return these error responses:

Status Description
400 Bad Request — Invalid parameters
401 Unauthorized — Missing or invalid API key
403 Forbidden — Insufficient permissions
404 Not Found — Resource doesn't exist
429 Rate Limited — Too many requests
500 Server Error — Something went wrong

Error Response Format:

json
{
  "error": "Invalid JSON body",
  "message": "Request body must be valid JSON",
  "request_id": "req_abc123"
}

Rate limiting is enforced based on your plan. See Rate Limits section for details.

---

Rate Limits

Plan Requests/Second Requests/Day
Starter 10 10,000
Professional 50 100,000
Enterprise 200 Unlimited

Rate limit headers are included in all responses:

text
X-RateLimit-Limit: 50
X-RateLimit-Remaining: 49
X-RateLimit-Reset: 1706140800

Code Examples

JavaScript/Node.js

javascript
const axios = require('axios');

const apiKey = 'your_api_key';
const baseUrl = 'https://ag-aml.runloci.com';

async function screenCustomer(name, dob = null) {
  const response = await axios.post(
    `${baseUrl}/v1/aml/screen`,
    { name, dob },
    { headers: { 'X-API-Key': apiKey } }
  );
  return response.data;
}

// Usage
const result = await screenCustomer('John Smith');
if (result.decision === 'BLOCK') {
  console.log(`BLOCKED: Matched ${result.match.entity_name}`);
} else if (result.decision === 'REVIEW') {
  console.log('Manual review required');
} else {
  console.log('Customer cleared');
}

Python

python
import requests

API_KEY = "your_api_key"
BASE_URL = "https://ag-aml.runloci.com"

def screen_customer(name: str, dob: str = None) -> dict:
    response = requests.post(
        f"{BASE_URL}/v1/aml/screen",
        headers={"X-API-Key": API_KEY},
        json={"name": name, "dob": dob}
    )
    return response.json()

# Usage
result = screen_customer("John Smith", "1985-03-15")
if result["decision"] == "BLOCK":
    print(f"BLOCKED: Matched {result['match']['entity_name']}")
elif result["decision"] == "REVIEW":
    print("Manual review required")
else:
    print("Customer cleared")

cURL

bash
# Basic screening
curl -X POST "https://ag-aml.runloci.com/v1/aml/screen" \
  -H "X-API-Key: your_api_key" \
  -H "Content-Type: application/json" \
  -d '{"name": "John Smith"}'

# Agent lookup with relationships
curl -X POST "https://ag-aml.runloci.com/v1/aml/agent/lookup" \
  -H "X-API-Key: your_api_key" \
  -H "Content-Type: application/json" \
  -d '{"query": "Sani Abacha", "include_related": true}'

All code examples include error handling best practices. Click to copy!

---

Sanctions Coverage

List Source Update Frequency
OFAC SDN US Treasury Daily
OFAC Non-SDN US Treasury (SSI, FSE, CAPTA, etc.) Daily
UN Consolidated UN Security Council Daily
EU Sanctions European Commission Daily
UK Sanctions FCDO/HMT Daily
Nigeria NIGSAC Nigeria Sanctions Committee Daily
Nigeria PEPs OpenSanctions Daily

Support