API Documentation

Integrate SMS verification into your applications with our powerful and easy-to-use REST API.

RESTful API • JSON Responses • Rate Limited

Quick Start Guide

Get up and running with our API in minutes. Follow these simple steps to start receiving SMS codes programmatically.

1

Get API Key

Create an account and generate your API key from the dashboard.

2

Request Number

Make a POST request to get a phone number for your chosen service.

3

Get SMS Code

Poll the API to retrieve the SMS verification code when it arrives.

Base URL

https://realartline.com/api/v1

Authentication

All API requests require authentication using your API key in the Authorization header:

Authorization: Bearer YOUR_API_KEY

API Endpoints

Complete reference for all available API endpoints and their usage.

GET /services

Get a list of all available services and their current pricing.

Example Response:

{
  "success": true,
  "data": [
    {
      "id": 1,
      "name": "WhatsApp",
      "code": "whatsapp",
      "price": {
        "US": 0.85,
        "GB": 0.75,
        "DE": 0.65
      }
    }
  ]
}
GET /countries

Get a list of all supported countries with their codes.

Example Response:

{
  "success": true,
  "data": [
    {
      "id": 1,
      "name": "United States",
      "code": "US",
      "available": true
    }
  ]
}
POST /order

Request a phone number for SMS verification.

Request Body:

{
  "service": "whatsapp",
  "country": "US"
}

Example Response:

{
  "success": true,
  "data": {
    "order_id": "12345",
    "phone_number": "+1234567890",
    "status": "waiting",
    "expires_at": "2024-01-20T10:30:00Z"
  }
}
GET /order/{order_id}

Check the status of an order and retrieve the SMS code if available.

Example Response (SMS Received):

{
  "success": true,
  "data": {
    "order_id": "12345",
    "phone_number": "+1234567890",
    "status": "completed",
    "sms_code": "123456",
    "received_at": "2024-01-20T10:25:00Z"
  }
}
DELETE /order/{order_id}

Cancel an active order and release the phone number.

Example Response:

{
  "success": true,
  "message": "Order cancelled successfully"
}

Rate Limits & Error Handling

Important information about API limits and error responses.

Rate Limits

  • 100 requests per minute
  • 1000 requests per hour
  • 10000 requests per day

Rate limit headers are included in all responses to help you track your usage.

Common Error Codes

400 Bad Request
401 Unauthorized
402 Insufficient Balance
404 Not Found
429 Rate Limited
500 Server Error

SDKs & Code Examples

Get started quickly with our code examples in popular programming languages.

Python Example

import requests

api_key = "your_api_key_here"
base_url = "https://realartline.com/api/v1"

headers = {
    "Authorization": f"Bearer {api_key}",
    "Content-Type": "application/json"
}

# Order a number
response = requests.post(
    f"{base_url}/order",
    json={"service": "whatsapp", "country": "US"},
    headers=headers
)

order = response.json()
print(f"Number: {order['data']['phone_number']}")

# Check for SMS
order_id = order['data']['order_id']
sms_response = requests.get(
    f"{base_url}/order/{order_id}",
    headers=headers
)

print(sms_response.json())

JavaScript Example

const apiKey = 'your_api_key_here';
const baseUrl = 'https://realartline.com/api/v1';

const headers = {
    'Authorization': `Bearer ${apiKey}`,
    'Content-Type': 'application/json'
};

// Order a number
const orderResponse = await fetch(`${baseUrl}/order`, {
    method: 'POST',
    headers: headers,
    body: JSON.stringify({
        service: 'whatsapp',
        country: 'US'
    })
});

const order = await orderResponse.json();
console.log(`Number: ${order.data.phone_number}`);

// Check for SMS
const orderId = order.data.order_id;
const smsResponse = await fetch(
    `${baseUrl}/order/${orderId}`,
    { headers: headers }
);

const smsData = await smsResponse.json();
console.log(smsData);

Ready to Start Building?

Get your API key and start integrating SMS verification into your applications today.