Zendesk Android User Login Issue | Community
Skip to main content

Zendesk Android User Login Issue

  • May 12, 2022
  • 3 replies
  • 0 views

Artem14

I'm trying to make a login for user on android. I enable JSON Web Token in Single sign-on admin panel and enable External Authentication in End user authentication. I also crease secret key in End user authentication section on Messaging panel. 

Then I'm trying to generate JWT token on android side and sign with secret key that I generated in Messaging panel and using HS256 algorithm.

I also fill all params that was required in zendesk docs such as iat, jti, email, name and external_id. Without external_id I have error that it must be filled. 

com.squareup.moshi.JsonDataException: Required value 'externalId' (JSON name 'external_id') missing at $

external_id I fill with my end user_id; I also try to fill it with ID that in End user authentication section on Messaging panel starting with app...

Secret key for sign JWT I'm also tryed different such as Shared secret in Single sign-on admin panel.

On all this attempts I'm always get HTTP 401 Unauthorized.

This is one of JWT token that I generate 

eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpYXQiOjE2NTIzNjU4NjAsImp0aSI6ImExMjFiNWZlLWU0OTUtNGU3Yi1iYzU4LTkzZGE4OTZlNjkyNiIsImV4dGVybmFsX2lkIjoiYXBwXzYyN2QxMDgyODZhNzU4MDBmNjI2YzBjOCIsImVtYWlsIjoiZXhhbXBsZUBlbWFpbC5jb20iLCJuYW1lIjoibmV3VXNlciJ9.ocH4E0vzl5VCm2SoIWCqXAbRGr96PvS2EIAiDffpghs

I assume that I'm using wrong sign token for JWT or I something not enable in admin panel.

I'm using latest zendesk version:

zendesk.messaging:messaging-android:2.3.0

3 replies

Greg29
  • May 16, 2022
Hi Artem! It sounds like you're trying to use the SSO method of JWT to work with your SDK, which does not work. I would recommend reading through that article and letting me know if you continue seeing issues!

Artem14
  • Author
  • May 17, 2022

Thanks for response! I read the article and try to implement - It's seems that I need to use different SDK of zendesk to init and then set identity. I tried this one 

implementation group: 'com.zendesk', name: 'messaging', version: '5.2.3'
implementation group: 'com.zendesk', name: 'support', version: '5.0.8'

But this sdk does not provide api that I using such as PushNotifications, Zendesk.instance.eventFlow.

This API provide 

zendesk.messaging:messaging-android

And also it have methods login and logout. Login method need JWT token. Can I make login user with this method and if so - which token should I use?


  • August 12, 2022

Hi, my team of agents hasnt been able to login and action customer enquiries today. they keep getting logged off. We have tried clearing cache cookies, tried different browsers however nothing is working. can someone help