Render style
render_styleRender a MapLibre style to a PNG image to preview changes and receive diagnostics on style errors, failed requests, and missing icons. Accepts style as object, URL, or file path.
Instructions
Renders a MapLibre style to a PNG image, so you can see what the style looks like, for example after changing it. Also reports what the renderer noticed, such as style errors, failed requests and missing icons. Pass the style as an object, a URL or a file path. Without center, zoom or bounds, the camera stored in the style is used.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | URL of a style JSON document. | |
| path | No | Path to a style JSON file, relative to the directory the server runs in. | |
| zoom | No | ||
| pitch | No | Tilt in degrees from looking straight down. | |
| style | No | The style as a JSON object. | |
| width | No | ||
| bounds | No | [west, south, east, north] to fit the map to, instead of center and zoom. | |
| center | No | [longitude, latitude] of the map center. | |
| height | No | ||
| bearing | No | The compass direction at the top of the map, in degrees. | |
| renderer | No | The MapLibre renderer to draw with. | gl-js |