# Admin panel

Run your instance from the admin panel at /admin, with its own sign-in, roles and audit log.

The admin panel is for the people who run an opendesk instance, not for the people who work in it. You find people and workspaces, end a stolen session, suspend an account or a workspace that abuses the instance, raise a workspace's limits, retry background jobs and check the instance's health. Every action is in the panel's own audit log.

A self-hosted instance serves it at `https://desk.example.com/admin/`. It talks to the same API as the app but has its own sign-in and sessions: being an owner of a workspace gives no access to it, and signing in to it never signs you in or out of the app.

## The first admin

Nobody is an admin until you make someone one from the command line, on the machine that runs opendesk. The person signs up in the app first.

```sh
cd /opt/opendesk
docker compose exec opendesk /opendesk admin grant you@example.com
docker compose exec opendesk /opendesk admin list
```

After that, a super admin adds the others from **Admins** in the panel. `opendesk admin revoke <email>` removes an admin and ends their panel sessions, even when nobody can sign in.

## Signing in

The panel asks for your email, password and a code from your authenticator app every time. Before you can sign in:

- Turn on two-factor authentication in the app, under **Settings > Security**.
- Have a password. If you only sign in with Google, Microsoft, GitHub or SSO, set one with **Forgot password** on the sign-in page.

A panel session ends an hour after you last used it, and 12 hours after you signed in whatever you do. Turning off a user's two-factor authentication, deleting a user or a workspace and changing the admins ask for a fresh code.

## Roles

| Role | Can |
| --- | --- |
| Viewer | See every page |
| Support | Also sign users out, resend the confirmation email, suspend and restore users and workspaces, change a workspace's limits, grant AI usage and give a complimentary plan, retry and cancel jobs |
| Super | Also turn off a user's two-factor authentication, delete users and workspaces, manage admins, and publish website policies |

The role is checked on every request, so removing or downgrading an admin takes effect at once. There is always at least one super admin.

## Language

Choose English, French, German or Simplified Chinese from the language menu in the top
bar or on the sign-in page. The panel remembers the selection in that browser and uses
the browser's language for the first visit. Server-supplied health details are in English.

## Suspending

**Suspending a user** signs them out everywhere and stops them signing in. Their workspaces keep working for everyone else.

**Suspending a workspace** pauses it without deleting anything. Its members see a page that says the workspace is suspended. Its API keys, chat widget and help center stop answering. Inbound mail is kept but not turned into tickets, and queued replies, webhooks, automations and AI stop. Restoring it lets everything run again; mail that arrived meanwhile and replies that were queued are not replayed.

Both show up in the workspace's own audit log, so its admins know the instance's operator acted.

## Limits and AI usage

On an instance without billing every workspace already has unlimited use, so limits only matter on an instance that runs billing. There, you can give a workspace more mailboxes, more members, a larger monthly AI allowance or more Collab mail storage than its plan, or grant it AI usage that never expires.

## Complimentary plan

On an instance that runs billing, you can give a workspace **Pro** or **Premium** without a subscription, until a date you choose or until you change it, with a note on why. While it lasts the workspace has that plan's limits, its AI allowance for each owner, admin and agent, and Collab. If the workspace also subscribes, it is on whichever plan is higher. You can end it early. When it ends, the workspace is on its own plan again, Free or its subscription's. The workspace list can be filtered to the workspaces that have one now.

Without billing a complimentary plan is stored but changes nothing: every workspace already has every limit lifted and Collab, unless the instance sets `COLLAB=false`.

## Website policies

In **Website policies**, a super admin can enter privacy, terms, refund and cancellation,
and contact information. Pick a document and a language, write or edit the text, and
publish it when ready. Draft changes take effect only when you publish them.

With an instance AI provider configured, **Generate translation** produces a preview
for another language. Review the result before saving or publishing it. A public link
uses the requested language when it has been published and otherwise falls back to
English or another published version.

Share published links from this page with customers or add them in the Stripe Dashboard.
Your API origin must be publicly reachable for Stripe to read the document.

## Updates

The **Health** page shows the version the instance runs, the newest release, and whether automatic updates are on and how their last run went. When a newer release is out it gives the command to run, and super admins get an email about it. See [Backups and upgrades](/self-hosting/backups-and-upgrades/#update-notices).

## Its own address

On one domain the panel shares the app's origin. To give it a host of its own, point a second hostname at the same opendesk, have your proxy send it to `/admin/`, and set the panel's address:

```sh
ADMIN_URL=https://admin.desk.example.com
```

The admin API answers only that origin. If you use Turnstile, add the hostname to the widget's allowed domains in Cloudflare.

## Configuration

| Variable | Default | Meaning |
| --- | --- | --- |
| `ADMIN_URL` | `APP_URL` + `/admin` | Where the panel is. Its origin is the only one the admin API accepts. |
| `ADMIN_ENV_LABEL` | empty | A short label in the panel's top bar, such as `Production` or `Staging`. |
