Hierarchy
- LinesCollections
Properties
Readonly channels
Channels (messengers).
Readonly clients
Clients.
Readonly lines
Live Chats.
Readonly metrics
Metrics.
Readonly sessions
Sessions.
Methods
getOperatorStatus
-
The method returns an operator’s status.
Returns one of the values OperatorStatusType:
const user = await System.users.getCurrentUser(); const operatorStatus = await System. lines.getOperatorStatus(user);
Parameters
-
user: UserItemRef
User whose status needs to be obtained.
Returns Promise<OperatorStatusType>
-
setOperatorStatus
-
The method is used to change an operator’s status.
Example:
const user = await System.users.getCurrentUser(); await System.lines.setOperatorStatus(user, OperatorStatusType.offline);
Parameters
-
user: UserItemRef
User whose status needs to be changed.
-
status: OperatorStatusType
New status of the operator.
Returns Promise<void>
-
System.lines object
Grants access to Live Chat system collections. This object is always accessible as a global value in scripts:
const cu = await System.users.getCurrentUser(); await System.lines.sessions. assignToOperator(cu);