/v1/images/static Generate flat map images server-side — from a bounding box, a centre point, or a coordinate set with GeoJSON overlays — with no browser, no WebGL, and no rendering pipeline.
One HTTP request returns a PNG or WebP image ready to embed in PDFs, emails, dashboards, reports, and notification cards. Pass route geometry as GeoJSON and it renders directly into the image — no client-side compositing required.
# Generate a 800×500 map centred on New Delhi
curl "https://api.farun.io/v1/images/static" \
-H "X-RapidAPI-Key: YOUR_KEY" \
-H "X-RapidAPI-Host: farun-maps.p.rapidapi.com" \
-G \
--data-urlencode "center=77.2090,28.6139" \
--data-urlencode "zoom=12" \
--data-urlencode "size=800x500" \
--data-urlencode "format=png" \
--output map.png
# Response: binary PNG — ready to embed or store Format
PNG or WebP
Max size
1280×1280 px
Overlay
GeoJSON supported
Output modes
Pass a centre point and zoom, a bounding box, or a GeoJSON geometry and let the API fit the frame automatically. Every mode returns a single image — no stitching, no post-processing.
?center=lon,lat&zoom=N Specify a longitude/latitude centre and a zoom level. The image is centred exactly on that coordinate. Ideal for place cards, location thumbnails, and address previews.
?bbox=west,south,east,north Pass a bounding box and the API fills the requested image dimensions to that extent. Useful for region overviews, service area maps, and coverage summaries where the area matters more than a fixed zoom.
?geojson=...&padding=N Pass a GeoJSON Feature or FeatureCollection and the API fits the frame to the geometry bounds with optional padding. Route lines, polygons, and point clusters are rendered directly into the image.
Who uses it
Static map images solve the problem of needing a map in a context where a live, interactive map is impossible — inside a PDF, an HTML email, a Slack notification, or a server-rendered report. One API call returns the image. No JavaScript required on the consuming side.
Fleet & Logistics
Attach a static route map to every completed trip report. Pass the route GeoJSON from the Routing API directly as an overlay — the image renders the full journey path on a clean map background, ready to embed in a PDF or email.
Insurance & Claims
Generate a map image centred on a reported incident coordinate for every claims document. Combine with terrain map layers for context on accident reports in hilly or mountainous areas.
Real Estate & Property
Generate a property location map for every listing page, valuation report, or agent brochure — server-side, without embedding a live map widget. Bounding-box mode auto-frames the neighbourhood.
Operations & Dispatch
Include a daily route map or zone coverage image in morning briefing emails. The Isochrone API generates the coverage polygon; pass it as GeoJSON to Static Images to produce a map card ready for any email client.
Developer Tools
Add a map thumbnail to any SaaS dashboard card, user profile, or activity feed item — without loading a full interactive map widget per card. One cached image per location, generated once and stored.
Marine & Field Ops
Generate a nautical or terrain chart image before a voyage or field mission — printable, offline-ready, and embeddable in mission briefing documents. Use the bbox parameter to frame the operational area precisely.
GeoJSON Overlays
Pass a GeoJSON Feature or FeatureCollection as a query parameter and the API renders it directly into the map image. Route lines, isochrone polygons, bounding areas, and point markers are all supported. No client-side compositing needed.
# 1. Get a route from the Routing API
ROUTE=$(curl -s "https://api.farun.io/v1/routing/directions" \
-d '{"origin":[77.20,28.61],"dest":[77.10,28.70]}' \
| jq '.geometry')
# 2. Pass the geometry to Static Images as an overlay
curl "https://api.farun.io/v1/images/static" \
-H "X-RapidAPI-Key: YOUR_KEY" \
-G \
--data-urlencode "geojson=$ROUTE" \
--data-urlencode "padding=60" \
--data-urlencode "size=900x500" \
--data-urlencode "overlay_color=%23ea580c" \
--data-urlencode "overlay_width=3" \
--output route-map.png overlay_color Hex colour for line/stroke
overlay_width Stroke width in pixels
fill_color Polygon fill colour + opacity
marker_color Point marker colour
Endpoint reference
https://api.farun.io/v1/images/static Query parameters
center zoom bbox geojson size format padding style retina Response codes
200 image/png or image/webp Map image. Cache using standard HTTP cache headers. 400 Bad request Missing or conflicting parameters (e.g. center + bbox together), or invalid GeoJSON. 401 Unauthorized Missing or invalid RapidAPI key. 413 Payload too large GeoJSON overlay exceeds the maximum allowed size. 422 Unprocessable Valid parameters but geometry falls outside supported coverage area. 429 Rate limited Request rate exceeds your plan. Upgrade on RapidAPI. Server-side integration
async function generateTripMap(
routeGeoJson: GeoJSON.LineString
): Promise<Buffer>
const params = new URLSearchParams(
geojson: JSON.stringify(routeGeoJson),
size: '900x500',
padding: '60',
format: 'webp',
overlay_color: '%23ea580c',
overlay_width: '3',
);
const res = await fetch(
`https://api.farun.io/v1/images/static?$${params}`,
{ headers: { 'X-RapidAPI-Key': process.env.RAPIDAPI_KEY } }
);
return Buffer.from(
await res.arrayBuffer()
);
} Always call this server-side. Never expose your RapidAPI key in client-side code. Generate the image on your backend and serve it as a static asset or embed it inline.
Output format
PNG or WebP
Max dimensions
1280 × 1280 px
Retina (2×)
Supported via ?retina=true
GeoJSON types
Point, Line, Polygon, Collection
Map styles
Standard, dark, nautical, terrain
Cache headers
Cache-Control: max-age=86400
How it compares
Both APIs generate server-side map images from coordinates and overlays. The differences are in pricing structure, GeoJSON support, private hosting, and offline tile use.
| Capability | Farun | Mapbox |
|---|---|---|
| Output formats | PNG + WebP | PNG + JPEG |
| GeoJSON overlay | Full FeatureCollection support | Limited — path and marker only |
| Auto-fit to geometry | Yes — geojson mode with padding | No — requires manual bbox |
| Nautical map style | Built-in farun-nautical style | Not available |
| Terrain / topo style | Built-in farun-terrain style | Satellite only |
| Retina (2x) support | Yes — ?retina=true | Yes — @2x suffix |
| Private hosting | Available for enterprise | Not available |
| Pricing model | Pay-as-you-go via RapidAPI | Mapbox account + map loads |
| Free tier | 500 images / month | 50,000 static tile requests / month |
Often used together
Generate a route LineString, then pass it directly as a GeoJSON overlay to render a trip map.
Generate a reachability polygon, then visualise the coverage area as a filled overlay on a static image.
Use vector tiles for interactive maps in the browser. Use Static Images for the same data in documents and emails.
Stitch raster tiles manually for precise tile-level control, or use Static Images for single-request simplicity.
Start building
Subscribe on RapidAPI for instant key access. The free tier covers 500 static map images per month — enough to build and test a complete report or notification pipeline.