MapScale Docs
•••
Try it · Live

Map sandbox

Style a live map, highlight an area and place objects on it — then copy the code that produced what you are looking at.

What you’ll achieve

Every control here maps onto a documented API parameter or a MapLibre call, so nothing you copy is sandbox-only.

Language, accent colour and layer visibility are query parameters on GET /styles/v1/streets. Changing one fetches a new style document from the API.

Label language
Layer groups
Code for this map
const map = new maplibregl.Map({
  container: "map",
  style: "https://api.mapscale.io/styles/v1/streets?key=YOUR_PUBLISHABLE_KEY&lang=th&accent=0f766e",
  center: [100.5018, 13.7563],
  zoom: 11
})

// lang, accent and hide are style parameters — the server returns a
// different style document, so there is nothing to restyle client-side.

The style URL

Everything in the styling tab is one of these query parameters. The server assembles the style document; the browser does not restyle anything.

LIVE API PLAYGROUND

Sign in or create an account

Continue to run live requests directly from the docs.

Edit the inputs, send a real request, and inspect the live response.

Editable inputs

6 possible values
Request preview
curl \
  -H "X-MapScale-Key: $MAPSCALE_API_KEY" \
  "https://api.mapscale.io/styles/v1/streets?lang=th"
Live response
Default response
{
  "status": "200",
  "contentType": "application/json",
  "description": "A MapLibre style document."
}

On this page