# Entities

### Device

A `Device` represents a single ParqEx Access Controller. Each device can have one or more `Door` (depending on the model. see below what a single-door entity looks like). The attributes of a `Device` are as follows:

| Attribute Name                  | Data Type                           | Description                                                               |
| ------------------------------- | ----------------------------------- | ------------------------------------------------------------------------- |
| `id`                            | UUID                                | Unique identifier of the `Device`                                         |
| `number_of_entities_controlled` | Integer                             | *1-100*                                                                   |
| `doors`                         | Object                              | An object array of `Door`s (see below)                                    |
| `last_contact`                  | Timestamp (eg. YYYY-MM-DD HH:MM:SS) | Timestamp of the last time the `Device` reached out to the ParqEx service |
| `active`                        | Boolean                             | **true** if `Device` is enabled/authorized by ParqEx, **false** otherwise |
| `registered`                    | Boolean                             | **true** if `Device` is registered with ParqEx, **false** otherwise       |

### Door

A `Door` represents a single access control point (pedestrian door, garage door, elevator button etc.) opener connected to a ParqEx Controller. A `Door` must belong to a device. The attributes of a device are as follows:

| Attribute Name      | Data Type                           | Description                                                                                                                               |
| ------------------- | ----------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
| `id`                | UUID                                | Unique identifier of the `Door`                                                                                                           |
| `image`             | String                              | *Deprecated*                                                                                                                              |
| `light`             | Boolean                             | *Deprecated*                                                                                                                              |
| `sensor`            | Boolean                             | *Deprecated*                                                                                                                              |
| `last_toggled`      | Timestamp (eg. YYYY-MM-DD HH:MM:SS) | Timestamp of the last time the `Device` reported a `Door` state change                                                                    |
| `name`              | String                              | A name assigned by the user. Every user can set their own unique names.                                                                   |
| `active`            | Boolean                             | **true** if the `Door` has been registered to a `Device`, **false** otherwise                                                             |
| `state`             | Enum                                | Either “OPEN” or “CLOSED”. Represents current state of door.                                                                              |
| `user_relationship` | String                              | “Owner” if the current user is the admin of the `Device`, “Has Access” otherwise (see [Permissions](broken://pages/-MP2Ba1_GDtzgd6emWr6)) |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.parqex.com/-MUyxAVrX9S4wky8UoX6/the-basics/entities.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
