# Directory card

> Canonical HTML: https://screenrig.ai/docs/cards/directory/

A building directory: tenants, departments or people with their floor and suite, in a table that pages by itself.

Category: People. Tags: Wayfinding and directories, Lobbies and reception, Offices and workplaces, Healthcare.

## Previews

![Directory](/cards/directory/v1/screenshots/canvas-bloom.webp?sha=4fca9c2b849046920ff1a1eca170c3e8a5ba96a460cf1fd611dd49d7cabe8fb9)

Canvas

![Directory](/cards/directory/v1/screenshots/corner-bloom.webp?sha=ea6686739591916ed1fb7bfe7460055648d77d1ad47ced811cc8088b21369fa0)

Corner

![Directory](/cards/directory/v1/screenshots/chip-bloom.webp?sha=46ea85af93a52e0f2ad5ca1ae3601a84f643f7a716fd23624a66e7ac04e366f7)

Chip

## Views and forms

Views: canvas, corner, chip. Canvas forms: landscape, portrait, square, strip.

[Card views, themes and publishing](/docs/cards/). [Browse the gallery](/apps/#cards).

## Data and privacy

This card uses its configured properties and live card data.

## Properties

For theme, background, accent and position, see [Common properties](/docs/cards/#common-properties).

Set static properties in `params`. Bind `data` to a project card data key for live values; that document holds only dynamic properties. Without a data key, put the complete configuration in `params`. Nested rows describe the contents of their parent property.

### Static properties

| Name | Type | Default | Values and limits | Description |
| --- | --- | --- | --- | --- |
| `title` | string | `"Directory"` | maxLength: `40` |  |
| `order` | string | `"name"` | `"name"`, `"floor"`, `"listed"` | name: A to Z. floor: lowest floor first, then A to Z. listed: as given. |
| `rowsPerPage` | integer | `6` | minimum: `3`; maximum: `16` | Rows on a page of the canvas view. |
| `pageSeconds` | integer | `12` | minimum: `4`; maximum: `60` | Seconds each page stays up. |
| `floorLabel` | string | `"Floor"` | maxLength: `12` |  |
| `suiteLabel` | string | `"Suite"` | maxLength: `12` |  |

### Dynamic properties

| Name | Type | Default | Values and limits | Description |
| --- | --- | --- | --- | --- |
| `entries` | array | `[]` | minItems: `0`; maxItems: `200` |  |
| `entries[].name` | string |  | minLength: `1`; maxLength: `60`; Required |  |
| `entries[].detail` | string | `""` | maxLength: `60` | A line under the name: a trade, a department, a role. |
| `entries[].floor` | string | `""` | maxLength: `12` | A number reads as "Floor 3"; any other text ("Ground", "Lobby") is shown as written. |
| `entries[].suite` | string | `""` | maxLength: `12` | A suite with a digit reads as "Suite 305"; any other text is shown as written. |
| `footnote` | string | `""` | maxLength: `120` |  |

## Canvas example

Add this item to a playlist page’s `primitives`. [Publish the playlist and assign a screen](/docs/cards/#publish-a-card-canvas).

```json
{
  "id": "directory",
  "primitive": "card",
  "card": "directory",
  "major": 1,
  "params": {
    "theme": "neomustard"
  },
  "rect": {
    "x": 0,
    "y": 0,
    "width": 1920,
    "height": 1080
  },
  "layer": 0,
  "content_fit": "fill",
  "data": "directory-main"
}
```

## Write live data

Create this document before showing the card, then replace it to update the screen without republishing. Use the same project as the playlist. Supply your API authorization through the environment; see [API authentication](/docs/authentication/).

```console
curl --request PUT "https://api.screenrig.ai/api/card-data/directory-main" \
  --header "Authorization: Bearer $SCREENRIG_TOKEN" \
  --header "ScreenRig-Project: $SCREENRIG_PROJECT" \
  --header "Content-Type: application/json" \
  --data '{"document":{"entries":[],"footnote":""}}'
```
