Version 1 · maps and tiles
ChertMap tile API
Vector tiles, map styles, fonts, raster tiles and static map images for Saudi Arabia, served by ChertMap from its own servers.
Base address
All addresses start with https://tiles.chertmap.com/v1. The API is read-only: GET, HEAD and OPTIONS. Cross-origin requests are allowed. Coordinates are WGS84, longitude before latitude.
Access is open in this version: no key is sent. API keys, scopes and quotas arrive with the ChertMap API gateway in a later release, so write your integration so that a key can be added.
Endpoints
| What | Address | Returns |
|---|---|---|
| Style list | /styles.json | JSON |
| Map style | /styles/{theme}-{language}.json | MapLibre style. Themes: standard, light, dark. Languages: ar, en |
| Tileset description | /tiles/{tileset}.json | TileJSON 3.0.0 |
| Vector tile | /tiles/{tileset}/{z}/{x}/{y} | Mapbox Vector Tile, gzip |
| Glyphs | /fonts/{fontstack}/{start}-{end}.pbf | Glyph range (256 code points) |
| Sprites | /sprites/{light|dark}[@2x].{json|png} | Sprite sheet |
| Raster tile | /raster/{style}/{z}/{x}/{y}[@2x].{png|jpg|webp} | 256 px image (512 px with @2x) |
| Static map | /static-map/{style}/{lon},{lat},{zoom}[@{bearing}[,{pitch}]]/{width}x{height}[@2x].{png|jpg|webp} | Image, up to 2048 px a side |
| Layer catalogue | /layers.json | Data layers, with availability |
| Data releases | /datasets.json | Current and previous data release |
| Status | /status.json | API version and data release in use |
Tilesets
| Tileset | Content | Zooms |
|---|---|---|
basemap | Saudi Arabia: land, water, land use, roads, buildings, boundaries, places, points of interest | 0–15 |
world | World outline: land, water, country borders, country and city names | 0–5 |
regions | The 13 regions of Saudi Arabia | 0–15 |
governorates | Governorates of Saudi Arabia | 0–15 |
cities | Cities and towns, with population where recorded | 0–15 |
poi | Places by category: ?category=mosques|health|education|fuel|food|finance. Below zoom 13 nearby places are returned as one point with point_count | 4–16 |
Names are in name_ar and name_en in the overlay tilesets, and in name, name:ar, name:en in the basemap. The basemap follows the Protomaps basemap layer schema, version 4.
Show a map
Use any renderer that reads MapLibre styles. With MapLibre GL JS, served from your own site:
<!doctype html>
<link rel="stylesheet" href="maplibre-gl.css">
<div id="map" style="height:480px"></div>
<script type="module">
import maplibregl from "./maplibre-gl.mjs";
// right-to-left text: register an RTL text module with maplibregl.setRTLTextPlugin(...) before creating the map
const map = new maplibregl.Map({
container: "map",
style: "https://tiles.chertmap.com/v1/styles/standard-en.json",
center: [46.7167, 24.6877], // longitude, latitude
zoom: 10
});
</script>
Images
A static map of central Riyadh, 600 by 400 pixels: https://tiles.chertmap.com/v1/static-map/standard-en/46.7167,24.6877,11/600x400.png
A raster tile: https://tiles.chertmap.com/v1/raster/standard-ar/6/39/27.png
Credit you must show
The map data is OpenStreetMap data under the Open Database License. Every map you show from this API must display © OpenStreetMap contributors, linked to https://www.openstreetmap.org/copyright where a link is possible. The supplied styles and TileJSON carry this credit; static images have it drawn in.
Data and coverage
Detailed coverage is Saudi Arabia. Outside it, only the world outline is available. /datasets.json gives the release in use and the date of the OpenStreetMap data behind it. Completeness follows OpenStreetMap and varies by region.
Not part of this version: search and geocoding, routing, traffic, public transport, satellite imagery, terrain, street-level imagery and the National Address. /layers.json lists them as unavailable.
Errors and caching
Errors are JSON: {"error":{"code":"not_found","message":"…"}}. A tile with no data returns 204. Responses carry Cache-Control; tiles may be cached for one hour.