> ## Documentation Index
> Fetch the complete documentation index at: https://help.allthenticate.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Automate guest access for hotels with the API

> Use the Allthenticate API to manage hotel access: invite guests and staff, assign PINs and cards, group rooms, schedule doors and issue time-limited guest links.

Every call needs an API key. See [Allthenticate API](https://help.allthenticate.com/help/integrations/api.md) for how to create one and send it, and for the full reference with request and response schemas.

## Find your users

`GET /multipleusers` returns every user in your organization. Pass `user_tag=GUEST` to return only guest users.

Each user includes fields such as `email`, `email_id`, `first_name`, `last_name`, `groups` and `email_status`. Use `email_id` to identify a user in later calls.

## Invite guests and staff

People need to join your organization before they can use Allthenticate. `POST /invites` invites them.

| Parameter | Required | Description |
| - | - | - |
| `emails` | Yes | JSON array of email addresses, for example `["alex@example.com"]` |
| `smartcards` | No | JSON array with one smartcard entry per email, in the same order |
| `groups` | No | JSON array of groups to add everyone to, for example `[{"id": 2}]` |
| `no_email` | No | `true` to skip sending invitation emails |
| `allow_duplicates` | No | `true` to add a smartcard number even if another user already has it |

The response lists who was added, invited, already existed or was invalid, and `add_ids` with the new users' IDs. Unless you set `no_email`, each person receives an email with an invite link.

## Group users and doors

Groups let you manage access for many users or doors at once.

To create a group, call `POST /groups`:

| Parameter | Required | Description |
| - | - | - |
| `type` | Yes | `users` or `resources` |
| `name` | Yes | Name of the group |
| `add_ids` | No | JSON array of IDs to add: `email_id` values for users, `resource_id` values for doors |
| `resource_type` | No | For resource groups, `DOOR` or `COMPUTER` |

The response includes the new `group_id`.

To change a group's members, call `PUT /groups` with `type`, `group_id`, and `add_ids` or `del_ids` (JSON arrays of IDs).

## Assign PINs and smartcards

A PIN or card number lets someone open a door from a keypad or card reader connected to the ALL IN.

To set a user's PINs and cards, call `PUT /modifysmartcards`:

| Parameter | Required | Description |
| - | - | - |
| `email_id` | Yes | The user to update |
| `smartcards` | Yes | JSON array such as `[{"number": "1234", "label": "Room key"}]`. `label` is optional. This replaces the user's list; send `[]` to remove them all. |
| `allow_duplicates` | No | `true` to allow a number that another user already has |

To read a user's PINs and cards, call `GET /modifysmartcards` with `email_id`.

## Schedule doors

Schedules lock and unlock doors automatically at set times. Call `POST /schedules` to create one, or `PUT /schedules` with `schedule_id` to change one.

| Parameter | Required | Description |
| - | - | - |
| `schedule_name` | Yes | Name of the schedule; cannot be empty |
| `events` | Yes | JSON array of events (see below) |
| `resource_id` or `resource_group_id` | One of them | The door or door group to schedule. Pass exactly one. |
| `start_time` | No | When the schedule starts, as `YYYY-MM-DD HH:MM:SS` |
| `end_time` | No | When the schedule ends, as `YYYY-MM-DD HH:MM:SS` |

Each event has a `time` (`HH:MM:SS`), a true or false value for each day from `monday` to `sunday`, and an `event_type` (`0` unlock, `1` lock). Every event must run on at least one day.

```json theme={null}
[
  {"time": "08:00:00", "monday": true, "tuesday": true, "wednesday": true, "thursday": true, "friday": true, "saturday": false, "sunday": false, "event_type": 0},
  {"time": "18:00:00", "monday": true, "tuesday": true, "wednesday": true, "thursday": true, "friday": true, "saturday": false, "sunday": false, "event_type": 1}
]
```

## Create guest links

A guest link lets someone unlock specific doors from a web browser for a set period. Guests can open it anywhere; see [Unlock doors remotely](https://help.allthenticate.com/help/reader/remote-unlock.md) for how links behave.

To create one or more links, call `POST /magiclinkadmin`:

| Parameter | Required | Description |
| - | - | - |
| `email_list` | Yes | Emails to give the link to. Repeat the parameter for several. |
| `resource_id_list` | Yes | Door IDs the link unlocks. Repeat the parameter for several. Must be doors. |
| `end_time` | Yes | When the link expires, in UTC, as `YYYY-MM-DD hh:mm:ss` |
| `name` | Yes | Name of the access policy, to find it later |
| `start_time` | No | When the link becomes active, in UTC. Defaults to now. |
| `send_email` | No | `false` to not email the link. Defaults to `true`. |
| `config_id` | No | Configuration to apply to the link |
| `smartcards` | No | Smartcards to add, mapped one-to-one to the emails, such as `[{"label": "Room 12", "number": "1234"}]` |
| `allow_duplicates` | No | `true` to add a smartcard number even if another user already has it |
| `time_mapping` | No | Hours the link works on each day of the week. Defaults to 24/7. |

`time_mapping` is an array of seven days starting on Sunday, each a list of `[start_hour, end_hour]` ranges:

```text theme={null}
24/7:                       [[[0,24]], [[0,24]], [[0,24]], [[0,24]], [[0,24]], [[0,24]], [[0,24]]]
Weekdays 9 am to 5 pm:      [[], [[9,17]], [[9,17]], [[9,17]], [[9,17]], [[9,17]], []]
Weekdays 9-12 and 1-5 pm:   [[], [[9,12],[13,17]], [[9,12],[13,17]], [[9,12],[13,17]], [[9,12],[13,17]], [[9,12],[13,17]], []]
```

The response includes the `magic_token`, `email_ids` (each email mapped to its `email_id`), the `config_id` used, and the new `magic_link_id`.

For a quick link for one guest that is valid for 7 days, call `POST /quickmagiclink` with `email` and `resource_id` (a door).

Links expire at their end time. To revoke one earlier, call `DELETE /magiclinkadmin` with `magic_link_id`.

## Unlock doors directly

To lock or unlock a door from your own system, call `POST /setlock`:

| Parameter | Required | Description |
| - | - | - |
| `uuid` | Yes | UUID of the door |
| `lock_state` | Yes | `true` to lock, `false` to unlock |
| `unlock_time` | No | Seconds to keep the door unlocked, from 5 to 60. Values outside that range are clamped. |

The response reports the result of the request.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.