# Latency Global — llms.txt
## Overview
Latency Global is a SaaS platform for global latency and uptime monitoring with intelligent GeoDNS automation. It monitors HTTP/HTTPS, Ping, DNS, and SSL endpoints from 70+ global Points of Presence (PoPs), with 40 more coming soon, delivers multi-channel alerts, and can automatically update DNS records to route traffic to the optimal origin server based on real-time performance data.
## Key Links
- **Website:**
- **Pricing:**
- **Network / PoP Map:**
- **Free Tools:**
- **Contact:**
- **Terms of Service:**
- **Privacy Policy:**
## API
### Base URL
```
https://latency.global/api
```
All versioned endpoints are under `/api/v1/`.
### Versioning
The API uses URL-path versioning: `/api/v1/...`
### Resources
| Resource | Endpoints |
|----------|-----------|
| **Monitors** | `GET /v1/monitors`, `POST /v1/monitors`, `GET /v1/monitors/{id}`, `PUT /v1/monitors/{id}`, `PATCH /v1/monitors/{id}`, `DELETE /v1/monitors/{id}`, `GET /v1/monitors/{id}/results`, `GET /v1/monitors/{id}/stats` |
| **Alerts** | `GET /v1/alerts`, `POST /v1/alerts`, `GET /v1/alerts/{id}`, `PUT /v1/alerts/{id}`, `PATCH /v1/alerts/{id}`, `DELETE /v1/alerts/{id}` |
| **PoPs** | `GET /v1/pops`, `GET /v1/pops/{code}` (read-only) |
| **Probe** | `POST /v1/probe/ping`, `POST /v1/probe/traceroute`, `POST /v1/probe/mtr`, `POST /v1/probe/dns`, `POST /v1/probe/http-get`, `POST /v1/probe/https-get` |
| **Health** | `GET /api/health` (public, no auth) |
### Response Format
Success:
```json
{
"data": { ... },
"meta": { ... },
"links": { ... }
}
```
Error:
```json
{
"error": "Error Type",
"message": "Human-readable description",
"errors": { ... }
}
```
### HTTP Status Codes
| Code | Meaning |
|------|---------|
| 200 | Success |
| 201 | Created |
| 400 | Bad Request |
| 401 | Unauthorized (missing/invalid token) |
| 403 | Forbidden (plan limit reached) |
| 404 | Not Found |
| 422 | Validation Error |
| 429 | Rate Limit Exceeded |
| 500 | Server Error |
### Pagination
Page-based: use `page` and `per_page` query parameters (default `per_page`: 20 for monitors, 50 for results).
### Rate Limiting
Daily request limits by plan:
| Plan | Limit |
|------|-------|
| Starter ($5/mo) | 10,000 requests/day |
| Pro ($25/mo) | 100,000 requests/day |
| Business ($99/mo) | 1,000,000 requests/day |
Response headers:
- `X-RateLimit-Limit` — daily limit
- `X-RateLimit-Remaining` — requests remaining today
- `X-RateLimit-Reset` — timestamp when limit resets
## Auth
- **Scheme:** Bearer token
- **Header:** `Authorization: Bearer lat_`
- **Token creation:** Dashboard → API section → Create Token
- **Token prefix:** `lat_`
- **Token also accepted as:** query/body parameter `api_token`
## Webhooks
### Alert Webhooks
When monitor alerts trigger, configured webhook URLs receive:
```json
{
"alert_name": "Website Down",
"monitor_name": "My Website",
"monitor_url": "https://example.com",
"type": "down",
"status": "down",
"latency": null,
"checked_at": "2024-01-01T12:00:00Z",
"pop_location": "us-east-1",
"incident_id": 456
}
```
Alert channels: `email`, `webhook` (custom URL), `slack`.
## Common Tasks
- **Create a monitor:** `POST /api/v1/monitors` with `name`, `type` (http/https/ping/dns), `url`, `interval`
- **Check uptime stats:** `GET /api/v1/monitors/{id}/stats?days=7`
- **Get check results:** `GET /api/v1/monitors/{id}/results?from=...&to=...`
- **Run a ping from a global PoP:** `POST /api/v1/probe/ping` with `target`, `pop`
- **Run a traceroute:** `POST /api/v1/probe/traceroute` with `target`, `protocol`, `port`
- **DNS lookup from a PoP:** `POST /api/v1/probe/dns` with `name`, `type`, `resolver`
- **HTTP timing check:** `POST /api/v1/probe/http-get` with `url`
- **List all PoPs:** `GET /api/v1/pops`
- **Create an alert:** `POST /api/v1/alerts` with `monitor_id`, `type` (down/slow/ssl_expiring), `channels`
## Free Tools (No Auth Required)
| Tool | URL |
|------|-----|
| Global Ping Test | |
| Global HTTP Response Time Test | |
| DNS Propagation Checker | |
| SSL Certificate Checker | |
| HTTP Header Analyzer | |
| IP Geolocation Lookup | |
| Global Outage Map | |
## Examples & SDKs
### Code Examples
**cURL — list monitors:**
```bash
curl -X GET https://latency.global/api/v1/monitors \
-H "Authorization: Bearer lat_abc123..."
```
**cURL — create monitor:**
```bash
curl -X POST https://latency.global/api/v1/monitors \
-H "Authorization: Bearer lat_abc123..." \
-H "Content-Type: application/json" \
-d '{"name":"My API","type":"https","url":"https://api.example.com/health","interval":60}'
```
**Python:**
```python
import requests
headers = {"Authorization": "Bearer lat_abc123...", "Content-Type": "application/json"}
response = requests.get("https://latency.global/api/v1/monitors", headers=headers)
```
**JavaScript (Node.js):**
```javascript
const axios = require('axios');
const headers = { Authorization: 'Bearer lat_abc123...', 'Content-Type': 'application/json' };
axios.get('https://latency.global/api/v1/monitors', { headers }).then(res => console.log(res.data));
```
### WordPress Plugin
A WordPress plugin is available for integrating Latency Global monitoring into WordPress sites.
- **GitHub:**
- **Download (v1.0.0):**
Features:
- One-click monitor setup for WordPress sites
- Dashboard widget with uptime stats
- Shortcodes: `[latency_uptime]`, `[latency_status]`, `[latency_stats]`
- Built-in network tools (ping, HTTP, DNS)
### OpenAPI Specification
An OpenAPI 3.1.0 spec is available for the low-level probe endpoints: `/ping`, `/traceroute`, `/mtr`, `/dns`, `/http`, `/healthz`.
## Glossary
| Term | Definition |
|------|------------|
| **PoP** | Point of Presence — a globally distributed probe location that executes monitoring checks |
| **GeoDNS** | Automatic DNS record updates based on real-time latency data to route users to the optimal origin |
| **MTR** | My Traceroute — combines ping and traceroute into a single network diagnostic |
| **Probe** | A lightweight service deployed at each PoP that executes network checks (ping, HTTP, DNS, traceroute, MTR) |
| **Origin** | A backend server or endpoint being monitored; GeoDNS routes traffic between multiple origins |
| **Policy** | A GeoDNS automation rule that defines the strategy (performance, availability, balanced) and thresholds for DNS updates |
## Support / Contact
- **Email:** support@latency.global
- **Website:**
- **GitHub:**
- **LinkedIn:**
- **Twitter/X:**