Maps API

Maps API reference

Scalar API Reference
v4.8.0
OpenAPI 3.1.0

MapTiler Server API

Server:http://localhost:3650/api

MapTiler Server API

Client Libraries

Maps

Embeddable HTML viewer

Path Parameters
  • mapId
    Type: string
    required

    Identifier of the map. See MapTiler Server Maps http://localhost:3650/admin/.

Responses
  • text/html
  • 404

    The item does not exist

Request Example for get/maps/{mapId}/
curl http://localhost:3650/api/maps/streets/
No Body

Style JSON of the map

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

Path Parameters
  • mapId
    Type: string
    required

    Identifier of the map. See MapTiler Server Maps http://localhost:3650/admin/.

Responses
  • application/json
  • 404

    The item does not exist

Request Example for get/maps/{mapId}/style.json
curl http://localhost:3650/api/maps/streets/style.json
{}

Map symbols (sprites)

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

Path Parameters
  • mapId
    Type: string
    required

    Identifier of the map. See MapTiler Server Maps http://localhost:3650/admin/.

  • scale
    enum
    const:  
    @2x

    Use "@2x" to get "retina"/HiDPI image.

    values
    • @2x
  • format
    Type: string enum
    required
    values
    • png
    • json
Responses
  • 404

    The item does not exist

Request Example for get/maps/{mapId}/sprite{scale}.{format}
curl http://localhost:3650/api/maps/streets/sprite@2x.png
No Body

Raster XYZ tiles

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.

Path Parameters
  • tileSize
    enum
    const:  
    256

    Integer numbers.

    values
    • 256
  • z
    Type: integer
    required

    Zoom level. Specifies the tile's zoom level. See Tiles à la Google Maps

  • x
    Type: integer
    required

    Column. Specifies the tile's column. See Tiles à la Google Maps

  • y
    Type: integer
    required

    Row. Specifies the tile's row. See Tiles à la Google Maps

  • scale
    enum
    const:  
    @2x

    Use "@2x" to get "retina"/HiDPI image.

    values
    • @2x
  • format
    Type: string enum
    required

    The value depends on the Map settings.

    values
    • png
    • jpg
    • webp
  • mapId
Responses
  • image/*
  • 400

    Out of bounds / Invalid format

  • 404

    The item does not exist

Request Example for get/maps/{mapId}/{tileSize}/{z}/{x}/{y}{scale}.{format}
curl 'http://localhost:3650/api/maps/{mapId}/256/1/1/1@2x.png'
@filename

TileJSON

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, ...).

Path Parameters
  • mapId
    Type: string
    required

    Identifier of the map. See MapTiler Server Maps http://localhost:3650/admin/.

  • tileSize
    enum
    const:  
    256

    Integer numbers.

    values
    • 256
Responses
  • application/json
  • 404

    The item does not exist

Request Example for get/maps/{mapId}/{tileSize}/tiles.json
curl http://localhost:3650/api/maps/streets/256/tiles.json
{}

OGC API - Tiles

Tileset landing page of the rasterized tiles. Can be used in software supporting the OGC API - Tiles v1.0 specification.

Path Parameters
  • mapId
    Type: string
    required

    Identifier of the map. See MapTiler Server Maps http://localhost:3650/admin/.

Responses
  • application/json
  • 404

    The item does not exist

Request Example for get/maps/{mapId}/tiles
curl http://localhost:3650/api/maps/streets/tiles
string

OGC API TileMatrixSets

Description of the tileset tile matrix sets according to the OGC Web API. This resource is linked from the OGC API - Tiles endpoint.

Path Parameters
  • mapId
    Type: string
    required

    Identifier of the map. See MapTiler Server Maps http://localhost:3650/admin/.

Responses
  • application/json
  • 404

    The item does not exist

Request Example for get/maps/{mapId}/tileMatrixSet
curl http://localhost:3650/api/maps/streets/tileMatrixSet
string

WMTS Capabilities

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.

Path Parameters
  • mapId
    Type: string
    required

    Identifier of the map. See MapTiler Server Maps http://localhost:3650/admin/.

Responses
  • text/xml
  • 404

    The item does not exist

Request Example for get/maps/{mapId}/WMTSCapabilities.xml
curl http://localhost:3650/api/maps/streets/WMTSCapabilities.xml
string

WMTS Capabilities for all layers

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.

Responses
  • text/xml
  • 404

    The item does not exist

Request Example for get/WMTSCapabilities.xml
curl http://localhost:3650/api/WMTSCapabilities.xml
string

WMS Capabilities

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

Path Parameters
  • mapId
    Type: string
    required

    Identifier of the map. See MapTiler Server Maps http://localhost:3650/admin/.

Responses
  • text/xml
  • 404

    The item does not exist

Request Example for get/maps/{mapId}/wms?service=WMS&request=GetCapabilities
curl 'http://localhost:3650/api/maps/streets/wms?service=WMS&request=GetCapabilities'
string

WMS Capabilities for all layers

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.

Responses
  • text/xml
  • 404

    The item does not exist

Request Example for get/maps/wms?service=WMS&request=GetCapabilities
curl 'http://localhost:3650/api/maps/wms?service=WMS&request=GetCapabilities'
string
Using the OpenAPI Specification?
Get the openapi.yaml
Was this helpful?
MapTiler Server API
Maps API | MapTiler Server API
Maps API