crate::srv
Render a static map image with optional vector overlays. See [our documentation](https://maplibre.org/martin/sources-styles/) for the supported overlay body -- a `GeoJSON` `FeatureCollection` with style properties on each feature.
An empty or missing body renders the base map alone.
post/style/{style_id}/static/{camera}/{size}.{format}
Path parameters
style_idstring required
camerastring required
lon,lat,zoom[@bearing[,pitch]] or minLon,minLat,maxLon,maxLat.
sizestring required
WIDTHxHEIGHT[@SCALEx] - e.g. 800x600 or 400x300@2x.
format'png' | 'jpg' | 'webp' required
Image format requested in the URL.
Output encoding. png, jpg, or webp (canonical names only; .jpeg is redirected to .jpg via [redirect_static_jpeg]).
Request body
Example request
{
"features": [
{
"properties": {
"circle-color": "#285DAA",
"circle-radius": 8,
"fill-color": "#95BEFA",
"line-cap": "round",
"line-color": "#285DAA",
"line-join": "round",
"line-width": 2
}
}
]
}Response
Rendered static map image