Skip to main content

Helpshift Delegates

The Helpshift SDK provides delegate callbacks to help app developers track a user's activities within the help section.

Helpshift Delegate implementation

Bind the event delegate by using BindEventDelegate()

You can listen to the events fired by Helpshift. All the events are defined in HelpshiftConstants.h


Events invoked before binding BindEventDelegate cannot be received again.


Helpshift Session Delegates

Helpshift session started event

This event gets fired when the Helpshift session starts

  • Event name: HelpshiftEventSDKSessionStarted
  • Event data: null

Helpshift session ended event

This event gets fired when the Helpshift session ends.

  • Event name: HelpshiftEventSDKSessionEnded
  • Event data: null

Unread Message Count Event

This event gets fired when you call RequestUnreadMessageCount(FetchFromServer) API to request unread messages count.

  • Event name: HelpshiftEventReceivedUnreadMessageCount
  • Event data keys:
    • HelpshiftEventDataMessageCount (int32)
    • HelpshiftEventDataMessageCountFromCache

Conversation Status Event

This event contains information about the current ongoing conversation.

  • Event name: HelpshiftEventConversationStatus
  • Event data:
    • HelpshiftEventDataLatestIssueId (FString)
    • HelpshiftEventDataLatestIssuePublishId (FString)
    • HelpshiftEventDataIsIssueOpen (bool)

Widget Toggle Event

This event is triggered when the user opens or exits the chat screen. This event is triggered with a boolean value of "visible" key. For your reference, see the below example:

  • Event name: HelpshiftEventWidgetToggle
  • Event data: HelpshiftEventDataSDKVisible (bool)

User Click On Action Event

This event is triggered when the user clicks on the link or call action of an action card message.

  • Event Name : HelpshiftEventUserClickOnAction
  • Event data:
    • HelpshiftEventDataActionData
    • HelpshiftEventDataActionType
    • HelpshiftEventDataActionTypeCall
    • HelpshiftEventDataActionTypeLink
Key (Constant)Key (Raw)Type

The key constants are available from SDK X 10.3.0 onwards. For older SDK X versions, please use the raw keys instead.

Conversation Start Event

This event triggers when the user sends the first message in a conversation. The event data object has a key, message, which includes the message string the end-user sent to start the conversation. For your reference, see the below example.

  • Event name: HelpshiftEventConversationStart
  • Event data: HelpshiftEventDataMessage (FString)

Message Add Event

This event is triggered when the user adds a message in a conversation. It might be a text message, response via bot input, or an attachment. The event data object has type and body keys, which indicates the type and body of the message added by the user. For your reference, see the below example.

  • Event name: HelpshiftEventMessageAdd
  • Event data keys:
    • HelpshiftEventDataMessageType - HelpshiftEventDataMessageTypeAttachment or HelpshiftEventDataMessageTypeText
    • HelpshiftEventDataMessageBody (FString)

Agent Message Received Event

This event is triggered when the user receives any message from an agent in a conversation. This delegate is not triggered for bot messages or messages sent via automations.

  • Event name : HelpshiftEventAgentMessageReceived

  • Event data:

    KeyKey ( Raw )TypeValue
    HelpshiftEventDataPublishIDpublishIdFStringConversation ID of the ongoing issue
    HelpshiftEventDataMessageTypetypeFStringMessage Type of the message
    HelpshiftEventDataMessageBodybodyFStringThe actual message sent by the agent or empty
    HelpshiftEventDataCreatedTimecreatedTsint32Unix epoch timestamp in ms
    HelpshiftEventDataAttachmentsattachmentsMap<FString, Object>>Attachments, if they are present
    HelpshiftEventDataURLurlFStringURL of the attachment
    HelpshiftEventDataContentTypecontentTypeFStringMIME type of the attachment
    HelpshiftEventDataFileNamefileNameFStringFile name of the attachment
    HelpshiftEventDataSizesizeint32Size of the attachment in bytes
    HelpshiftEventDataMessageTypeAppReviewRequestapp_review_requestFStringMessage type when agent request for App Review
    HelpshiftEventDataMessageTypeScreenshotRequestscreenshot_requestFStringMessage type when agent request screen shot
    HelpshiftEventDataMessageTypeTexttypeFStringMessage type of text
  • For Android , this delegate is available from 10.3.0 and above versions
  • The key constants are available from SDK X 10.3.0 onwards. For older SDK X versions, please use the raw keys instead.
  • The attachments key is only present if the agent has sent attachments.
  • Since attachments sent by agents may not have the necessary MIME type or name, it is possible that HelpshiftEvent.DATA_CONTENT_TYPE is absent from the payload. For such cases, file type can be inferred from extension from file name
  • HelpshiftEventDataMessageType has following types :
    • HelpshiftEventDataMessageTypeAppReviewRequest
    • HelpshiftEventDataMessageTypeScreenshotRequest
    • HelpshiftEventDataMessageTypeText

CSAT Submit Event

This event is triggered when the user submits a CSAT rating after the conversation ends. The event data object has rating and additionalFeedback keys, which indicates the (star) rating and the additional comments provided by the user with the CSAT form. For your reference, see the below example.

  • Event name: HelpshiftEventCsatSubmit
  • Event data keys:
    • HelpshiftEventDataCsatRating (int)
    • HelpshiftEventDataAdditionalFeedback (string)

Conversation End Event

This event is triggered when the conversation ends (resolved or rejected) and it cannot be reopened.

  • Event name: HelpshiftEventConversationEnd()
  • Event Data: none

Conversation Rejected Event

This event is triggered when an agent rejects the conversation.

  • Event name: HelpshiftEventConversationRejected
  • Event data: none

Conversation Resolved Event

This event is triggered when an agent resolves the conversation.

  • Event name: HelpshiftEventConversationResolved
  • Event data: none

Conversation Reopened Event

When resolution question is enabled, the users are asked if they're satisfied with the resolution. If the user rejects it and sends a new message, then the conversation is reopened and the Conversation Reopened event is triggered.

  • Event name: HelpshiftEventConversationReopened
  • Event data: none

User Authentication Failed Event

If you have user authentication feature enabled on the Dashboard and if you pass an invalid token in the Login(userDataMap), then you will receive this event with reason string. Check here for more info

You have to use BindAuthFailureDelegate to listen to Authentication failure events.

The authentication failure reason is wrapped in an enum EHelpshiftAuthenticationFailureReason Example:

Reason type :

  • EHelpshiftAuthenticationFailureReason.REASON_INVALID_AUTH_TOKEN
  • EHelpshiftAuthenticationFailureReason.REASON_AUTH_TOKEN_NOT_PROVIDED
  • EHelpshiftAuthenticationFailureReason.UNKNOWN