Skip to Content
On this page

Role Management

Use roles to grant API, menu and button permissions. A user can have multiple roles. Missing permissions can hide menus or buttons, or cause API requests to be rejected.

Maintain roles

Permission types

terminologyon-site understanding
rolea set of permissions, For example, “read-only monitoring,” “operation and maintenance,” and “project administrator.”
API permissionsBackground interface call permissions. If the page button is visible but API permissions are missing, the operation may still fail.
Menu permissionsVisible permissions for left navigation and page entrances. Without menu permissions, users usually cannot see the page.
Button PermissionsOperation permissions for adding, editing, deleting, exporting, authorizing, and other buttons within the page.
AuthorizationThe process of checking API, menu, and button permissions for roles.
Least permissionsOnly grant the necessary permissions to complete the work. Don’t configure ordinary users as super administrators in the production environment.

Page Entry

After logging into TGateway Web, enter “System Administration → Role Management.”

Role Management Page

Page Structure

AreaDescription
Role Name SearchFilter List by Role Name.
Tool buttonsare Add, Batch Delete, and Refresh in order. To delete in bulk, you need to check the role first.
Role ListDisplays role names, descriptions, enabled statuses, and action buttons.
Operations columnincludes editing, authorizing, copying, and deleting. The Super Administrator role cannot be deleted.

List Fields

FieldsDescription
Role NameRole display name, which is also the name the user sees when assigning roles.
Description:Role Description, such as “Operation and Maintenance,” “Read-Only Monitoring,” “Project Administrator.”
StatusEnabled or Disabled. Disabling roles will no longer grant permissions.
OperationsEdit, authorize, copy, delete.

Add and edit roles

  1. Open System Management → Role Management, click Add, and name the role for its responsibility, for example Shift Viewer.
  2. Enter an optional description, keep it enabled, and save.
  3. Find the new role and open Authorize. Creating a role alone does not grant access to business pages.
  4. Configure menu/button and API permissions as described below, then save each tab’s changes.
  5. Assign the role in User Management. Sign in as that user in a private window or another browser and verify the required pages and operations.

Use Edit to change an existing role. Changes affect every user assigned that role.

Role Configuration Drawer

Configuration ItemsDescription
Role NameRequired. It is recommended to name according to job responsibilities and not use personal names as long-term role names.
Descriptionoptional. Explain the role to which it applies, permission boundaries, and maintenance considerations.
Enableto check if the role is active. This switch can be turned off when temporarily disabling a role.

Copy a role

Click the copy button in the role row to create a new role based on an existing one. Copying is suitable for the following scenarios:

ScenariosSuggestions
Create similar responsibilitiesCopy existing roles first, Further increase and decrease permissions.
Temporary AuthorizationAfter copying frequently used roles, add a separate temporary permission, which can be disabled or deleted after completion.
Permission ComparisonAfter copying, confirm the adjustment scope via “Preview Differences.”

After copying a role, immediately modify the role name and description to avoid confusion between multiple roles’ uses.

Disable or delete a role

To suspend a role, edit it, turn off Enable, and save. Before deletion, check its assigned users and give them the required replacement roles. The Super Administrator role cannot be deleted.

Configure and verify permissions

Authorization Drawer

Click the authorization button in the role row to open the “Role Authorization” drawer. The drawer contains tabs for “API Authorization” and “Menu Button Authorization,” with options at the bottom for “Cancel,” “Preview Difference,” and “Save.”

API Authorization

Which service interfaces can the API authorization control role call. Even if the page buttons are visible, if the corresponding API permissions are missing, interface calls may still fail.

AreaDescription
Search APIFilter the list of interfaces by permission code, interface URL, or description.
Select AllSelect all interfaces in the current API permission list.
ClearClear current API permission selections.
Permission encodingBusiness permission identification, such as variable writing, user maintenance, log export, etc.
Interface URLThe interface path corresponding to the current permission.
DescriptionInterface Purpose Description.

API authorization is suitable for minimizing allocation by function. For example, read-only monitoring roles usually only retain query interfaces; The operations role can add interfaces for write, restart, import/export, and log export.

Menu button authorization controls which menus users can see and which buttons within the menus can be operated.

AreaDescription
Search for menus or buttonsFilter permission trees by menu name or button name.
Select AllSelect all menu and button nodes.
ClearClear all menu and button selections.
Menu Nodecontrols whether the left navigation menu and page entry are visible.
Button nodesControl whether buttons for adding, editing, deleting, exporting, authorizing, etc. are visible on the page.

