How to achieve what is shown on marketplace demo using UIkit

Demo link : https://main.d2bo0ept0iv0u2.amplifyapp.com/

How do achieve that, “Chat with merchant” button. The sandbox link on the page show a different example code. Not sure, why would anyone demo something and share sample code of something else :slight_smile:

Hello @persistent_coder,

Can you share where you found this demo? Thanks!

Here : Chat for marketplaces | Interactive demos and samples | Sendbird

@persistent_coder,

Thank you for the link. I can see now where the confusion lies. I think the idea is that we have standard sample applications for each language and thus that is what is linked. The Chat with Merchant button is not really something to Sendbird per say. It simply creates a channel and navigates you to a page where you can access that channel. The repo that drives this specific example is private however I’ll provide you with the function that occurs when the button runs:

 const startChat = async () => {
    if (!sellerChannel) return;
    const channelState = (
      await sellerChannel.getMetaData([channelMetaDataKeys.state])
    )[channelMetaDataKeys.state];

    navigation.navigate('Inbox');
    if (channelState === 'initial') {
      navigation.navigate('Chat', { channelUrl: sellerChannel.url });
    }
  };

@Tyler, Got that. Thank you. Cheers