Claude Identity Verification API Integration: APAC KYC Guide

Key Takeaways
- Claude extracts and structures ID document fields; it does not replace a licensed IDV vendor.
- Request Zero Data Retention before sending any real passport or HKID image.
- Force JSON output with tool_choice and temperature=0 for auditable, deterministic extraction.
- Keep humans in the loop on every adverse decision under MAS and HKMA expectations.
- Run shadow mode for weeks before enabling any auto-clear path.
Quick Answer: A Claude identity verification API integration uses Claude's vision and tool-use to extract structured fields from ID documents, then reconciles them against a licensed IDV vendor's biometric and sanctions results. Claude assists extraction; it does not make the KYC decision. Zero Data Retention is mandatory for regulated workloads.
A Singapore-licensed payments firm I spoke with last quarter had a very specific operational problem. Their onboarding queue for corporate accounts had a 38-hour median turnaround, and 70% of that time was a human analyst squinting at a scanned Hong Kong Business Registration certificate, a Companies Registry extract, and three director passports — then typing the fields into a case management tool. Their compliance team wasn't slow. They were doing data entry.
Related reading: Headless Commerce Business Case Builder for APAC Teams
That is the real use case behind a Claude identity verification API integration: not replacing your KYC vendor, but putting a document-understanding layer between the raw artefacts your customer uploads and the structured decision your compliance system needs. Claude reads the documents, extracts fields into a schema, flags mismatches, and writes an auditable rationale. A dedicated IDV provider still does the biometric match, liveness check, and sanctions screening. Those are two different jobs, and conflating them is how teams end up with a regulator asking uncomfortable questions.
Related reading: Staff Augmentation vs Managed Squad: APAC Tech Decision Guide
Related reading: Apertus Open Foundation Model: Sovereign AI for APAC Teams
There's a second, separate meaning of "Claude identity verification" worth clearing up before we build anything, because the search results mix them badly.
Two different things called "Claude identity verification"
1. Anthropic verifying you. In 2025 Anthropic began rolling out identity and age verification for Claude consumer accounts, using Persona as the verification vendor, targeting suspected underage users, policy violators, and accounts in restricted jurisdictions (The New Stack). Anthropic's own help centre states verification data is used solely to confirm identity and meet legal and safety obligations (Claude Help Center). If you're a developer on the API, this is mostly orthogonal — API authentication is separate from consumer identity verification, a point that dev.to and several Reddit threads have made repeatedly. What does affect developers is organisation-level verification for higher rate tiers and the Claude Cyber Verification Program for security-focused workloads.
2. You using Claude to verify your customers. That's the build in this guide — a Claude identity verification API integration that sits squarely inside AML/CFT obligations that differ between Singapore, Hong Kong, and Australia.
Do not let anyone sell you on "skip Claude KYC" proxy services that resell API access without verification. If you're a regulated entity in APAC, an unverified upstream vendor in your customer due diligence chain is an audit finding waiting to happen.
Related reading: Looker vs Power BI: Retail Analytics APAC Comparison
Prerequisites
Before you write a line of code, have these in place:
- An Anthropic Console account with a verified organisation and an API key. Create keys at the Claude Console; store them in a secrets manager (AWS Secrets Manager, GCP Secret Manager, HashiCorp Vault), never in
.envfiles committed to your repo. - A decision on data retention. Anthropic's commercial terms state API inputs and outputs are not used to train models by default, with a standard retention window for trust and safety, according to Anthropic's own published terms (Anthropic Privacy Center). For KYC payloads containing passport images, request Zero Data Retention (ZDR) on your organisation before processing a single real document. Check current terms at the Anthropic Privacy Center — this is the single most important prerequisite for a regulated workload.
- A licensed IDV/biometric vendor — Persona, Sumsub, Onfido, Jumio, or Trulioo. Claude does not perform liveness detection or 1:1 facial matching, and you should not try to make it.
- An orchestration layer. n8n (self-hosted, so documents never leave your VPC), Make, or your own service. For regulated workloads I strongly favour self-hosted n8n in your own cloud region — Singapore
ap-southeast-1or Hong Kongap-east-1. - A legal basis and privacy notice aligned to Singapore's PDPA (PDPC) and Hong Kong's PDPO (PCPD). According to the PDPC's 2022 amendment guidance, Singapore's PDPA financial penalty ceiling rose in October 2022 to up to 10% of annual turnover in Singapore for organisations with turnover above S$10 million. That number tends to focus the mind.
- Python 3.11+ or Node 20+, plus
curlfor testing.
Related reading: Adobe Commerce to Shopify Plus Migration Playbook: 9 Phased Steps
One more: get your compliance officer in the room at design stage. Retro-fitting an audit trail onto a working pipeline is three times the work. I've watched teams try.
Ready to Transform Your Ecommerce Operations?
Branch8 specializes in ecommerce platform implementation and AI-powered automation solutions. Contact us today to discuss your ecommerce automation strategy.
Step 1: Verify your API access and model availability
Start with the dullest possible test — confirm the key works and the model responds.
1export ANTHROPIC_API_KEY="sk-ant-..."23curl https://api.anthropic.com/v1/messages \4 -H "x-api-key: $ANTHROPIC_API_KEY" \5 -H "anthropic-version: 2023-06-01" \6 -H "content-type: application/json" \7 -d '{8 "model": "claude-sonnet-4-5-20250929",9 "max_tokens": 64,10 "messages": [{"role": "user", "content": "Reply with the single word: ready"}]11 }'
Expected output:
1{2 "id": "msg_01XYZ...",3 "type": "message",4 "role": "assistant",5 "model": "claude-sonnet-4-5-20250929",6 "content": [{"type": "text", "text": "ready"}],7 "stop_reason": "end_turn",8 "usage": {"input_tokens": 16, "output_tokens": 3}9}
If you get a 401, your key is wrong or revoked. A 429 means you've hit a rate limit for your organisation tier — relevant if you're batch-processing an onboarding backlog.
Step 2: Replace long-lived API keys with workload identity federation
A static sk-ant- key sitting in an environment variable on a container that touches passport scans is the kind of thing that turns a minor incident into a notifiable breach. The Claude Platform now supports Workload Identity Federation: your workload presents a short-lived OIDC token from your own identity provider, and exchanges it for a short-lived Claude access token. No long-lived secret on the box.
The shape, using a GCP service account as the IdP:
1# 1. Get an OIDC token from your own IdP (GCP metadata server example)2OIDC_TOKEN=$(curl -s -H "Metadata-Flavor: Google" \3 "http://metadata.google.internal/computeMetadata/v1/instance/service-accounts/default/identity?audience=https://api.anthropic.com")45# 2. Exchange it for a short-lived Claude access token6# (confirm the current endpoint + body in the Claude Platform docs)7curl -s "$CLAUDE_STS_ENDPOINT" \8 -H "content-type: application/json" \9 -d "{\"subject_token\":\"$OIDC_TOKEN\",\"workload_identity_pool\":\"$POOL_ID\"}"
Then call the Messages API with Authorization: Bearer <access_token> instead of x-api-key. Check the exact request shape in the Claude Platform documentation before wiring it in — federation configuration is the kind of thing that changes.
Trade-off, honestly stated: federation adds setup complexity and an IdP dependency. For a 200-application-per-month onboarding flow, static keys rotated quarterly through a secrets manager may be proportionate. For anything processing identity documents at volume in a licensed entity, federation is worth the afternoon.
Ready to Transform Your Ecommerce Operations?
Branch8 specializes in ecommerce platform implementation and AI-powered automation solutions. Contact us today to discuss your ecommerce automation strategy.
Step 3: Build the document extraction call with enforced structure
This is the core of the integration. The mistake teams make is asking Claude for "a summary of this passport." You want a schema, every time, with no prose. Use tool definitions to force structured JSON output.
1import base64, json2from anthropic import Anthropic34client = Anthropic() # reads ANTHROPIC_API_KEY56EXTRACT_TOOL = {7 "name": "record_identity_document",8 "description": "Record fields extracted from a government-issued identity document.",9 "input_schema": {10 "type": "object",11 "properties": {12 "document_type": {13 "type": "string",14 "enum": ["passport", "hkid", "sg_nric", "driver_licence", "other", "unreadable"]15 },16 "issuing_jurisdiction": {"type": "string", "description": "ISO 3166-1 alpha-2, e.g. HK, SG, AU"},17 "full_name_latin": {"type": "string"},18 "full_name_native": {"type": "string", "description": "Chinese characters if printed; empty if absent"},19 "document_number": {"type": "string"},20 "date_of_birth": {"type": "string", "description": "YYYY-MM-DD, empty if not legible"},21 "date_of_expiry": {"type": "string", "description": "YYYY-MM-DD, empty if not legible"},22 "mrz_present": {"type": "boolean"},23 "tamper_indicators": {24 "type": "array",25 "items": {"type": "string"},26 "description": "Visual anomalies observed: font mismatch, misaligned text, digital artefacts"27 },28 "legibility_score": {"type": "integer", "description": "0-100 confidence the image is readable"},29 "extraction_notes": {"type": "string", "description": "One sentence of rationale for the audit log"}30 },31 "required": ["document_type", "issuing_jurisdiction", "legibility_score", "extraction_notes"]32 }33}3435SYSTEM = (36 "You extract fields from identity documents for a regulated financial institution. "37 "Transcribe only what is visibly printed. Never infer, guess, or complete a partially "38 "obscured field. If a field is not legible, return an empty string. You do not make "39 "approve or reject decisions. Always call record_identity_document."40)4142def extract(image_bytes: bytes, media_type: str = "image/jpeg") -> dict:43 resp = client.messages.create(44 model="claude-sonnet-4-5-20250929",45 max_tokens=1024,46 temperature=0,47 system=SYSTEM,48 tools=[EXTRACT_TOOL],49 tool_choice={"type": "tool", "name": "record_identity_document"},50 messages=[{51 "role": "user",52 "content": [53 {"type": "image", "source": {54 "type": "base64",55 "media_type": media_type,56 "data": base64.b64encode(image_bytes).decode()57 }},58 {"type": "text", "text": "Extract all legible fields from this document."}59 ]60 }]61 )62 for block in resp.content:63 if block.type == "tool_use":64 return block.input65 raise RuntimeError("no tool_use block returned")
Copy-pasteable output for a clean Hong Kong passport scan:
1{2 "document_type": "passport",3 "issuing_jurisdiction": "HK",4 "full_name_latin": "CHAN TAI MAN",5 "full_name_native": "陳大文",6 "document_number": "K1234567",7 "date_of_birth": "1988-03-14",8 "date_of_expiry": "2031-07-02",9 "mrz_present": true,10 "tamper_indicators": [],11 "legibility_score": 94,12 "extraction_notes": "All MRZ lines legible; printed fields match MRZ transliteration."13}
Three deliberate design choices there. temperature=0 for determinism. tool_choice forced, so you never get a chatty paragraph where your parser expects JSON. And extraction_notes exists purely to give your compliance file a human-readable rationale — the thing an auditor asks for when they want to know why a record says what it says.
Step 4: Cross-check against your IDV vendor, don't replace it
Here is where the architecture matters more than the prompt. Claude extracts. Persona (or Sumsub, or Onfido) does the regulated part: document authenticity, liveness, biometric match, PEP and sanctions screening. Your orchestrator compares the two and escalates on disagreement.
1from datetime import date23def reconcile(claude_fields: dict, vendor_result: dict) -> dict:4 flags = []56 if claude_fields["legibility_score"] < 70:7 flags.append("LOW_LEGIBILITY")89 if claude_fields.get("tamper_indicators"):10 flags.append("VISUAL_TAMPER_SIGNAL")1112 def norm(s): return "".join(ch for ch in (s or "").upper() if ch.isalpha())13 if norm(claude_fields.get("full_name_latin")) != norm(vendor_result.get("name")):14 flags.append("NAME_MISMATCH")1516 if claude_fields.get("date_of_birth") != vendor_result.get("dob"):17 flags.append("DOB_MISMATCH")1819 expiry = claude_fields.get("date_of_expiry")20 if expiry and date.fromisoformat(expiry) <= date.today():21 flags.append("DOCUMENT_EXPIRED")2223 if vendor_result.get("liveness") != "passed":24 flags.append("LIVENESS_FAIL")2526 return {27 "route": "AUTO_CLEAR" if not flags else "HUMAN_REVIEW",28 "flags": flags,29 "rationale": claude_fields.get("extraction_notes", "")30 }
Output on a mismatch:
1{2 "route": "HUMAN_REVIEW",3 "flags": ["NAME_MISMATCH", "LOW_LEGIBILITY"],4 "rationale": "Given name partially obscured by glare; surname legible."5}
Note what the model is not doing: it is not deciding. MAS Notice 626 and the associated AML/CFT guidelines permit non-face-to-face customer verification where the institution applies appropriate risk-mitigation measures, according to the Monetary Authority of Singapore's published notice (MAS), and the HKMA has similarly supported remote onboarding of individual customers since its 2019 circulars, according to the HKMA's own circular guidance (HKMA). Both regimes put the accountability on the institution, not the vendor. An LLM output in your approval path is a control you must be able to explain, test, and override.
Ready to Transform Your Ecommerce Operations?
Branch8 specializes in ecommerce platform implementation and AI-powered automation solutions. Contact us today to discuss your ecommerce automation strategy.
Step 5: Orchestrate it in n8n with a human-in-the-loop branch
Self-hosted n8n is a good fit here because the document bytes stay inside your VPC, and the workflow is visible to a compliance reviewer who doesn't read Python. A minimal node sequence:
- Webhook — receives the IDV vendor's
inquiry.completedevent. - HTTP Request — fetches the document image from your own object store (not the vendor's CDN, so you control retention).
- HTTP Request → Anthropic Messages API — the Step 3 call.
- Code node — the
reconcile()logic. - Switch node —
AUTO_CLEARvsHUMAN_REVIEW. - Postgres/Airtable node — write the immutable audit record.
- Slack/Teams node — notify the reviewer queue with flags and rationale.
The webhook verification step is non-negotiable:
1// n8n Code node: verify the IDV provider's webhook signature before anything else2const crypto = require('crypto');3const raw = $input.first().json.rawBody;4const received = $input.first().json.headers['persona-signature'];56const expected = crypto7 .createHmac('sha256', $env.IDV_WEBHOOK_SECRET)8 .update(raw)9 .digest('hex');1011if (!crypto.timingSafeEqual(Buffer.from(expected), Buffer.from(received))) {12 throw new Error('Webhook signature mismatch — dropping payload');13}14return $input.all();
A practical detail from building this kind of pipeline with a Greater China retail group handling cross-border customer registrations: set your n8n execution data pruning aggressively (EXECUTIONS_DATA_MAX_AGE, EXECUTIONS_DATA_PRUNE=true). By default, orchestrators cheerfully store the full payload of every run — including base64 passport images — in their own database, according to n8n's own hosting and self-deployment documentation (n8n Docs). That's a copy of your most sensitive data in a system nobody listed on the data inventory.
1# docker-compose env for self-hosted n8n handling PII2EXECUTIONS_DATA_PRUNE=true3EXECUTIONS_DATA_MAX_AGE=72 # hours4EXECUTIONS_DATA_SAVE_ON_SUCCESS=none5N8N_ENCRYPTION_KEY=${VAULT_N8N_KEY}
Step 6: Redact, log, and make it auditable
Two logs, different lifetimes. The operational log holds full extracted fields and lives as long as your AML record-keeping obligation requires — five years from the end of the business relationship under Singapore's AML/CFT notices and Hong Kong's AMLO. The debug log holds model latency, token counts, model version, and flags, with every PII field masked.
1import re, hashlib23SENSITIVE = ("document_number", "date_of_birth", "full_name_latin", "full_name_native")45def redact_for_telemetry(fields: dict) -> dict:6 out = dict(fields)7 for k in SENSITIVE:8 if out.get(k):9 out[k] = "sha256:" + hashlib.sha256(out[k].encode()).hexdigest()[:12]10 return out
Pin the model version in your audit record. When Anthropic ships a new Sonnet, your extraction behaviour can shift, and "which model made this extraction on 14 March" is a question you want a one-line answer to. Log model, prompt_version, tool_schema_version, and usage on every call.
Ready to Transform Your Ecommerce Operations?
Branch8 specializes in ecommerce platform implementation and AI-powered automation solutions. Contact us today to discuss your ecommerce automation strategy.
Step 7: Evaluate before you ship — with regional documents
Most teams test with US passports and an Australian driver licence, then deploy into a market where half the uploads are a photo of a Hong Kong ID card taken at an angle under fluorescent light, or a Vietnamese CCCD, or an Indonesian KTP with a laminate reflection across the NIK.
Build a golden set of 200–400 real-shape documents (synthetic or consented), spanning:
- HKID, Singapore NRIC/FIN, Malaysian MyKad, Indonesian KTP, Philippine PhilID, Vietnamese CCCD, Taiwan ID
- Chinese-character names, including traditional and simplified
- Glare, 15–30° rotation, partial crop, low resolution, screenshot-of-a-screen
Measure field-level exact-match accuracy and, more importantly, the rate at which the model returns a confident value that is wrong. Silent errors are the dangerous failure mode; a blank field routes to a human, a wrong field routes to an account.
1python eval.py --dataset golden_apac_v3.jsonl \2 --model claude-sonnet-4-5-20250929 \3 --metrics exact_match,silent_error_rate,escalation_rate
Set an escalation threshold your operations team can actually staff. If 35% of applications route to human review, you need to know that before you promise the business a 4-hour SLA.
Where regional compliance actually bites
Three things that catch APAC teams:
Cross-border transfer. Sending a Singapore customer's NRIC image to a US-hosted inference endpoint is a transfer. Under the PDPA Transfer Limitation Obligation you need comparable protection in place; Hong Kong's PDPO section 33 remains uncommenced but the PCPD's guidance on cross-border transfers still sets the expectation. Document the transfer, the safeguards, and the ZDR arrangement.
Automated decision-making. Keep a human in the loop on adverse outcomes. If you operate into the EU as well, GDPR Article 22 restricts solely automated decisions with legal or similarly significant effects, and account rejection qualifies, according to the European Data Protection Board's guidance on automated decision-making (EDPB).
Vendor concentration. Your regulator will ask what happens if Anthropic's API is unavailable mid-onboarding. Have a documented fallback: queue to manual review, don't fail the application.
Ready to Transform Your Ecommerce Operations?
Branch8 specializes in ecommerce platform implementation and AI-powered automation solutions. Contact us today to discuss your ecommerce automation strategy.
What to do next
Run it in shadow mode first. Point the Claude identity verification API integration at live traffic, write its output to a separate table, and let your analysts keep working as they always have. After three or four weeks you'll have a real comparison between model extraction and human extraction on your document mix — which is the only dataset that matters for the go/no-go call. Then enable auto-clear for your lowest-risk segment only, and widen from there.
Honest assessment of who this is not for. If you onboard fewer than roughly 100 customers a month, the engineering, evaluation, and compliance documentation cost will exceed what you save on analyst hours — buy an all-in-one IDV platform instead. If you're in a jurisdiction where your regulator has not yet published a position on AI in CDD workflows, expect to spend more time in written correspondence than in code. And if your compliance team isn't resourced to own and periodically re-test a model-based control, don't build one; an unmonitored automated control is worse than a slow manual one, because it fails quietly.
For everyone else — teams running cross-border onboarding across Hong Kong, Singapore, and Southeast Asia, where document variety is the actual bottleneck — a well-scoped Claude identity verification API integration moves the human effort from transcription to judgement. That's the right trade.
If you're scoping an onboarding automation build across APAC markets and want a second opinion on the architecture or the compliance boundaries, talk to the Branch8 team.
Sources
- Claude Help Center — Identity verification on Claude
- Claude Platform Docs — API and Workload Identity Federation
- Anthropic — Privacy, commercial terms and trust resources
- The New Stack — Anthropic lays down identity verification on Claude
- Monetary Authority of Singapore — AML/CFT notices and guidelines
- [Hong Kong Monetary Authority — AML/CFT and remote onboarding circulars
FAQ
API authentication is separate from Claude consumer identity verification — you authenticate with an API key or workload identity federation token, not a passport. However, Anthropic does apply organisation-level verification for higher usage tiers and certain programs, and consumer Claude accounts may be asked for ID via Persona in specific circumstances such as suspected underage use or restricted jurisdictions.
About the Author
Matt Li
Co-Founder & CEO, Branch8 & Second Talent
Matt Li is Co-Founder and CEO of Branch8, a Y Combinator-backed (S15) Adobe Solution Partner and e-commerce consultancy headquartered in Hong Kong, and Co-Founder of Second Talent, a global tech hiring platform ranked #1 in Global Hiring on G2. With 12 years of experience in e-commerce strategy, platform implementation, and digital operations, he has led delivery of Adobe Commerce Cloud projects for enterprise clients including Chow Sang Sang, HomePlus (HKBN), Maxim's, Hong Kong International Airport, Hotai/Toyota, and Evisu. Prior to founding Branch8, Matt served as Vice President of Mid-Market Enterprises at HSBC. He serves as Vice Chairman of the Hong Kong E-Commerce Business Association (HKEBA). A self-taught software engineer, Matt graduated from the University of Toronto with a Bachelor of Commerce in Finance and Economics.