Interface ChatApiCommands
- 
- All Known Implementing Classes:
- UninitializedChat, ZopimChat, ZopimChatApi
 
 
 public interface ChatApiCommandsChat APIs interfaceDefines the set of APIs available in a given chat session. APIs will be linked to the account configured during initialization of ZopimChatApi.init(String)
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method and Description voidaddNote(java.lang.String note)Appends a note to the current visitor notevoiddisconnect()Disconnect the current chat, used when switching to push mode.booleanemailTranscript(java.lang.String email)Emails the current chat transcriptvoidendChat()Ends the current chat.voidresend(java.lang.String messageId)Re-sends the visitor message.voidsend(java.io.File file)Sends the file to the current chat log.voidsend(java.lang.String message)Sends the visitor message.voidsendChatComment(java.lang.String comment)Sets a comment to the current chat session.voidsendChatRating(ChatLog.Rating rating)Sets rating for the current chat session.booleansendOfflineMessage(java.lang.String name, java.lang.String email, java.lang.String message)Sends email to agents defined in the dashboard for this account.voidsetDepartment(java.lang.String department)Sets a department to the current chat session.voidsetEmail(java.lang.String email)Sets the email for the user in the current chat session.voidsetName(java.lang.String name)Sets the name for the user in the current chat session.voidsetNote(java.lang.String note)Sets a note to the visitor profilevoidsetPhoneNumber(java.lang.String phoneNumber)Sets phone number information for the user that is in the current chat session.
 
- 
- 
- 
Method Detail- 
sendvoid send(java.lang.String message) Sends the visitor message.This message will appear in the agent dashboard in an active chat queue. - Parameters:
- message- to be sent
- See Also:
- Agent Visitor List
 
 - 
sendvoid send(java.io.File file) Sends the file to the current chat log. Successful file send will trigger a chat log update with information about the file being uploaded.File must pass validation check and upload requirements defined in Zopim attachments page A successful file upload will be visible in the agent dashboard. - Parameters:
- file- to send
- See Also:
- ChatLogObserver, Agent Dashboard
 
 - 
resendvoid resend(java.lang.String messageId) Re-sends the visitor message.This message will appear in the agent dashboard. - Parameters:
- messageId- id of the message to resend
- See Also:
- Agent Visitor List
 
 - 
sendOfflineMessageboolean sendOfflineMessage(java.lang.String name, java.lang.String email, java.lang.String message)Sends email to agents defined in the dashboard for this account.Email must be provided in order for the agent to be able to respond. - Parameters:
- name- of the visitor
- email- of the visitor
- message- inquiry
- Returns:
- true if was able to send, false otherwise
 
 - 
sendChatRatingvoid sendChatRating(ChatLog.Rating rating) Sets rating for the current chat session.This will appear as a response to the chat rating questionnaire sent by an agent to the visitor. - Parameters:
- rating- to set
 
 - 
sendChatCommentvoid sendChatComment(java.lang.String comment) Sets a comment to the current chat session.- Parameters:
- comment- to set
 
 - 
emailTranscriptboolean emailTranscript(java.lang.String email) Emails the current chat transcriptIt will send an email to the provided address with the current chat log - Parameters:
- email- address to send the transcript to
- Returns:
- true if email was sent, false otherwise
 
 - 
endChatvoid endChat() Ends the current chat. This will update the connection status to closed.
 - 
disconnectvoid disconnect() Disconnect the current chat, used when switching to push mode.
 - 
setDepartmentvoid setDepartment(java.lang.String department) Sets a department to the current chat session.Configuring a department in the chat will deliver the chat to the right group of agents supporting that department's inquiries. This information will be visible in the agent dashboard. Provided department should be one of the departments available in this account. The list of available departments will be available in LivechatDepartmentsPathafter initialization is completeChatService#onChatInitialized(). Setting a non defined department will have no effect.- Parameters:
- department- visitor is chatting with
- See Also:
- Departments Dashboard
 
 - 
setPhoneNumbervoid setPhoneNumber(java.lang.String phoneNumber) Sets phone number information for the user that is in the current chat session.This information will be visible in the agent dashboard. - Parameters:
- phoneNumber- of the visitor
- See Also:
- Agent Dashboard
 
 - 
setNamevoid setName(java.lang.String name) Sets the name for the user in the current chat session.This information will be visible in the agent dashboard. - Parameters:
- name- of the visitor
- See Also:
- Agent Dashboard
 
 - 
setEmailvoid setEmail(java.lang.String email) Sets the email for the user in the current chat session.This information will be visible in the agent dashboard. - Parameters:
- email- of the visitor
- See Also:
- Agent Dashboard
 
 - 
setNotevoid setNote(java.lang.String note) Sets a note to the visitor profile- Parameters:
- note- about the visitor
 
 - 
addNotevoid addNote(java.lang.String note) Appends a note to the current visitor note- Parameters:
- note- about the visitor to append
 
 
- 
 
-