---
title: "Assign a specific unit to a reservation."
method: PUT
path: "/booking/v1/reservation-actions/{id}/assign-unit/{unitId}"
tags: ["ReservationActions"]
---

# Assign a specific unit to a reservation.

`PUT /booking/v1/reservation-actions/{id}/assign-unit/{unitId}`

## Request

- Base URL: `https://api.apaleo.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.apaleo.com/booking/v1/reservation-actions/{id}/assign-unit/{unitId}`
- Auth: OAuth 2
  - Implicit: `https://identity.apaleo.com/connect/authorize`
  - Scopes: `reservations.assign-unit`, `reservations.manage`, `admin`

Assigns a specific unit to a reservation which is in state 'Confirmed' or 'InHouse'.
If the unit is not available, the call will return an error, and no unit will be assigned.<br>You must have at least one of these scopes: 'reservations.assign-unit, reservations.manage'.<br>For fine-grained clients, you must have this permission: 'core.reservations.modify'.

## Path parameters

- `id` string, required
- `unitId` string, required

## Query parameters

- `from` string
- `to` string
- `lockUnit` boolean

## Response `200`

Unit assignment was successful.

- AssignedUnitModel
  - `unit` EmbeddedUnitModel, required
    - `id` string, required: The unit id
    - `name` string, nullable: The name for the unit
    - `description` string, nullable: The description for the unit
    - `unitGroupId` string, nullable: The unit group id

## Other responses

- `400`: Bad request.
- `401`: You are unauthorized.
- `403`: Forbidden.
- `404`: The Request-URI could not be found.
- `422`: Validation errors in the request body or query params.
- `499`: Client closed request.
- `500`: An unexpected error occurred.
- `503`: The server is currently unavailable. Please try later.

## Changes

> 6 revisions in range; 1 not diffed.

- **2026-09-01** `6510a7df7143`: 2 info
  - added the new optional `query` request parameter `lockUnit`
  - added the non-success response with the status `499`

[Operation history](https://skmtc.dev/apaleo/apis/apaleo-booking-api/changes/booking/v1/reservation-actions/:id/assign-unit/:unitId/put.md)

---

[API](https://skmtc.dev/apaleo/apis/apaleo-booking-api.md) - [All operations](https://skmtc.dev/apaleo/apis/apaleo-booking-api/llms.txt) - [OpenAPI document](https://skmtc.dev/apaleo/apis/apaleo-booking-api/revisions/0d255d2a27e9?raw)
