4.12 Packet Exchanges to Create an Agent Session for an ACD Group

Figure 14: Creating agent session for an ACD group
The agent application can create an agent session for an ACD group by following these steps:
The client establishes the session and creates an agent as described in the example in section 4.11.
The client sends a GetAgentGroupList packet to server to obtain the agent groups into which agent is permitted to log on to the automatic call distributor. The return value is a positive number that is the request identifier, or a negative number in case of error.
The server creates a packet LINE_PROXYREQUEST with structure based on the client requested packet type. For GetAgentGroupList packet, LINE_PROXYREQUEST packet is created with structure of type LINEPROXYREQUEST_GETAGENTGROUPLIST.
The server sends the LINE_PROXYREQUEST packet to registered proxy function handler.
After completing the request, proxy application sends the response by calling lineProxyResponse function which results in generation of LINE_REPLY packet with LINEAGENTGROUPLIST.
The server calls the RemoteSPEventProc method of the client with the LINE_REPLY packet, which matches the request identifier previously returned for the proxy request packet. A return value of 0 indicates that the operation was carried out successfully, or a negative number is returned on error.
The client sends a CreateAgentSession packet to server to create a session for an ACD group. The return value is a positive number that is the request identifier, or a negative number in case of error.
The server creates a packet LINE_PROXYREQUEST with structure based on the client requested packet type. For CreateAgentSession packet, LINE_PROXYREQUEST packet is created with structure of type LINEPROXYREQUEST_CREATEAGENTSESSION.
The server sends the LINE_PROXYREQUEST packet to registered proxy function handler.
After completing the request, the proxy application sends the response by calling the lineProxyResponse function, which results in generation of the LINE_REPLY packet.
The server calls the RemoteSPEventProc method of the client with the LINE_REPLY packet, which matches the request identifier previously returned for the proxy request packet. A return value of 0 indicates that the operation was carried out successfully, or a negative number is returned on error.