API reference

AsiaSafe API

Live safety data for Southeast Asia: alerts, area safety scores, scams and hospitals. The public surface is keyless and licensed CC BY 4.0. Aggregate endpoints for partners are keyed.

Base URLs and auth

The public REST surface needs no credentials. Partner endpoints take an X-API-Key header. There are no request signing steps.

Public REST
https://api.thaisafe.app/v1
Keyless. CC BY 4.0.
Partner data
https://api.thaisafe.app/b2b
Header: X-API-Key.

Your first request

List active alerts. Every list response carries a data array and a pagination block.

request
curl https://api.thaisafe.app/v1/alerts?pageSize=2
200 response
{
  "success": true,
  "data": [
    {
      "id": "alr_8f21c0",
      "type": "weather",
      "severity": "high",
      "title": "Heavy rainfall warning",
      "description": "Flash flooding possible across low-lying districts.",
      "region": "chiang-mai",
      "latitude": 18.7883,
      "longitude": 98.9853,
      "isActive": true,
      "startTime": "2026-07-30T22:10:00Z",
      "endTime": null,
      "createdAt": "2026-07-30T22:12:04Z"
    }
  ],
  "pagination": { "page": 1, "pageSize": 2, "total": 37 }
}

Public endpoints

All relative to https://api.thaisafe.app/v1. List endpoints accept page and pageSize.

Endpoints under https://api.thaisafe.app/v1
GET/alertsActive safety alerts, paginated and sorted newest first.
GET/safety/hospitalsHospital directory with emergency contacts and 24h status.
GET/safety/scamsVerified tourist scams ranked by report frequency.
GET/safety/beachesBeach conditions: flag status, currents, water quality.
GET/weather/forecastCurrent conditions and 7-day forecast for a region.
GET/community/feedModerated community safety reports from travellers.
GET/newsRegional safety news, filterable by category and region.

Partner endpoints

Aggregate views relative to https://api.thaisafe.app/b2b. These need a partner key.

Endpoints under https://api.thaisafe.app/b2b
GET/data/safety-summaryActive alert, scam and report counts grouped by type.
GET/data/trendsIncident trends by week or month, filterable by type and region.
GET/data/heatmapAnonymised incident density points for mapping.
request
curl https://api.thaisafe.app/b2b/data/safety-summary \
  -H "X-API-Key: $ASIASAFE_KEY"

MCP server

A stateless remote MCP server exposes the same data to AI agents over JSON-RPC 2.0 at POST /mcp. Tools available:

get_region_safetylist_active_alertslookup_scamsfind_hospitalslist_regions
tools/call
curl https://api.thaisafe.app/mcp \
  -H "Content-Type: application/json" \
  -d '{
    "jsonrpc": "2.0",
    "id": 1,
    "method": "tools/call",
    "params": {
      "name": "get_region_safety",
      "arguments": { "region": "phuket" }
    }
  }'

Rate limits

SurfaceLimitAuth
Public REST (/v1)60 requests / minute per IPNone
MCP (/mcp)30 requests / minute per IPNone
Partner data (/b2b)1000 requests / minuteX-API-Key

Building on this?

See how tourism teams and insurers use the data, or request a partner key for production.