Returns the agent's name string according to the latest events received.

Sample code

var agentName = chat.getAgentLoginName();