sitemap.xml llms.txt
Skip to main content

Identification

Session type​

Session is a union type that implements either UserSession or AdminSession.


Interfaces​

UserSession​

The UserSession interface defines the structure of a user session.

Required Properties​

  • token: string - A unique token used for authentication.
  • userKey: string - User key.
  • accountShortName: string - Account short name.
  • displayName: string - The user's display name.
  • objectType: 'user' - A constant string indicating that this is a user session.
  • loginMethod: { objectType: string } - An object describing the login method.
    • objectType: string specifies the type of login method. Possible values: NativeLoginMethod, SSOLoginMethod or NoneLoginMethod.

Optional Properties​

  • groupKey?: string - When defined, indicates that in this session the user is logged in as a member of a group.
  • groupName?: string - The name of the group the user is associated with.
  • groupRole? (keyof typeof GROUP_ROLE) - Defines the user's permissions. For a discussion fo user roles, see User session.
  • multipleGroups?: boolean - A flag indicating that the user is a member of multiple groups and the session context cannot be selected by default.
  • projectShortName?: string - Project short name. Undefined when multipleGroups is true.
  • projectKey?: string - Project key.

AdminSession​

The AdminSession interface defines the structure of an admin session.

Admin sessions have either a global role (SYSTEM or MONITOR) for system-wide access, or team-specific roles (teamAccountRole and/or teamProjectRole) for account/project access. Personal accounts always give the admin an OWNER role for their own account.

Required Properties​

  • adminHandle: string - The handle used to log in.
  • adminKey: string - A unique key identifying the admin.
  • expires: boolean - Indicates whether the session has an expiration.
  • multipleAccounts: boolean - A flag indicating that the admin is associated with multiple accounts and the session context cannot be selected by default.
  • objectType: "admin" - A constant string identifying the object type, always set to "admin".
  • timeoutMinutes: number - The session timeout duration, in minutes.
  • token: string - A unique token used for authentication.

Optional Properties​

  • globalRole? (ROLE.SYSTEM | ROLE.MONITOR) - Global system role. Present when the admin has system-wide access.
  • teamAccountRole? (ROLE.OWNER | ROLE.AUTHOR | ROLE.SUPPORT | ROLE.ASSOCIATE) - Defines the admin's permissions within the account. When present, teamAccountShortName should also be present. For a discussion of admin roles, see Admin session.
  • teamAccountShortName?: string - A shortened or simplified name for the team account the admin is associated with. Present when teamAccountRole is set.
  • teamProjectRole? (ROLE.AUTHOR | ROLE.SUPPORT) - Role within a specific project. When present, projectShortName and projectKey should also be present.
  • projectShortName?: string - Project short name. Present when the admin is scoped to a specific project.
  • projectKey?: string - Project key. Present when the admin is scoped to a specific project.
  • groupKey?: string - Group key. Present when the admin is scoped to a specific group.