---
title: "Update a room"
method: PATCH
path: "/api/agents/{agentId}/rooms/{roomId}"
tags: ["rooms", "agents"]
---

# Update a room

`PATCH /api/agents/{agentId}/rooms/{roomId}`

## Request

- Base URL: `http://localhost:3000`
- URL: `http://localhost:3000/api/agents/{agentId}/rooms/{roomId}`
- Auth: none declared

Updates a specific room

## Path parameters

- `agentId` string, uuid, required
- `roomId` string, uuid, required

## Request body

- object
  - `name` string: New name for the room

## Response `200`

Room updated successfully

- object
  - `success` boolean
  - `data` Room
    - `id` string, uuid: Unique identifier for the room
    - `name` string: Name of the room
    - `source` string: Source of the room
    - `worldId` string, uuid: ID of the world this room belongs to
    - `entities` object[]: Entities in this room
      - `id` string, uuid
      - `name` string

## Other responses

- `400`: Invalid agent ID or room ID
- `404`: Agent or room not found
- `500`: Error updating room

---

[API](https://skmtc.dev/elizaos/apis/eliza-os-api.md) - [All operations](https://skmtc.dev/elizaos/apis/eliza-os-api/llms.txt) - [OpenAPI document](https://skmtc.dev/elizaos/apis/eliza-os-api/revisions/d606a12682bb?raw)
