Class: Presence

WTAPI.Presence()

new Presence()

Represents a Presence of a User. Use WTAPI.Presence.Builder to create a new presence.
Source:

Classes

Builder

Methods

getConnectedCall() → {WTAPI.ConnectedCall|null}

Returns call information in presence status of user, or null if there is no active call.
Source:
Returns:
Type
WTAPI.ConnectedCall | null

getLocation() → {WTAPI.Location|null}

Returns location of user, or null if user doesn't set it.
Source:
Returns:
Type
WTAPI.Location | null

getProfileData() → {WTAPI.ProfileData|null}

Returns profile data of user, or null if user doesn't set it.
Source:
Returns:
Type
WTAPI.ProfileData | null

getStatusIcon() → {String}

Returns a status icon representing a current status. Possible values: away away-offline dnd dnd-offline mur mur-offline online offline
Source:
Returns:
Type
String

getStatusMessage() → {String|null}

Returns the status message of the presence, or null if user doesn't set it.
Source:
Returns:
Type
String | null

getStatusUntil() → {Date|null}

Returns the expire date of the presence, or null if user doesn't set it. Expire date - a date when this presence are valid.
Source:
Returns:
Type
Date | null

isAway() → {boolean}

Returns true if user set away status.
Source:
Returns:
Type
boolean

isConnectedCallAvailable() → {boolean}

Returns true if user talking on the phone.
Source:
Returns:
Type
boolean

isDND() → {boolean}

Returns true if user set DND status.
Source:
Returns:
Type
boolean

isEmpty() → {boolean}

Returns true if user is offline and has default values for other properties.
Source:
Returns:
Type
boolean

isLocationAvailable() → {boolean}

Returns true if user set his location.
Source:
Returns:
Type
boolean

isMUR() → {boolean}

Returns true if user set MUR status.
Source:
Returns:
Type
boolean

isOnline() → {boolean}

Returns true if user is online (available) and false if the user is offline (unavailable).
Source:
Returns:
Type
boolean

isRegisteredDevice() → {boolean}

Returns true if user has a registered device.
Source:
Returns:
Type
boolean

isRinging() → {boolean}

Returns true if somebody is calling to user.
Source:
Returns:
Type
boolean

isStatusMessageAvailable() → {boolean}

Returns true if user set custom status message.
Source:
Returns:
Type
boolean

isStatusUntilAvailable() → {boolean}

Returns true if user set expire date for presence.
Source:
Returns:
Type
boolean

isTalking() → {boolean}

Returns true if user is talking with somebody.
Source:
Returns:
Type
boolean

isTalkingAndRinging() → {boolean}

Returns true if user is talking and somebody tries to call him.
Source:
Returns:
Type
boolean