AtlasSIM API documentation
Integrate SMS verification reception and virtual number purchasing directly into your applications with our REST API.
Introduction
The AtlasSIM API is a REST API that uses the JSON format for all requests and responses. It lets you automate the purchase of virtual numbers, track received SMS, and manage your balance from your own systems.
All requests must be sent over HTTPS to the following base URL:
https://api.atlas-sim.org/v1Every response contains a JSON object with a status field and the requested data. Errors are returned with an appropriate HTTP code and an explicit message.
Authentication
The API uses Bearer token authentication. Your API key must be passed in the Authorization HTTP header of every request.
Example header to include in all your requests:
Authorization: Bearer sk_live_51H8x...........Never share your API key publicly (Git repo, front-end code, etc.). Any request without a valid header will return a 401 error.
API key management
From your account area, under the "API" section, you can create, view, and revoke your API keys at any time.
Creating a key
Click "Generate new key", give it an explicit name (e.g. "Production", "Test"), then copy it immediately: it will never be shown in plain text again.
Key rotation
We recommend rotating your keys every 90 days. Generate a new key, update your integrations, then revoke the old one once the transition is validated to avoid any service interruption.
Scopes
Each key can be limited to specific permissions: read-only (balance, history), or read/write (order purchase and cancellation). Use the principle of least privilege for each integration.
Security
Store your keys in environment variables, never in versioned code. Enable low-balance alerts and regularly monitor your keys' activity log from the dashboard.
Endpoints
Here is the complete list of endpoints available to interact with the AtlasSIM platform.
/balanceCheck balance
Returns the available balance of the account associated with the API key used.
curl -X GET "https://api.atlas-sim.org/v1/balance" \
-H "Authorization: Bearer sk_live_51H8x..."{
"status": "success",
"data": {
"balance": 42.85,
"currency": "USD"
}
}/countriesList countries
Returns the list of available countries with their code and the number of numbers in stock.
| Parameter | Type | Required | Description |
|---|---|---|---|
| search | string | No | Filters countries by name (partial search). |
curl -X GET "https://api.atlas-sim.org/v1/countries?search=fr" \
-H "Authorization: Bearer sk_live_51H8x..."{
"status": "success",
"data": [
{ "code": "fr", "name": "France", "in_stock": 1245 },
{ "code": "ci", "name": "Côte d'Ivoire", "in_stock": 830 }
]
}/servicesList services
Returns the list of services (apps) available for a given country, with their price and availability.
| Parameter | Type | Required | Description |
|---|---|---|---|
| country | string | Yes | Country code (e.g. fr, us, ci). |
curl -X GET "https://api.atlas-sim.org/v1/services?country=fr" \
-H "Authorization: Bearer sk_live_51H8x..."{
"status": "success",
"data": [
{ "id": "whatsapp", "name": "WhatsApp", "price": 0.18, "available": true },
{ "id": "telegram", "name": "Telegram", "price": 0.15, "available": true }
]
}/ordersBuy a number
Instantly reserves and assigns a virtual number for the requested service and country. The corresponding amount is deducted from your balance.
| Parameter | Type | Required | Description |
|---|---|---|---|
| country | string | Yes | Desired country code. |
| service | string | Yes | Service identifier (e.g. whatsapp, telegram). |
| max_price | number | No | Maximum accepted price, to avoid price fluctuations. |
curl -X POST "https://api.atlas-sim.org/v1/orders" \
-H "Authorization: Bearer sk_live_51H8x..." \
-H "Content-Type: application/json" \
-d '{
"country": "fr",
"service": "whatsapp",
"max_price": 0.25
}'{
"status": "success",
"data": {
"id": "ord_9f83k2la",
"phone_number": "+33612345678",
"service": "whatsapp",
"country": "fr",
"price": 0.18,
"status": "pending",
"expires_at": "2024-06-01T12:34:56Z"
}
}/orders/{id}Order status
Returns the current status of an order as well as the received SMS code, if any.
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | string | Yes | Unique order identifier (in the URL). |
curl -X GET "https://api.atlas-sim.org/v1/orders/ord_9f83k2la" \
-H "Authorization: Bearer sk_live_51H8x..."{
"status": "success",
"data": {
"id": "ord_9f83k2la",
"status": "completed",
"phone_number": "+33612345678",
"sms_code": "482913",
"sms_text": "Votre code WhatsApp est 482913",
"received_at": "2024-06-01T12:31:02Z"
}
}/orders/{id}/cancelCancel an order
Cancels a pending order and fully refunds the corresponding balance, if no SMS has been received yet.
| Parameter | Type | Required | Description |
|---|---|---|---|
| id | string | Yes | Unique order identifier (in the URL). |
curl -X POST "https://api.atlas-sim.org/v1/orders/ord_9f83k2la/cancel" \
-H "Authorization: Bearer sk_live_51H8x..."{
"status": "success",
"data": {
"id": "ord_9f83k2la",
"status": "cancelled",
"refunded_amount": 0.18
}
}/ordersOrder history
Returns the paginated history of your orders, with the ability to filter by status or period.
| Parameter | Type | Required | Description |
|---|---|---|---|
| status | string | No | Filter by status: pending, completed, cancelled, expired. |
| page | number | No | Page number for pagination (default: 1). |
| limit | number | No | Number of results per page (default: 20, max: 100). |
curl -X GET "https://api.atlas-sim.org/v1/orders?status=completed&page=1&limit=20" \
-H "Authorization: Bearer sk_live_51H8x..."{
"status": "success",
"data": {
"page": 1,
"total": 132,
"orders": [
{ "id": "ord_9f83k2la", "service": "whatsapp", "country": "fr", "status": "completed", "price": 0.18 },
{ "id": "ord_7d21m4xz", "service": "telegram", "country": "us", "status": "expired", "price": 0.15 }
]
}
}Webhooks
Configure a webhook URL from your account area to receive order-related events in real time, instead of continuously polling the API.
Available events
order.createdA new order was created and a number was assigned.sms.receivedAn SMS code was received for an ongoing order.order.expiredAn order expired without receiving any SMS; the balance was refunded.balance.lowThe account balance dropped below the configured alert threshold.
Payload security
Every webhook request is signed with HMAC-SHA256 using your webhook secret key. The signature is provided in the X-AtlasSIM-Signature header and must be verified server-side before any processing.
X-AtlasSIM-Signature: sha256=7f1c3d9e0a4b2f8e6c5d1a9b3e7f0c2d{
"event": "sms.received",
"data": {
"order_id": "ord_9f83k2la",
"sms_code": "482913",
"sms_text": "Votre code WhatsApp est 482913",
"received_at": "2024-06-01T12:31:02Z"
}
}Retries
If your endpoint does not respond with a 2xx status code, AtlasSIM performs up to 5 retries with exponential backoff, over a 24-hour period.
Response codes and errors
The API uses standard HTTP status codes to indicate the success or failure of a request.
| Code | Meaning |
|---|---|
| 200 | Success. The request was processed correctly. |
| 201 | Resource successfully created (e.g. new order). |
| 400 | Invalid request: missing or malformed parameter. |
| 401 | Missing, invalid, or revoked API key. |
| 402 | Insufficient balance to perform the requested operation. |
| 404 | Resource not found (order, country, or service does not exist). |
| 409 | Conflict: the number or service is no longer available. |
| 429 | Too many requests: the rate limit has been exceeded. |
| 500 | Internal server error. Try again or contact support. |
Rate limits
Each API key is subject to a requests-per-minute limit depending on your plan.
| Plan | Limit | Allowed burst |
|---|---|---|
| Standard | 60 req/min | 100 req |
| Pro | 300 req/min | 500 req |
| Enterprise | Custom | Custom |
Exceeding the limit returns a 429 status code with a Retry-After header indicating the delay before the next allowed attempt.
SDK examples
Here is how to call the number purchase endpoint from different environments.
curl -X POST "https://api.atlas-sim.org/v1/orders" \
-H "Authorization: Bearer sk_live_51H8x..." \
-H "Content-Type: application/json" \
-d '{"country": "fr", "service": "whatsapp"}'Best practices and support
- Always cache the list of countries and services: it rarely changes and this reduces the number of requests.
- Use webhooks rather than polling to track incoming SMS in real time.
- Handle 429 errors with exponential backoff to respect rate limits.
- Never hard-code your API keys: use secure environment variables.
- Test your integrations with small amounts before deploying to production.
Need help?
Our technical team is available to support you with your integration.
