How to record a resource created for Calling and chat in ACS?

Dev 111 Reputation points
2020-12-21T08:15:29.933+00:00

In the Prerequisites it is mentioned that I need to record my connection string, but I didn't find anything such to record my connection string.

I am implementing Chat using ACS but when I am using token that I being generated for calling but I am always getting 401 error and thread creation is getting failed.

Can you please guide me with this.

  1. Do I need to create access token for chat freshly?
  2. How can I record my resource or "You'll need to record your resource endpoint for this quickstart." What it means actually.

Thanks

Azure Communication Services
Azure Communication Services
An Azure communication platform for deploying applications across devices and platforms.
847 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. ajkuma 25,786 Reputation points Microsoft Employee
    2020-12-21T18:05:38.743+00:00

    @Dev , I believe you’re referring to the Azure doc ‘prerequisites’ section in the document.

    To rectify 401 unauthorized error, kindly re-verify that you have a valid access token.

    1. Once you have an access token, you should be able to reuse it as long as it has not expired (24 hours).
    2. 'Record' in this context means just to keep a note/keep in mind, it is required for the creation of the client.

    I have shared your feedback with the content author to review and we'll update the doc as necessary to more clarity.

    Uri endpoint = new Uri("https://<RESOURCE_NAME>.communication.azure.com");   
    CommunicationUserCredential communicationUserCredential = new CommunicationUserCredential(<Access_Token>);   
    ChatClient chatClient = new ChatClient(endpoint, communicationUserCredential);  
    

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.