Freshness
GET
/v1/freshnessMonths between today and each country's newest finished period, worst first.
On every plan, Free includedKey requiredJSON or CSVCached until the next release
Parameters
| Name | Type | Description |
|---|---|---|
| freqoptional | M | Q | A query | Frequency: monthly, quarterly or annual e.g. M |
Request
# How many months behind each country is
curl "https://api.tourismapi.com/v1/freshness" \
-H "X-API-Key: $TOURISM_API_KEY"const res = await fetch("https://api.tourismapi.com/v1/freshness", {
headers: { "X-API-Key": process.env.TOURISM_API_KEY }
});
if (!res.ok) throw new Error(`Tourism API ${res.status}`);
const { meta, data } = await res.json();
console.log(meta.data_as_of, data);import os, requests
r = requests.get(
"https://api.tourismapi.com/v1/freshness",
headers={"X-API-Key": os.environ["TOURISM_API_KEY"]},
timeout=10,
)
r.raise_for_status()
body = r.json()
print(body["meta"]["data_as_of"], body["data"])$ch = curl_init("https://api.tourismapi.com/v1/freshness");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ["X-API-Key: " . getenv("TOURISM_API_KEY")],
]);
$body = json_decode(curl_exec($ch), true);
print_r($body["data"]);
Example response
{
"meta": {
"request_id": "req_9218e3d9ce",
"data_as_of": "2026-10-20T04:48:24Z",
"count": 125
},
"data": [
{
"iso": "KI",
"name": "Kiribati",
"latest": "2018-12",
"months_behind": 94
},
{
"iso": "KZ",
"name": "Kazakhstan",
"latest": "2022-10",
"months_behind": 48
},
{
"iso": "GM",
"name": "Gambia",
"latest": "2022-12",
"months_behind": 46
}
]
}Response fields
| Field | Type | Example |
|---|---|---|
| iso | string | KI |
| name | string | Kiribati |
| latest | string | 2018-12 |
| months_behind | number | 94 |