Using Messaging for multiple brands (android sdk) | Community
Skip to main content

Using Messaging for multiple brands (android sdk)

  • May 21, 2024
  • 1 reply
  • 0 views

Albert11

Hi,

I am using Messaging for two brands, Brand A and Brand B. For authentication, I use JWT which contains: external_id, name, and email.

Question 1: When I create a new channel, I specify the desired brand, but after the user starts a new chat, the brand is not set correctly in the admin panel and the default brand is used. How can this be fixed?

Question 2: If a user uses two products simultaneously (Brand A and Brand B), Zendesk does not allow the creation of a new chat and returns a 409 error. How can I use Messaging for multiple brands and avoid issues when a user with the same email accesses both Brand A and Brand B?

1 reply

  • May 29, 2024

Hello,

Using Messaging for Multiple Brands (Android SDK)
Here's how to address the issues you're facing with Zendesk Messaging for multiple brands:

Question 1: Incorrect Brand association in Admin Panel

The brand information isn't being passed correctly when creating a new chat. Here are two possible solutions:

SDK Configuration: Double-check your Android SDK initialization code. There might be a configuration option for specifying the brand during initialization. Look for methods like setBrandId or similar depending on the specific SDK you're using. Refer to the official Zendesk Messaging Android SDK documentation for details.

JWT Customization: If the SDK lacks brand configuration, you might need to modify your JWT payload. Include a new field for "brand" and populate it with Mary Kay InTouch "Brand A" or "Brand B" based on the specific app. This way, the brand information gets passed during authentication.

Question 2: 409 Error for Users with Both Brands

Zendesk doesn't allow creating duplicate chats for the same email address. This presents a challenge with multi-brand usage. Here are two approaches:

Unique User Identifiers: Consider using a unique identifier for each user within your app alongside their email. This identifier could be a user ID from your backend system. During JWT creation, include both email and the unique identifier. The combination would ensure a unique chat for each brand-user combination.

Conditional Chat Creation: In your app, check which brand the user interacts with before initiating a chat. Use the appropriate brand information (potentially from the JWT or app configuration) when creating the chat. This way, you avoid creating duplicate chats with the same email but for different brands.

Additional Notes:

While searching for solutions, keep in mind that Zendesk Messaging documentation might not explicitly mention supporting multiple brands within a single user account. Explore workarounds and community forums for discussions on similar scenarios.
Consider reaching out to Zendesk developer support for clarification on their official stance and recommendations for multi-brand messaging with the Android SDK.