Maps API

Embeddable HTML viewer

Added in v1.0.0
GET http://localhost:3650/api/maps/{mapId}/

Request

Path Parameters

Parameters Type Description
mapId
string
Identifier of the map. See MapTiler Server Maps.
Example: streets
Added in v1.0.0
Request example

  http://localhost:3650/api/maps/streets/

Responses

Code Content Description
200 text/html
404

The item does not exist

Style JSON of the map

Added in v1.0.0
GET http://localhost:3650/api/maps/{mapId}/style.json

Style JSON describing the map cartography. Can be used with various libraries to display a vector map (e.g. Mapbox GL JS, OpenLayers, ...).

Request

Path Parameters

Parameters Type Description
mapId
string
Identifier of the map. See MapTiler Server Maps.
Example: streets
Added in v1.0.0
Request example

  http://localhost:3650/api/maps/streets/style.json

Responses

Code Content Description
200 application/json Style JSON object https://docs.mapbox.com/mapbox-gl-js/style-spec/ StyleJSON Object
404

The item does not exist

Map symbols (sprites)

Added in v1.0.0
GET http://localhost:3650/api/maps/{mapId}/sprite{scale}.{format}

Map symbols (sprites) required to display the vector map.

Request

Path Parameters

Parameters Type Description
mapId
string
Identifier of the map. See MapTiler Server Maps.
Example: streets
Added in v1.0.0
scale
string
Allowed values: @2x
Added in v1.0.0
format
string
Allowed values: png json
Added in v1.0.0
Request example

  http://localhost:3650/api/maps/streets/sprite.png

Responses

Code Content Description
200 application/json
200 image/png
404

The item does not exist

Raster XYZ tiles

Added in v1.0.0
GET http://localhost:3650/api/maps/{mapId}/{tileSize}/{z}/{x}/{y}{scale}.{format}

Rasterized tiles (XYZ) of the map. Can be used with various libraries to display a raster map (e.g. Leaflet, OpenLayers, ...). It's usually better (if possible) to use the TileJSON rather than using the tile URL directly.

Request

Path Parameters

Parameters Type Description
mapId
string
Identifier of the map. See MapTiler Server Maps.
Example: streets
Added in v1.0.0
tileSize
integer
Allowed values: 256
Added in v1.0.0
z
integer
Added in v1.0.0
x
integer
Added in v1.0.0
y
integer
Added in v1.0.0
scale
string
Use “@2x” to get “retina”/HiDPI image.
Allowed values: @2x
Added in v4.2.0
format
string
The value depends on the Map settings.
Allowed values: png jpg webp
Added in v4.2.0
Request example

  http://localhost:3650/api/maps/streets/10/536/358.png

Responses

Code Content Description
200 image/*
400

Out of bounds / Invalid format

404

The item does not exist

TileJSON

Added in v1.0.0
GET http://localhost:3650/api/maps/{mapId}/{tileSize}/tiles.json

TileJSON describing the metadata of the map as well as link to the XYZ tiles. Can be used with various libraries to display a raster map (e.g. Leaflet, OpenLayers, ...).

Request

Path Parameters

Parameters Type Description
mapId
string
Identifier of the map. See MapTiler Server Maps.
Example: streets
Added in v1.0.0
tileSize
integer
Allowed values: 256
Added in v1.0.0
Request example

  http://localhost:3650/api/maps/streets/tiles.json

Responses

Code Content Description
200 application/json https://raw.githubusercontent.com/mapbox/tilejson-spec/master/2.2.0/schema.json TileJSON Object
404

The item does not exist

WMTS Capabilities

Added in v1.0.0
GET http://localhost:3650/api/maps/{mapId}/WMTSCapabilities.xml

WMTS Capabilities XML document describing the metadata of the map as well as link to the XYZ tiles. Can be used with various GIS software (e.g. QGIS) to display the map.

Request

Path Parameters

Parameters Type Description
mapId
string
Identifier of the map. See MapTiler Server Maps.
Example: streets
Added in v1.0.0
Request example

  http://localhost:3650/api/maps/streets/WMTSCapabilities.xml

Responses

Code Content Description
200 text/xml
404

The item does not exist

WMTS Capabilities for all layers

Added in v1.0.0
GET http://localhost:3650/api/WMTSCapabilities.xml

WMTS Capabilities XML document describing the metadata of all map layers as well as link to the XYZ tiles. Can be used with various GIS software (e.g. QGIS) to display the map.

Request

Request example

  http://localhost:3650/api/WMTSCapabilities.xml

Responses

Code Content Description
200 text/xml
404

The item does not exist

WMS Capabilities

Added in v4.2.0
GET http://localhost:3650/api/maps/{mapId}/wms?service=WMS&request=GetCapabilities

WMS Capabilities XML document describing the metadata of the map. Can be used with various GIS software (e.g. QGIS) to display the map.

Request

Path Parameters

Parameters Type Description
mapId
string
Identifier of the map. See MapTiler Server Maps.
Example: streets
Added in v4.2.0
Request example

  http://localhost:3650/api/maps/streets/wms?service=WMS&request=GetCapabilities

Responses

Code Content Description
200 text/xml
404

The item does not exist

WMS Capabilities for all layers

Added in v4.2.0
GET http://localhost:3650/api/maps/wms?service=WMS&request=GetCapabilities

WMS capabilities XML document describing the metadata of all map layers. Can be used with various GIS software (e.g. QGIS) to display the map.

Request

Request example

  http://localhost:3650/api/maps/wms?service=WMS&request=GetCapabilities

Responses

Code Content Description
200 text/xml
404

The item does not exist