Departments
A department is a lightweight grouping of researchers: a unique name, an optional description, and an active flag. That is the whole record. Its value comes from what it unlocks elsewhere — filtering the researcher directory, and, if you switch it on, letting colleagues in the same department see each other’s sequencing orders.
Departments matter more than their small data model suggests, because a researcher picks their department once, during registration, and can never change it afterwards. Getting the list right before you invite researchers is therefore the single most important thing on this page.
What a department affects
| Where | Effect |
|---|---|
Registration form (/register) | The department dropdown is filled from GET /api/departments, which returns only active departments, sorted by name. A department that does not exist yet cannot be chosen. |
Researchers page (/admin/users) | Department is a sortable column and a filter. The filter is built from departments actually in use, so an empty department never appears there. |
Researcher profile (/admin/users/<id>) | Shown as part of the profile. |
Sequencing order list (/api/orders) | With Department Sharing on, a researcher’s list is scoped to everyone in their department instead of just themselves. |
| Support tickets | With Department Sharing on, ticket visibility and the reference-picker options widen the same way. |
Departments do not affect pipelines, storage paths, quotas, billing, ENA submission, or notification routing. There is no per-department configuration.
Managing departments
Users → Departments (/admin/departments) lists every department with its
user count and status.
| Action | Control | Notes |
|---|---|---|
| Create | Add Department button | Name is required and must be unique after trimming; description is optional |
| Edit | Pencil icon on the row | Renaming to an existing name is rejected |
| Deactivate / activate | Dot toggle on the row | Flips isActive; inactive rows are dimmed and the user count is preserved |
| Delete | Trash icon on the row | Opens a confirmation dialog, and is refused while any user is assigned — see below |
| Search | Search box | Matches name and description |
| Filter | Status dropdown | All, active only, or inactive only |
| Sort | Column headers | Department, Status, Users, Created |
Delete versus deactivate
Deleting a department with users assigned is blocked, not
merely warned about. DELETE /api/admin/departments/<id>
answers 400 with
Cannot delete department with assigned users. Deactivate it instead.
Deactivating is almost always what you want:
- Deactivate removes the department from the registration dropdown so no new researchers can join it, while every existing assignment, sequencing order and study stays intact and attributed.
- Delete only succeeds on a department with zero users, and it is permanent.
Because researchers cannot move between departments, a merge or rename is best handled as a rename of the surviving department plus a deactivation of the one you are retiring. Deleting is realistically only for cleaning up a department created by mistake.
Department sharing
The Department Sharing switch lives on Settings → Accounts
(/admin/admin-accounts), under Access & Sharing — not on the Departments
page. It is stored as departmentSharing in the site settings and is written by
PUT /api/admin/settings/access. It is off by default.
How the sequencing order list is scoped:
| Caller | Sharing off | Sharing on |
|---|---|---|
| Facility admin | All sequencing orders | All sequencing orders |
| Researcher with a department | Only their own | Every order whose owner is in the same department |
| Researcher without a department | Only their own | Only their own |
Sharing widens the list, not the detail view.
GET /api/orders/[id] still requires the caller to be the owner or
a facility admin, and answers 403 Forbidden otherwise. A
researcher will therefore see a colleague’s sequencing order in the list and
be refused when opening it. Treat department sharing as a visibility feature,
not as shared editing, and tell your users so before you enable it.
Because sharing follows department membership, review the assignments before switching it on. Anyone parked in a catch-all department will suddenly see every sequencing order from everyone else parked there.
Worked example
A small facility serving three groups:
Create the real units
Add Microbial Genomics, Clinical Metagenomics and Bioinformatics, each
with a one-line description of what the group works on. The description is shown
nowhere user-facing, but it makes the admin list readable when the department
count grows.
Add a fallback
Add External / Collaborators for users who do not belong to any internal
group. Keep it clearly named — with sharing on, everyone inside it can see each
other’s sequencing orders.
Invite researchers
Only now send people to /register. They will see exactly these four options.
Decide on sharing
If groups genuinely work on shared projects, turn on Department Sharing and warn users that opening a colleague’s sequencing order is still blocked.
Retire a group later
When Clinical Metagenomics is folded into Microbial Genomics, deactivate it
rather than deleting it. Its historical sequencing orders and studies keep their
attribution, and no new researcher can pick it.
Assisted import from a webpage
If your institution publishes its structure on a webpage, AI Import can extract the department names instead of you typing them.
Open the dialog
Press AI Import on the Departments page. If you have imported before, the last URL is pre-filled.
Provide a URL
An http or https URL, typically an institute overview or research-groups
listing. SeqDesk fetches the page server-side, strips scripts, styles, nav and
footer, converts it to plain text, and truncates it to 15,000 characters.
Review the extraction
The extracted list is returned with a note about what kind of page it looked like. Entries whose name already matches an existing department are flagged as duplicates and cannot be selected. Administrative units such as HR and IT are filtered out by the extraction prompt, but always read the list before importing — this is a best-effort extraction from arbitrary HTML.
Import the selection
Selected, non-duplicate entries are created as normal departments. The URL and a timestamp are saved so you can re-fetch later.
Extraction requires the ANTHROPIC_API_KEY environment variable on the SeqDesk
server. Without it the endpoint answers 503 with
AI extraction not configured (no API key). The server must also be able to
reach both the target URL and the model API — this feature does not work on an
air-gapped host.
Troubleshooting
| Symptom | Cause | Fix |
|---|---|---|
Department with this name already exists | Names are unique after trimming | Pick a different name, or edit the existing one |
Cannot delete department with assigned users. Deactivate it instead. | Users are still assigned | Deactivate instead; there is no bulk reassignment |
Department name is required | Name was empty or whitespace only | Enter a name |
| A department is missing from the registration form | It is inactive | Reactivate it on this page |
| A researcher is in the wrong department | Assignment is fixed at registration | The account has to be recreated; see User Management |
AI extraction not configured (no API key) | ANTHROPIC_API_KEY is unset | Set it in the server environment and restart, or add departments manually |
Failed to fetch webpage: 404 / Failed to fetch webpage content | The URL is wrong or unreachable from the server | Verify the URL and the server’s outbound network access |
| Sharing is on but a researcher still sees only their own orders | They have no department | Their assignment is empty; SeqDesk falls back to personal scope |
See also
- User Management — roles, registration and the account operations that are unavailable
- Sequencing Orders & Samples — what a researcher sees in the list that sharing widens
- Administration overview — the full map of admin screens