Free · no API key
IMEI API & MCP server
Validate IMEI numbers, identify the device from its TAC, and generate Luhn-valid test IMEIs, from your code, from ChatGPT, or from any MCP client.
MCP server
https://imeilens.com/mcp
Streamable HTTP · no auth
OpenAPI 3.1
https://imeilens.com/openapi.json
Import as a Custom GPT Action
REST base URL
https://imeilens.com/api/v1
JSON · open CORS
Quick start
No sign-up and no key. Call it from a terminal, a backend or the browser:
curl "https://imeilens.com/api/v1/imei/validate?imei=490154203237518"Or connect an AI assistant to the MCP server at https://imeilens.com/mcp and ask it to “validate 490154203237518” or “generate 5 Samsung test IMEIs”.
Validate IMEIs
Checks the length and the Luhn check digit, splits the number into its parts and identifies the device from our TAC database of about 276,000 entries. Accepts 15-digit IMEIs and 16-digit IMEISVs; spaces and dashes are ignored. This does not check blacklist, carrier or iCloud status (that’s the paid report).
GET/api/v1/imei/validate?imei={imei}
curl "https://imeilens.com/api/v1/imei/validate?imei=490154203237518"{
"imei": "490154203237518",
"valid": true,
"type": "imei",
"tac": "49015420",
"reporting_body": "49",
"serial": "323751",
"check_digit": 8,
"expected_check_digit": 8,
"device": { "brand": "Nokia", "model": "Nokia 3110" }
}Invalid numbers return valid: false and a reason: length, checksum or chars.
POST/api/v1/imei/validate
Validate up to 100 numbers in one request:
curl -X POST https://imeilens.com/api/v1/imei/validate \
-H "Content-Type: application/json" \
-d '{"imeis": ["490154203237518", "356938035643809"]}'{ "count": 2, "valid": 2, "results": [ … ] }Generate test IMEIs
Returns Luhn-valid IMEIs for form validation, QA and demos. By default numbers start with 00, the reporting body reserved for test equipment, so they can’t match a real phone.
GET/api/v1/imei/generate
| Param | Values | Description |
|---|---|---|
| count | 1–100 | How many to generate (default 1). |
| brand | apple, samsung, xiaomi, google, oppo, vivo, realme, oneplus, motorola, huawei, honor, nokia, tecno, infinix, sony, nothing | Use real TACs of that brand’s recent models; each result includes the model name. |
| tac | 8 digits | Use one exact Type Allocation Code. |
| prefix | 0–14 digits | Start every number with these digits (default 00). |
curl "https://imeilens.com/api/v1/imei/generate?count=2&brand=google"{
"imeis": [
{ "imei": "358124091085361", "tac": "35812409", "model": "Pixel 3XL" },
{ "imei": "353238341936531", "tac": "35323834", "model": "Pixel 8 Pro" }
],
"notice": "Generated IMEIs are Luhn-valid numbers for software testing only. …"
}Generate test ICCIDs
Returns Luhn-valid ICCID (SIM card) numbers: 89 + country calling code + random digits + check digit.
GET/api/v1/iccid/generate
| Param | Values | Description |
|---|---|---|
| count | 1–100 | How many to generate (default 1). |
| country | 01, 44, 49, 33, 34, 39, 55, 52, 90, 62, 91, 234 | Country calling code (default 01, USA/Canada). |
| length | 19 or 20 | Total digits (default 19). |
curl "https://imeilens.com/api/v1/iccid/generate?count=2&country=44"MCP server
A remote Model Context Protocol server (Streamable HTTP, stateless, no authentication) with three read-only tools:
- validate_imei:
imeis: string[](1–100). Same result as the REST endpoint. - generate_imei:
count,brand,tac,prefix. - generate_iccid:
count,country,length.
Claude
Claude.ai and Claude Desktop: Settings → Connectors → Add custom connector, URL https://imeilens.com/mcp. Claude Code:
claude mcp add --transport http imeilens https://imeilens.com/mcpCursor
Add to ~/.cursor/mcp.json:
{
"mcpServers": {
"imeilens": { "url": "https://imeilens.com/mcp" }
}
}VS Code
Add to .vscode/mcp.json:
{
"servers": {
"imeilens": { "type": "http", "url": "https://imeilens.com/mcp" }
}
}Test it
npx @modelcontextprotocol/inspector --cli https://imeilens.com/mcp --transport http --method tools/listChatGPT
As an app (MCP): Settings → Apps & Connectors → Advanced → enable Developer mode → Create. Use the URL https://imeilens.com/mcp and choose “No authentication”.
As a Custom GPT: Create a GPT → Configure → Actions → Import from URL https://imeilens.com/openapi.json. Privacy policy: https://imeilens.com/en/legal/privacy. Suggested instructions:
You are IMEILens. Validate IMEIs with validateImei / validateImeis and explain the result (TAC, check digit, device). Generate test IMEIs with generateImeis only for testing, QA or demos, and never help change or spoof a real device's IMEI. For blacklist, carrier, iCloud or warranty status, send users to https://imeilens.com.Limits & errors
- 60 requests per minute per IP across the API and MCP server. Over the limit you get
429withRetry-After: 60. - Up to 100 IMEIs per validate call and 100 per generate call; request bodies up to 32 KB.
- Errors are JSON:
{"error": "bad_request", "message": "…"}with status 400. - CORS is open (
Access-Control-Allow-Origin: *), so you can call it from browser code.
Need higher limits or bulk blacklist checks? Email support@imeilens.com.
Acceptable use
Generated IMEIs are for software testing only. They are not assigned to real devices. Never use them to change, clone or spoof a device’s IMEI or to get around blacklisting; that’s illegal in many countries and against our terms.