401 errors randomly calling API on v3

We are trying to integrate CometChat into our existing app and use the CometChatGroupListWithMessages. Randomly we will see a 401 error trying to call APIs. For example on page loads I will consonantly see it on this call: https://<APP_ID>.apiclient-us.cometchat.io/v3.0/groups?per_page=30&page=1. The initialization completed successfully and was put in our main.ts. Is this the right place for that?

We also noticed using the CometChatUI, this will happen on load as well but when we clicked to a different tab it works and clicking back works which is the same call on load.

Any ideas?

Hi @ashworcp,

Can you please let us know which UI Kit you are using and also the version of the UI Kit you are using?

Warm Regards,

Mayur Bhandari

@mayur.bhandari - I’m using this one: https://github.com/cometchat-pro/cometchat-pro-angular-ui-kit/tree/v3