We are facing difficulty while working with Sendbird React Native UIKIT. So, we are trying to connect to the Sendbird server using the useConnection
hook provided by Sendbird react native uikit. It gives us an error with a status code of 800120.
The steps that we have followed are:
- Wrapping of our app in the
SendbirdUiKitContainer
<SendbirdUIKitContainer
appId="F53DF97C-E104-4603-A396-8FC7DB7BB37A"
chatOptions={{ localCacheStorage: AsyncStorage }}
platformServices={{
file: FileService,
notification: NotificationService,
clipboard: ClipboardService,
media: MediaService,
}}
>
// our app
</SendbirdUIKitContainer>
- and then connecting to the Sendbird server.
const onPressChatWithUs = async () => {
console.log("before connection");
try {
const response = await connect("097094", {
nickname: "Yuvraj",
accessToken: "24ef5e8e34e1da4bab36ff8605bdc3cbf02b45a6",
});
console.log("after successful connection", response);
navigation.navigate("GroupChannelList");
} catch (error) {
console.log(error);
}
};
When onPressChatWithUs
is triggered, then it first consoles “before connection” as expected, and after a pause of 9-10 seconds throws an error with a status code of 800120
. The snapshot depicting the same is attached below.
SDK versions that we have used are:
"@sendbird/chat": "^4.6.0",
"@sendbird/uikit-react-native": "^2.4.1",
When searching for the error code, it shows:
The connection failed due to the unstable network or an unexpected error in the Chat SDK network library.
We have followed each step mentioned on https://sendbird.com/docs/uikit/v3/react-native/introduction/send-first-message#1-send-your-first-message precisely
Can someone please assist us to resolve this issue?