API Options

Helpshift provides several configuration options that you can use to customize the behavior of the SDK. Use these options in conjunction with our Helpshift APIs.

enableContactUs

Controls the visibility of the Helpshift Contact Us button when a user is viewing FAQs. You can customize this option to make it easier or more difficult to contact support.

Option:
enableContactUs
Values:
@"ALWAYS" / @"AFTER_SEARCH_AND_MARKING_UNHELPFUL" / @"AFTER_MARKING_ANSWER_UNHELPFUL" / @"NEVER"
Default:
@"ALWAYS"
Supported by:
showFAQs, showFAQSection, showSingleFAQ

Example:

[HelpshiftSupport showFAQsWithOptions:@{@"enableContactUs":@"NEVER"}];
@"ALWAYS"
show in the tool bar, search, and after marking an FAQ unhelpful. show me
@"AFTER_SEARCH_AND_MARKING_UNHELPFUL"
show after the user has performed search and marked an FAQ unhelpful. show me
@"AFTER_MARKING_ANSWER_UNHELPFUL"
show only after user marks an FAQ unhelpful. show me
@"NEVER"
do not show "Contact Us" button anywhere in the SDK.

gotoConversationAfterContactUs

Determines which screen a user sees after filing an issue via "Contact Us".

Option
gotoConversationAfterContactUs
Values
@"YES" / @"NO"
Default
@"NO"
Supported by
showFAQs, showFAQSection, showSingleFAQ, showConversation

Set the value to YES to go directly to the Conversation view. Use this option when you want to send replies to users immediately after they file issues. This is helpful when you provide 24-hour support or are using New Issue Automations

Example:

[HelpshiftSupport showConversationWithOptions:@{@"gotoConversationAfterContactUs":@"YES"}];

Set the value to NO to avoid entering the Conversation view. A "Thanks for contacting us" alert will be shown to the user after which user is taken back to your app. Most teams use this default option to acknowledge that an issue has been received, but not give the impression that there is a support Agent will reply immediately.

Best Practices

  • Set gotoConversationAfterContactUs to YES and send an autoresponse to your users using a New Issue Automation. In your reply, you can link to your FAQs and provide a timeframe for when you will reply to their issue.

requireEmail

The requireEmail option determines whether email is required or optional for starting a new conversation.

Option
requireEmail
Values
@"YES" / @"NO"
Default
@"NO"
Supported by
showFAQs, showFAQSection, showSingleFAQ, showConversation

Set the value to YES to require the user to fill out a valid email address when filing an issue. Set the value to NO to make email address optional.

Example:

[HelpshiftSupport showConversationWithOptions:@{@"requireEmail":@"YES"}];

Best Practices

  • The requireEmail option will be ignored if any of the following are true: "New Issue Forwarding" is turned ON in Helpshift Dashboard. "Closed Issues Transcript Archiving" is turned ON in Helpshift Dashboard. "Allow anonymous issues" is turned ON in Helpshift Dashboard. "enableFullPrivacy" option is set to true
  • Once requireEmail option is set, the SDK will use that value for all new conversations until it is changed again.

hideNameAndEmail

The hideNameAndEmail flag will hide the name and email fields when the user starts a new conversation.

Option
hideNameAndEmail
Values
@"YES" / @"NO"
Default
@"NO"
Supported by
showFAQs, showFAQSection, showSingleFAQ, showConversation

When the flag is set to YES the name and email fields will be hidden. Use this option when you do not need to collect your user's name or email address.

Set this flag to NO to make Name and Email fields visible when a user files an issue. This is helpful if you need name and/or email to identify your users.

Example:

[HelpshiftSupport showConversationWithOptions:@{@"hideNameAndEmail":@"YES"}];
  • The hideNameAndEmail option will be set to YES if any of the following are true: "Allow anonymous issues" is turned ON in Helpshift Dashboard enableFullPrivacy is set to true.
  • The hideNameAndEmail option will be set to NO if any of the following are true: "New Issue Forwarding" is ON and name and email are not available to the SDK "Closed Issues Transcript Archiving" is ON and name and email are not available to the SDK ** The requireEmail option is set to YES and email is not available to the SDK
  • Once hideNameAndEmail option is set, the SDK will use that value for all new conversations until it is changed again.

conversationPrefillText

The conversationPrefillText API option prefills a new conversation with the supplied string. You can use this option to add crash logs to a new conversation and prompt the user to send those logs as a support ticket. You can also use this option to set context depending on where and when in the app showConversation is being launched from.

Option
conversationPrefillText
Values
Non-empty NSString
Default
Empty string
Supported by
showConversation

Example:

NSString *preFillString = [MyApp getExceptionData];
[HelpshiftSupport showConversationWithOptions:@{@"conversationPrefillText":preFillString}];

To prefill a user's name and email address follow the instructions here.

enableFullPrivacy

In scenarios where the user attaches objectionable content in the screenshots, it becomes a huge COPPA concern. The enableFullPrivacy option will help solve this problem.

Option
enableFullPrivacy
Values
@"YES" / @"NO"
Default
@"NO"
Supported by
showFAQs, showFAQSection, showSingleFAQ, showConversation

Setting the enableFullPrivacy option to YES ensures full COPPA compliance by doing the following:

  1. Disable user-initiated screenshots - players cannot send images without being requested by an Agent.
  2. Do not collect any of the following personal information:
    • Email Address
    • Mobile country code and mobile network code
    • Country code and country
    • Custom meta-data that is labeled "private-data"

