Export Map Style Endpoint
const url = 'https://example.com/maps/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/style.json';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/maps/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/style.jsonExport a saved map as a complete MapLibre style JSON document.
Authorizations
Section titled “ Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”Responses
Section titled “ Responses ”A complete MapLibre style document for the saved map. Its shape is governed by the MapLibre Style Specification (https://maplibre.org/maplibre-style-spec/) and is not mirrored field-by-field in this contract. One guarantee beyond the spec: sprite is always emitted in the array form [{id, url}], which POST /maps/import also accepts, so exported documents round-trip.
MapLibre style document (https://maplibre.org/maplibre-style-spec/)
object
Example generated
{}Bad request — invalid payload
Unauthorized — missing or invalid credentials
Forbidden — caller lacks access to this resource
Not found
Conflict — resource state prevents the operation
Validation error
Too many requests — retry after the advertised interval
Headers
Section titled “ Headers ”Seconds until the request may be retried
Internal server error
Service unavailable — the database could not serve the request