Documentation menu
POST/styles/{spec}
Access and price
| Auth | An API key, as Authorization: Bearer snk_… or ?api_key=snk_…. Metered. Needs a full key; a browser (maps) key is refused. |
|---|---|
| Price | 1 call per request. Class: standard, or premium for truck and ADR work. Published as unit_rules.default in /pricing.json. |
| Premium | When the body asks for truck routing: "costing": "truck", a top-level adr object or "hazmat": true |
What it does
Publish a new immutable version of an existing style (existing versions are never modified).
An API key, as Authorization: Bearer snk_… or ?api_key=snk_…. Metered. Price: 1 call per request.
Call it
curl -fsS -X POST "https://api.mapmap.ai/styles/{spec}" \
-H "Authorization: Bearer $MAPMAP_KEY" \
-H "Content-Type: application/json" \
-d @request.jsonParameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| spec | path | string | yes | Style id |
Request body
application/json · UpdateStyleRequest
| Field | Type | Required | Description |
|---|---|---|---|
| theme | not stated | yes | The full sn-style theme document to publish as the next version. |
Responses
| Field | Type | Required | Description |
|---|---|---|---|
| id | string | yes | Style id. |
| style_url | string | yes | Immutable URL of the compiled style at this version. |
| version | integer | yes | The newly published, immutable version. |
Example: A response assembled from this schema's own field examples, enums, defaults and types; not a recorded call
{
"id": "string",
"style_url": "string",
"version": 0
}application/problem+json · Problem
unauthorized); the body carries signup, docs and a one-call hint for a free keyapplication/problem+json · Problem
X-PAYMENT). Not problem+jsonapplication/json · X402PaymentRequired
scope-insufficient), a request from an origin the key does not allow (origin-not-allowed), or an account restriction (forbidden)application/problem+json · Problem
application/problem+json · Problem
text/plain
problems list names the offending slot or layerapplication/problem+json · Problem
rate-limited, with Retry-After), or monthly quota exhausted with no payment path (quota-exceeded)application/problem+json · Problem
request-timeout)application/problem+json · Problem
Error bodies follow the shared problem model documented on API conventions.
Also under Tiles, styles and map assets
Generated from https://api.mapmap.ai/openapi.json on 2026-11-12 · operationId update_style