Skip to content

Output formats

PNG

PNG is the documented output of the current TypeScript rendering route. It is suitable for print placement, PDF generation, report attachments, previews, and downstream pixel-based processing.

Clients should verify both the HTTP status and response Content-Type before treating the body as an image.

SVG is experimental

The Rust endpoint accepts format=image/svg+xml or format=svg, but its current implementation first renders a raster image and then serializes runs of equal-colour pixels as SVG rectangles.

That means the result:

  • Scales as an SVG document container.
  • Is not semantic vector cartography.
  • Does not preserve roads, labels, or polygons as editable source features.
  • Is limited to 512 × 512 rendered pixels in the current Rust source.
  • Can become large or complex for detailed maps.

Do not advertise this as true vector artwork. PNG should remain the public default unless the SVG behavior is redesigned and benchmarked for a specific use case.

Transparency and colour

Output characteristics depend on the style and renderer. Test transparent backgrounds, colour profiles, label edges, and print conversion in the actual publishing workflow. DPI metadata and visual scaling are different concerns; confirm both when a receiving application relies on physical dimensions.