API Documentation

Veriphone is a REST-based phone number validation and carrier lookup API. Validate numbers, detect line types, identify carriers, and format phone data for 240+ countries.

Base URL https://api.veriphone.io

Introduction

The Veriphone API provides stateless JSON endpoints that any program or web browser can call via standard HTTP requests. Use it to check phone number validity, perform carrier lookups, detect line types (mobile, fixed-line, VoIP, toll-free), and retrieve formatted number data.

All endpoints accept both GET and POST requests. All responses are application/json; charset=UTF-8. CORS is enabled on all endpoints.

Quick Start

Validate your first phone number in under a minute.

  1. Sign up for a free account to get your API key
  2. Make a request to the /v2/verify endpoint
  3. Parse the JSON response for validation results
curl "https://api.veriphone.io/v2/verify?phone=%2B4915123577723" \
  -H "Authorization: Bearer YOUR_API_KEY"
const res = await fetch(
  'https://api.veriphone.io/v2/verify?phone=%2B4915123577723',
  { headers: { 'Authorization': 'Bearer YOUR_API_KEY' } }
);
const data = await res.json();
console.log(data.phone_valid, data.carrier);
import requests

res = requests.get(
    'https://api.veriphone.io/v2/verify',
    params={'phone': '+4915123577723'},
    headers={'Authorization': 'Bearer YOUR_API_KEY'}
)
data = res.json()
print(data['phone_valid'], data['carrier'])
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,
  'https://api.veriphone.io/v2/verify?phone=%2B4915123577723');
curl_setopt($ch, CURLOPT_HTTPHEADER, [
  'Authorization: Bearer YOUR_API_KEY'
]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);

Response

JSON
{
  "status": "success",
  "phone": "+4915123577723",
  "phone_valid": true,
  "phone_type": "mobile",
  "phone_region": "Germany",
  "country": "Germany",
  "country_code": "DE",
  "country_prefix": "49",
  "international_number": "+49 1512 3577723",
  "local_number": "01512 3577723",
  "e164": "+4915123577723",
  "carrier": "T-Mobile"
}

Authentication

The API uses API keys to authenticate requests. You can view and manage your key in your control panel. Each authenticated request to /v2/verify deducts 1 credit from your balance — keep your key secure and never expose it in client-side code.

Your API key is read from (checked in this order):

  1. Authorization: Bearer <key> header (recommended)
  2. key cookie
  3. key query or body parameter
Header Auth (recommended)
Authorization: Bearer YOUR_API_KEY
Query Param Auth
https://api.veriphone.io/v2/verify?phone=...&key=YOUR_API_KEY
Security
Do not share your API key in publicly accessible areas such as GitHub repositories, client-side JavaScript, or public forums.

Errors

Veriphone uses standard HTTP status codes. Successful requests return 200. Failures return an error object:

Error Response
{
  "status": "error",
  "code": 400,
  "type": "BadRequest",
  "message": "Human-readable error description"
}
CodeTypeMeaning
400BadRequestInvalid or missing input parameter
401UnauthorizedInvalid or missing API key
402PaymentRequiredInsufficient credits
403ForbiddenAccess denied
404NotFoundResource not found
429TooManyRequestsRate limit exceeded
500InternalServerErrorServer-side error — retry or contact support