---
title: "Get a unit"
method: GET
path: "/inventory/v1/units/{id}"
tags: ["Unit"]
---

# Get a unit

`GET /inventory/v1/units/{id}`

Get a unit by id.<br>You must have at least one of these scopes: 'units.read, setup.read, setup.manage'.

## Path parameters

- `id` string, required

## Query parameters

- `languages` string[]
- `expand` string[]

## Response `200`

Return all the unit data.

- UnitModel
  - `id` string, required — The unit id
  - `name` string, required — The name for the unit
  - `description` object, required — The description for the unit
  - `property` EmbeddedPropertyModel, required
    - `id` string, required — The property id
    - `code` string, nullable — The code for the property that can be shown in reports and table views
    - `name` string, nullable — The name for the property
    - `description` string, nullable — The description for the property
  - `unitGroup` EmbeddedUnitGroupModel
    - `id` string, required — The unit group id
    - `code` string, nullable — The code for the unit group that can be shown in reports and table views
    - `name` string, nullable — The name for the unit group
    - `description` string, nullable — The description for the unit group
    - `type` 'BedRoom' | 'MeetingRoom' | 'EventSpace' | 'ParkingLot' | 'Other', nullable — The unit group type
  - `connectingUnit` EmbeddedUnitModel
    - `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
  - `status` UnitStatusModel, required
    - `isOccupied` boolean, required
    - `condition` 'Clean' | 'CleanToBeInspected' | 'Dirty', required
    - `maintenance` UnitMaintenanceModel
      - `id` string, required — The id for the scheduled maintenance
      - `from` string, date-time, required — Date and time the scheduled maintenance window starts<br />A date and time (without fractional second part) in UTC or with UTC offset as defined in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO8601:2004</a>
      - `to` string, date-time, required — Date and time the scheduled maintenance window ends<br />A date and time (without fractional second part) in UTC or with UTC offset as defined in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO8601:2004</a>
      - `type` 'OutOfService' | 'OutOfOrder' | 'OutOfInventory', required — The type of maintenance that is planned for the unit. A small repair (OutOfService), a bigger disfunction that does not allow to sell the unit (OutOfOrder) or is it even under construction and should reduce the house count (OutOfInventory)
      - `description` string, nullable — The description text for the maintenance
  - `maxPersons` integer, required — Maximum number of persons for the unit
  - `created` string, date-time, required — Date of creation<br />A date and time (without fractional second part) in UTC or with UTC offset as defined in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO8601:2004</a>
  - `archived` string, date-time, nullable — Date when the unit was archived<br />A date and time (without fractional second part) in UTC or with UTC offset as defined in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO8601:2004</a>
  - `isArchived` boolean — Indicates whether the unit is archived. A unit is archived if the Archived property has a value.
  - `attributes` UnitAttributeModel[], nullable — Collection of user defined attributes of unit
    - `id` string, required — Id of unit attribute
    - `name` string, required — The name of the unit attribute
    - `description` string, nullable — Description of unit attribute
  - `connectedUnits` ConnectedUnitModel[], nullable — Collection of connected units
    - `id` string, required — The unit id
    - `name` string, required — The name for the unit
    - `description` string, required — The description for the unit
    - `unitGroupId` string, required — The unit group id
    - `condition` 'Clean' | 'CleanToBeInspected' | 'Dirty', required — The current status of the unit
    - `maxPersons` integer, required — Maximum number of persons for the unit
  - `actions` ActionModelUnitActionNotAllowedUnitActionReason[], nullable — The list of actions for this unit
    - `action` 'Delete' | 'Archive', required
    - `isAllowed` boolean, required
    - `reasons` ActionReasonModelNotAllowedUnitActionReason[], nullable
      - `code` 'DeleteNotAllowedOnArchivedUnit' | 'DeleteNotAllowedBecauseUnitIsReferenced' | 'DeleteNotAllowedBecauseUnitIsPartOfConnectingUnit' | 'DeleteNotAllowedBecauseUnitWasPartOfArchivedCombinedUnit' | 'UnitAlreadyArchived' | 'ArchiveNotAllowedBecauseUnitCanBeDeleted' | 'ArchiveNotAllowedBecauseAssignedToInHouseReservation' | 'ArchiveNotAllowedBecauseAssignedToFutureConfirmedReservation' | 'ArchiveNotAllowedBecauseLinkedToActiveOrFutureMaintenance' | 'ArchiveNotAllowedBecausePartOfCombinedInventory', required
      - `message` string, required

## 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.

---

[API](https://skmtc.dev/apaleo/apis/apaleo-inventory-api.md) · [All operations](https://skmtc.dev/apaleo/apis/apaleo-inventory-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/apaleo/apaleo-inventory-api/revisions/a2846f52cdfb/schema)