To send personally identifiable information through custom meta-data, the information must be added inside a dictionary with a "private-data" key. If this option is set to YES, this data will be removed when the user starts a new conversation.

Example:

[HelpshiftSupport showFAQsWithOptions:@{@"enableFullPrivacy":@"YES"}];

Best Practices

In your registration process, ask your user for his/her age. If the user's age is 13 or younger, set enableFullPrivacy to YES. This way, you comply with COPPA for your children users, but collect valuable user and device data for your other users.

Once enableFullPrivacy flag is set, the SDK will use that value for all further sessions until it is changed again.

showSearchOnNewConversation

Use this option to provide better ticket deflection.

Option
showSearchOnNewConversation
Values
@"YES" / @"NO"
Default
@"NO"
Supported by
showConversation,showFAQs.showFAQSection

Set showSearchOnNewConversation to YES to show relevant FAQs to a user's issue before it is filed. This helps answer tickets with FAQs before they reach your support team. If there are no relevant FAQs, the user can continue filing a new conversation with his original text by pressing the "Send Anyway" button. This flag is also effective in the showFAQs API. In this case if the user starts a conversation from an FAQ page, he is not redirected to search results or if the user has already performed a search in the current session, he will not be taken through search again. If the user wishes to leave a feedback (via Rate our app alert), he will not be taken through search.

Example:

[HelpshiftSupport showConversationWithOptions:@{@"showSearchOnNewConversation":@"YES"}];

showConversationResolutionQuestion

This option enables or disables the showing of Conversation Resolution view after the agent marks an issue resolved. Conversation Resolution is added to the bottom of the screen with a Yes and No button. If the user taps Yes, then this view is replaced with a Start a new conversation view. If the user taps No, then we dismiss the Conversation Resolution view and let them continue the conversation.

This option is set to YES by default, which means that the user will be presented with Conversation Resolution view. If you wish to skip this view then the option needs to be set to NO.

Option
showConversationResolutionQuestion
Values
@"YES" / @"NO"
Default
@"YES"

Example:

[HelpshiftSupport showConversationWithOptions:@{@"showConversationResolutionQuestion":@"NO"}];

enableDefaultFallbackLanguage

This option enables or disables fallback to default language that is English for FAQs.

Option
enableDefaultFallbackLanguage
Values
@"YES" / @"NO"
Default
@"YES"
Supported by
installForApiKey

This option enables or disables fallback to default language that is English for FAQs. In case you have FAQs in multiple languages but do not wish to fallback to English if localisation is missing, set this flag to ‘NO’.

For example if the SDK language is set to French and this option is set to YES, then the FAQs for which french translation is available will be displayed in french and for the FAQs for which french translation is not available will be displayed in English. If the value of this option is set to NO then the FAQs for French translation will be displayed, and the FAQs for which the translation is not provided will not be displayed at all.

Example:

[HelpshiftCore installForApiKey:@"YOUR_API_KEY" domainName:@"YOUR_DOMAIN_NAME" appID:@"YOUR_APP_ID"
                    withOptions:@{@"enableDefaultFallbackLanguage" : @"NO"}];

enableCompulsoryRating

This option determines whether giving Customer Satisfaction rating is compulsory for users before starting a new Conversation.

This option is set to NO by default.

Option
enableCompulsoryRating
Values
@"YES" / @"NO"
Default
@"NO"
Min SDK
v2.0.0
Supported by
showConversation,showFAQs,showFAQSection, showSingleFAQ

Example:

[HelpshiftSupport showConversation:@{@"enableCompulsoryRating":@"YES"}];

In order to enable the CSAT feature, turn on the "Customer Satisfaction Survey" toggle on the Dashboard under App Settings.

enableLogging

Upon setting enableLogging to YES, Helpshift SDK logs will be generated in the Xcode console. This will be useful for debugging the SDK integration issues.

Option:
enableLogging
Values:
@"YES" / @"NO"
Default:
@"NO"
Min SDK
v2.1.0
Supported by:
installForApiKey:domainName:appId:

Example:

    NSDictionary *installConfig = @{@"enableLogging" : @"yes"};
    [HelpshiftCore initializeWithProvider:[HelpshiftSupport sharedInstance]];
    [HelpshiftCore installForApiKey:@"<YOUR_API_KEY>"
                         domainName:@"<YOUR_COMPANY>.helpshift.com"
                              appID:@"<YOUR_APP_ID>"
                        withOptions:installConfig];

disableErrorLogging

The Helpshift macOS SDK will log critical errors to a file in the application directory on the local storage. In the rare case that a user encounters critical errors while using the SDK, this file can be shared with Helpshift support to help us debug. The maximum size of this log file is 100 KB. You can disable this logging by setting disableErrorLogging to YES.

Option:
disableErrorLogging
Values:
@"YES" / @"NO"
Default:
@"NO"
Min SDK
v2.1.0
Supported by:
installForApiKey:domainName:appId:

Example:

    NSDictionary *installConfig = @{@"disableErrorLogging" : @"yes"};
    [HelpshiftCore initializeWithProvider:[HelpshiftSupport sharedInstance]];
    [HelpshiftCore installForApiKey:@"<YOUR_API_KEY>"
                         domainName:@"<YOUR_COMPANY>.helpshift.com"
                              appID:@"<YOUR_APP_ID>"
                        withOptions:installConfig];

You can collect the logs file from an end user's machine and share it with Helpshift supporte team. Use the logFilePath API to get the log file's path on the end user's machine.

Example:

    NSString *helpshiftLogFilePath = [HelpshiftCore logFilePath];