Skip to content
Skip to documentation content

Documentation home / Command / Invitations

Invitations

Create reusable workspace invitation links, inspect their join history and revoke active links.

At a glance

In Trapitan: /workspaces/{workspace_id}/invitations.

Who can open this page: Verified manage_members and enabled entitlement.

What you see

The Invitations page has Create invitation link and a table with Created, Expires, Status, Joined and row actions. Joined expands to the attributed users' labels and Travian accounts, or No one joined with this invitation. Copy is available for each row; Revoke appears only on active rows. The creation dialog asks for an Expiration date, not an intended user or account.

Who fills in each field

A workspace-manager chooses the expiration date and asks Trapitan to create the opaque invitation URL. Joining members select their roster accounts on the separate Join page. Joined is invitation attribution history, not a list of current active memberships; a removed membership can appear as Former member. Labels use display name, then email, then the stored user identifier. No real invitation URL or user record is shown in this guide.

Field or data What it means Who fills it in Can it be changed here? When it updates
Created, expires and status Creation time, expiration boundary and active/expired/revoked status. Date picker defaults seven days ahead, permits 1–30 days; expiry is midnight UTC after chosen date. workspace-manager, backend-derived Read-only Page load from latest recorded values
Joined Count/details of attributed joins, including display label and Travian account; this is attribution history, not a current member roster. signed-in-member, roster-ingest, backend-derived Read-only Page load from latest recorded values
Invitation URL Reusable opaque public ID link; no intended account or recoverable secret is collected. Never copy real URLs into public docs. workspace-manager, backend-derived Read-only Invitation creation

Calculations

No derived values on this page.

Freshness and updates

Loading the page reads stored links and attributed joins. Creation and revocation reload the page after success. The date picker defaults to seven days from the current UTC date and permits dates one to thirty days ahead. The selected date remains valid through that day: expiration is midnight UTC immediately after it. The table's Expires date is the stored expiration-boundary date, which is one day later than the date selected in the dialog. Status is evaluated when links are read and again when a user tries to join; the table does not promise live status updates.

Actions and permissions

Who can take action: The actor and permission for each action are listed below. Who can perform each action depends on the server's checks, independently of whether navigation or a button is visible.

Action Actor Permission
Create invitation link workspace-manager Verified manage_members, enabled entitlement, same origin and workspace alliance configured
Copy invitation link workspace-manager Page access manage_members; local clipboard copy does not change link
Revoke invitation link workspace-manager Verified manage_members, enabled entitlement and same origin; lookup by workspace/invite ID; already revoked is idempotent

In Trapitan, open Create invitation link, review its expiration date and create. The server revalidates the allowed date range and requires the workspace's alliance to be configured. A successful creation adds a reusable link; no account is preselected and a successful join does not consume it. Copy only writes that row's URL to the local clipboard and does not change its lifecycle.

In Trapitan — revoke a link: Use the active row's Revoke action and confirm the browser's Revoke invitation link? prompt. Revocation stops later joins, including joins from an already opened page. Repeating a revocation for the same scoped link is harmless. Revoking a link does not revoke memberships already created with it. There is no expiry-edit control or one-use quota on this page; create a new link when a different expiry is needed.

States and edge cases

With no links, the table says No invitation links yet. An active link can become expired at its stored UTC boundary; revoked takes precedence over expired. Clipboard failures show Copy failed. Creation/date/alliance failures stay in the dialog with feedback; failed revocation shows feedback without claiming success. Create and revoke require verified manage_members authorization, enabled entitlement and same-origin requests; link lookup is scoped to the workspace. A stale link or one from another workspace cannot be revoked through this workspace's action. Opening Invitations does not grant recipients access: each join still requires Discord authentication, a current roster account on the correct server and alliance, and the user/server active-membership rule. Later protected features also require verification, entitlement and the relevant grant.

Source references

Source reviewed: 2026-10-05

Source references

Stable page ID: command.invitations.

  • src/trapitan/api/routes/web.py
  • src/trapitan/web/templates/alliance_membership.html
  • src/trapitan/web/static/js/invitation-links.js
  • src/trapitan/memberships/service.py
  • src/trapitan/authorization/dependencies.py
  • src/trapitan/authorization/policy.py
  • src/trapitan/api/routes/invites.py