Selecting a menu can also select its child buttons. After searching and selecting a menu, clear the search and expand it to remove unneeded edit, delete, write, and control buttons. Menu/button selections do not grant the corresponding API permissions.

Example: allow only System Overview

Use Shift Viewer without collection editing, writes, restarts, or account management.

  1. In API Authorization, search overview:get, check that the results retrieve status, statistics, or lists, and select them. Do not select every result for the broader word overview, which also includes test-data insertion.
  2. Search for and select each of the following codes separately, waiting for the filtered results before selecting.
Permission codePurpose
system:get_system_infoSystem resources and software-license state.
project:get_project_infoProject information.
network_config:get_network_configsNetwork interfaces.
real_alarm:get_real_alarm_variablesTop-bar alarm count.
  1. Save, reopen authorization, and use Menu Button Authorization to select System Overview. Retain only its refresh, top-bar system status, top-bar alarm badge, and workspace project-information buttons.
  2. Preview the differences, save, and assign the role to an ordinary user. Sign in with an independent browser session.

The user should see System Overview, device statistics, and system resources, without Collection Configuration, User Management, or runtime-restart actions. Do not use admin to verify restricted permissions.

If switching tabs prompts about unsaved authorization, cancel the switch, save the current tab, then reopen authorization for the other tab.

Debug Permission Levels

The Collection Configuration and Data Forwarding menus each provide five independent debug button permissions. They are split by risk, so a role can receive view or query access without also receiving writes or controls.

Button permissionAPI permission codeScope
Debug Viewdebug:viewView the Debug tab, object overview, runtime state, and redacted summaries.
Read-only Debugdebug:queryPerform reads, node browsing, state queries, and read-only diagnostics.
General Debug Writedebug:writeWrite ordinary points, publish messages, maintain subscriptions, and run low-risk protocol commands.
Dangerous Debug Controldebug:dangerousStart or stop PLCs, reset equipment, move robots, perform batch I/O, send arbitrary commands, delete datasets, or disconnect clients.
Sensitive Debug Datadebug:sensitiveView certificate trust information, identity information, and other sensitive debugging content.

When authorizing, first select the corresponding debug buttons under Menu Button Authorization, then verify the same codes under API Authorization. The default user role contains only Debug View and Read-only Debug; the other three permissions must be granted by separate roles.

Recommended role split:

RoleSuggested debug permissions
Read-only DebugDebug View and Read-only Debug.
General WriteRead-only Debug plus General Debug Write.
Dangerous ControlAdd Dangerous Debug Control for approved equipment-maintenance staff; do not include Sensitive Debug Data by default.
Sensitive Data ReviewAdd Sensitive Debug Data for the business need; do not include writes or dangerous controls by default.

Note

Do not select all debug permissions merely to make one button available. Dangerous controls and sensitive data are separate responsibilities and should be approved, granted, and audited separately.

Preview Differences and Save

After clicking “Preview Differences,” the bottom of your drawer will display the statistics for this permission adjustment.

Difference ItemDescription
Add Menu / Cancel MenuThe number of menu permissions that will be added or canceled after this save.
Add button / Cancel buttonNumber of button permissions added or canceled after this save.
Add API / Cancel APIThe number of interface permissions that will be added or removed after this save.

After confirming the discrepancies, click “Save”. After saving, logged-in users usually need to refresh the page or log in again to see the latest menus, buttons, and interface permission effects.

Role design and precautions

Common Role Suggestions

Role TypesPermission Suggestions
Read-only monitoringread-only APIs and menus for system overview, data queries, real-time alarms, and log queries.
Operations and maintenance personnelOn top of read-only monitoring, permissions such as variable writing, device debugging, log export, and runtime restart are added.
Configure administratorsCollect configurations, data forwarding, scripts, nodes, rules, and plugin maintenance permissions.
Security AdministratorUser management, role management, menu management, audit log permissions.

Usage Notes

ScenariosRecommended
Super AdministratorSuper Administrator has the highest privileges, so account sharing should be restricted, and login audits should be checked regularly.
API and button inconsistencyIf only the button is authorized but the API is not authorized, page operations may fail; If only the API is authorized but the button is not authorized, users may not be able to trigger it from the page.
Delete RoleBefore deleting, check the user’s binding relationship to avoid having no available permissions after logging in.
Batch deletionOnly performs on regular roles that are not used as deleted; super administrator roles cannot be deleted.
Permission Adjustment AuditView audit records in the system log after important permission adjustments.