mcp-onfido — Claude Code MCP server: what it does, how to install
Connects Onfido identity verification and KYC workflows to your AI assistant. Useful for managing applicants, file uploads, and checks from IDE chats.
claude mcp add --env ONFIDO_API_TOKEN=<ONFIDO_API_TOKEN> --env ONFIDO_REGION=<ONFIDO_REGION> --transport stdio onfido -- npx -y @codespar/mcp-onfidoWhat mcp-onfido does
This server connects coding agents to Onfido API version 3.6 with 20 distinct tools. It handles identity checks covering 195+ countries. Agents can register applicant records, submit identity documents, handle selfie uploads, and trigger check reports directly. Workflow runs for Onfido Studio are supported too.
Document files and selfie photos arrive as base64 strings. The tool bundles them into multipart/form-data before forwarding them to Onfido. Beyond default endpoints, optional region routing handles EU, US, and CA data residency via ONFIDO_REGION. You can run the process over stdio or switch to HTTP on port 3000.
A valid ONFIDO_API_TOKEN is mandatory or requests fail immediately. Direct live photo uploads may be blocked depending on your Onfido contract settings. In those setups, use generate_sdk_token to handle capture through client SDKs instead.
What it helps with
- create and manage applicant profiles for identity verification
- upload identity documents and live photos encoded as base64
- inspect status of KYC checks and read detailed breakdown reports
- mint short-lived tokens for frontend Onfido SDK integrations
- trigger and monitor Onfido Studio workflow runs
Example prompts for the agent
- Create an applicant record in Onfido for Jane Doe using email [email protected]
- Upload
passport.jpgfor applicantapp_123and trigger standard document checks - Generate an SDK token for applicant
app_123to initialize verification in the mobile app
How to install mcp-onfido
Platform CLI
claude mcp add --env ONFIDO_API_TOKEN=<ONFIDO_API_TOKEN> --env ONFIDO_REGION=<ONFIDO_REGION> --transport stdio onfido -- npx -y @codespar/mcp-onfidoReplace <…> with your own values
Platform CLI
codex mcp add onfido --env ONFIDO_API_TOKEN=<ONFIDO_API_TOKEN> --env ONFIDO_REGION=<ONFIDO_REGION> -- npx -y @codespar/mcp-onfidoReplace <…> with your own values
Config file
{
"mcpServers": {
"onfido": {
"command": "npx",
"args": [
"-y",
"@codespar/mcp-onfido"
],
"env": {
"ONFIDO_API_TOKEN": "<ONFIDO_API_TOKEN>",
"ONFIDO_REGION": "<ONFIDO_REGION>"
}
}
}
}Replace <…> with your own values
Config file
{
"servers": {
"onfido": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@codespar/mcp-onfido"
],
"env": {
"ONFIDO_API_TOKEN": "<ONFIDO_API_TOKEN>",
"ONFIDO_REGION": "<ONFIDO_REGION>"
}
}
}
}Replace <…> with your own values
Platform CLI
gemini mcp add -e ONFIDO_API_TOKEN=<ONFIDO_API_TOKEN> -e ONFIDO_REGION=<ONFIDO_REGION> onfido npx -y @codespar/mcp-onfidoReplace <…> with your own values
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about mcp-onfido
How to install mcp-onfido in Claude Code?
Run claude mcp add mcp-onfido -e ONFIDO_API_TOKEN=<ONFIDO_API_TOKEN> -- npx -y @codespar/mcp-onfido.
What does mcp-onfido do?
It exposes 20 tools for running applicant identity verification, document parsing, and AML screening against Onfido.
How does the server handle image uploads?
You pass the image as a base64 string, and the server automatically wraps the payload into multipart/form-data.