---
title: "Update map (layers, name, metadata, tile packs)"
method: PATCH
path: "/v1/maps/{id}"
tags: ["Maps"]
---

# Update map (layers, name, metadata, tile packs)

`PATCH /v1/maps/{id}`

## Request

- Base URL: `https://api.sprixen.com`
- URL: `https://api.sprixen.com/v1/maps/{id}`
- Auth: `bearer` (a scheme the document does not define)

## Path parameters

- `id` string, required

## Request body

- UpdateMapDto
  - `name` string
  - `description` string
  - `gridWidth` number
  - `gridHeight` number
  - `layers` object
  - `terrainWeights` object: Terrain weight map. Structure: { cells: [[{grass:1.0, dirt:0.0, ...}, ...], ...], materials: ["grass","dirt","sand","water","stone"] }
  - `metadata` object
  - `thumbnailUrl` string
  - `tilePackSlugs` string[]

## Response `200`

Map updated

## Other responses

- `403`: Access denied
- `404`: Map not found

---

[API](https://skmtc.dev/sprixen/apis/sprixen-api.md) · [All operations](https://skmtc.dev/sprixen/apis/sprixen-api/llms.txt) · [OpenAPI document](https://skmtc.dev/sprixen/apis/sprixen-api/revisions/6c0c57f6da58?raw)
