diff --git a/sdk/communication/azure-communication-chat/README.md b/sdk/communication/azure-communication-chat/README.md index 60aa755c0e8e..bb51eaa966a4 100644 --- a/sdk/communication/azure-communication-chat/README.md +++ b/sdk/communication/azure-communication-chat/README.md @@ -36,8 +36,8 @@ tokenresponse = identity_client.issue_token(user, scopes=["chat"]) token = tokenresponse.token ``` -The `user` created above will be used later, because that user should be added as a member of new chat thread when you creating -it with this token. It is because the initiator of the create request must be in the list of the members of the chat thread. +The `user` created above will be used later, because that user should be added as a participant of new chat thread when you creating +it with this token. It is because the initiator of the create request must be in the list of the participants of the chat thread. ## Create the Chat Client @@ -54,12 +54,12 @@ chat_client = ChatClient(endpoint, CommunicationUserCredential(token)) ## Create Chat Thread Client The ChatThreadClient will allow you to perform operations specific to a chat thread, like send message, get message, update -the chat thread topic, add members to chat thread, etc. +the chat thread topic, add participants to chat thread, etc. You can get it by creating a new chat thread using ChatClient: ```python -chat_thread_client = chat_client.create_chat_thread(topic, thread_members) +chat_thread_client = chat_client.create_chat_thread(topic, thread_participants) ``` Alternatively, if you have created a chat thread before and you have its thread_id, you can create it by: @@ -70,14 +70,14 @@ chat_thread_client = chat_client.get_chat_thread_client(thread_id) # Key concepts -A chat conversation is represented by a chat thread. Each user in the thread is called a thread member. Thread members can chat with one another privately in a 1:1 chat or huddle up in a 1:N group chat. Users also get near real-time updates for when others are typing and when they have read the messages. +A chat conversation is represented by a chat thread. Each user in the thread is called a thread participant. Thread participants can chat with one another privately in a 1:1 chat or huddle up in a 1:N group chat. Users also get near real-time updates for when others are typing and when they have read the messages. Once you initialized a `ChatClient` class, you can do the following chat operations: ## Create, get, update, and delete threads ```Python -create_chat_thread(topic, thread_members, **kwargs) +create_chat_thread(topic, thread_participants, **kwargs) get_chat_thread(thread_id, **kwargs) list_chat_threads(**kwargs) delete_chat_thread(thread_id, **kwargs) @@ -88,7 +88,7 @@ Once you initialized a `ChatThreadClient` class, you can do the following chat o ## Update thread ```python -update_thread(topic, **kwargs) +update_topic(topic, **kwargs) ``` ## Send, get, update, and delete messages @@ -101,12 +101,12 @@ update_message(message_id, content, **kwargs) delete_message(message_id, **kwargs) ``` -## Get, add, and remove members +## Get, add, and remove participants ```Python -list_members(**kwargs) -add_members(thread_members, **kwargs) -remove_member(member_id, **kwargs) +list_participants(**kwargs) +add_participants(thread_participants, **kwargs) +remove_participant(participant_id, **kwargs) ``` ## Send typing notification @@ -130,7 +130,7 @@ The following sections provide several code snippets covering some of the most c ## Thread Operations @@ -140,24 +140,24 @@ The following sections provide several code snippets covering some of the most c Use the `create_chat_thread` method to create a chat thread client object. - Use `topic` to give a thread topic; -- Use `thread_members` to list the `ChatThreadMember` to be added to the thread; +- Use `thread_participants` to list the `ChatThreadParticipant` to be added to the thread; - `user`, required, it is the `CommunicationUser` you created by CommunicationIdentityClient.create_user() from User Access Tokens -- `display_name`, optional, is the display name for the thread member. -- `share_history_time`, optional, time from which the chat history is shared with the member. +- `display_name`, optional, is the display name for the thread participant. +- `share_history_time`, optional, time from which the chat history is shared with the participant. `ChatThreadClient` is the result returned from creating a thread, you can use it to perform other chat operations to this chat thread ```Python -from azure.communication.chat import ChatThreadMember +from azure.communication.chat import ChatThreadParticipant topic = "test topic" -thread_members = [ChatThreadMember( +thread_participants = [ChatThreadParticipant( user='', display_name='name', share_history_time=datetime.utcnow() )] -chat_thread_client = chat_client.create_chat_thread(topic, thread_members) +chat_thread_client = chat_client.create_chat_thread(topic, thread_participants) thread_id = chat_thread_client.thread_id ``` @@ -281,50 +281,50 @@ Use `delete_message` to delete a message. chat_thread_client.delete_message(message_id) ``` -## Thread Member Operations +## Thread Participant Operations -### Get thread members +### Get thread participants -Use `list_members` to retrieve the members of the thread. +Use `list_participants` to retrieve the participants of the thread. -An iterator of `[ChatThreadMember]` is the response returned from listing members +An iterator of `[ChatThreadParticipant]` is the response returned from listing participants ```python -chat_thread_members = chat_thread_client.list_members() -for chat_thread_member in chat_thread_members: - print(chat_thread_member) +chat_thread_participants = chat_thread_client.list_participants() +for chat_thread_participant in chat_thread_participants: + print(chat_thread_participant) ``` -### Add thread members +### Add thread participants -Use `add_members` method to add thread members to the thread. +Use `add_participants` method to add thread participants to the thread. -- Use `thread_members` to list the `ChatThreadMember` to be added to the thread; +- Use `thread_participants` to list the `ChatThreadParticipant` to be added to the thread; - `user`, required, it is the `CommunicationUser` you created by CommunicationIdentityClient.create_user() from User Access Tokens -- `display_name`, optional, is the display name for the thread member. -- `share_history_time`, optional, time from which the chat history is shared with the member. +- `display_name`, optional, is the display name for the thread participant. +- `share_history_time`, optional, time from which the chat history is shared with the participant. ```Python -from azure.communication.chat import ChatThreadMember +from azure.communication.chat import ChatThreadParticipant from datetime import datetime -member = ChatThreadMember( +participant = ChatThreadParticipant( user='', display_name='name', share_history_time=datetime.utcnow()) -thread_members = [member] -chat_thread_client.add_members(thread_members) +thread_participants = [participant] +chat_thread_client.add_participants(thread_participants) ``` -### Remove thread member +### Remove thread participant -Use `remove_member` method to remove thread member from the thread identified by threadId. +Use `remove_participant` method to remove thread participant from the thread identified by threadId. `user` is the `CommunicationUser` you created by CommunicationIdentityClient.create_user() from User Access Tokens and was added into this chat thread. ```python -chat_thread_client.remove_member(user) +chat_thread_client.remove_participant(user) ``` ## Events Operations @@ -349,7 +349,7 @@ chat_thread_client.send_read_receipt(message_id) `list_read_receipts` method retrieves read receipts for a thread. -An iterator of `[ReadReceipt]` is the response returned from listing read receipts +An iterator of `[ChatMessageReadReceipt]` is the response returned from listing read receipts ```python read_receipts = chat_thread_client.list_read_receipts() diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/__init__.py b/sdk/communication/azure-communication-chat/azure/communication/chat/__init__.py index 1ddd2a494b36..dfbdd67b37de 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/__init__.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/__init__.py @@ -8,10 +8,10 @@ ) from ._shared.user_credential import CommunicationUserCredential from ._models import ( - ChatThreadMember, + ChatThreadParticipant, ChatMessage, ChatThread, - ReadReceipt, + ChatMessageReadReceipt, ) from ._shared.models import CommunicationUser @@ -20,12 +20,12 @@ 'ChatThreadClient', 'ChatMessage', 'ChatMessagePriority', - 'ReadReceipt', + 'ChatMessageReadReceipt', 'SendChatMessageResult', 'ChatThread', 'ChatThreadInfo', 'CommunicationUserCredential', - 'ChatThreadMember', + 'ChatThreadParticipant', 'CommunicationUser', ] __version__ = VERSION diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_chat_client.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_chat_client.py index ca3914de99da..25bd2187344f 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_chat_client.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_chat_client.py @@ -11,15 +11,17 @@ from urlparse import urlparse # type: ignore from azure.core.tracing.decorator import distributed_trace -from azure.core.exceptions import HttpResponseError from ._chat_thread_client import ChatThreadClient from ._common import CommunicationUserCredentialPolicy from ._shared.user_credential import CommunicationUserCredential from ._generated import AzureCommunicationChatService from ._generated.models import CreateChatThreadRequest -from ._models import ChatThread -from ._utils import _to_utc_datetime # pylint: disable=unused-import +from ._models import ( + ChatThread, + ChatThreadParticipant +) +from ._utils import _to_utc_datetime, return_response # pylint: disable=unused-import from ._version import SDK_MONIKER if TYPE_CHECKING: @@ -117,7 +119,7 @@ def get_chat_thread_client( @distributed_trace def create_chat_thread( self, topic, # type: str - thread_members, # type: list[ChatThreadMember] + thread_participants, # type: list[ChatThreadParticipant] **kwargs # type: Any ): # type: (...) -> ChatThreadClient @@ -125,8 +127,8 @@ def create_chat_thread( :param topic: Required. The thread topic. :type topic: str - :param thread_members: Required. Members to be added to the thread. - :type thread_members: list[~azure.communication.chat.ChatThreadMember] + :param thread_participants: Required. Participants to be added to the thread. + :type thread_participants: list[~azure.communication.chat.ChatThreadParticipant] :return: ChatThreadClient :rtype: ~azure.communication.chat.ChatThreadClient :raises: ~azure.core.exceptions.HttpResponseError, ValueError @@ -142,28 +144,29 @@ def create_chat_thread( """ if not topic: raise ValueError("topic cannot be None.") - if not thread_members: - raise ValueError("List of ThreadMember cannot be None.") - - members = [m._to_generated() for m in thread_members] # pylint:disable=protected-access - create_thread_request = CreateChatThreadRequest(topic=topic, members=members) - - create_chat_thread_result = self._client.create_chat_thread(create_thread_request, **kwargs) - - multiple_status = create_chat_thread_result.multiple_status - thread_status = [status for status in multiple_status if status.type == "Thread"] - if not thread_status: - raise HttpResponseError(message="Can not find chat thread status result from: {}".format(thread_status)) - if thread_status[0].status_code != 201: - raise HttpResponseError(message="Chat thread creation failed with status code {}, message: {}.".format( - thread_status[0].status_code, thread_status[0].message)) - - thread_id = thread_status[0].id - + if not thread_participants: + raise ValueError("List of ChatThreadParticipant cannot be None.") + + participants = [m._to_generated() for m in thread_participants] # pylint:disable=protected-access + create_thread_request = CreateChatThreadRequest(topic=topic, participants=participants) + + response, create_chat_thread_result = self._client.create_chat_thread( + create_thread_request, cls=return_response, **kwargs) + if response is not None: + response_header = response.http_response.headers + if ('Azure-Acs-InvalidParticipants' in response_header.keys() and + response_header['Azure-Acs-InvalidParticipants'] is not None): + invalid_participant_and_reason_list = response_header['Azure-Acs-InvalidParticipants'].split('|') + errors = [] + for invalid_participant_and_reason in invalid_participant_and_reason_list: + participant, reason = invalid_participant_and_reason.split(',', 1) + errors.append('participant ' + participant + ' failed to join thread ' + + create_chat_thread_result.id + ' return statue code ' + reason) + raise ValueError(errors) return ChatThreadClient( endpoint=self._endpoint, credential=self._credential, - thread_id=thread_id, + thread_id=create_chat_thread_result.id, **kwargs ) diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_chat_thread_client.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_chat_thread_client.py index fee9156a2b63..c2d304607642 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_chat_thread_client.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_chat_thread_client.py @@ -16,16 +16,16 @@ from ._common import CommunicationUserCredentialPolicy from ._generated import AzureCommunicationChatService from ._generated.models import ( - AddChatThreadMembersRequest, + AddChatParticipantsRequest, SendReadReceiptRequest, SendChatMessageRequest, UpdateChatMessageRequest, UpdateChatThreadRequest ) from ._models import ( - ChatThreadMember, + ChatThreadParticipant, ChatMessage, - ReadReceipt + ChatMessageReadReceipt ) from ._utils import _to_utc_datetime # pylint: disable=unused-import @@ -42,7 +42,7 @@ class ChatThreadClient(object): """A client to interact with the AzureCommunicationService Chat gateway. Instances of this class is normally created by ChatClient.create_chat_thread() - This client provides operations to add member to chat thread, remove member from + This client provides operations to add participant to chat thread, remove participant from chat thread, send message, delete message, update message, send typing notifications, send and list read receipt @@ -113,7 +113,7 @@ def thread_id(self): return self._thread_id @distributed_trace - def update_thread( + def update_topic( self, topic=None, # type: Optional[str] **kwargs # type: Any @@ -132,17 +132,17 @@ def update_thread( .. admonition:: Example: .. literalinclude:: ../samples/chat_thread_client_sample.py - :start-after: [START update_thread] - :end-before: [END update_thread] + :start-after: [START update_topic] + :end-before: [END update_topic] :language: python :dedent: 8 :caption: Updating chat thread. """ - update_thread_request = UpdateChatThreadRequest(topic=topic) + update_topic_request = UpdateChatThreadRequest(topic=topic) return self._client.update_chat_thread( chat_thread_id=self._thread_id, - body=update_thread_request, + update_chat_thread_request=update_topic_request, **kwargs) @distributed_trace @@ -176,7 +176,7 @@ def send_read_receipt( post_read_receipt_request = SendReadReceiptRequest(chat_message_id=message_id) return self._client.send_chat_read_receipt( self._thread_id, - body=post_read_receipt_request, + send_read_receipt_request=post_read_receipt_request, **kwargs) @distributed_trace @@ -184,11 +184,11 @@ def list_read_receipts( self, **kwargs # type: Any ): - # type: (...) -> ItemPaged[ReadReceipt] + # type: (...) -> ItemPaged[ChatMessageReadReceipt] """Gets read receipts for a thread. :keyword callable cls: A custom type or function that will be passed the direct response - :return: ItemPaged[:class:`~azure.communication.chat.ReadReceipt`] + :return: ItemPaged[:class:`~azure.communication.chat.ChatMessageReadReceipt`] :rtype: ~azure.core.paging.ItemPaged :raises: ~azure.core.exceptions.HttpResponseError, ValueError @@ -203,7 +203,7 @@ def list_read_receipts( """ return self._client.list_chat_read_receipts( self._thread_id, - cls=lambda objs: [ReadReceipt._from_generated(x) for x in objs], # pylint:disable=protected-access + cls=lambda objs: [ChatMessageReadReceipt._from_generated(x) for x in objs], # pylint:disable=protected-access **kwargs) @distributed_trace @@ -236,7 +236,7 @@ def send_message( content, # type: str **kwargs # type: Any ): - # type: (...) -> SendChatMessageResult + # type: (...) -> str """Sends a message to a thread. :param content: Required. Chat message content. @@ -246,8 +246,8 @@ def send_message( :keyword str sender_display_name: The display name of the message sender. This property is used to populate sender name for push notifications. :keyword callable cls: A custom type or function that will be passed the direct response - :return: SendChatMessageResult, or the result of cls(response) - :rtype: ~azure.communication.chat.SendChatMessageResult + :return: str, or the result of cls(response) + :rtype: str :raises: ~azure.core.exceptions.HttpResponseError, ValueError .. admonition:: Example: @@ -270,10 +270,12 @@ def send_message( priority=priority, sender_display_name=sender_display_name ) - return self._client.send_chat_message( + + send_chat_message_result = self._client.send_chat_message( chat_thread_id=self._thread_id, - body=create_message_request, + send_chat_message_request=create_message_request, **kwargs) + return send_chat_message_result.id @distributed_trace def get_message( @@ -376,7 +378,7 @@ def update_message( return self._client.update_chat_message( chat_thread_id=self._thread_id, chat_message_id=message_id, - body=update_message_request, + update_chat_message_request=update_message_request, **kwargs) @distributed_trace @@ -413,44 +415,80 @@ def delete_message( **kwargs) @distributed_trace - def list_members( + def list_participants( self, **kwargs # type: Any ): - # type: (...) -> ItemPaged[ChatThreadMember] - """Gets the members of a thread. + # type: (...) -> ItemPaged[ChatThreadParticipant] + """Gets the participants of a thread. :keyword callable cls: A custom type or function that will be passed the direct response - :return: ItemPaged[:class:`~azure.communication.chat.ChatThreadMember`] + :return: ItemPaged[:class:`~azure.communication.chat.ChatThreadParticipant`] :rtype: ~azure.core.paging.ItemPaged :raises: ~azure.core.exceptions.HttpResponseError, ValueError .. admonition:: Example: .. literalinclude:: ../samples/chat_thread_client_sample.py - :start-after: [START list_members] - :end-before: [END list_members] + :start-after: [START list_participants] + :end-before: [END list_participants] :language: python :dedent: 8 - :caption: Listing members of chat thread. + :caption: Listing participants of chat thread. """ - return self._client.list_chat_thread_members( + return self._client.list_chat_participants( self._thread_id, - cls=lambda objs: [ChatThreadMember._from_generated(x) for x in objs], # pylint:disable=protected-access + cls=lambda objs: [ChatThreadParticipant._from_generated(x) for x in objs], # pylint:disable=protected-access + **kwargs) + + @distributed_trace + def add_participant( + self, + thread_participant, # type: ChatThreadParticipant + **kwargs # type: Any + ): + # type: (...) -> None + """Adds single thread participant to a thread. If participant already exist, no change occurs. + + :param thread_participant: Required. Single thread participant to be added to the thread. + :type thread_participant: ~azure.communication.chat.ChatThreadParticipant + :keyword callable cls: A custom type or function that will be passed the direct response + :return: None, or the result of cls(response) + :rtype: None + :raises: ~azure.core.exceptions.HttpResponseError, ValueError + + .. admonition:: Example: + + .. literalinclude:: ../samples/chat_thread_client_sample.py + :start-after: [START add_participant] + :end-before: [END add_participant] + :language: python + :dedent: 8 + :caption: Adding single participant to chat thread. + """ + if not thread_participant: + raise ValueError("thread_participant cannot be None.") + + participants = [thread_participant._to_generated()] # pylint:disable=protected-access + add_thread_participants_request = AddChatParticipantsRequest(participants=participants) + + return self._client.add_chat_participants( + chat_thread_id=self._thread_id, + add_chat_participants_request=add_thread_participants_request, **kwargs) @distributed_trace - def add_members( + def add_participants( self, - thread_members, # type: list[ChatThreadMember] + thread_participants, # type: list[ChatThreadParticipant] **kwargs # type: Any ): # type: (...) -> None - """Adds thread members to a thread. If members already exist, no change occurs. + """Adds thread participants to a thread. If participants already exist, no change occurs. - :param thread_members: Required. Thread members to be added to the thread. - :type thread_members: list[~azure.communication.chat.ChatThreadMember] + :param thread_participants: Required. Thread participants to be added to the thread. + :type thread_participants: list[~azure.communication.chat.ChatThreadParticipant] :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -459,33 +497,33 @@ def add_members( .. admonition:: Example: .. literalinclude:: ../samples/chat_thread_client_sample.py - :start-after: [START add_members] - :end-before: [END add_members] + :start-after: [START add_participants] + :end-before: [END add_participants] :language: python :dedent: 8 - :caption: Adding members to chat thread. + :caption: Adding participants to chat thread. """ - if not thread_members: - raise ValueError("thread_members cannot be None.") + if not thread_participants: + raise ValueError("thread_participants cannot be None.") - members = [m._to_generated() for m in thread_members] # pylint:disable=protected-access - add_thread_members_request = AddChatThreadMembersRequest(members=members) + participants = [m._to_generated() for m in thread_participants] # pylint:disable=protected-access + add_thread_participants_request = AddChatParticipantsRequest(participants=participants) - return self._client.add_chat_thread_members( + return self._client.add_chat_participants( chat_thread_id=self._thread_id, - body=add_thread_members_request, + add_chat_participants_request=add_thread_participants_request, **kwargs) @distributed_trace - def remove_member( + def remove_participant( self, user, # type: CommunicationUser **kwargs # type: Any ): # type: (...) -> None - """Remove a member from a thread. + """Remove a participant from a thread. - :param user: Required. User identity of the thread member to remove from the thread. + :param user: Required. User identity of the thread participant to remove from the thread. :type user: ~azure.communication.chat.CommunicationUser :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) @@ -495,18 +533,18 @@ def remove_member( .. admonition:: Example: .. literalinclude:: ../samples/chat_thread_client_sample.py - :start-after: [START remove_member] - :end-before: [END remove_member] + :start-after: [START remove_participant] + :end-before: [END remove_participant] :language: python :dedent: 8 - :caption: Removing member from chat thread. + :caption: Removing participant from chat thread. """ if not user: raise ValueError("user cannot be None.") - return self._client.remove_chat_thread_member( + return self._client.remove_chat_participant( chat_thread_id=self._thread_id, - chat_member_id=user.identifier, + chat_participant_id=user.identifier, **kwargs) def close(self): diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/_azure_communication_chat_service.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/_azure_communication_chat_service.py index 996122990a6b..386507ece71d 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/_azure_communication_chat_service.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/_azure_communication_chat_service.py @@ -39,6 +39,7 @@ def __init__( client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} self._serialize = Serializer(client_models) + self._serialize.client_side_validation = False self._deserialize = Deserializer(client_models) diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/_configuration.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/_configuration.py index 65b08c58e662..ffeba8865187 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/_configuration.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/_configuration.py @@ -38,7 +38,7 @@ def __init__( super(AzureCommunicationChatServiceConfiguration, self).__init__(**kwargs) self.endpoint = endpoint - self.api_version = "2020-09-21-preview2" + self.api_version = "2020-11-01-preview3" kwargs.setdefault('sdk_moniker', 'azurecommunicationchatservice/{}'.format(VERSION)) self._configure(**kwargs) diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/_azure_communication_chat_service.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/_azure_communication_chat_service.py index eb5faba2dd2b..0b37b0a92e70 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/_azure_communication_chat_service.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/_azure_communication_chat_service.py @@ -34,6 +34,7 @@ def __init__( client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} self._serialize = Serializer(client_models) + self._serialize.client_side_validation = False self._deserialize = Deserializer(client_models) diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/_configuration.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/_configuration.py index 60e56e152f13..ccd461ebf21b 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/_configuration.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/_configuration.py @@ -33,7 +33,7 @@ def __init__( super(AzureCommunicationChatServiceConfiguration, self).__init__(**kwargs) self.endpoint = endpoint - self.api_version = "2020-09-21-preview2" + self.api_version = "2020-11-01-preview3" kwargs.setdefault('sdk_moniker', 'azurecommunicationchatservice/{}'.format(VERSION)) self._configure(**kwargs) diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/operations/_azure_communication_chat_service_operations.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/operations/_azure_communication_chat_service_operations.py index b1ab6ae6f996..8153823a07ec 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/operations/_azure_communication_chat_service_operations.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/aio/operations/_azure_communication_chat_service_operations.py @@ -14,7 +14,7 @@ from azure.core.pipeline import PipelineResponse from azure.core.pipeline.transport import AsyncHttpResponse, HttpRequest -from ... import models +from ... import models as _models T = TypeVar('T') ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -25,29 +25,29 @@ def list_chat_read_receipts( self, chat_thread_id: str, **kwargs - ) -> AsyncIterable["models.ReadReceiptsCollection"]: - """Gets read receipts for a thread. + ) -> AsyncIterable["_models.ChatMessageReadReceiptsCollection"]: + """Gets chat message read receipts for a thread. - Gets read receipts for a thread. + Gets chat message read receipts for a thread. - :param chat_thread_id: Thread id to get the read receipts for. + :param chat_thread_id: Thread id to get the chat message read receipts for. :type chat_thread_id: str :keyword callable cls: A custom type or function that will be passed the direct response - :return: An iterator like instance of either ReadReceiptsCollection or the result of cls(response) - :rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.communication.chat.models.ReadReceiptsCollection] + :return: An iterator like instance of either ChatMessageReadReceiptsCollection or the result of cls(response) + :rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.communication.chat.models.ChatMessageReadReceiptsCollection] :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ReadReceiptsCollection"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatMessageReadReceiptsCollection"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" def prepare_request(next_link=None): @@ -80,7 +80,7 @@ def prepare_request(next_link=None): return request async def extract_data(pipeline_response): - deserialized = self._deserialize('ReadReceiptsCollection', pipeline_response) + deserialized = self._deserialize('ChatMessageReadReceiptsCollection', pipeline_response) list_of_elem = deserialized.value if cls: list_of_elem = cls(list_of_elem) @@ -106,7 +106,7 @@ async def get_next(next_link=None): async def send_chat_read_receipt( self, chat_thread_id: str, - body: "models.SendReadReceiptRequest", + send_read_receipt_request: "_models.SendReadReceiptRequest", **kwargs ) -> None: """Sends a read receipt event to a thread, on behalf of a user. @@ -115,8 +115,8 @@ async def send_chat_read_receipt( :param chat_thread_id: Thread id to send the read receipt event to. :type chat_thread_id: str - :param body: Read receipt details. - :type body: ~azure.communication.chat.models.SendReadReceiptRequest + :param send_read_receipt_request: Read receipt details. + :type send_read_receipt_request: ~azure.communication.chat.models.SendReadReceiptRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -126,13 +126,13 @@ async def send_chat_read_receipt( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" content_type = kwargs.pop("content_type", "application/json") accept = "application/json" @@ -154,7 +154,7 @@ async def send_chat_read_receipt( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'SendReadReceiptRequest') + body_content = self._serialize.body(send_read_receipt_request, 'SendReadReceiptRequest') body_content_kwargs['content'] = body_content request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = await self._client._pipeline.run(request, stream=False, **kwargs) @@ -172,33 +172,33 @@ async def send_chat_read_receipt( async def send_chat_message( self, chat_thread_id: str, - body: "models.SendChatMessageRequest", + send_chat_message_request: "_models.SendChatMessageRequest", **kwargs - ) -> "models.SendChatMessageResult": + ) -> "_models.SendChatMessageResult": """Sends a message to a thread. Sends a message to a thread. :param chat_thread_id: The thread id to send the message to. :type chat_thread_id: str - :param body: Details of the message to send. - :type body: ~azure.communication.chat.models.SendChatMessageRequest + :param send_chat_message_request: Details of the message to send. + :type send_chat_message_request: ~azure.communication.chat.models.SendChatMessageRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: SendChatMessageResult, or the result of cls(response) :rtype: ~azure.communication.chat.models.SendChatMessageResult :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.SendChatMessageResult"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.SendChatMessageResult"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" content_type = kwargs.pop("content_type", "application/json") accept = "application/json" @@ -220,7 +220,7 @@ async def send_chat_message( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'SendChatMessageRequest') + body_content = self._serialize.body(send_chat_message_request, 'SendChatMessageRequest') body_content_kwargs['content'] = body_content request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = await self._client._pipeline.run(request, stream=False, **kwargs) @@ -244,7 +244,7 @@ def list_chat_messages( max_page_size: Optional[int] = None, start_time: Optional[datetime.datetime] = None, **kwargs - ) -> AsyncIterable["models.ChatMessagesCollection"]: + ) -> AsyncIterable["_models.ChatMessagesCollection"]: """Gets a list of messages from a thread. Gets a list of messages from a thread. @@ -261,17 +261,17 @@ def list_chat_messages( :rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.communication.chat.models.ChatMessagesCollection] :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatMessagesCollection"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatMessagesCollection"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" def prepare_request(next_link=None): @@ -336,7 +336,7 @@ async def get_chat_message( chat_thread_id: str, chat_message_id: str, **kwargs - ) -> "models.ChatMessage": + ) -> "_models.ChatMessage": """Gets a message by id. Gets a message by id. @@ -350,17 +350,17 @@ async def get_chat_message( :rtype: ~azure.communication.chat.models.ChatMessage :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatMessage"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatMessage"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL @@ -400,7 +400,7 @@ async def update_chat_message( self, chat_thread_id: str, chat_message_id: str, - body: "models.UpdateChatMessageRequest", + update_chat_message_request: "_models.UpdateChatMessageRequest", **kwargs ) -> None: """Updates a message. @@ -411,8 +411,8 @@ async def update_chat_message( :type chat_thread_id: str :param chat_message_id: The message id. :type chat_message_id: str - :param body: Details of the request to update the message. - :type body: ~azure.communication.chat.models.UpdateChatMessageRequest + :param update_chat_message_request: Details of the request to update the message. + :type update_chat_message_request: ~azure.communication.chat.models.UpdateChatMessageRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -422,14 +422,14 @@ async def update_chat_message( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" - content_type = kwargs.pop("content_type", "application/json") + api_version = "2020-11-01-preview3" + content_type = kwargs.pop("content_type", "application/merge-patch+json") accept = "application/json" # Construct URL @@ -451,13 +451,13 @@ async def update_chat_message( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'UpdateChatMessageRequest') + body_content = self._serialize.body(update_chat_message_request, 'UpdateChatMessageRequest') body_content_kwargs['content'] = body_content request = self._client.patch(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = await self._client._pipeline.run(request, stream=False, **kwargs) response = pipeline_response.http_response - if response.status_code not in [200]: + if response.status_code not in [204]: map_error(status_code=response.status_code, response=response, error_map=error_map) raise HttpResponseError(response=response) @@ -489,13 +489,13 @@ async def delete_chat_message( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL @@ -548,13 +548,13 @@ async def send_typing_notification( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL @@ -586,33 +586,33 @@ async def send_typing_notification( send_typing_notification.metadata = {'url': '/chat/threads/{chatThreadId}/typing'} # type: ignore - def list_chat_thread_members( + def list_chat_participants( self, chat_thread_id: str, **kwargs - ) -> AsyncIterable["models.ChatThreadMembersCollection"]: - """Gets the members of a thread. + ) -> AsyncIterable["_models.ChatParticipantsCollection"]: + """Gets the participants of a thread. - Gets the members of a thread. + Gets the participants of a thread. - :param chat_thread_id: Thread id to get members for. + :param chat_thread_id: Thread id to get participants for. :type chat_thread_id: str :keyword callable cls: A custom type or function that will be passed the direct response - :return: An iterator like instance of either ChatThreadMembersCollection or the result of cls(response) - :rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.communication.chat.models.ChatThreadMembersCollection] + :return: An iterator like instance of either ChatParticipantsCollection or the result of cls(response) + :rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.communication.chat.models.ChatParticipantsCollection] :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatThreadMembersCollection"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatParticipantsCollection"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" def prepare_request(next_link=None): @@ -622,7 +622,7 @@ def prepare_request(next_link=None): if not next_link: # Construct URL - url = self.list_chat_thread_members.metadata['url'] # type: ignore + url = self.list_chat_participants.metadata['url'] # type: ignore path_format_arguments = { 'endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), 'chatThreadId': self._serialize.url("chat_thread_id", chat_thread_id, 'str'), @@ -645,7 +645,7 @@ def prepare_request(next_link=None): return request async def extract_data(pipeline_response): - deserialized = self._deserialize('ChatThreadMembersCollection', pipeline_response) + deserialized = self._deserialize('ChatParticipantsCollection', pipeline_response) list_of_elem = deserialized.value if cls: list_of_elem = cls(list_of_elem) @@ -666,22 +666,22 @@ async def get_next(next_link=None): return AsyncItemPaged( get_next, extract_data ) - list_chat_thread_members.metadata = {'url': '/chat/threads/{chatThreadId}/members'} # type: ignore + list_chat_participants.metadata = {'url': '/chat/threads/{chatThreadId}/participants'} # type: ignore - async def add_chat_thread_members( + async def add_chat_participants( self, chat_thread_id: str, - body: "models.AddChatThreadMembersRequest", + add_chat_participants_request: "_models.AddChatParticipantsRequest", **kwargs ) -> None: - """Adds thread members to a thread. If members already exist, no change occurs. + """Adds thread participants to a thread. If participants already exist, no change occurs. - Adds thread members to a thread. If members already exist, no change occurs. + Adds thread participants to a thread. If participants already exist, no change occurs. - :param chat_thread_id: Id of the thread to add members to. + :param chat_thread_id: Id of the thread to add participants to. :type chat_thread_id: str - :param body: Thread members to be added to the thread. - :type body: ~azure.communication.chat.models.AddChatThreadMembersRequest + :param add_chat_participants_request: Thread participants to be added to the thread. + :type add_chat_participants_request: ~azure.communication.chat.models.AddChatParticipantsRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -691,18 +691,18 @@ async def add_chat_thread_members( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" content_type = kwargs.pop("content_type", "application/json") accept = "application/json" # Construct URL - url = self.add_chat_thread_members.metadata['url'] # type: ignore + url = self.add_chat_participants.metadata['url'] # type: ignore path_format_arguments = { 'endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), 'chatThreadId': self._serialize.url("chat_thread_id", chat_thread_id, 'str'), @@ -719,35 +719,35 @@ async def add_chat_thread_members( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'AddChatThreadMembersRequest') + body_content = self._serialize.body(add_chat_participants_request, 'AddChatParticipantsRequest') body_content_kwargs['content'] = body_content request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = await self._client._pipeline.run(request, stream=False, **kwargs) response = pipeline_response.http_response - if response.status_code not in [207]: + if response.status_code not in [201]: map_error(status_code=response.status_code, response=response, error_map=error_map) raise HttpResponseError(response=response) if cls: return cls(pipeline_response, None, {}) - add_chat_thread_members.metadata = {'url': '/chat/threads/{chatThreadId}/members'} # type: ignore + add_chat_participants.metadata = {'url': '/chat/threads/{chatThreadId}/participants'} # type: ignore - async def remove_chat_thread_member( + async def remove_chat_participant( self, chat_thread_id: str, - chat_member_id: str, + chat_participant_id: str, **kwargs ) -> None: - """Remove a member from a thread. + """Remove a participant from a thread. - Remove a member from a thread. + Remove a participant from a thread. - :param chat_thread_id: Thread id to remove the member from. + :param chat_thread_id: Thread id to remove the participant from. :type chat_thread_id: str - :param chat_member_id: Id of the thread member to remove from the thread. - :type chat_member_id: str + :param chat_participant_id: Id of the thread participant to remove from the thread. + :type chat_participant_id: str :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -757,21 +757,21 @@ async def remove_chat_thread_member( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL - url = self.remove_chat_thread_member.metadata['url'] # type: ignore + url = self.remove_chat_participant.metadata['url'] # type: ignore path_format_arguments = { 'endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), 'chatThreadId': self._serialize.url("chat_thread_id", chat_thread_id, 'str'), - 'chatMemberId': self._serialize.url("chat_member_id", chat_member_id, 'str'), + 'chatParticipantId': self._serialize.url("chat_participant_id", chat_participant_id, 'str'), } url = self._client.format_url(url, **path_format_arguments) @@ -794,35 +794,35 @@ async def remove_chat_thread_member( if cls: return cls(pipeline_response, None, {}) - remove_chat_thread_member.metadata = {'url': '/chat/threads/{chatThreadId}/members/{chatMemberId}'} # type: ignore + remove_chat_participant.metadata = {'url': '/chat/threads/{chatThreadId}/participants/{chatParticipantId}'} # type: ignore async def create_chat_thread( self, - body: "models.CreateChatThreadRequest", + create_chat_thread_request: "_models.CreateChatThreadRequest", **kwargs - ) -> "models.MultiStatusResponse": + ) -> "_models.ChatThread": """Creates a chat thread. Creates a chat thread. - :param body: Request payload for creating a chat thread. - :type body: ~azure.communication.chat.models.CreateChatThreadRequest + :param create_chat_thread_request: Request payload for creating a chat thread. + :type create_chat_thread_request: ~azure.communication.chat.models.CreateChatThreadRequest :keyword callable cls: A custom type or function that will be passed the direct response - :return: MultiStatusResponse, or the result of cls(response) - :rtype: ~azure.communication.chat.models.MultiStatusResponse + :return: ChatThread, or the result of cls(response) + :rtype: ~azure.communication.chat.models.ChatThread :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.MultiStatusResponse"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatThread"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" content_type = kwargs.pop("content_type", "application/json") accept = "application/json" @@ -843,17 +843,17 @@ async def create_chat_thread( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'CreateChatThreadRequest') + body_content = self._serialize.body(create_chat_thread_request, 'CreateChatThreadRequest') body_content_kwargs['content'] = body_content request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = await self._client._pipeline.run(request, stream=False, **kwargs) response = pipeline_response.http_response - if response.status_code not in [207]: + if response.status_code not in [201]: map_error(status_code=response.status_code, response=response, error_map=error_map) raise HttpResponseError(response=response) - deserialized = self._deserialize('MultiStatusResponse', pipeline_response) + deserialized = self._deserialize('ChatThread', pipeline_response) if cls: return cls(pipeline_response, deserialized, {}) @@ -866,7 +866,7 @@ def list_chat_threads( max_page_size: Optional[int] = None, start_time: Optional[datetime.datetime] = None, **kwargs - ) -> AsyncIterable["models.ChatThreadsInfoCollection"]: + ) -> AsyncIterable["_models.ChatThreadsInfoCollection"]: """Gets the list of chat threads of a user. Gets the list of chat threads of a user. @@ -881,17 +881,17 @@ def list_chat_threads( :rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.communication.chat.models.ChatThreadsInfoCollection] :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatThreadsInfoCollection"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatThreadsInfoCollection"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" def prepare_request(next_link=None): @@ -952,7 +952,7 @@ async def get_next(next_link=None): async def update_chat_thread( self, chat_thread_id: str, - body: "models.UpdateChatThreadRequest", + update_chat_thread_request: "_models.UpdateChatThreadRequest", **kwargs ) -> None: """Updates a thread's properties. @@ -961,8 +961,8 @@ async def update_chat_thread( :param chat_thread_id: The id of the thread to update. :type chat_thread_id: str - :param body: Request payload for updating a chat thread. - :type body: ~azure.communication.chat.models.UpdateChatThreadRequest + :param update_chat_thread_request: Request payload for updating a chat thread. + :type update_chat_thread_request: ~azure.communication.chat.models.UpdateChatThreadRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -972,14 +972,14 @@ async def update_chat_thread( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" - content_type = kwargs.pop("content_type", "application/json") + api_version = "2020-11-01-preview3" + content_type = kwargs.pop("content_type", "application/merge-patch+json") accept = "application/json" # Construct URL @@ -1000,13 +1000,13 @@ async def update_chat_thread( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'UpdateChatThreadRequest') + body_content = self._serialize.body(update_chat_thread_request, 'UpdateChatThreadRequest') body_content_kwargs['content'] = body_content request = self._client.patch(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = await self._client._pipeline.run(request, stream=False, **kwargs) response = pipeline_response.http_response - if response.status_code not in [200]: + if response.status_code not in [204]: map_error(status_code=response.status_code, response=response, error_map=error_map) raise HttpResponseError(response=response) @@ -1019,7 +1019,7 @@ async def get_chat_thread( self, chat_thread_id: str, **kwargs - ) -> "models.ChatThread": + ) -> "_models.ChatThread": """Gets a chat thread. Gets a chat thread. @@ -1031,17 +1031,17 @@ async def get_chat_thread( :rtype: ~azure.communication.chat.models.ChatThread :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatThread"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatThread"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL @@ -1096,13 +1096,13 @@ async def delete_chat_thread( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/__init__.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/__init__.py index 7ab0f15afde3..6e86967f52b8 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/__init__.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/__init__.py @@ -7,40 +7,36 @@ # -------------------------------------------------------------------------- try: - from ._models_py3 import AddChatThreadMembersRequest + from ._models_py3 import AddChatParticipantsRequest from ._models_py3 import ChatMessage + from ._models_py3 import ChatMessageReadReceipt + from ._models_py3 import ChatMessageReadReceiptsCollection from ._models_py3 import ChatMessagesCollection + from ._models_py3 import ChatParticipant + from ._models_py3 import ChatParticipantsCollection from ._models_py3 import ChatThread from ._models_py3 import ChatThreadInfo - from ._models_py3 import ChatThreadMember - from ._models_py3 import ChatThreadMembersCollection from ._models_py3 import ChatThreadsInfoCollection from ._models_py3 import CreateChatThreadRequest from ._models_py3 import Error - from ._models_py3 import IndividualStatusResponse - from ._models_py3 import MultiStatusResponse - from ._models_py3 import ReadReceipt - from ._models_py3 import ReadReceiptsCollection from ._models_py3 import SendChatMessageRequest from ._models_py3 import SendChatMessageResult from ._models_py3 import SendReadReceiptRequest from ._models_py3 import UpdateChatMessageRequest from ._models_py3 import UpdateChatThreadRequest except (SyntaxError, ImportError): - from ._models import AddChatThreadMembersRequest # type: ignore + from ._models import AddChatParticipantsRequest # type: ignore from ._models import ChatMessage # type: ignore + from ._models import ChatMessageReadReceipt # type: ignore + from ._models import ChatMessageReadReceiptsCollection # type: ignore from ._models import ChatMessagesCollection # type: ignore + from ._models import ChatParticipant # type: ignore + from ._models import ChatParticipantsCollection # type: ignore from ._models import ChatThread # type: ignore from ._models import ChatThreadInfo # type: ignore - from ._models import ChatThreadMember # type: ignore - from ._models import ChatThreadMembersCollection # type: ignore from ._models import ChatThreadsInfoCollection # type: ignore from ._models import CreateChatThreadRequest # type: ignore from ._models import Error # type: ignore - from ._models import IndividualStatusResponse # type: ignore - from ._models import MultiStatusResponse # type: ignore - from ._models import ReadReceipt # type: ignore - from ._models import ReadReceiptsCollection # type: ignore from ._models import SendChatMessageRequest # type: ignore from ._models import SendChatMessageResult # type: ignore from ._models import SendReadReceiptRequest # type: ignore @@ -52,20 +48,18 @@ ) __all__ = [ - 'AddChatThreadMembersRequest', + 'AddChatParticipantsRequest', 'ChatMessage', + 'ChatMessageReadReceipt', + 'ChatMessageReadReceiptsCollection', 'ChatMessagesCollection', + 'ChatParticipant', + 'ChatParticipantsCollection', 'ChatThread', 'ChatThreadInfo', - 'ChatThreadMember', - 'ChatThreadMembersCollection', 'ChatThreadsInfoCollection', 'CreateChatThreadRequest', 'Error', - 'IndividualStatusResponse', - 'MultiStatusResponse', - 'ReadReceipt', - 'ReadReceiptsCollection', 'SendChatMessageRequest', 'SendChatMessageResult', 'SendReadReceiptRequest', diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/_models.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/_models.py index 4bc3f247591d..9598cb18db1f 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/_models.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/_models.py @@ -10,29 +10,29 @@ import msrest.serialization -class AddChatThreadMembersRequest(msrest.serialization.Model): - """Thread members to be added to the thread. +class AddChatParticipantsRequest(msrest.serialization.Model): + """Participants to be added to the thread. All required parameters must be populated in order to send to Azure. - :param members: Required. Members to add to a chat thread. - :type members: list[~azure.communication.chat.models.ChatThreadMember] + :param participants: Required. Participants to add to a chat thread. + :type participants: list[~azure.communication.chat.models.ChatParticipant] """ _validation = { - 'members': {'required': True}, + 'participants': {'required': True}, } _attribute_map = { - 'members': {'key': 'members', 'type': '[ChatThreadMember]'}, + 'participants': {'key': 'participants', 'type': '[ChatParticipant]'}, } def __init__( self, **kwargs ): - super(AddChatThreadMembersRequest, self).__init__(**kwargs) - self.members = kwargs['members'] + super(AddChatParticipantsRequest, self).__init__(**kwargs) + self.participants = kwargs['participants'] class ChatMessage(msrest.serialization.Model): @@ -112,6 +112,74 @@ def __init__( self.edited_on = kwargs.get('edited_on', None) +class ChatMessageReadReceipt(msrest.serialization.Model): + """A chat message read receipt indicates the time a chat message was read by a recipient. + + Variables are only populated by the server, and will be ignored when sending a request. + + :ivar sender_id: Chat message read receipt sender id. + :vartype sender_id: str + :ivar chat_message_id: Id for the chat message that has been read. This id is generated by the + server. + :vartype chat_message_id: str + :ivar read_on: Chat message read receipt timestamp. The timestamp is in ISO8601 format: ``yyyy- + MM-ddTHH:mm:ssZ``. + :vartype read_on: ~datetime.datetime + """ + + _validation = { + 'sender_id': {'readonly': True}, + 'chat_message_id': {'readonly': True}, + 'read_on': {'readonly': True}, + } + + _attribute_map = { + 'sender_id': {'key': 'senderId', 'type': 'str'}, + 'chat_message_id': {'key': 'chatMessageId', 'type': 'str'}, + 'read_on': {'key': 'readOn', 'type': 'iso-8601'}, + } + + def __init__( + self, + **kwargs + ): + super(ChatMessageReadReceipt, self).__init__(**kwargs) + self.sender_id = None + self.chat_message_id = None + self.read_on = None + + +class ChatMessageReadReceiptsCollection(msrest.serialization.Model): + """ChatMessageReadReceiptsCollection. + + Variables are only populated by the server, and will be ignored when sending a request. + + :ivar value: Collection of chat message read receipts. + :vartype value: list[~azure.communication.chat.models.ChatMessageReadReceipt] + :ivar next_link: If there are more chat message read receipts that can be retrieved, the next + link will be populated. + :vartype next_link: str + """ + + _validation = { + 'value': {'readonly': True}, + 'next_link': {'readonly': True}, + } + + _attribute_map = { + 'value': {'key': 'value', 'type': '[ChatMessageReadReceipt]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__( + self, + **kwargs + ): + super(ChatMessageReadReceiptsCollection, self).__init__(**kwargs) + self.value = None + self.next_link = None + + class ChatMessagesCollection(msrest.serialization.Model): """Collection of chat messages for a particular chat thread. @@ -143,6 +211,70 @@ def __init__( self.next_link = None +class ChatParticipant(msrest.serialization.Model): + """A participant of the chat thread. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. The id of the chat participant. + :type id: str + :param display_name: Display name for the chat participant. + :type display_name: str + :param share_history_time: Time from which the chat history is shared with the participant. The + timestamp is in ISO8601 format: ``yyyy-MM-ddTHH:mm:ssZ``. + :type share_history_time: ~datetime.datetime + """ + + _validation = { + 'id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'display_name': {'key': 'displayName', 'type': 'str'}, + 'share_history_time': {'key': 'shareHistoryTime', 'type': 'iso-8601'}, + } + + def __init__( + self, + **kwargs + ): + super(ChatParticipant, self).__init__(**kwargs) + self.id = kwargs['id'] + self.display_name = kwargs.get('display_name', None) + self.share_history_time = kwargs.get('share_history_time', None) + + +class ChatParticipantsCollection(msrest.serialization.Model): + """Collection of participants belong to a particular thread. + + Variables are only populated by the server, and will be ignored when sending a request. + + :param value: Chat participants. + :type value: list[~azure.communication.chat.models.ChatParticipant] + :ivar next_link: If there are more chat participants that can be retrieved, the next link will + be populated. + :vartype next_link: str + """ + + _validation = { + 'next_link': {'readonly': True}, + } + + _attribute_map = { + 'value': {'key': 'value', 'type': '[ChatParticipant]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__( + self, + **kwargs + ): + super(ChatParticipantsCollection, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.next_link = None + + class ChatThread(msrest.serialization.Model): """ChatThread. @@ -157,8 +289,11 @@ class ChatThread(msrest.serialization.Model): :vartype created_on: ~datetime.datetime :ivar created_by: Id of the chat thread owner. :vartype created_by: str - :param members: Chat thread members. - :type members: list[~azure.communication.chat.models.ChatThreadMember] + :param deleted_on: The timestamp when the chat thread was deleted. The timestamp is in ISO8601 + format: ``yyyy-MM-ddTHH:mm:ssZ``. + :type deleted_on: ~datetime.datetime + :param participants: Chat participants. + :type participants: list[~azure.communication.chat.models.ChatParticipant] """ _validation = { @@ -172,7 +307,8 @@ class ChatThread(msrest.serialization.Model): 'topic': {'key': 'topic', 'type': 'str'}, 'created_on': {'key': 'createdOn', 'type': 'iso-8601'}, 'created_by': {'key': 'createdBy', 'type': 'str'}, - 'members': {'key': 'members', 'type': '[ChatThreadMember]'}, + 'deleted_on': {'key': 'deletedOn', 'type': 'iso-8601'}, + 'participants': {'key': 'participants', 'type': '[ChatParticipant]'}, } def __init__( @@ -184,7 +320,8 @@ def __init__( self.topic = kwargs.get('topic', None) self.created_on = None self.created_by = None - self.members = kwargs.get('members', None) + self.deleted_on = kwargs.get('deleted_on', None) + self.participants = kwargs.get('participants', None) class ChatThreadInfo(msrest.serialization.Model): @@ -196,8 +333,9 @@ class ChatThreadInfo(msrest.serialization.Model): :vartype id: str :param topic: Chat thread topic. :type topic: str - :param is_deleted: Flag if a chat thread is soft deleted. - :type is_deleted: bool + :param deleted_on: The timestamp when the chat thread was deleted. The timestamp is in ISO8601 + format: ``yyyy-MM-ddTHH:mm:ssZ``. + :type deleted_on: ~datetime.datetime :ivar last_message_received_on: The timestamp when the last message arrived at the server. The timestamp is in ISO8601 format: ``yyyy-MM-ddTHH:mm:ssZ``. :vartype last_message_received_on: ~datetime.datetime @@ -211,7 +349,7 @@ class ChatThreadInfo(msrest.serialization.Model): _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'topic': {'key': 'topic', 'type': 'str'}, - 'is_deleted': {'key': 'isDeleted', 'type': 'bool'}, + 'deleted_on': {'key': 'deletedOn', 'type': 'iso-8601'}, 'last_message_received_on': {'key': 'lastMessageReceivedOn', 'type': 'iso-8601'}, } @@ -222,75 +360,10 @@ def __init__( super(ChatThreadInfo, self).__init__(**kwargs) self.id = None self.topic = kwargs.get('topic', None) - self.is_deleted = kwargs.get('is_deleted', None) + self.deleted_on = kwargs.get('deleted_on', None) self.last_message_received_on = None -class ChatThreadMember(msrest.serialization.Model): - """A member of the chat thread. - - All required parameters must be populated in order to send to Azure. - - :param id: Required. The id of the chat thread member in the format - ``8:acs:ResourceId_AcsUserId``. - :type id: str - :param display_name: Display name for the chat thread member. - :type display_name: str - :param share_history_time: Time from which the chat history is shared with the member. The - timestamp is in ISO8601 format: ``yyyy-MM-ddTHH:mm:ssZ``. - :type share_history_time: ~datetime.datetime - """ - - _validation = { - 'id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'display_name': {'key': 'displayName', 'type': 'str'}, - 'share_history_time': {'key': 'shareHistoryTime', 'type': 'iso-8601'}, - } - - def __init__( - self, - **kwargs - ): - super(ChatThreadMember, self).__init__(**kwargs) - self.id = kwargs['id'] - self.display_name = kwargs.get('display_name', None) - self.share_history_time = kwargs.get('share_history_time', None) - - -class ChatThreadMembersCollection(msrest.serialization.Model): - """Collection of thread members belong to a particular thread. - - Variables are only populated by the server, and will be ignored when sending a request. - - :param value: Chat thread members. - :type value: list[~azure.communication.chat.models.ChatThreadMember] - :ivar next_link: If there are more chat threads that can be retrieved, the next link will be - populated. - :vartype next_link: str - """ - - _validation = { - 'next_link': {'readonly': True}, - } - - _attribute_map = { - 'value': {'key': 'value', 'type': '[ChatThreadMember]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__( - self, - **kwargs - ): - super(ChatThreadMembersCollection, self).__init__(**kwargs) - self.value = kwargs.get('value', None) - self.next_link = None - - class ChatThreadsInfoCollection(msrest.serialization.Model): """Collection of chat threads. @@ -329,18 +402,18 @@ class CreateChatThreadRequest(msrest.serialization.Model): :param topic: Required. The chat thread topic. :type topic: str - :param members: Required. Members to be added to the chat thread. - :type members: list[~azure.communication.chat.models.ChatThreadMember] + :param participants: Required. Participants to be added to the chat thread. + :type participants: list[~azure.communication.chat.models.ChatParticipant] """ _validation = { 'topic': {'required': True}, - 'members': {'required': True}, + 'participants': {'required': True}, } _attribute_map = { 'topic': {'key': 'topic', 'type': 'str'}, - 'members': {'key': 'members', 'type': '[ChatThreadMember]'}, + 'participants': {'key': 'participants', 'type': '[ChatParticipant]'}, } def __init__( @@ -349,7 +422,7 @@ def __init__( ): super(CreateChatThreadRequest, self).__init__(**kwargs) self.topic = kwargs['topic'] - self.members = kwargs['members'] + self.participants = kwargs['participants'] class Error(msrest.serialization.Model): @@ -357,13 +430,14 @@ class Error(msrest.serialization.Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar code: + :ivar code: Error code. :vartype code: str - :ivar message: + :ivar message: Description of the error. :vartype message: str - :ivar target: + :ivar target: If applicable, would be used to indicate the property causing the error. :vartype target: str - :ivar inner_errors: + :ivar inner_errors: If applicable, inner errors would be returned for more details on the + error. :vartype inner_errors: list[~azure.communication.chat.models.Error] """ @@ -392,147 +466,6 @@ def __init__( self.inner_errors = None -class IndividualStatusResponse(msrest.serialization.Model): - """IndividualStatusResponse. - - Variables are only populated by the server, and will be ignored when sending a request. - - :ivar id: Identifies the resource to which the individual status corresponds. - :vartype id: str - :ivar status_code: The status code of the resource operation. - - Possible values include: - 200 for a successful update or delete, - 201 for successful creation, - 400 for a malformed input, - 403 for lacking permission to execute the operation, - 404 for resource not found. - :vartype status_code: int - :ivar message: The message explaining why the operation failed for the resource identified by - the key; null if the operation succeeded. - :vartype message: str - :ivar type: Identifies the type of the resource to which the individual status corresponds. - :vartype type: str - """ - - _validation = { - 'id': {'readonly': True}, - 'status_code': {'readonly': True}, - 'message': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'status_code': {'key': 'statusCode', 'type': 'int'}, - 'message': {'key': 'message', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - } - - def __init__( - self, - **kwargs - ): - super(IndividualStatusResponse, self).__init__(**kwargs) - self.id = None - self.status_code = None - self.message = None - self.type = None - - -class MultiStatusResponse(msrest.serialization.Model): - """MultiStatusResponse. - - Variables are only populated by the server, and will be ignored when sending a request. - - :ivar multiple_status: The list of status information for each resource in the request. - :vartype multiple_status: list[~azure.communication.chat.models.IndividualStatusResponse] - """ - - _validation = { - 'multiple_status': {'readonly': True}, - } - - _attribute_map = { - 'multiple_status': {'key': 'multipleStatus', 'type': '[IndividualStatusResponse]'}, - } - - def __init__( - self, - **kwargs - ): - super(MultiStatusResponse, self).__init__(**kwargs) - self.multiple_status = None - - -class ReadReceipt(msrest.serialization.Model): - """A read receipt indicates the time a chat message was read by a recipient. - - Variables are only populated by the server, and will be ignored when sending a request. - - :ivar sender_id: Read receipt sender id. - :vartype sender_id: str - :ivar chat_message_id: Id for the chat message that has been read. This id is generated by the - server. - :vartype chat_message_id: str - :ivar read_on: Read receipt timestamp. The timestamp is in ISO8601 format: ``yyyy-MM- - ddTHH:mm:ssZ``. - :vartype read_on: ~datetime.datetime - """ - - _validation = { - 'sender_id': {'readonly': True}, - 'chat_message_id': {'readonly': True}, - 'read_on': {'readonly': True}, - } - - _attribute_map = { - 'sender_id': {'key': 'senderId', 'type': 'str'}, - 'chat_message_id': {'key': 'chatMessageId', 'type': 'str'}, - 'read_on': {'key': 'readOn', 'type': 'iso-8601'}, - } - - def __init__( - self, - **kwargs - ): - super(ReadReceipt, self).__init__(**kwargs) - self.sender_id = None - self.chat_message_id = None - self.read_on = None - - -class ReadReceiptsCollection(msrest.serialization.Model): - """ReadReceiptsCollection. - - Variables are only populated by the server, and will be ignored when sending a request. - - :ivar value: Collection of read receipts. - :vartype value: list[~azure.communication.chat.models.ReadReceipt] - :ivar next_link: If there are more read receipts that can be retrieved, the next link will be - populated. - :vartype next_link: str - """ - - _validation = { - 'value': {'readonly': True}, - 'next_link': {'readonly': True}, - } - - _attribute_map = { - 'value': {'key': 'value', 'type': '[ReadReceipt]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__( - self, - **kwargs - ): - super(ReadReceiptsCollection, self).__init__(**kwargs) - self.value = None - self.next_link = None - - class SendChatMessageRequest(msrest.serialization.Model): """Details of the message to send. diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/_models_py3.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/_models_py3.py index 85157315f42c..2ace184240fa 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/_models_py3.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/models/_models_py3.py @@ -15,31 +15,31 @@ from ._azure_communication_chat_service_enums import * -class AddChatThreadMembersRequest(msrest.serialization.Model): - """Thread members to be added to the thread. +class AddChatParticipantsRequest(msrest.serialization.Model): + """Participants to be added to the thread. All required parameters must be populated in order to send to Azure. - :param members: Required. Members to add to a chat thread. - :type members: list[~azure.communication.chat.models.ChatThreadMember] + :param participants: Required. Participants to add to a chat thread. + :type participants: list[~azure.communication.chat.models.ChatParticipant] """ _validation = { - 'members': {'required': True}, + 'participants': {'required': True}, } _attribute_map = { - 'members': {'key': 'members', 'type': '[ChatThreadMember]'}, + 'participants': {'key': 'participants', 'type': '[ChatParticipant]'}, } def __init__( self, *, - members: List["ChatThreadMember"], + participants: List["ChatParticipant"], **kwargs ): - super(AddChatThreadMembersRequest, self).__init__(**kwargs) - self.members = members + super(AddChatParticipantsRequest, self).__init__(**kwargs) + self.participants = participants class ChatMessage(msrest.serialization.Model): @@ -126,6 +126,74 @@ def __init__( self.edited_on = edited_on +class ChatMessageReadReceipt(msrest.serialization.Model): + """A chat message read receipt indicates the time a chat message was read by a recipient. + + Variables are only populated by the server, and will be ignored when sending a request. + + :ivar sender_id: Chat message read receipt sender id. + :vartype sender_id: str + :ivar chat_message_id: Id for the chat message that has been read. This id is generated by the + server. + :vartype chat_message_id: str + :ivar read_on: Chat message read receipt timestamp. The timestamp is in ISO8601 format: ``yyyy- + MM-ddTHH:mm:ssZ``. + :vartype read_on: ~datetime.datetime + """ + + _validation = { + 'sender_id': {'readonly': True}, + 'chat_message_id': {'readonly': True}, + 'read_on': {'readonly': True}, + } + + _attribute_map = { + 'sender_id': {'key': 'senderId', 'type': 'str'}, + 'chat_message_id': {'key': 'chatMessageId', 'type': 'str'}, + 'read_on': {'key': 'readOn', 'type': 'iso-8601'}, + } + + def __init__( + self, + **kwargs + ): + super(ChatMessageReadReceipt, self).__init__(**kwargs) + self.sender_id = None + self.chat_message_id = None + self.read_on = None + + +class ChatMessageReadReceiptsCollection(msrest.serialization.Model): + """ChatMessageReadReceiptsCollection. + + Variables are only populated by the server, and will be ignored when sending a request. + + :ivar value: Collection of chat message read receipts. + :vartype value: list[~azure.communication.chat.models.ChatMessageReadReceipt] + :ivar next_link: If there are more chat message read receipts that can be retrieved, the next + link will be populated. + :vartype next_link: str + """ + + _validation = { + 'value': {'readonly': True}, + 'next_link': {'readonly': True}, + } + + _attribute_map = { + 'value': {'key': 'value', 'type': '[ChatMessageReadReceipt]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__( + self, + **kwargs + ): + super(ChatMessageReadReceiptsCollection, self).__init__(**kwargs) + self.value = None + self.next_link = None + + class ChatMessagesCollection(msrest.serialization.Model): """Collection of chat messages for a particular chat thread. @@ -157,6 +225,76 @@ def __init__( self.next_link = None +class ChatParticipant(msrest.serialization.Model): + """A participant of the chat thread. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. The id of the chat participant. + :type id: str + :param display_name: Display name for the chat participant. + :type display_name: str + :param share_history_time: Time from which the chat history is shared with the participant. The + timestamp is in ISO8601 format: ``yyyy-MM-ddTHH:mm:ssZ``. + :type share_history_time: ~datetime.datetime + """ + + _validation = { + 'id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'display_name': {'key': 'displayName', 'type': 'str'}, + 'share_history_time': {'key': 'shareHistoryTime', 'type': 'iso-8601'}, + } + + def __init__( + self, + *, + id: str, + display_name: Optional[str] = None, + share_history_time: Optional[datetime.datetime] = None, + **kwargs + ): + super(ChatParticipant, self).__init__(**kwargs) + self.id = id + self.display_name = display_name + self.share_history_time = share_history_time + + +class ChatParticipantsCollection(msrest.serialization.Model): + """Collection of participants belong to a particular thread. + + Variables are only populated by the server, and will be ignored when sending a request. + + :param value: Chat participants. + :type value: list[~azure.communication.chat.models.ChatParticipant] + :ivar next_link: If there are more chat participants that can be retrieved, the next link will + be populated. + :vartype next_link: str + """ + + _validation = { + 'next_link': {'readonly': True}, + } + + _attribute_map = { + 'value': {'key': 'value', 'type': '[ChatParticipant]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__( + self, + *, + value: Optional[List["ChatParticipant"]] = None, + **kwargs + ): + super(ChatParticipantsCollection, self).__init__(**kwargs) + self.value = value + self.next_link = None + + class ChatThread(msrest.serialization.Model): """ChatThread. @@ -171,8 +309,11 @@ class ChatThread(msrest.serialization.Model): :vartype created_on: ~datetime.datetime :ivar created_by: Id of the chat thread owner. :vartype created_by: str - :param members: Chat thread members. - :type members: list[~azure.communication.chat.models.ChatThreadMember] + :param deleted_on: The timestamp when the chat thread was deleted. The timestamp is in ISO8601 + format: ``yyyy-MM-ddTHH:mm:ssZ``. + :type deleted_on: ~datetime.datetime + :param participants: Chat participants. + :type participants: list[~azure.communication.chat.models.ChatParticipant] """ _validation = { @@ -186,14 +327,16 @@ class ChatThread(msrest.serialization.Model): 'topic': {'key': 'topic', 'type': 'str'}, 'created_on': {'key': 'createdOn', 'type': 'iso-8601'}, 'created_by': {'key': 'createdBy', 'type': 'str'}, - 'members': {'key': 'members', 'type': '[ChatThreadMember]'}, + 'deleted_on': {'key': 'deletedOn', 'type': 'iso-8601'}, + 'participants': {'key': 'participants', 'type': '[ChatParticipant]'}, } def __init__( self, *, topic: Optional[str] = None, - members: Optional[List["ChatThreadMember"]] = None, + deleted_on: Optional[datetime.datetime] = None, + participants: Optional[List["ChatParticipant"]] = None, **kwargs ): super(ChatThread, self).__init__(**kwargs) @@ -201,7 +344,8 @@ def __init__( self.topic = topic self.created_on = None self.created_by = None - self.members = members + self.deleted_on = deleted_on + self.participants = participants class ChatThreadInfo(msrest.serialization.Model): @@ -213,8 +357,9 @@ class ChatThreadInfo(msrest.serialization.Model): :vartype id: str :param topic: Chat thread topic. :type topic: str - :param is_deleted: Flag if a chat thread is soft deleted. - :type is_deleted: bool + :param deleted_on: The timestamp when the chat thread was deleted. The timestamp is in ISO8601 + format: ``yyyy-MM-ddTHH:mm:ssZ``. + :type deleted_on: ~datetime.datetime :ivar last_message_received_on: The timestamp when the last message arrived at the server. The timestamp is in ISO8601 format: ``yyyy-MM-ddTHH:mm:ssZ``. :vartype last_message_received_on: ~datetime.datetime @@ -228,7 +373,7 @@ class ChatThreadInfo(msrest.serialization.Model): _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'topic': {'key': 'topic', 'type': 'str'}, - 'is_deleted': {'key': 'isDeleted', 'type': 'bool'}, + 'deleted_on': {'key': 'deletedOn', 'type': 'iso-8601'}, 'last_message_received_on': {'key': 'lastMessageReceivedOn', 'type': 'iso-8601'}, } @@ -236,87 +381,16 @@ def __init__( self, *, topic: Optional[str] = None, - is_deleted: Optional[bool] = None, + deleted_on: Optional[datetime.datetime] = None, **kwargs ): super(ChatThreadInfo, self).__init__(**kwargs) self.id = None self.topic = topic - self.is_deleted = is_deleted + self.deleted_on = deleted_on self.last_message_received_on = None -class ChatThreadMember(msrest.serialization.Model): - """A member of the chat thread. - - All required parameters must be populated in order to send to Azure. - - :param id: Required. The id of the chat thread member in the format - ``8:acs:ResourceId_AcsUserId``. - :type id: str - :param display_name: Display name for the chat thread member. - :type display_name: str - :param share_history_time: Time from which the chat history is shared with the member. The - timestamp is in ISO8601 format: ``yyyy-MM-ddTHH:mm:ssZ``. - :type share_history_time: ~datetime.datetime - """ - - _validation = { - 'id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'display_name': {'key': 'displayName', 'type': 'str'}, - 'share_history_time': {'key': 'shareHistoryTime', 'type': 'iso-8601'}, - } - - def __init__( - self, - *, - id: str, - display_name: Optional[str] = None, - share_history_time: Optional[datetime.datetime] = None, - **kwargs - ): - super(ChatThreadMember, self).__init__(**kwargs) - self.id = id - self.display_name = display_name - self.share_history_time = share_history_time - - -class ChatThreadMembersCollection(msrest.serialization.Model): - """Collection of thread members belong to a particular thread. - - Variables are only populated by the server, and will be ignored when sending a request. - - :param value: Chat thread members. - :type value: list[~azure.communication.chat.models.ChatThreadMember] - :ivar next_link: If there are more chat threads that can be retrieved, the next link will be - populated. - :vartype next_link: str - """ - - _validation = { - 'next_link': {'readonly': True}, - } - - _attribute_map = { - 'value': {'key': 'value', 'type': '[ChatThreadMember]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__( - self, - *, - value: Optional[List["ChatThreadMember"]] = None, - **kwargs - ): - super(ChatThreadMembersCollection, self).__init__(**kwargs) - self.value = value - self.next_link = None - - class ChatThreadsInfoCollection(msrest.serialization.Model): """Collection of chat threads. @@ -355,30 +429,30 @@ class CreateChatThreadRequest(msrest.serialization.Model): :param topic: Required. The chat thread topic. :type topic: str - :param members: Required. Members to be added to the chat thread. - :type members: list[~azure.communication.chat.models.ChatThreadMember] + :param participants: Required. Participants to be added to the chat thread. + :type participants: list[~azure.communication.chat.models.ChatParticipant] """ _validation = { 'topic': {'required': True}, - 'members': {'required': True}, + 'participants': {'required': True}, } _attribute_map = { 'topic': {'key': 'topic', 'type': 'str'}, - 'members': {'key': 'members', 'type': '[ChatThreadMember]'}, + 'participants': {'key': 'participants', 'type': '[ChatParticipant]'}, } def __init__( self, *, topic: str, - members: List["ChatThreadMember"], + participants: List["ChatParticipant"], **kwargs ): super(CreateChatThreadRequest, self).__init__(**kwargs) self.topic = topic - self.members = members + self.participants = participants class Error(msrest.serialization.Model): @@ -386,13 +460,14 @@ class Error(msrest.serialization.Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar code: + :ivar code: Error code. :vartype code: str - :ivar message: + :ivar message: Description of the error. :vartype message: str - :ivar target: + :ivar target: If applicable, would be used to indicate the property causing the error. :vartype target: str - :ivar inner_errors: + :ivar inner_errors: If applicable, inner errors would be returned for more details on the + error. :vartype inner_errors: list[~azure.communication.chat.models.Error] """ @@ -421,147 +496,6 @@ def __init__( self.inner_errors = None -class IndividualStatusResponse(msrest.serialization.Model): - """IndividualStatusResponse. - - Variables are only populated by the server, and will be ignored when sending a request. - - :ivar id: Identifies the resource to which the individual status corresponds. - :vartype id: str - :ivar status_code: The status code of the resource operation. - - Possible values include: - 200 for a successful update or delete, - 201 for successful creation, - 400 for a malformed input, - 403 for lacking permission to execute the operation, - 404 for resource not found. - :vartype status_code: int - :ivar message: The message explaining why the operation failed for the resource identified by - the key; null if the operation succeeded. - :vartype message: str - :ivar type: Identifies the type of the resource to which the individual status corresponds. - :vartype type: str - """ - - _validation = { - 'id': {'readonly': True}, - 'status_code': {'readonly': True}, - 'message': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'status_code': {'key': 'statusCode', 'type': 'int'}, - 'message': {'key': 'message', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - } - - def __init__( - self, - **kwargs - ): - super(IndividualStatusResponse, self).__init__(**kwargs) - self.id = None - self.status_code = None - self.message = None - self.type = None - - -class MultiStatusResponse(msrest.serialization.Model): - """MultiStatusResponse. - - Variables are only populated by the server, and will be ignored when sending a request. - - :ivar multiple_status: The list of status information for each resource in the request. - :vartype multiple_status: list[~azure.communication.chat.models.IndividualStatusResponse] - """ - - _validation = { - 'multiple_status': {'readonly': True}, - } - - _attribute_map = { - 'multiple_status': {'key': 'multipleStatus', 'type': '[IndividualStatusResponse]'}, - } - - def __init__( - self, - **kwargs - ): - super(MultiStatusResponse, self).__init__(**kwargs) - self.multiple_status = None - - -class ReadReceipt(msrest.serialization.Model): - """A read receipt indicates the time a chat message was read by a recipient. - - Variables are only populated by the server, and will be ignored when sending a request. - - :ivar sender_id: Read receipt sender id. - :vartype sender_id: str - :ivar chat_message_id: Id for the chat message that has been read. This id is generated by the - server. - :vartype chat_message_id: str - :ivar read_on: Read receipt timestamp. The timestamp is in ISO8601 format: ``yyyy-MM- - ddTHH:mm:ssZ``. - :vartype read_on: ~datetime.datetime - """ - - _validation = { - 'sender_id': {'readonly': True}, - 'chat_message_id': {'readonly': True}, - 'read_on': {'readonly': True}, - } - - _attribute_map = { - 'sender_id': {'key': 'senderId', 'type': 'str'}, - 'chat_message_id': {'key': 'chatMessageId', 'type': 'str'}, - 'read_on': {'key': 'readOn', 'type': 'iso-8601'}, - } - - def __init__( - self, - **kwargs - ): - super(ReadReceipt, self).__init__(**kwargs) - self.sender_id = None - self.chat_message_id = None - self.read_on = None - - -class ReadReceiptsCollection(msrest.serialization.Model): - """ReadReceiptsCollection. - - Variables are only populated by the server, and will be ignored when sending a request. - - :ivar value: Collection of read receipts. - :vartype value: list[~azure.communication.chat.models.ReadReceipt] - :ivar next_link: If there are more read receipts that can be retrieved, the next link will be - populated. - :vartype next_link: str - """ - - _validation = { - 'value': {'readonly': True}, - 'next_link': {'readonly': True}, - } - - _attribute_map = { - 'value': {'key': 'value', 'type': '[ReadReceipt]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__( - self, - **kwargs - ): - super(ReadReceiptsCollection, self).__init__(**kwargs) - self.value = None - self.next_link = None - - class SendChatMessageRequest(msrest.serialization.Model): """Details of the message to send. diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/operations/_azure_communication_chat_service_operations.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/operations/_azure_communication_chat_service_operations.py index a2fdb439c5df..5bd7ed00d62f 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/operations/_azure_communication_chat_service_operations.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_generated/operations/_azure_communication_chat_service_operations.py @@ -14,7 +14,7 @@ from azure.core.pipeline import PipelineResponse from azure.core.pipeline.transport import HttpRequest, HttpResponse -from .. import models +from .. import models as _models if TYPE_CHECKING: # pylint: disable=unused-import,ungrouped-imports @@ -30,29 +30,29 @@ def list_chat_read_receipts( chat_thread_id, # type: str **kwargs # type: Any ): - # type: (...) -> Iterable["models.ReadReceiptsCollection"] - """Gets read receipts for a thread. + # type: (...) -> Iterable["_models.ChatMessageReadReceiptsCollection"] + """Gets chat message read receipts for a thread. - Gets read receipts for a thread. + Gets chat message read receipts for a thread. - :param chat_thread_id: Thread id to get the read receipts for. + :param chat_thread_id: Thread id to get the chat message read receipts for. :type chat_thread_id: str :keyword callable cls: A custom type or function that will be passed the direct response - :return: An iterator like instance of either ReadReceiptsCollection or the result of cls(response) - :rtype: ~azure.core.paging.ItemPaged[~azure.communication.chat.models.ReadReceiptsCollection] + :return: An iterator like instance of either ChatMessageReadReceiptsCollection or the result of cls(response) + :rtype: ~azure.core.paging.ItemPaged[~azure.communication.chat.models.ChatMessageReadReceiptsCollection] :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ReadReceiptsCollection"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatMessageReadReceiptsCollection"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" def prepare_request(next_link=None): @@ -85,7 +85,7 @@ def prepare_request(next_link=None): return request def extract_data(pipeline_response): - deserialized = self._deserialize('ReadReceiptsCollection', pipeline_response) + deserialized = self._deserialize('ChatMessageReadReceiptsCollection', pipeline_response) list_of_elem = deserialized.value if cls: list_of_elem = cls(list_of_elem) @@ -111,7 +111,7 @@ def get_next(next_link=None): def send_chat_read_receipt( self, chat_thread_id, # type: str - body, # type: "models.SendReadReceiptRequest" + send_read_receipt_request, # type: "_models.SendReadReceiptRequest" **kwargs # type: Any ): # type: (...) -> None @@ -121,8 +121,8 @@ def send_chat_read_receipt( :param chat_thread_id: Thread id to send the read receipt event to. :type chat_thread_id: str - :param body: Read receipt details. - :type body: ~azure.communication.chat.models.SendReadReceiptRequest + :param send_read_receipt_request: Read receipt details. + :type send_read_receipt_request: ~azure.communication.chat.models.SendReadReceiptRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -132,13 +132,13 @@ def send_chat_read_receipt( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" content_type = kwargs.pop("content_type", "application/json") accept = "application/json" @@ -160,7 +160,7 @@ def send_chat_read_receipt( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'SendReadReceiptRequest') + body_content = self._serialize.body(send_read_receipt_request, 'SendReadReceiptRequest') body_content_kwargs['content'] = body_content request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = self._client._pipeline.run(request, stream=False, **kwargs) @@ -178,34 +178,34 @@ def send_chat_read_receipt( def send_chat_message( self, chat_thread_id, # type: str - body, # type: "models.SendChatMessageRequest" + send_chat_message_request, # type: "_models.SendChatMessageRequest" **kwargs # type: Any ): - # type: (...) -> "models.SendChatMessageResult" + # type: (...) -> "_models.SendChatMessageResult" """Sends a message to a thread. Sends a message to a thread. :param chat_thread_id: The thread id to send the message to. :type chat_thread_id: str - :param body: Details of the message to send. - :type body: ~azure.communication.chat.models.SendChatMessageRequest + :param send_chat_message_request: Details of the message to send. + :type send_chat_message_request: ~azure.communication.chat.models.SendChatMessageRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: SendChatMessageResult, or the result of cls(response) :rtype: ~azure.communication.chat.models.SendChatMessageResult :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.SendChatMessageResult"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.SendChatMessageResult"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" content_type = kwargs.pop("content_type", "application/json") accept = "application/json" @@ -227,7 +227,7 @@ def send_chat_message( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'SendChatMessageRequest') + body_content = self._serialize.body(send_chat_message_request, 'SendChatMessageRequest') body_content_kwargs['content'] = body_content request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = self._client._pipeline.run(request, stream=False, **kwargs) @@ -252,7 +252,7 @@ def list_chat_messages( start_time=None, # type: Optional[datetime.datetime] **kwargs # type: Any ): - # type: (...) -> Iterable["models.ChatMessagesCollection"] + # type: (...) -> Iterable["_models.ChatMessagesCollection"] """Gets a list of messages from a thread. Gets a list of messages from a thread. @@ -269,17 +269,17 @@ def list_chat_messages( :rtype: ~azure.core.paging.ItemPaged[~azure.communication.chat.models.ChatMessagesCollection] :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatMessagesCollection"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatMessagesCollection"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" def prepare_request(next_link=None): @@ -345,7 +345,7 @@ def get_chat_message( chat_message_id, # type: str **kwargs # type: Any ): - # type: (...) -> "models.ChatMessage" + # type: (...) -> "_models.ChatMessage" """Gets a message by id. Gets a message by id. @@ -359,17 +359,17 @@ def get_chat_message( :rtype: ~azure.communication.chat.models.ChatMessage :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatMessage"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatMessage"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL @@ -409,7 +409,7 @@ def update_chat_message( self, chat_thread_id, # type: str chat_message_id, # type: str - body, # type: "models.UpdateChatMessageRequest" + update_chat_message_request, # type: "_models.UpdateChatMessageRequest" **kwargs # type: Any ): # type: (...) -> None @@ -421,8 +421,8 @@ def update_chat_message( :type chat_thread_id: str :param chat_message_id: The message id. :type chat_message_id: str - :param body: Details of the request to update the message. - :type body: ~azure.communication.chat.models.UpdateChatMessageRequest + :param update_chat_message_request: Details of the request to update the message. + :type update_chat_message_request: ~azure.communication.chat.models.UpdateChatMessageRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -432,14 +432,14 @@ def update_chat_message( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" - content_type = kwargs.pop("content_type", "application/json") + api_version = "2020-11-01-preview3" + content_type = kwargs.pop("content_type", "application/merge-patch+json") accept = "application/json" # Construct URL @@ -461,13 +461,13 @@ def update_chat_message( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'UpdateChatMessageRequest') + body_content = self._serialize.body(update_chat_message_request, 'UpdateChatMessageRequest') body_content_kwargs['content'] = body_content request = self._client.patch(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = self._client._pipeline.run(request, stream=False, **kwargs) response = pipeline_response.http_response - if response.status_code not in [200]: + if response.status_code not in [204]: map_error(status_code=response.status_code, response=response, error_map=error_map) raise HttpResponseError(response=response) @@ -500,13 +500,13 @@ def delete_chat_message( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL @@ -560,13 +560,13 @@ def send_typing_notification( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL @@ -598,34 +598,34 @@ def send_typing_notification( send_typing_notification.metadata = {'url': '/chat/threads/{chatThreadId}/typing'} # type: ignore - def list_chat_thread_members( + def list_chat_participants( self, chat_thread_id, # type: str **kwargs # type: Any ): - # type: (...) -> Iterable["models.ChatThreadMembersCollection"] - """Gets the members of a thread. + # type: (...) -> Iterable["_models.ChatParticipantsCollection"] + """Gets the participants of a thread. - Gets the members of a thread. + Gets the participants of a thread. - :param chat_thread_id: Thread id to get members for. + :param chat_thread_id: Thread id to get participants for. :type chat_thread_id: str :keyword callable cls: A custom type or function that will be passed the direct response - :return: An iterator like instance of either ChatThreadMembersCollection or the result of cls(response) - :rtype: ~azure.core.paging.ItemPaged[~azure.communication.chat.models.ChatThreadMembersCollection] + :return: An iterator like instance of either ChatParticipantsCollection or the result of cls(response) + :rtype: ~azure.core.paging.ItemPaged[~azure.communication.chat.models.ChatParticipantsCollection] :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatThreadMembersCollection"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatParticipantsCollection"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" def prepare_request(next_link=None): @@ -635,7 +635,7 @@ def prepare_request(next_link=None): if not next_link: # Construct URL - url = self.list_chat_thread_members.metadata['url'] # type: ignore + url = self.list_chat_participants.metadata['url'] # type: ignore path_format_arguments = { 'endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), 'chatThreadId': self._serialize.url("chat_thread_id", chat_thread_id, 'str'), @@ -658,7 +658,7 @@ def prepare_request(next_link=None): return request def extract_data(pipeline_response): - deserialized = self._deserialize('ChatThreadMembersCollection', pipeline_response) + deserialized = self._deserialize('ChatParticipantsCollection', pipeline_response) list_of_elem = deserialized.value if cls: list_of_elem = cls(list_of_elem) @@ -679,23 +679,23 @@ def get_next(next_link=None): return ItemPaged( get_next, extract_data ) - list_chat_thread_members.metadata = {'url': '/chat/threads/{chatThreadId}/members'} # type: ignore + list_chat_participants.metadata = {'url': '/chat/threads/{chatThreadId}/participants'} # type: ignore - def add_chat_thread_members( + def add_chat_participants( self, chat_thread_id, # type: str - body, # type: "models.AddChatThreadMembersRequest" + add_chat_participants_request, # type: "_models.AddChatParticipantsRequest" **kwargs # type: Any ): # type: (...) -> None - """Adds thread members to a thread. If members already exist, no change occurs. + """Adds thread participants to a thread. If participants already exist, no change occurs. - Adds thread members to a thread. If members already exist, no change occurs. + Adds thread participants to a thread. If participants already exist, no change occurs. - :param chat_thread_id: Id of the thread to add members to. + :param chat_thread_id: Id of the thread to add participants to. :type chat_thread_id: str - :param body: Thread members to be added to the thread. - :type body: ~azure.communication.chat.models.AddChatThreadMembersRequest + :param add_chat_participants_request: Thread participants to be added to the thread. + :type add_chat_participants_request: ~azure.communication.chat.models.AddChatParticipantsRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -705,18 +705,18 @@ def add_chat_thread_members( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" content_type = kwargs.pop("content_type", "application/json") accept = "application/json" # Construct URL - url = self.add_chat_thread_members.metadata['url'] # type: ignore + url = self.add_chat_participants.metadata['url'] # type: ignore path_format_arguments = { 'endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), 'chatThreadId': self._serialize.url("chat_thread_id", chat_thread_id, 'str'), @@ -733,36 +733,36 @@ def add_chat_thread_members( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'AddChatThreadMembersRequest') + body_content = self._serialize.body(add_chat_participants_request, 'AddChatParticipantsRequest') body_content_kwargs['content'] = body_content request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = self._client._pipeline.run(request, stream=False, **kwargs) response = pipeline_response.http_response - if response.status_code not in [207]: + if response.status_code not in [201]: map_error(status_code=response.status_code, response=response, error_map=error_map) raise HttpResponseError(response=response) if cls: return cls(pipeline_response, None, {}) - add_chat_thread_members.metadata = {'url': '/chat/threads/{chatThreadId}/members'} # type: ignore + add_chat_participants.metadata = {'url': '/chat/threads/{chatThreadId}/participants'} # type: ignore - def remove_chat_thread_member( + def remove_chat_participant( self, chat_thread_id, # type: str - chat_member_id, # type: str + chat_participant_id, # type: str **kwargs # type: Any ): # type: (...) -> None - """Remove a member from a thread. + """Remove a participant from a thread. - Remove a member from a thread. + Remove a participant from a thread. - :param chat_thread_id: Thread id to remove the member from. + :param chat_thread_id: Thread id to remove the participant from. :type chat_thread_id: str - :param chat_member_id: Id of the thread member to remove from the thread. - :type chat_member_id: str + :param chat_participant_id: Id of the thread participant to remove from the thread. + :type chat_participant_id: str :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -772,21 +772,21 @@ def remove_chat_thread_member( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL - url = self.remove_chat_thread_member.metadata['url'] # type: ignore + url = self.remove_chat_participant.metadata['url'] # type: ignore path_format_arguments = { 'endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), 'chatThreadId': self._serialize.url("chat_thread_id", chat_thread_id, 'str'), - 'chatMemberId': self._serialize.url("chat_member_id", chat_member_id, 'str'), + 'chatParticipantId': self._serialize.url("chat_participant_id", chat_participant_id, 'str'), } url = self._client.format_url(url, **path_format_arguments) @@ -809,36 +809,36 @@ def remove_chat_thread_member( if cls: return cls(pipeline_response, None, {}) - remove_chat_thread_member.metadata = {'url': '/chat/threads/{chatThreadId}/members/{chatMemberId}'} # type: ignore + remove_chat_participant.metadata = {'url': '/chat/threads/{chatThreadId}/participants/{chatParticipantId}'} # type: ignore def create_chat_thread( self, - body, # type: "models.CreateChatThreadRequest" + create_chat_thread_request, # type: "_models.CreateChatThreadRequest" **kwargs # type: Any ): - # type: (...) -> "models.MultiStatusResponse" + # type: (...) -> "_models.ChatThread" """Creates a chat thread. Creates a chat thread. - :param body: Request payload for creating a chat thread. - :type body: ~azure.communication.chat.models.CreateChatThreadRequest + :param create_chat_thread_request: Request payload for creating a chat thread. + :type create_chat_thread_request: ~azure.communication.chat.models.CreateChatThreadRequest :keyword callable cls: A custom type or function that will be passed the direct response - :return: MultiStatusResponse, or the result of cls(response) - :rtype: ~azure.communication.chat.models.MultiStatusResponse + :return: ChatThread, or the result of cls(response) + :rtype: ~azure.communication.chat.models.ChatThread :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.MultiStatusResponse"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatThread"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" content_type = kwargs.pop("content_type", "application/json") accept = "application/json" @@ -859,17 +859,17 @@ def create_chat_thread( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'CreateChatThreadRequest') + body_content = self._serialize.body(create_chat_thread_request, 'CreateChatThreadRequest') body_content_kwargs['content'] = body_content request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = self._client._pipeline.run(request, stream=False, **kwargs) response = pipeline_response.http_response - if response.status_code not in [207]: + if response.status_code not in [201]: map_error(status_code=response.status_code, response=response, error_map=error_map) raise HttpResponseError(response=response) - deserialized = self._deserialize('MultiStatusResponse', pipeline_response) + deserialized = self._deserialize('ChatThread', pipeline_response) if cls: return cls(pipeline_response, deserialized, {}) @@ -883,7 +883,7 @@ def list_chat_threads( start_time=None, # type: Optional[datetime.datetime] **kwargs # type: Any ): - # type: (...) -> Iterable["models.ChatThreadsInfoCollection"] + # type: (...) -> Iterable["_models.ChatThreadsInfoCollection"] """Gets the list of chat threads of a user. Gets the list of chat threads of a user. @@ -898,17 +898,17 @@ def list_chat_threads( :rtype: ~azure.core.paging.ItemPaged[~azure.communication.chat.models.ChatThreadsInfoCollection] :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatThreadsInfoCollection"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatThreadsInfoCollection"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" def prepare_request(next_link=None): @@ -969,7 +969,7 @@ def get_next(next_link=None): def update_chat_thread( self, chat_thread_id, # type: str - body, # type: "models.UpdateChatThreadRequest" + update_chat_thread_request, # type: "_models.UpdateChatThreadRequest" **kwargs # type: Any ): # type: (...) -> None @@ -979,8 +979,8 @@ def update_chat_thread( :param chat_thread_id: The id of the thread to update. :type chat_thread_id: str - :param body: Request payload for updating a chat thread. - :type body: ~azure.communication.chat.models.UpdateChatThreadRequest + :param update_chat_thread_request: Request payload for updating a chat thread. + :type update_chat_thread_request: ~azure.communication.chat.models.UpdateChatThreadRequest :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -990,14 +990,14 @@ def update_chat_thread( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" - content_type = kwargs.pop("content_type", "application/json") + api_version = "2020-11-01-preview3" + content_type = kwargs.pop("content_type", "application/merge-patch+json") accept = "application/json" # Construct URL @@ -1018,13 +1018,13 @@ def update_chat_thread( header_parameters['Accept'] = self._serialize.header("accept", accept, 'str') body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(body, 'UpdateChatThreadRequest') + body_content = self._serialize.body(update_chat_thread_request, 'UpdateChatThreadRequest') body_content_kwargs['content'] = body_content request = self._client.patch(url, query_parameters, header_parameters, **body_content_kwargs) pipeline_response = self._client._pipeline.run(request, stream=False, **kwargs) response = pipeline_response.http_response - if response.status_code not in [200]: + if response.status_code not in [204]: map_error(status_code=response.status_code, response=response, error_map=error_map) raise HttpResponseError(response=response) @@ -1038,7 +1038,7 @@ def get_chat_thread( chat_thread_id, # type: str **kwargs # type: Any ): - # type: (...) -> "models.ChatThread" + # type: (...) -> "_models.ChatThread" """Gets a chat thread. Gets a chat thread. @@ -1050,17 +1050,17 @@ def get_chat_thread( :rtype: ~azure.communication.chat.models.ChatThread :raises: ~azure.core.exceptions.HttpResponseError """ - cls = kwargs.pop('cls', None) # type: ClsType["models.ChatThread"] + cls = kwargs.pop('cls', None) # type: ClsType["_models.ChatThread"] error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL @@ -1116,13 +1116,13 @@ def delete_chat_thread( error_map = { 404: ResourceNotFoundError, 409: ResourceExistsError, - 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(models.Error, response)), - 403: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 429: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), - 503: lambda response: HttpResponseError(response=response, model=self._deserialize(models.Error, response)), + 401: lambda response: ClientAuthenticationError(response=response, model=self._deserialize(_models.Error, response)), + 403: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 429: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), + 503: lambda response: HttpResponseError(response=response, model=self._deserialize(_models.Error, response)), } error_map.update(kwargs.pop('error_map', {})) - api_version = "2020-09-21-preview2" + api_version = "2020-11-01-preview3" accept = "application/json" # Construct URL diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_models.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_models.py index 3ef3f9d73c87..ae2dbdc03a23 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_models.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_models.py @@ -5,19 +5,19 @@ # ------------------------------------ from ._shared.models import CommunicationUser -from ._generated.models import ChatThreadMember as ChatThreadMemberAutorest +from ._generated.models import ChatParticipant as ChatParticipantAutorest -class ChatThreadMember(object): - """A member of the chat thread. +class ChatThreadParticipant(object): + """A participant of the chat thread. All required parameters must be populated in order to send to Azure. :param user: Required. The CommunicationUser. :type user: CommunicationUser - :param display_name: Display name for the chat thread member. + :param display_name: Display name for the chat thread participant. :type display_name: str - :param share_history_time: Time from which the chat history is shared with the member. The + :param share_history_time: Time from which the chat history is shared with the participant. The timestamp is in ISO8601 format: ``yyyy-MM-ddTHH:mm:ssZ``. :type share_history_time: ~datetime.datetime """ @@ -31,15 +31,15 @@ def __init__( self.share_history_time = kwargs.get('share_history_time', None) @classmethod - def _from_generated(cls, chat_thread_member): + def _from_generated(cls, chat_thread_participant): return cls( - user=CommunicationUser(chat_thread_member.id), - display_name=chat_thread_member.display_name, - share_history_time=chat_thread_member.share_history_time + user=CommunicationUser(chat_thread_participant.id), + display_name=chat_thread_participant.display_name, + share_history_time=chat_thread_participant.share_history_time ) def _to_generated(self): - return ChatThreadMemberAutorest( + return ChatParticipantAutorest( id=self.user.identifier, display_name=self.display_name, share_history_time=self.share_history_time @@ -54,7 +54,7 @@ class ChatMessage(object): :ivar id: The id of the chat message. This id is server generated. :vartype id: str :param type: Type of the chat message. Possible values include: "Text", - "ThreadActivity/TopicUpdate", "ThreadActivity/AddMember", "ThreadActivity/DeleteMember". + "ThreadActivity/TopicUpdate", "ThreadActivity/AddParticipant", "ThreadActivity/DeleteParticipant". :type type: str :param priority: The chat message priority. Possible values include: "Normal", "High". :type priority: str or ~azure.communication.chat.models.ChatMessagePriority @@ -123,8 +123,8 @@ class ChatThread(object): :vartype created_on: ~datetime.datetime :ivar created_by: the chat thread owner. :vartype created_by: CommunicationUser - :param members: Chat thread members. - :type members: list[~azure.communication.chat.ChatThreadMember] + :param participants: Chat thread participants. + :type participants: list[~azure.communication.chat.ChatThreadParticipant] """ # pylint:disable=protected-access @@ -137,7 +137,7 @@ def __init__( self.topic = kwargs.get('topic', None) self.created_on = kwargs['created_on'] self.created_by = kwargs['created_by'] - self.members = kwargs.get('members', None) + self.participants = kwargs.get('participants', None) @classmethod def _from_generated(cls, chat_thread): @@ -146,12 +146,12 @@ def _from_generated(cls, chat_thread): topic=chat_thread.topic, created_on=chat_thread.created_on, created_by=CommunicationUser(chat_thread.created_by), - members=[ChatThreadMember._from_generated(x) for x in chat_thread.members] + participants=[ChatThreadParticipant._from_generated(x) for x in chat_thread.participants] ) -class ReadReceipt(object): - """A read receipt indicates the time a chat message was read by a recipient. +class ChatMessageReadReceipt(object): + """A chat message read receipt indicates the time a chat message was read by a recipient. Variables are only populated by the server, and will be ignored when sending a request. diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/_utils.py b/sdk/communication/azure-communication-chat/azure/communication/chat/_utils.py index 886f4b51c413..5311e8979cc3 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/_utils.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/_utils.py @@ -6,3 +6,6 @@ def _to_utc_datetime(value): return value.strftime('%Y-%m-%dT%H:%M:%SZ') + +def return_response(response, deserialized, _): # pylint: disable=unused-argument + return response, deserialized diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_client_async.py b/sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_client_async.py index 1997b165c18a..473ce05c9767 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_client_async.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_client_async.py @@ -28,9 +28,9 @@ ) from .._models import ( ChatThread, - ChatThreadMember + ChatThreadParticipant ) -from .._utils import _to_utc_datetime # pylint: disable=unused-import +from .._utils import _to_utc_datetime, return_response # pylint: disable=unused-import from .._version import SDK_MONIKER @@ -118,15 +118,15 @@ def get_chat_thread_client( @distributed_trace_async async def create_chat_thread( self, topic: str, - thread_members: List[ChatThreadMember], + thread_participants: List[ChatThreadParticipant], **kwargs ) -> ChatThreadClient: """Creates a chat thread. :param topic: Required. The thread topic. :type topic: str - :param thread_members: Required. Members to be added to the thread. - :type thread_members: list[~azure.communication.chat.ChatThreadMember] + :param thread_participants: Required. Participants to be added to the thread. + :type thread_participants: list[~azure.communication.chat.ChatThreadParticipant] :return: ChatThreadClient :rtype: ~azure.communication.chat.aio.ChatThreadClient :raises: ~azure.core.exceptions.HttpResponseError, ValueError @@ -142,28 +142,29 @@ async def create_chat_thread( """ if not topic: raise ValueError("topic cannot be None.") - if not thread_members: - raise ValueError("List of ThreadMember cannot be None.") - - members = [m._to_generated() for m in thread_members] # pylint:disable=protected-access - create_thread_request = CreateChatThreadRequest(topic=topic, members=members) - - create_chat_thread_result = await self._client.create_chat_thread(create_thread_request, **kwargs) - - multiple_status = create_chat_thread_result.multiple_status - thread_status = [status for status in multiple_status if status.type == "Thread"] - if not thread_status: - raise HttpResponseError(message="Can not find chat thread status result from: {}".format(thread_status)) - if thread_status[0].status_code != 201: - raise HttpResponseError(message="Chat thread creation failed with status code {}, message: {}.".format( - thread_status[0].status_code, thread_status[0].message)) - - thread_id = thread_status[0].id - + if not thread_participants: + raise ValueError("List of ThreadParticipant cannot be None.") + + participants = [m._to_generated() for m in thread_participants] # pylint:disable=protected-access + create_thread_request = CreateChatThreadRequest(topic=topic, participants=participants) + + response, create_chat_thread_result = await self._client.create_chat_thread( + create_thread_request, cls=return_response, **kwargs) + if response is not None: + response_header = response.http_response.headers + if ('Azure-Acs-InvalidParticipants' in response_header.keys() and + response_header['Azure-Acs-InvalidParticipants'] is not None): + invalid_participant_and_reason_list = response_header['Azure-Acs-InvalidParticipants'].split('|') + errors = [] + for invalid_participant_and_reason in invalid_participant_and_reason_list: + participant, reason = invalid_participant_and_reason.split(',', 1) + errors.append('participant ' + participant + ' failed to join thread ' + + create_chat_thread_result.id + ' return statue code ' + reason) + raise ValueError(errors) return ChatThreadClient( endpoint=self._endpoint, credential=self._credential, - thread_id=thread_id, + thread_id=create_chat_thread_result.id, **kwargs ) diff --git a/sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_thread_client_async.py b/sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_thread_client_async.py index 703cfb80ece5..139c61694537 100644 --- a/sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_thread_client_async.py +++ b/sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_thread_client_async.py @@ -21,7 +21,7 @@ from .._shared.user_credential_async import CommunicationUserCredential from .._generated.aio import AzureCommunicationChatService from .._generated.models import ( - AddChatThreadMembersRequest, + AddChatParticipantsRequest, SendReadReceiptRequest, SendChatMessageRequest, UpdateChatMessageRequest, @@ -29,9 +29,9 @@ SendChatMessageResult ) from .._models import ( - ChatThreadMember, + ChatThreadParticipant, ChatMessage, - ReadReceipt + ChatMessageReadReceipt ) from .._shared.models import CommunicationUser from .._utils import _to_utc_datetime # pylint: disable=unused-import @@ -42,7 +42,7 @@ class ChatThreadClient(object): """A client to interact with the AzureCommunicationService Chat gateway. Instances of this class is normally created by ChatClient.create_chat_thread() - This client provides operations to add member to chat thread, remove member from + This client provides operations to add participant to chat thread, remove participant from chat thread, send message, delete message, update message, send typing notifications, send and list read receipt @@ -111,7 +111,7 @@ def thread_id(self): return self._thread_id @distributed_trace_async - async def update_thread( + async def update_topic( self, *, topic: str = None, @@ -130,17 +130,17 @@ async def update_thread( .. admonition:: Example: .. literalinclude:: ../samples/chat_thread_client_sample_async.py - :start-after: [START update_thread] - :end-before: [END update_thread] + :start-after: [START update_topic] + :end-before: [END update_topic] :language: python :dedent: 12 :caption: Updating chat thread. """ - update_thread_request = UpdateChatThreadRequest(topic=topic) + update_topic_request = UpdateChatThreadRequest(topic=topic) return await self._client.update_chat_thread( chat_thread_id=self._thread_id, - body=update_thread_request, + update_chat_thread_request=update_topic_request, **kwargs) @distributed_trace_async @@ -173,18 +173,18 @@ async def send_read_receipt( post_read_receipt_request = SendReadReceiptRequest(chat_message_id=message_id) return await self._client.send_chat_read_receipt( self._thread_id, - body=post_read_receipt_request, + send_read_receipt_request=post_read_receipt_request, **kwargs) @distributed_trace def list_read_receipts( self, **kwargs - ) -> AsyncItemPaged[ReadReceipt]: + ) -> AsyncItemPaged[ChatMessageReadReceipt]: """Gets read receipts for a thread. :keyword callable cls: A custom type or function that will be passed the direct response - :return: AsyncItemPaged[:class:`~azure.communication.chat.ReadReceipt`] + :return: AsyncItemPaged[:class:`~azure.communication.chat.ChatMessageReadReceipt`] :rtype: ~azure.core.async_paging.AsyncItemPaged :raises: ~azure.core.exceptions.HttpResponseError, ValueError @@ -199,7 +199,7 @@ def list_read_receipts( """ return self._client.list_chat_read_receipts( self._thread_id, - cls=lambda objs: [ReadReceipt._from_generated(x) for x in objs], # pylint:disable=protected-access + cls=lambda objs: [ChatMessageReadReceipt._from_generated(x) for x in objs], # pylint:disable=protected-access **kwargs) @distributed_trace_async @@ -230,7 +230,7 @@ async def send_message( self, content: str, **kwargs - ) -> SendChatMessageResult: + ) -> str: """Sends a message to a thread. :param content: Required. Chat message content. @@ -240,8 +240,8 @@ async def send_message( :keyword str sender_display_name: The display name of the message sender. This property is used to populate sender name for push notifications. :keyword callable cls: A custom type or function that will be passed the direct response - :return: SendChatMessageResult, or the result of cls(response) - :rtype: ~azure.communication.chat.SendChatMessageResult + :return: str, or the result of cls(response) + :rtype: str :raises: ~azure.core.exceptions.HttpResponseError, ValueError .. admonition:: Example: @@ -264,11 +264,13 @@ async def send_message( priority=priority, sender_display_name=sender_display_name ) - return await self._client.send_chat_message( + send_chat_message_result = await self._client.send_chat_message( chat_thread_id=self._thread_id, - body=create_message_request, + send_chat_message_request=create_message_request, **kwargs) + return send_chat_message_result.id + @distributed_trace_async async def get_message( self, @@ -368,7 +370,7 @@ async def update_message( return await self._client.update_chat_message( chat_thread_id=self._thread_id, chat_message_id=message_id, - body=update_message_request, + update_chat_message_request=update_message_request, **kwargs) @distributed_trace_async @@ -404,41 +406,76 @@ async def delete_message( **kwargs) @distributed_trace - def list_members( + def list_participants( self, **kwargs - ) -> AsyncItemPaged[ChatThreadMember]: - """Gets the members of a thread. + ) -> AsyncItemPaged[ChatThreadParticipant]: + """Gets the participants of a thread. :keyword callable cls: A custom type or function that will be passed the direct response - :return: AsyncItemPaged[:class:`~azure.communication.chat.ChatThreadMember`] + :return: AsyncItemPaged[:class:`~azure.communication.chat.ChatThreadParticipant`] :rtype: ~azure.core.async_paging.AsyncItemPaged :raises: ~azure.core.exceptions.HttpResponseError, ValueError .. admonition:: Example: .. literalinclude:: ../samples/chat_thread_client_sample_async.py - :start-after: [START list_members] - :end-before: [END list_members] + :start-after: [START list_participants] + :end-before: [END list_participants] :language: python :dedent: 12 - :caption: Listing members of chat thread. + :caption: Listing participants of chat thread. """ - return self._client.list_chat_thread_members( + return self._client.list_chat_participants( self._thread_id, - cls=lambda objs: [ChatThreadMember._from_generated(x) for x in objs], # pylint:disable=protected-access + cls=lambda objs: [ChatThreadParticipant._from_generated(x) for x in objs], # pylint:disable=protected-access + **kwargs) + + @distributed_trace_async + async def add_participant( + self, + thread_participant: ChatThreadParticipant, + **kwargs + ) -> None: + """Adds single thread participant to a thread. If participant already exist, no change occurs. + + :param thread_participant: Required. Single thread participant to be added to the thread. + :type thread_participant: ~azure.communication.chat.ChatThreadParticipant + :keyword callable cls: A custom type or function that will be passed the direct response + :return: None, or the result of cls(response) + :rtype: None + :raises: ~azure.core.exceptions.HttpResponseError, ValueError + + .. admonition:: Example: + + .. literalinclude:: ../samples/chat_thread_client_sample_async.py + :start-after: [START add_participant] + :end-before: [END add_participant] + :language: python + :dedent: 12 + :caption: Adding single participant to chat thread. + """ + if not thread_participant: + raise ValueError("thread_participant cannot be None.") + + participants = [thread_participant._to_generated()] # pylint:disable=protected-access + add_thread_participants_request = AddChatParticipantsRequest(participants=participants) + + return await self._client.add_chat_participants( + chat_thread_id=self._thread_id, + add_chat_participants_request=add_thread_participants_request, **kwargs) @distributed_trace_async - async def add_members( + async def add_participants( self, - thread_members: List[ChatThreadMember], + thread_participants: List[ChatThreadParticipant], **kwargs ) -> None: - """Adds thread members to a thread. If members already exist, no change occurs. + """Adds thread participants to a thread. If participants already exist, no change occurs. - :param thread_members: Required. Thread members to be added to the thread. - :type thread_members: list[~azure.communication.chat.ChatThreadMember] + :param thread_participants: Required. Thread participants to be added to the thread. + :type thread_participants: list[~azure.communication.chat.ChatThreadParticipant] :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) :rtype: None @@ -447,32 +484,32 @@ async def add_members( .. admonition:: Example: .. literalinclude:: ../samples/chat_thread_client_sample_async.py - :start-after: [START add_members] - :end-before: [END add_members] + :start-after: [START add_participants] + :end-before: [END add_participants] :language: python :dedent: 12 - :caption: Adding members to chat thread. + :caption: Adding participants to chat thread. """ - if not thread_members: - raise ValueError("thread_members cannot be None.") + if not thread_participants: + raise ValueError("thread_participants cannot be None.") - members = [m._to_generated() for m in thread_members] # pylint:disable=protected-access - add_thread_members_request = AddChatThreadMembersRequest(members=members) + participants = [m._to_generated() for m in thread_participants] # pylint:disable=protected-access + add_thread_participants_request = AddChatParticipantsRequest(participants=participants) - return await self._client.add_chat_thread_members( + return await self._client.add_chat_participants( chat_thread_id=self._thread_id, - body=add_thread_members_request, + add_chat_participants_request=add_thread_participants_request, **kwargs) @distributed_trace_async - async def remove_member( + async def remove_participant( self, user: CommunicationUser, **kwargs ) -> None: - """Remove a member from a thread. + """Remove a participant from a thread. - :param user: Required. User identity of the thread member to remove from the thread. + :param user: Required. User identity of the thread participant to remove from the thread. :type user: ~azure.communication.chat.CommunicationUser :keyword callable cls: A custom type or function that will be passed the direct response :return: None, or the result of cls(response) @@ -482,18 +519,18 @@ async def remove_member( .. admonition:: Example: .. literalinclude:: ../samples/chat_thread_client_sample_async.py - :start-after: [START remove_member] - :end-before: [END remove_member] + :start-after: [START remove_participant] + :end-before: [END remove_participant] :language: python :dedent: 12 - :caption: Removing member from chat thread. + :caption: Removing participant from chat thread. """ if not user: raise ValueError("user cannot be None.") - return await self._client.remove_chat_thread_member( + return await self._client.remove_chat_participant( chat_thread_id=self._thread_id, - chat_member_id=user.identifier, + chat_participant_id=user.identifier, **kwargs) async def close(self) -> None: diff --git a/sdk/communication/azure-communication-chat/samples/chat_client_sample.py b/sdk/communication/azure-communication-chat/samples/chat_client_sample.py index 071b53a95dc0..90d9d3421858 100644 --- a/sdk/communication/azure-communication-chat/samples/chat_client_sample.py +++ b/sdk/communication/azure-communication-chat/samples/chat_client_sample.py @@ -54,7 +54,7 @@ def create_thread(self): from datetime import datetime from azure.communication.chat import( ChatClient, - ChatThreadMember, + ChatThreadParticipant, CommunicationUser, CommunicationUserCredential ) @@ -62,12 +62,12 @@ def create_thread(self): chat_client = ChatClient(self.endpoint, CommunicationUserCredential(self.token)) topic = "test topic" - members = [ChatThreadMember( + participants = [ChatThreadParticipant( user=self.user, display_name='name', share_history_time=datetime.utcnow() )] - chat_thread_client = chat_client.create_chat_thread(topic, members) + chat_thread_client = chat_client.create_chat_thread(topic, participants) # [END create_thread] self._thread_id = chat_thread_client.thread_id diff --git a/sdk/communication/azure-communication-chat/samples/chat_client_sample_async.py b/sdk/communication/azure-communication-chat/samples/chat_client_sample_async.py index 15e046bf3fcb..9a4db1a2c60e 100644 --- a/sdk/communication/azure-communication-chat/samples/chat_client_sample_async.py +++ b/sdk/communication/azure-communication-chat/samples/chat_client_sample_async.py @@ -53,18 +53,18 @@ def create_chat_client(self): async def create_thread_async(self): from datetime import datetime from azure.communication.chat.aio import ChatClient, CommunicationUserCredential - from azure.communication.chat import ChatThreadMember, CommunicationUser + from azure.communication.chat import ChatThreadParticipant, CommunicationUser chat_client = ChatClient(self.endpoint, CommunicationUserCredential(self.token)) async with chat_client: # [START create_thread] topic = "test topic" - members = [ChatThreadMember( + participants = [ChatThreadParticipant( user=self.user, display_name='name', share_history_time=datetime.utcnow() )] - chat_thread_client = await chat_client.create_chat_thread(topic, members) + chat_thread_client = await chat_client.create_chat_thread(topic, participants) # [END create_thread] self._thread_id = chat_thread_client.thread_id diff --git a/sdk/communication/azure-communication-chat/samples/chat_thread_client_sample.py b/sdk/communication/azure-communication-chat/samples/chat_thread_client_sample.py index e0a26dbe80ab..48b6320c8429 100644 --- a/sdk/communication/azure-communication-chat/samples/chat_thread_client_sample.py +++ b/sdk/communication/azure-communication-chat/samples/chat_thread_client_sample.py @@ -9,8 +9,8 @@ DESCRIPTION: These samples demonstrate create a chat thread client, to update chat thread, get chat message, list chat messages, update chat message, send - read receipt, list read receipts, delete chat message, add members, remove - members, list members, send typing notification + read receipt, list read receipts, delete chat message, add participants, remove + participants, list participants, send typing notification You need to use azure.communication.configuration module to get user access token and user identity before run this sample @@ -50,30 +50,30 @@ def create_chat_thread_client(self): from datetime import datetime from azure.communication.chat import ( ChatClient, - ChatThreadMember, + ChatThreadParticipant, CommunicationUser, CommunicationUserCredential ) chat_client = ChatClient(self.endpoint, CommunicationUserCredential(self.token)) topic = "test topic" - members = [ChatThreadMember( + participants = [ChatThreadParticipant( user=self.user, display_name='name', share_history_time=datetime.utcnow() )] - chat_thread_client = chat_client.create_chat_thread(topic, members) + chat_thread_client = chat_client.create_chat_thread(topic, participants) # [END create_chat_thread_client] self._thread_id = chat_thread_client.thread_id print("chat_thread_client created") - def update_thread(self): + def update_topic(self): from azure.communication.chat import ChatThreadClient from azure.communication.chat import CommunicationUserCredential chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) - # [START update_thread] + # [START update_topic] topic = "updated thread topic" - chat_thread_client.update_thread(topic=topic) - # [END update_thread] + chat_thread_client.update_topic(topic=topic) + # [END update_topic] print("update_chat_thread succeeded") @@ -88,13 +88,13 @@ def send_message(self): content = 'hello world' sender_display_name = 'sender name' - send_message_result = chat_thread_client.send_message( + send_message_result_id = chat_thread_client.send_message( content, priority=priority, sender_display_name=sender_display_name) # [END send_message] - self._message_id = send_message_result.id + self._message_id = send_message_result_id print("send_chat_message succeeded, message id:", self._message_id) def get_message(self): @@ -164,43 +164,58 @@ def delete_message(self): # [END delete_message] print("delete_chat_message succeeded") - def list_members(self): + def list_participants(self): from azure.communication.chat import ChatThreadClient from azure.communication.chat import CommunicationUserCredential chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) - # [START list_members] - chat_thread_members = chat_thread_client.list_members() - print("list_chat_members succeeded, members: ") - for chat_thread_member in chat_thread_members: - print(chat_thread_member) - # [END list_members] - - def add_members(self): + # [START list_participants] + chat_thread_participants = chat_thread_client.list_participants() + print("list_chat_participants succeeded, participants: ") + for chat_thread_participant in chat_thread_participants: + print(chat_thread_participant) + # [END list_participants] + + def add_participant(self): from azure.communication.chat import ChatThreadClient, CommunicationUserCredential chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) - # [START add_members] - from azure.communication.chat import ChatThreadMember + # [START add_participant] + from azure.communication.chat import ChatThreadParticipant from datetime import datetime - new_member = ChatThreadMember( + new_chat_thread_participant = ChatThreadParticipant( user=self.new_user, display_name='name', share_history_time=datetime.utcnow()) - thread_members = [new_member] - chat_thread_client.add_members(thread_members) - # [END add_members] - print("add_chat_members succeeded") + chat_thread_client.add_participant(new_chat_thread_participant) + # [END add_participant] + print("add_chat_participant succeeded") - def remove_member(self): + def add_participants(self): + from azure.communication.chat import ChatThreadClient, CommunicationUserCredential + chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) + + # [START add_participants] + from azure.communication.chat import ChatThreadParticipant + from datetime import datetime + new_participant = ChatThreadParticipant( + user=self.new_user, + display_name='name', + share_history_time=datetime.utcnow()) + thread_participants = [new_participant] + chat_thread_client.add_participants(thread_participants) + # [END add_participants] + print("add_chat_participants succeeded") + + def remove_participant(self): from azure.communication.chat import ChatThreadClient from azure.communication.chat import CommunicationUserCredential, CommunicationUser chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) - # [START remove_member] - chat_thread_client.remove_member(self.new_user) - # [END remove_member] + # [START remove_participant] + chat_thread_client.remove_participant(self.new_user) + # [END remove_participant] - print("remove_chat_member succeeded") + print("remove_chat_participant succeeded") def send_typing_notification(self): from azure.communication.chat import ChatThreadClient, CommunicationUserCredential @@ -219,7 +234,7 @@ def clean_up(self): if __name__ == '__main__': sample = ChatThreadClientSamples() sample.create_chat_thread_client() - sample.update_thread() + sample.update_topic() sample.send_message() sample.get_message() sample.list_messages() @@ -227,8 +242,9 @@ def clean_up(self): sample.send_read_receipt() sample.list_read_receipts() sample.delete_message() - sample.add_members() - sample.list_members() - sample.remove_member() + sample.add_participant() + sample.add_participants() + sample.list_participants() + sample.remove_participant() sample.send_typing_notification() sample.clean_up() diff --git a/sdk/communication/azure-communication-chat/samples/chat_thread_client_sample_async.py b/sdk/communication/azure-communication-chat/samples/chat_thread_client_sample_async.py index 3f195a5706c2..64f96222f39c 100644 --- a/sdk/communication/azure-communication-chat/samples/chat_thread_client_sample_async.py +++ b/sdk/communication/azure-communication-chat/samples/chat_thread_client_sample_async.py @@ -9,8 +9,8 @@ DESCRIPTION: These samples demonstrate create a chat thread client, to update chat thread, get chat message, list chat messages, update chat message, send - read receipt, list read receipts, delete chat message, add members, remove - members, list members, send typing notification + read receipt, list read receipts, delete chat message, add participants, remove + participants, list participants, send typing notification You need to use azure.communication.configuration module to get user access token and user identity before run this sample @@ -50,34 +50,34 @@ async def create_chat_thread_client_async(self): # [START create_chat_thread_client] from datetime import datetime from azure.communication.chat.aio import ChatClient, CommunicationUserCredential - from azure.communication.chat import ChatThreadMember, CommunicationUser + from azure.communication.chat import ChatThreadParticipant, CommunicationUser chat_client = ChatClient(self.endpoint, CommunicationUserCredential(self.token)) async with chat_client: topic = "test topic" - members = [ChatThreadMember( + participants = [ChatThreadParticipant( user=self.user, display_name='name', share_history_time=datetime.utcnow() )] - chat_thread_client = await chat_client.create_chat_thread(topic, members) + chat_thread_client = await chat_client.create_chat_thread(topic, participants) # [END create_chat_thread_client] self._thread_id = chat_thread_client.thread_id print("thread created, id: " + self._thread_id) - async def update_thread_async(self): + async def update_topic_async(self): from azure.communication.chat.aio import ChatThreadClient, CommunicationUserCredential chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) async with chat_thread_client: - # [START update_thread] + # [START update_topic] topic = "updated thread topic" - await chat_thread_client.update_thread(topic=topic) - # [END update_thread] + await chat_thread_client.update_topic(topic=topic) + # [END update_topic] - print("update_thread succeeded") + print("update_topic succeeded") async def send_message_async(self): from azure.communication.chat.aio import ChatThreadClient, CommunicationUserCredential @@ -91,12 +91,12 @@ async def send_message_async(self): content='hello world' sender_display_name='sender name' - send_message_result = await chat_thread_client.send_message( + send_message_result_id = await chat_thread_client.send_message( content, priority=priority, sender_display_name=sender_display_name) # [END send_message] - self._message_id = send_message_result.id + self._message_id = send_message_result_id print("send_message succeeded, message id:", self._message_id) async def get_message_async(self): @@ -169,44 +169,60 @@ async def delete_message_async(self): # [END delete_message] print("delete_message succeeded") - async def list_members_async(self): + async def list_participants_async(self): from azure.communication.chat.aio import ChatThreadClient, CommunicationUserCredential chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) async with chat_thread_client: - # [START list_members] - chat_thread_members = chat_thread_client.list_members() - print("list_members succeeded, members:") - async for chat_thread_member in chat_thread_members: - print(chat_thread_member) - # [END list_members] - - async def add_members_async(self): + # [START list_participants] + chat_thread_participants = chat_thread_client.list_participants() + print("list_participants succeeded, participants:") + async for chat_thread_participant in chat_thread_participants: + print(chat_thread_participant) + # [END list_participants] + + async def add_participant_async(self): from azure.communication.chat.aio import ChatThreadClient, CommunicationUserCredential chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) async with chat_thread_client: - # [START add_members] - from azure.communication.chat import ChatThreadMember, CommunicationUser + # [START add_participant] + from azure.communication.chat import ChatThreadParticipant, CommunicationUser from datetime import datetime - new_member = ChatThreadMember( + new_chat_thread_participant = ChatThreadParticipant( user=self.new_user, display_name='name', share_history_time=datetime.utcnow()) - members = [new_member] - await chat_thread_client.add_members(members) - # [END add_members] - print("add_members succeeded") + await chat_thread_client.add_participant(new_chat_thread_participant) + # [END add_participant] + print("add_participant succeeded") - async def remove_member_async(self): + async def add_participants_async(self): from azure.communication.chat.aio import ChatThreadClient, CommunicationUserCredential chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) async with chat_thread_client: - # [START remove_member] - await chat_thread_client.remove_member(self.new_user) - # [END remove_member] - print("remove_member_async succeeded") + # [START add_participants] + from azure.communication.chat import ChatThreadParticipant, CommunicationUser + from datetime import datetime + new_participant = ChatThreadParticipant( + user=self.new_user, + display_name='name', + share_history_time=datetime.utcnow()) + participants = [new_participant] + await chat_thread_client.add_participants(participants) + # [END add_participants] + print("add_participants succeeded") + + async def remove_participant_async(self): + from azure.communication.chat.aio import ChatThreadClient, CommunicationUserCredential + chat_thread_client = ChatThreadClient(self.endpoint, CommunicationUserCredential(self.token), self._thread_id) + + async with chat_thread_client: + # [START remove_participant] + await chat_thread_client.remove_participant(self.new_user) + # [END remove_participant] + print("remove_participant_async succeeded") async def send_typing_notification_async(self): from azure.communication.chat.aio import ChatThreadClient, CommunicationUserCredential @@ -227,7 +243,7 @@ def clean_up(self): async def main(): sample = ChatThreadClientSamplesAsync() await sample.create_chat_thread_client_async() - await sample.update_thread_async() + await sample.update_topic_async() await sample.send_message_async() await sample.get_message_async() await sample.list_messages_async() @@ -235,9 +251,10 @@ async def main(): await sample.send_read_receipt_async() await sample.list_read_receipts_async() await sample.delete_message_async() - await sample.add_members_async() - await sample.list_members_async() - await sample.remove_member_async() + await sample.add_participant_async() + await sample.add_participants_async() + await sample.list_participants_async() + await sample.remove_participant_async() await sample.send_typing_notification_async() sample.clean_up() diff --git a/sdk/communication/azure-communication-chat/swagger/SWAGGER.md b/sdk/communication/azure-communication-chat/swagger/SWAGGER.md index 4d99df5dd8ce..1eb37c2ac30c 100644 --- a/sdk/communication/azure-communication-chat/swagger/SWAGGER.md +++ b/sdk/communication/azure-communication-chat/swagger/SWAGGER.md @@ -15,7 +15,7 @@ autorest SWAGGER.md ### Settings ``` yaml -input-file: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/8818a603b78a1355ba1647ab9cd4e3354cdc4b69/specification/communication/data-plane/Microsoft.CommunicationServicesChat/preview/2020-09-21-preview2/communicationserviceschat.json +input-file: https://int.chatgateway.trafficmanager.net/swagger/2020-11-01-preview3/swagger.json output-folder: ../azure/communication/chat/_generated namespace: azure.communication.chat no-namespace-folders: true diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_create_chat_thread.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_create_chat_thread.yaml index 373dedcff227..7bef7ec7773e 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_create_chat_thread.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_create_chat_thread.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:04 GMT + - Thu, 26 Nov 2020 01:19:09 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:04 GMT + - Thu, 26 Nov 2020 01:19:09 GMT ms-cv: - - fe8GIULrmE6QhpXm1qICYQ.0 - strict-transport-security: - - max-age=2592000 + - lhCdaxUwWUCal3LpTU2/gQ.0 transfer-encoding: - chunked x-processing-time: - - 226ms + - 161ms status: code: 200 message: OK @@ -52,35 +50,33 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:04 GMT + - Thu, 26 Nov 2020 01:19:09 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:04.2945816+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:19:09.280025+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:04 GMT + - Thu, 26 Nov 2020 01:19:10 GMT ms-cv: - - 1hqRr6NaHkKQuQschfqWGQ.0 - strict-transport-security: - - max-age=2592000 + - 9zBM01rBnkSnsXIF6pGg8w.0 transfer-encoding: - chunked x-processing-time: - - 292ms + - 318ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -89,33 +85,34 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:19:11Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:05 GMT + - Thu, 26 Nov 2020 01:19:11 GMT ms-cv: - - uBNvvJKY+0Oh3CuI/A8sNQ.0 + - wLPXVZlkIk+EvcDCV57y1w.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 181ms + - 1351ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: null headers: @@ -128,27 +125,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:05 GMT + - Thu, 26 Nov 2020 01:19:11 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:06 GMT + - Thu, 26 Nov 2020 01:19:28 GMT ms-cv: - - CyKTdQdMlk6bJqwL6tj9BQ.0 - strict-transport-security: - - max-age=2592000 + - l/47be0coky6GSohoG6/uA.0 x-processing-time: - - 711ms + - 17271ms status: code: 204 message: No Content @@ -164,23 +159,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:06 GMT + - Thu, 26 Nov 2020 01:19:29 GMT ms-cv: - - XTK1Jm4VZ0ibw36diC8kng.0 + - HzqDDsO2CE+cpW9xSamN4w.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 73ms + - 323ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_delete_chat_thread.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_delete_chat_thread.yaml index db29ed63cc3f..bac0ab889a78 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_delete_chat_thread.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_delete_chat_thread.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:07 GMT + - Thu, 26 Nov 2020 01:19:29 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:07 GMT + - Thu, 26 Nov 2020 01:19:29 GMT ms-cv: - - cft8FETd2UenFqgeAw98sQ.0 - strict-transport-security: - - max-age=2592000 + - SN6y0S8TH0KORnzRByGoUg.0 transfer-encoding: - chunked x-processing-time: - - 205ms + - 148ms status: code: 200 message: OK @@ -52,35 +50,33 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:07 GMT + - Thu, 26 Nov 2020 01:19:30 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:07.0340593+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:19:29.5716996+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:07 GMT + - Thu, 26 Nov 2020 01:19:29 GMT ms-cv: - - MdHwjpKprkWMYv6+/3eEKg.0 - strict-transport-security: - - max-age=2592000 + - uWqIQAyWREKBinbwxtNxyQ.0 transfer-encoding: - chunked x-processing-time: - - 275ms + - 297ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -89,33 +85,34 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:19:31Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:07 GMT + - Thu, 26 Nov 2020 01:19:31 GMT ms-cv: - - cKYTG/oDkUGXVLvim9h/fQ.0 + - oscR5GX7Vky40MLMHjeT5Q.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 312ms + - 1341ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: null headers: @@ -128,23 +125,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:08 GMT + - Thu, 26 Nov 2020 01:19:32 GMT ms-cv: - - XyKlM6f0X06+KtoO2znMow.0 + - HTHqkbsQBE24n1uuWzevlA.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 127ms + - 327ms status: code: 204 message: No Content @@ -160,27 +157,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:09 GMT + - Thu, 26 Nov 2020 01:19:32 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:09 GMT + - Thu, 26 Nov 2020 01:19:49 GMT ms-cv: - - JkDTB7thgEu6K+Afey0hcA.0 - strict-transport-security: - - max-age=2592000 + - q+P4L9UaAEuPRZqgxVFYNw.0 x-processing-time: - - 1143ms + - 16592ms status: code: 204 message: No Content @@ -196,23 +191,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:09 GMT + - Thu, 26 Nov 2020 01:19:48 GMT ms-cv: - - P/JKbYmTQ0qaJ6vsKCrOGQ.0 + - CwOn2xpCeEG4Vi66SNyTZA.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 26ms + - 251ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_get_chat_thread.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_get_chat_thread.yaml index 6dc4dad27296..0431e7809c53 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_get_chat_thread.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_get_chat_thread.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:10 GMT + - Thu, 26 Nov 2020 01:19:49 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:10 GMT + - Thu, 26 Nov 2020 01:19:49 GMT ms-cv: - - 5vACECezBEyDSy5w3VORLQ.0 - strict-transport-security: - - max-age=2592000 + - H+q0Jj4I9EaBypbStNPULg.0 transfer-encoding: - chunked x-processing-time: - - 210ms + - 147ms status: code: 200 message: OK @@ -52,35 +50,33 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:11 GMT + - Thu, 26 Nov 2020 01:19:49 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:10.5782778+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:19:49.2596204+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:10 GMT + - Thu, 26 Nov 2020 01:19:49 GMT ms-cv: - - 3/Cmsjb/lUmflZSClTOkyQ.0 - strict-transport-security: - - max-age=2592000 + - gHerHEpe9Um9mBStpqCpsw.0 transfer-encoding: - chunked x-processing-time: - - 276ms + - 312ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -89,33 +85,34 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:19:50Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:12 GMT + - Thu, 26 Nov 2020 01:19:50 GMT ms-cv: - - z2B2eOCdzkCNpgqC28YFzw.0 + - UyVjv8vg2U27HwevNccVXA.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 554ms + - 845ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: null headers: @@ -126,27 +123,27 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: - body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-10-01T22:48:12Z", - "createdBy": "sanitized", "members": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:19:50Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:12 GMT + - Thu, 26 Nov 2020 01:19:50 GMT ms-cv: - - aDV48+ZQsEuC4x5W5jWwTg.0 + - HIanX4hnMEqzk47JpFUnQg.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 40ms + - 268ms status: code: 200 message: OK @@ -162,27 +159,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:12 GMT + - Thu, 26 Nov 2020 01:19:51 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:13 GMT + - Thu, 26 Nov 2020 01:20:08 GMT ms-cv: - - AVq30DZDM0u/cQqTQsdlgA.0 - strict-transport-security: - - max-age=2592000 + - oPT6/1XsDUGqdhZpf8CPOw.0 x-processing-time: - - 1007ms + - 16545ms status: code: 204 message: No Content @@ -198,23 +193,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:13 GMT + - Thu, 26 Nov 2020 01:20:07 GMT ms-cv: - - apLQYuh0kE6e/ZK01i2aTQ.0 + - mkFqRld8t02SdjqpytZVrA.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 110ms + - 304ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_get_thread_client.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_get_thread_client.yaml index 9b43fc008f6b..b5402ba74014 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_get_thread_client.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_get_thread_client.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:14 GMT + - Thu, 26 Nov 2020 01:20:09 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:14 GMT + - Thu, 26 Nov 2020 01:20:09 GMT ms-cv: - - v25eHGzcHEalxqZSO8wCDw.0 - strict-transport-security: - - max-age=2592000 + - rA5btKsFg06XGStisyHugg.0 transfer-encoding: - chunked x-processing-time: - - 225ms + - 195ms status: code: 200 message: OK @@ -52,35 +50,33 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:15 GMT + - Thu, 26 Nov 2020 01:20:10 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:14.369386+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:20:09.3532462+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:15 GMT + - Thu, 26 Nov 2020 01:20:09 GMT ms-cv: - - 3q1j7VOFVkuio7mS1RByjA.0 - strict-transport-security: - - max-age=2592000 + - 4JRdsjYW+Um6vcKNiBKDJQ.0 transfer-encoding: - chunked x-processing-time: - - 278ms + - 304ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -89,33 +85,34 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:20:10Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:16 GMT + - Thu, 26 Nov 2020 01:20:11 GMT ms-cv: - - Etag0jtBwkCHXR6dn2hV0Q.0 + - OpFYOFiYMkWagptd3pV0tQ.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 405ms + - 836ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: null headers: @@ -128,27 +125,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:16 GMT + - Thu, 26 Nov 2020 01:20:11 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:16 GMT + - Thu, 26 Nov 2020 01:20:27 GMT ms-cv: - - zOVlGk9D6Uq8CvO7ddoUFA.0 - strict-transport-security: - - max-age=2592000 + - mYTFkzkVmE6Q3Fhz5tgBuQ.0 x-processing-time: - - 961ms + - 16069ms status: code: 204 message: No Content @@ -164,23 +159,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:17 GMT + - Thu, 26 Nov 2020 01:20:27 GMT ms-cv: - - gYVJZBeVd0SN5k49zKaf9Q.0 + - dgIk5vEohk+XZCi2a+lKkA.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 66ms + - 295ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_list_chat_threads.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_list_chat_threads.yaml index fddfa3ccfa6d..c3b0626fc745 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_list_chat_threads.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e.test_list_chat_threads.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:17 GMT + - Thu, 26 Nov 2020 01:20:27 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:17 GMT + - Thu, 26 Nov 2020 01:20:27 GMT ms-cv: - - AOUpOr5lqEeuEClYbLGQow.0 - strict-transport-security: - - max-age=2592000 + - ZtOl01ckpUGH/4TRzuEdLw.0 transfer-encoding: - chunked x-processing-time: - - 208ms + - 151ms status: code: 200 message: OK @@ -52,35 +50,33 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:18 GMT + - Thu, 26 Nov 2020 01:20:28 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:17.6733861+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:20:27.8080382+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:18 GMT + - Thu, 26 Nov 2020 01:20:28 GMT ms-cv: - - sQoafUKDCE+DscyI7g3GUQ.0 - strict-transport-security: - - max-age=2592000 + - anDmDF3Q8kyP3C2nC7TxUQ.0 transfer-encoding: - chunked x-processing-time: - - 275ms + - 301ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -89,33 +85,34 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:20:29Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:19 GMT + - Thu, 26 Nov 2020 01:20:29 GMT ms-cv: - - vQ/O7g4eDEiL9aSLGDPT4w.0 + - mqvLyVJrq0i2gWVOshq+hw.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 241ms + - 836ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: null headers: @@ -126,26 +123,26 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads?maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:21 GMT + - Thu, 26 Nov 2020 01:20:31 GMT ms-cv: - - WYJfu7+2l0aDpzcem5Y2Kw.0 + - csVt83Uuw0Su49XZjCJSkA.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 45ms + - 412ms status: code: 200 message: OK @@ -161,27 +158,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:21 GMT + - Thu, 26 Nov 2020 01:20:32 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:21 GMT + - Thu, 26 Nov 2020 01:20:48 GMT ms-cv: - - xeND38DwIk6HZG1ygLTioA.0 - strict-transport-security: - - max-age=2592000 + - +bY5lxNVIkC85eE9KeRMgg.0 x-processing-time: - - 715ms + - 16912ms status: code: 204 message: No Content @@ -197,23 +192,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:22 GMT + - Thu, 26 Nov 2020 01:20:49 GMT ms-cv: - - 0rDmR1kkyUimsvKSGxkbwg.0 + - 6lzh61ChDU2JPa7gROzRzw.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 81ms + - 405ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_create_chat_thread_async.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_create_chat_thread_async.yaml index 0955dc57a35b..33d75f4cd399 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_create_chat_thread_async.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_create_chat_thread_async.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:22 GMT + - Thu, 26 Nov 2020 01:20:50 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:22 GMT + - Thu, 26 Nov 2020 01:20:49 GMT ms-cv: - - QSCbSrgO7U2Adg+S3C68Rg.0 - strict-transport-security: - - max-age=2592000 + - 7LNIlmsgVUKLclt9NmrIdg.0 transfer-encoding: - chunked x-processing-time: - - 212ms + - 191ms status: code: 200 message: OK @@ -52,82 +50,81 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:23 GMT + - Thu, 26 Nov 2020 01:20:50 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:22.7572342+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:20:49.1938339+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:23 GMT + - Thu, 26 Nov 2020 01:20:50 GMT ms-cv: - - KrqZ4jB1n0OzwHiNZo8q+w.0 - strict-transport-security: - - max-age=2592000 + - pdnzelD87EG6AddYOK4FuA.0 transfer-encoding: - chunked x-processing-time: - - 270ms + - 597ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:20:51Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:48:23 GMT - ms-cv: 2Y1gQKJ+EUyl0fF+H1ulFQ.0 + date: Thu, 26 Nov 2020 01:20:51 GMT + ms-cv: qT9nZ+YTzEWXC+i4ToeZOQ.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 294ms + x-processing-time: 1179ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:48:23 GMT - ms-cv: eDflju2COECRm6Lzy5iiVw.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:20:52 GMT + ms-cv: tF1t6AUKb0WV2J9oK1uNeg.0 strict-transport-security: max-age=2592000 - x-processing-time: 133ms + x-processing-time: 298ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -140,27 +137,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:24 GMT + - Thu, 26 Nov 2020 01:20:52 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:25 GMT + - Thu, 26 Nov 2020 01:21:10 GMT ms-cv: - - Pxl6t9kWIE2sUX52lEHOTg.0 - strict-transport-security: - - max-age=2592000 + - DCjC30JvEEGcibXtzydfQQ.0 x-processing-time: - - 1058ms + - 17288ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_delete_chat_thread.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_delete_chat_thread.yaml index 1b105347f499..b052f61217aa 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_delete_chat_thread.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_delete_chat_thread.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:25 GMT + - Thu, 26 Nov 2020 01:21:10 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:26 GMT + - Thu, 26 Nov 2020 01:21:10 GMT ms-cv: - - PI5HRuD/F06qldFWyCOXtQ.0 - strict-transport-security: - - max-age=2592000 + - wq7cVApy4kqd6SYbx3fpcQ.0 transfer-encoding: - chunked x-processing-time: - - 236ms + - 143ms status: code: 200 message: OK @@ -52,104 +50,103 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:26 GMT + - Thu, 26 Nov 2020 01:21:10 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:25.9847651+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:21:10.0726718+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:26 GMT + - Thu, 26 Nov 2020 01:21:10 GMT ms-cv: - - yW1xnufq20O4sEXQhtqzbw.0 - strict-transport-security: - - max-age=2592000 + - o2X2iQrwf0WAzigZf5n2TA.0 transfer-encoding: - chunked x-processing-time: - - 294ms + - 299ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:21:11Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:48:26 GMT - ms-cv: EzHyAxuiU0CSqwzJ+oWiWg.0 + date: Thu, 26 Nov 2020 01:21:11 GMT + ms-cv: aUwac+kdn0Sx2po45PYNyQ.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 300ms + x-processing-time: 845ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:48:26 GMT - ms-cv: VVrHZhE7o0+AuzhYvrh0/g.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:21:11 GMT + ms-cv: 7MyJLIjrCU2H24DKADVQPg.0 strict-transport-security: max-age=2592000 - x-processing-time: 65ms + x-processing-time: 284ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:48:27 GMT - ms-cv: QmT2ALRHWE+GS6vqkO4lAQ.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:21:11 GMT + ms-cv: mq02YsmKVkC0uCqh2FcEeg.0 strict-transport-security: max-age=2592000 - x-processing-time: 301ms + x-processing-time: 245ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -162,27 +159,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:28 GMT + - Thu, 26 Nov 2020 01:21:12 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:28 GMT + - Thu, 26 Nov 2020 01:21:28 GMT ms-cv: - - JspE4e7FgUCeNsXU49YE2w.0 - strict-transport-security: - - max-age=2592000 + - Y94mNlSzdUyoLHiR+Ba/2g.0 x-processing-time: - - 821ms + - 16505ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_get_chat_thread.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_get_chat_thread.yaml index dffc2aad4e32..6a188ddad020 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_get_chat_thread.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_get_chat_thread.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:29 GMT + - Thu, 26 Nov 2020 01:21:29 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:29 GMT + - Thu, 26 Nov 2020 01:21:29 GMT ms-cv: - - lwKVCJE5F06uFt4/VU6aMg.0 - strict-transport-security: - - max-age=2592000 + - zaLjG0NY1UaFlb37HqCSoA.0 transfer-encoding: - chunked x-processing-time: - - 206ms + - 144ms status: code: 200 message: OK @@ -52,106 +50,105 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:29 GMT + - Thu, 26 Nov 2020 01:21:29 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:29.0659228+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:21:29.3965216+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:29 GMT + - Thu, 26 Nov 2020 01:21:30 GMT ms-cv: - - qmHBkTmmi0aDlF4do9PzhA.0 - strict-transport-security: - - max-age=2592000 + - cbQRTe8Aek+UNzyPsIOY9Q.0 transfer-encoding: - chunked x-processing-time: - - 276ms + - 299ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:21:30Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:48:30 GMT - ms-cv: o2MF9Zgjj0mwIMNKKm/noA.0 + date: Thu, 26 Nov 2020 01:21:31 GMT + ms-cv: l2HmSTYrbE27CkF0SDA+Aw.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 173ms + x-processing-time: 979ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: - body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-10-01T22:48:30Z", - "createdBy": "sanitized", "members": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:21:30Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:48:30 GMT - ms-cv: v50+x4YTiEqJLZKZGxltjA.0 + date: Thu, 26 Nov 2020 01:21:31 GMT + ms-cv: 48rJVl5XQEGV7MMbLQuY2Q.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 39ms + x-processing-time: 252ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:48:30 GMT - ms-cv: 4x0MOpKhw0qadgA6xg9+5w.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:21:32 GMT + ms-cv: xBuagQl1ZUq9XQpOoTP2kQ.0 strict-transport-security: max-age=2592000 - x-processing-time: 53ms + x-processing-time: 360ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -164,27 +161,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:30 GMT + - Thu, 26 Nov 2020 01:21:32 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:31 GMT + - Thu, 26 Nov 2020 01:21:47 GMT ms-cv: - - //nLBSlVqkymBv5VfCeVjA.0 - strict-transport-security: - - max-age=2592000 + - +tRng5OY0EShIZ+U7tvKtg.0 x-processing-time: - - 1345ms + - 16050ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_get_thread_client.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_get_thread_client.yaml index 87c117057689..d69b3a04edb2 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_get_thread_client.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_get_thread_client.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:32 GMT + - Thu, 26 Nov 2020 01:21:48 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:32 GMT + - Thu, 26 Nov 2020 01:21:48 GMT ms-cv: - - Ff06YaMrR0+Ym1jPO1KDaQ.0 - strict-transport-security: - - max-age=2592000 + - uer+Ea5JKk618XcX2aUYjA.0 transfer-encoding: - chunked x-processing-time: - - 233ms + - 144ms status: code: 200 message: OK @@ -52,82 +50,81 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:33 GMT + - Thu, 26 Nov 2020 01:21:48 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:32.464477+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:21:48.2262131+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:32 GMT + - Thu, 26 Nov 2020 01:21:48 GMT ms-cv: - - H4g7sZOx10e5hA7ZrijZvw.0 - strict-transport-security: - - max-age=2592000 + - sa3ESOR4OEmriuLdfNHomQ.0 transfer-encoding: - chunked x-processing-time: - - 278ms + - 297ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:21:49Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:48:33 GMT - ms-cv: dE/9ZSRef0yrm6WWJAoN/Q.0 + date: Thu, 26 Nov 2020 01:21:50 GMT + ms-cv: ya0Ghl3QsEiAC+8XL/RmXQ.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 212ms + x-processing-time: 838ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:48:34 GMT - ms-cv: MA4Ar2rKKkaquEBoD4a1HA.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:21:50 GMT + ms-cv: pdps7Mhv+kKCLyJnFbZcwQ.0 strict-transport-security: max-age=2592000 - x-processing-time: 64ms + x-processing-time: 293ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -140,27 +137,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:34 GMT + - Thu, 26 Nov 2020 01:21:50 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:35 GMT + - Thu, 26 Nov 2020 01:22:06 GMT ms-cv: - - 3Rqn+fOjDE2y2m0y+IZzAQ.0 - strict-transport-security: - - max-age=2592000 + - hh/fQapqO0+qU9rHgve42w.0 x-processing-time: - - 1476ms + - 16894ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_list_chat_threads.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_list_chat_threads.yaml index 73e1724c3fe7..c0de98e51194 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_list_chat_threads.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_client_e2e_async.test_list_chat_threads.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:35 GMT + - Thu, 26 Nov 2020 01:22:07 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:35 GMT + - Thu, 26 Nov 2020 01:22:07 GMT ms-cv: - - zn/jmJiONEyuuseP/iz7vA.0 - strict-transport-security: - - max-age=2592000 + - abSdviEBLUyqxoosse0XjQ.0 transfer-encoding: - chunked x-processing-time: - - 205ms + - 143ms status: code: 200 message: OK @@ -52,105 +50,104 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:36 GMT + - Thu, 26 Nov 2020 01:22:08 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:35.8662311+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:22:07.3610587+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:36 GMT + - Thu, 26 Nov 2020 01:22:07 GMT ms-cv: - - 9alIkXSsXESDZAS6K9Gk9g.0 - strict-transport-security: - - max-age=2592000 + - t9nhLIXhQUO5LmSKQIwh0Q.0 transfer-encoding: - chunked x-processing-time: - - 279ms + - 298ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:22:08Z", + "createdBy": "sanitized", "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:48:37 GMT - ms-cv: 0fzbNJSoDUyX8Aj1rE4cSw.0 + date: Thu, 26 Nov 2020 01:22:08 GMT + ms-cv: p0gwIWsmHkWyCUYRDGsFdA.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 260ms + x-processing-time: 821ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads?maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:48:39 GMT - ms-cv: 6aLwM4jC4kOpGpUmRP2xqQ.0 + date: Thu, 26 Nov 2020 01:22:10 GMT + ms-cv: PDZijimua0aXNcZburvjWA.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 82ms + x-processing-time: 381ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads?maxPageSize=1&api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads?maxPageSize=1&api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:48:39 GMT - ms-cv: 5cuAM0L5A0y9tzm5hQVKDQ.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:22:11 GMT + ms-cv: r/IuVej42ESHIcmoag/dGg.0 strict-transport-security: max-age=2592000 - x-processing-time: 104ms + x-processing-time: 283ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -163,27 +160,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:39 GMT + - Thu, 26 Nov 2020 01:22:12 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:40 GMT + - Thu, 26 Nov 2020 01:22:28 GMT ms-cv: - - bFl0bfWM6Emlz7/WLQwjpQ.0 - strict-transport-security: - - max-age=2592000 + - Zo8NCaK/50OTdE0tDA7mDg.0 x-processing-time: - - 898ms + - 16231ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_add_participant.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_add_participant.yaml new file mode 100644 index 000000000000..fdae2aa3db70 --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_add_participant.yaml @@ -0,0 +1,290 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:22:28 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:22:28 GMT + ms-cv: + - dd+vYARl/0aU1L4LstbDYg.0 + transfer-encoding: + - chunked + x-processing-time: + - 160ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:22:29 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:22:28.3411326+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:22:28 GMT + ms-cv: + - mFh0TCxslE2XE+AM30ML5w.0 + transfer-encoding: + - chunked + x-processing-time: + - 300ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:22:29 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:22:29 GMT + ms-cv: + - 6P4tYc+Oskis9JocjuFqfQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 146ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:22:29Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a206-a7ef-b274-5a3a0d00011b", + "participants": "sanitized"}' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:22:30 GMT + ms-cv: + - VyHZBwcHUkeq1ZBe0z0K4w.0 + strict-transport-security: + - max-age=2592000 + transfer-encoding: + - chunked + x-processing-time: + - 830ms + status: + code: 201 + message: Created +- request: + body: '{"participants": "sanitized"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '183' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-11-01-preview3 + content-length: + - '0' + date: + - Thu, 26 Nov 2020 01:22:31 GMT + ms-cv: + - 6ovFy1YWXUyzgtTCQ0AuEg.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 913ms + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:22:31 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:22:47 GMT + ms-cv: + - NghzSFVLlkWYMI9eO/A79g.0 + x-processing-time: + - 16596ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:22:48 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:23:04 GMT + ms-cv: + - XRgg32P31UWn2RQYkEZ09g.0 + x-processing-time: + - 15718ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + date: + - Thu, 26 Nov 2020 01:23:04 GMT + ms-cv: + - jXcUJDKMH0yz1gpWOq5TVQ.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 305ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_add_participants.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_add_participants.yaml new file mode 100644 index 000000000000..003c8e255415 --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_add_participants.yaml @@ -0,0 +1,290 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:23:04 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:23:04 GMT + ms-cv: + - HerM2mQmd02OBAdCT3OyXQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 148ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:23:05 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:23:04.4533324+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:23:04 GMT + ms-cv: + - pn2gx/zkCEKfuOZPXwRTwQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 301ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:23:05 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:23:04 GMT + ms-cv: + - /2+tkc7pLEelGGLEH9kcJw.0 + transfer-encoding: + - chunked + x-processing-time: + - 149ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:23:06Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a207-34f9-b274-5a3a0d00011d", + "participants": "sanitized"}' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:23:06 GMT + ms-cv: + - Vmgei+anTEqeebmxZHF4CQ.0 + strict-transport-security: + - max-age=2592000 + transfer-encoding: + - chunked + x-processing-time: + - 818ms + status: + code: 201 + message: Created +- request: + body: '{"participants": "sanitized"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '183' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-11-01-preview3 + content-length: + - '0' + date: + - Thu, 26 Nov 2020 01:23:07 GMT + ms-cv: + - +sEVZwQx9kCCFwTfvjBrFg.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 843ms + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:23:07 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:23:23 GMT + ms-cv: + - NRdn3as36kaQxHnmvueoPg.0 + x-processing-time: + - 15967ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:23:23 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:23:40 GMT + ms-cv: + - PE0+Qm7kaEWHpVkvK1uWcQ.0 + x-processing-time: + - 16637ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + date: + - Thu, 26 Nov 2020 01:23:40 GMT + ms-cv: + - XyxI2gXMv0mcHZAKSMH0yg.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 312ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_delete_message.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_delete_message.yaml index c15444fc243a..587dc4e95b6a 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_delete_message.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_delete_message.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:46 GMT + - Thu, 26 Nov 2020 01:23:41 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:45 GMT + - Thu, 26 Nov 2020 01:23:40 GMT ms-cv: - - EnMLWQ9jpE+7q/UNlYJCQg.0 - strict-transport-security: - - max-age=2592000 + - +FisQ6g8mkuEiGHBt184tA.0 transfer-encoding: - chunked x-processing-time: - - 200ms + - 144ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:46 GMT + - Thu, 26 Nov 2020 01:23:41 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:46.1273593+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:23:40.9543611+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:46 GMT + - Thu, 26 Nov 2020 01:23:41 GMT ms-cv: - - 3TKmu7GgXU+fIhOV3PUIYw.0 - strict-transport-security: - - max-age=2592000 + - FowW+e67ZkWt5cNBT2x/hg.0 transfer-encoding: - chunked x-processing-time: - - 271ms + - 298ms status: code: 200 message: OK @@ -91,35 +87,33 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:47 GMT + - Thu, 26 Nov 2020 01:23:41 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:46 GMT + - Thu, 26 Nov 2020 01:23:41 GMT ms-cv: - - 7k8UcPEzhUKsx0dDluxBuw.0 - strict-transport-security: - - max-age=2592000 + - F5vvIThR+0aETPMo6gJvAw.0 transfer-encoding: - chunked x-processing-time: - - 200ms + - 139ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -128,33 +122,35 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:23:42Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a207-c397-b274-5a3a0d00011f", + "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:47 GMT + - Thu, 26 Nov 2020 01:23:42 GMT ms-cv: - - wWPQ+Q3hnEaaR1tGZYj8+g.0 + - nC7RUoxItUSPZAjGCSYyyA.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 319ms + - 832ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -170,26 +166,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:48 GMT + - Thu, 26 Nov 2020 01:23:43 GMT ms-cv: - - sD8hvsFJuEa+kltTBrtRnw.0 + - ILiVsd9LVkCkQeOJ/MSVBQ.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 158ms + - 632ms status: code: 201 message: Created @@ -205,23 +201,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:48 GMT + - Thu, 26 Nov 2020 01:23:44 GMT ms-cv: - - 5TjUA4oxnE6MrAX2wpGMaw.0 + - RTgZ5X8qA0OUsZRVG9lBeQ.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 69ms + - 395ms status: code: 204 message: No Content @@ -237,27 +233,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:49 GMT + - Thu, 26 Nov 2020 01:23:44 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:49 GMT + - Thu, 26 Nov 2020 01:24:01 GMT ms-cv: - - kAjCMg56YE65+rd1WbOMig.0 - strict-transport-security: - - max-age=2592000 + - CRD1a1Uh4kSa7pqIKjPX5g.0 x-processing-time: - - 797ms + - 16806ms status: code: 204 message: No Content @@ -273,27 +267,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:50 GMT + - Thu, 26 Nov 2020 01:24:01 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:49 GMT + - Thu, 26 Nov 2020 01:24:16 GMT ms-cv: - - 4ThWtTb6lEu5lp9hYtQwxg.0 - strict-transport-security: - - max-age=2592000 + - 3KneB3pMBUmzbeKy9rpxiA.0 x-processing-time: - - 419ms + - 15876ms status: code: 204 message: No Content @@ -309,23 +301,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:50 GMT + - Thu, 26 Nov 2020 01:24:17 GMT ms-cv: - - ZYuFiwL1tUWgcYwQTBGaaw.0 + - XrmTL9T+zE6cRYMnS+mh2w.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 116ms + - 292ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_get_message.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_get_message.yaml index c100c65fdf39..8c8eb60c1efa 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_get_message.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_get_message.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:50 GMT + - Thu, 26 Nov 2020 01:24:17 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:50 GMT + - Thu, 26 Nov 2020 01:24:17 GMT ms-cv: - - WS7ND5c3WUuDn89v7EfWbg.0 - strict-transport-security: - - max-age=2592000 + - msRYo46MSkyKI84reLo0HA.0 transfer-encoding: - chunked x-processing-time: - - 208ms + - 194ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:48:51 GMT + - Thu, 26 Nov 2020 01:24:18 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:48:50.8663366+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:24:17.1459685+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:51 GMT + - Thu, 26 Nov 2020 01:24:18 GMT ms-cv: - - utDeUWiMe0Gn2Wah1sXGBQ.0 - strict-transport-security: - - max-age=2592000 + - ME5w3LfU3k6qpGONFQFRGg.0 transfer-encoding: - chunked x-processing-time: - - 277ms + - 814ms status: code: 200 message: OK @@ -91,35 +87,33 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:51 GMT + - Thu, 26 Nov 2020 01:24:19 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:51 GMT + - Thu, 26 Nov 2020 01:24:18 GMT ms-cv: - - Ry9XK/V/cUKPCBSPDZjaFA.0 - strict-transport-security: - - max-age=2592000 + - IOXvc6LenEGqFVWCmDEvdw.0 transfer-encoding: - chunked x-processing-time: - - 204ms + - 145ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -128,33 +122,35 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:24:19Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a208-52d1-557d-5a3a0d0000df", + "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:52 GMT + - Thu, 26 Nov 2020 01:24:19 GMT ms-cv: - - Z2pEODAcXU62EN1+FJnhMg.0 + - EKBi3K6XsE+2Lhsqi5cRhg.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 197ms + - 825ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -170,26 +166,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:52 GMT + - Thu, 26 Nov 2020 01:24:20 GMT ms-cv: - - vrYs17LtTk20gGb3BgneNw.0 + - Orn/iKS620SaBNazUpUxiQ.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 98ms + - 684ms status: code: 201 message: Created @@ -203,28 +199,28 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 response: - body: '{"id": "sanitized", "type": "Text", "priority": "Normal", "version": "1601592533507", - "content": "hello world", "senderDisplayName": "sender name", "createdOn": "2020-10-01T22:48:53Z", + body: '{"id": "sanitized", "type": "Text", "priority": "Normal", "version": "1606353860857", + "content": "hello world", "senderDisplayName": "sender name", "createdOn": "2020-11-26T01:24:20Z", "senderId": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:48:52 GMT + - Thu, 26 Nov 2020 01:24:20 GMT ms-cv: - - 2HP7uIuMTU2NM1j0+PatjA.0 + - TgVAXmNOVUqQDFtLimeI3g.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 29ms + - 262ms status: code: 200 message: OK @@ -240,27 +236,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:53 GMT + - Thu, 26 Nov 2020 01:24:21 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:53 GMT + - Thu, 26 Nov 2020 01:24:38 GMT ms-cv: - - XtVwvl76U0CsZVtFMcHUow.0 - strict-transport-security: - - max-age=2592000 + - 7WkXURdvCUadQaKfM0XUCg.0 x-processing-time: - - 843ms + - 17535ms status: code: 204 message: No Content @@ -276,27 +270,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:48:54 GMT + - Thu, 26 Nov 2020 01:24:39 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:48:54 GMT + - Thu, 26 Nov 2020 01:24:55 GMT ms-cv: - - JHWAxwFKWkiiWueZDcAHlA.0 - strict-transport-security: - - max-age=2592000 + - 6iwCu22I9kCdX7N0AL23AA.0 x-processing-time: - - 788ms + - 16376ms status: code: 204 message: No Content @@ -312,23 +304,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:48:55 GMT + - Thu, 26 Nov 2020 01:24:55 GMT ms-cv: - - Sr6kvX5BWU+WCyrn7zAvZw.0 + - aNenUrVPlEqJY0ZCn/jJGw.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 86ms + - 323ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_messages.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_messages.yaml index 1a3e5d54f05a..f9440f907da3 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_messages.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_messages.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:02 GMT + - Thu, 26 Nov 2020 01:24:56 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:02 GMT + - Thu, 26 Nov 2020 01:24:56 GMT ms-cv: - - qL7UQ4ygKUmcBaucjPAStw.0 - strict-transport-security: - - max-age=2592000 + - 804wtj3mZUO4fzi6Z15Q+g.0 transfer-encoding: - chunked x-processing-time: - - 208ms + - 145ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:49:03 GMT + - Thu, 26 Nov 2020 01:24:56 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:49:02.3817726+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:24:55.8283538+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:02 GMT + - Thu, 26 Nov 2020 01:24:56 GMT ms-cv: - - xndN0tgzDEGPfT10J5Ltkw.0 - strict-transport-security: - - max-age=2592000 + - YO9czrtDg0yc1yz5Q+dGtA.0 transfer-encoding: - chunked x-processing-time: - - 275ms + - 302ms status: code: 200 message: OK @@ -91,35 +87,33 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:03 GMT + - Thu, 26 Nov 2020 01:24:56 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:02 GMT + - Thu, 26 Nov 2020 01:24:57 GMT ms-cv: - - g6J6xbDnykSHDssaSX8WuA.0 - strict-transport-security: - - max-age=2592000 + - SCM4p2/tX0ikotqp00XisQ.0 transfer-encoding: - chunked x-processing-time: - - 205ms + - 148ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -128,33 +122,35 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:24:57Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a208-e816-b274-5a3a0d000121", + "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:04 GMT + - Thu, 26 Nov 2020 01:24:57 GMT ms-cv: - - /KEwbshP4kK9aIDSvGLhqw.0 + - zYy8Kz/sKEKeY2vLvJFEvw.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 270ms + - 830ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -170,26 +166,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:04 GMT + - Thu, 26 Nov 2020 01:24:58 GMT ms-cv: - - 8yxddUHAxka8KKrGpiw8OQ.0 + - 6hVNy/RtuUyr5NI1d6pKYQ.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 73ms + - 695ms status: code: 201 message: Created @@ -203,26 +199,26 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized", "nextLink": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:06 GMT + - Thu, 26 Nov 2020 01:25:00 GMT ms-cv: - - iEHHhD2Nj0K+KjWGc4PzPQ.0 + - ghjd+uaBPE+xWRWajPhGfw.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 48ms + - 268ms status: code: 200 message: OK @@ -236,26 +232,26 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1%2F1%2F1970%2012%3A00%3A00%20AM%20%2B00%3A00&maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1%2F1%2F1970%2012%3A00%3A00%20AM%20%2B00%3A00&maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized", "nextLink": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:06 GMT + - Thu, 26 Nov 2020 01:25:01 GMT ms-cv: - - mCx1vcc7xEmiUzPmcjt9gw.0 + - 2m12bXnZ/U++YwOOw50L4Q.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 51ms + - 365ms status: code: 200 message: OK @@ -269,26 +265,26 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1%2F1%2F1970%2012%3A00%3A00%20AM%20%2B00%3A00&maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1%2F1%2F1970%2012%3A00%3A00%20AM%20%2B00%3A00&maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized", "nextLink": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:06 GMT + - Thu, 26 Nov 2020 01:25:01 GMT ms-cv: - - COvNsOwGN0OZVAByhVVEXg.0 + - +DvJechO5UqgndvobbF2Xw.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 61ms + - 367ms status: code: 200 message: OK @@ -302,26 +298,26 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1%2F1%2F1970%2012%3A00%3A00%20AM%20%2B00%3A00&maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1%2F1%2F1970%2012%3A00%3A00%20AM%20%2B00%3A00&maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:07 GMT + - Thu, 26 Nov 2020 01:25:02 GMT ms-cv: - - /lkJGiDpN0yVAbE1H9PfWg.0 + - lIr4DY11dUmOWzkSHJ8mBA.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 58ms + - 366ms status: code: 200 message: OK @@ -337,27 +333,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:07 GMT + - Thu, 26 Nov 2020 01:25:02 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:49:07 GMT + - Thu, 26 Nov 2020 01:25:18 GMT ms-cv: - - gZNu21k/sEOdZCXTSDz/9Q.0 - strict-transport-security: - - max-age=2592000 + - rIgTwNjkGkeXkbNXZKnPXQ.0 x-processing-time: - - 832ms + - 16745ms status: code: 204 message: No Content @@ -373,27 +367,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:08 GMT + - Thu, 26 Nov 2020 01:25:19 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:49:08 GMT + - Thu, 26 Nov 2020 01:25:34 GMT ms-cv: - - ku8bbLn0n0WR6HKhZguTJw.0 - strict-transport-security: - - max-age=2592000 + - kgOJ7BrWGkW6e+weZb19Zw.0 x-processing-time: - - 643ms + - 16159ms status: code: 204 message: No Content @@ -409,23 +401,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:49:09 GMT + - Thu, 26 Nov 2020 01:25:35 GMT ms-cv: - - de3ZyVjBu0um2HbLJ/f4XA.0 + - AqDCHeUbjkycBwqCunGccA.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 59ms + - 284ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_participants.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_participants.yaml new file mode 100644 index 000000000000..85a09145bc68 --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_participants.yaml @@ -0,0 +1,287 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:25:35 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:25:36 GMT + ms-cv: + - hX/F05n4+UKEOjz3NIZWRQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 179ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:25:36 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:25:35.7750135+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:25:36 GMT + ms-cv: + - WQ0fCTY9wEaEnGxgj2ontQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 299ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:25:36 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:25:36 GMT + ms-cv: + - DcATocgmY02K03bo5XfKLQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 144ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '205' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:25:37Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a209-8417-b274-5a3a0d000123", + "participants": "sanitized"}' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:25:37 GMT + ms-cv: + - jrosRGQh3ECXqftkXzAp9Q.0 + strict-transport-security: + - max-age=2592000 + transfer-encoding: + - chunked + x-processing-time: + - 815ms + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: GET + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 + response: + body: '{"value": "sanitized"}' + headers: + api-supported-versions: + - 2020-11-01-preview3 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:25:40 GMT + ms-cv: + - laV96dm1/E6ElZcKmLUUaA.0 + strict-transport-security: + - max-age=2592000 + transfer-encoding: + - chunked + x-processing-time: + - 744ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:25:41 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:25:56 GMT + ms-cv: + - 8U13ljcOEUuE4HMKo2PdsA.0 + x-processing-time: + - 16007ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:25:57 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:26:12 GMT + ms-cv: + - yLDPZxhkcEWJb7m8HoJCdg.0 + x-processing-time: + - 16445ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + date: + - Thu, 26 Nov 2020 01:26:13 GMT + ms-cv: + - UZR2pU4w+UmssQdbohylhw.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 289ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_read_receipts.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_read_receipts.yaml index 557afc3dc756..d8285c7a3c99 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_read_receipts.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_list_read_receipts.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:09 GMT + - Thu, 26 Nov 2020 01:26:14 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:09 GMT + - Thu, 26 Nov 2020 01:26:13 GMT ms-cv: - - QW5+EPDi4kuDBJENEGaeWQ.0 - strict-transport-security: - - max-age=2592000 + - A/P9P9V6pEadsXcfwqqklg.0 transfer-encoding: - chunked x-processing-time: - - 202ms + - 146ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:49:10 GMT + - Thu, 26 Nov 2020 01:26:14 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:49:09.6442672+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:26:14.0829614+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:09 GMT + - Thu, 26 Nov 2020 01:26:14 GMT ms-cv: - - rkd2UN8Tmk2I24ASaFwM3g.0 - strict-transport-security: - - max-age=2592000 + - JM8r6v+YY0ejA6y0LsKhBw.0 transfer-encoding: - chunked x-processing-time: - - 272ms + - 303ms status: code: 200 message: OK @@ -91,35 +87,33 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:10 GMT + - Thu, 26 Nov 2020 01:26:15 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:09 GMT + - Thu, 26 Nov 2020 01:26:14 GMT ms-cv: - - nlcIPGPSxEeW1i6uwYRF2Q.0 - strict-transport-security: - - max-age=2592000 + - 94Efc2Yx6E2gDj+3CbbMAQ.0 transfer-encoding: - chunked x-processing-time: - - 197ms + - 146ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -128,33 +122,35 @@ interactions: Connection: - keep-alive Content-Length: - - '200' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:26:15Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20a-19b6-b274-5a3a0d000125", + "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:11 GMT + - Thu, 26 Nov 2020 01:26:16 GMT ms-cv: - - bCITJJz1x0ur2lJr6xWOtA.0 + - OIYYMsHJjUaD5nZhLq7jDQ.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 189ms + - 821ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -170,26 +166,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:11 GMT + - Thu, 26 Nov 2020 01:26:17 GMT ms-cv: - - H0JLEz8XM0+3KGw5Qk/sBA.0 + - 5pQbwxxB10KHVAyeTNnSjw.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 77ms + - 693ms status: code: 201 message: Created @@ -207,25 +203,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-length: - '0' date: - - Thu, 01 Oct 2020 22:49:12 GMT + - Thu, 26 Nov 2020 01:26:17 GMT ms-cv: - - JowfBSb2ykysq77Lz+vljw.0 + - JJEHa6GlDECwkZQHkOcX3w.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 43ms + - 668ms status: code: 201 message: Created @@ -239,26 +235,26 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 response: body: '{"value": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:14 GMT + - Thu, 26 Nov 2020 01:26:20 GMT ms-cv: - - vus31CqeikaLUeLq6t7W4A.0 + - HFpdZBGKkkS9+HQJ9I4/rQ.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 29ms + - 249ms status: code: 200 message: OK @@ -274,27 +270,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:14 GMT + - Thu, 26 Nov 2020 01:26:20 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:49:15 GMT + - Thu, 26 Nov 2020 01:26:36 GMT ms-cv: - - UUFuuAVChUqQpCoTk6aC+w.0 - strict-transport-security: - - max-age=2592000 + - wQvnxAp9GEScZluSWlPcKw.0 x-processing-time: - - 1277ms + - 16099ms status: code: 204 message: No Content @@ -310,27 +304,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:15 GMT + - Thu, 26 Nov 2020 01:26:36 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:49:16 GMT + - Thu, 26 Nov 2020 01:26:52 GMT ms-cv: - - DSB4fsJ5EkuqRYSCFGtnyg.0 - strict-transport-security: - - max-age=2592000 + - aIlRF5bFVU+K+7v3C9gN0g.0 x-processing-time: - - 601ms + - 16458ms status: code: 204 message: No Content @@ -346,23 +338,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:49:16 GMT + - Thu, 26 Nov 2020 01:26:53 GMT ms-cv: - - K5WSAsuL4UOBINl3WiLxDg.0 + - xZvcQIwoLky0fFKFlkK/9A.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 57ms + - 283ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_remove_participant.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_remove_participant.yaml new file mode 100644 index 000000000000..4e79d000bcdd --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_remove_participant.yaml @@ -0,0 +1,322 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:26:53 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:26:53 GMT + ms-cv: + - L3MwZ02q+0KXjA6cPkf3zg.0 + transfer-encoding: + - chunked + x-processing-time: + - 175ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:26:54 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:26:53.8507271+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:26:54 GMT + ms-cv: + - pQgqab8VE0SZ4Oq9dgY3mg.0 + transfer-encoding: + - chunked + x-processing-time: + - 783ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:26:54 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:26:54 GMT + ms-cv: + - iFqkvLMJxUOQ2LGuHmiWpA.0 + transfer-encoding: + - chunked + x-processing-time: + - 153ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:26:55Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20a-b333-557d-5a3a0d0000e1", + "participants": "sanitized"}' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:26:56 GMT + ms-cv: + - 9/n37bfN1k+b5pcZuR6b2Q.0 + strict-transport-security: + - max-age=2592000 + transfer-encoding: + - chunked + x-processing-time: + - 1340ms + status: + code: 201 + message: Created +- request: + body: '{"participants": "sanitized"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '183' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-11-01-preview3 + content-length: + - '0' + date: + - Thu, 26 Nov 2020 01:26:57 GMT + ms-cv: + - uruLT70rVkaontGqh4BaNA.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 833ms + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants/8%3Aacs%3A9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20a-b745-557d-5a3a0d0000e2?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-11-01-preview3 + date: + - Thu, 26 Nov 2020 01:26:57 GMT + ms-cv: + - fTookN+trEy/B7qvkvcVqQ.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 427ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:26:58 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:27:13 GMT + ms-cv: + - x6apGyPKZ0a6QRVVbsMSaQ.0 + x-processing-time: + - 16005ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:27:14 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:27:30 GMT + ms-cv: + - GF97YOCr+UmWjcc9UlpHsg.0 + x-processing-time: + - 16723ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + date: + - Thu, 26 Nov 2020 01:27:31 GMT + ms-cv: + - sMR50s3i+ECIkM0o2e2DzA.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 290ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_message.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_message.yaml index 0850c9d0fb0c..4b5a12db0945 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_message.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_message.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:56 GMT + - Thu, 26 Nov 2020 01:27:31 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:56 GMT + - Thu, 26 Nov 2020 01:27:30 GMT ms-cv: - - GMVOn586ckCmNFeWshbP/Q.0 - strict-transport-security: - - max-age=2592000 + - Rc3uv0zfaUWJiXIDROynSA.0 transfer-encoding: - chunked x-processing-time: - - 199ms + - 145ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:49:57 GMT + - Thu, 26 Nov 2020 01:27:31 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:49:56.8632234+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:27:31.4138168+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:57 GMT + - Thu, 26 Nov 2020 01:27:31 GMT ms-cv: - - tnBunc2ZEUeO+78I0/wm5g.0 - strict-transport-security: - - max-age=2592000 + - wng3+OJem0CbKMTETRRu0A.0 transfer-encoding: - chunked x-processing-time: - - 273ms + - 299ms status: code: 200 message: OK @@ -91,35 +87,33 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:57 GMT + - Thu, 26 Nov 2020 01:27:32 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:57 GMT + - Thu, 26 Nov 2020 01:27:31 GMT ms-cv: - - UauaJy88IkKtPRfrgEtheg.0 - strict-transport-security: - - max-age=2592000 + - QZ1WDUG7r0mOH0YPnCeFgw.0 transfer-encoding: - chunked x-processing-time: - - 201ms + - 147ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -128,33 +122,35 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:27:33Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20b-46e6-557d-5a3a0d0000e3", + "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:58 GMT + - Thu, 26 Nov 2020 01:27:32 GMT ms-cv: - - Y5gJZriTyE6uKIhoAuE6eA.0 + - iUhieEkBXUCaR8EQ3kIC0w.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 373ms + - 831ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -170,26 +166,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:49:58 GMT + - Thu, 26 Nov 2020 01:27:33 GMT ms-cv: - - 4rvkImjvUEyFLHmTbgKacQ.0 + - X6/bdVsrgkSbcCR6yMDmyQ.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 67ms + - 651ms status: code: 201 message: Created @@ -205,27 +201,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:49:59 GMT + - Thu, 26 Nov 2020 01:27:34 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:49:59 GMT + - Thu, 26 Nov 2020 01:27:50 GMT ms-cv: - - uShxY/ox1Ui1ZK71kxCQgQ.0 - strict-transport-security: - - max-age=2592000 + - CEA1vnH3kkygOS1DiF3fDg.0 x-processing-time: - - 662ms + - 16279ms status: code: 204 message: No Content @@ -241,27 +235,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:00 GMT + - Thu, 26 Nov 2020 01:27:50 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:00 GMT + - Thu, 26 Nov 2020 01:28:06 GMT ms-cv: - - mQ/pQO5ay06GTJOmk/vunQ.0 - strict-transport-security: - - max-age=2592000 + - omYum9GtMUeTXF/MKSMo7w.0 x-processing-time: - - 459ms + - 16274ms status: code: 204 message: No Content @@ -277,23 +269,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:50:00 GMT + - Thu, 26 Nov 2020 01:28:06 GMT ms-cv: - - k9EuA5eQeUm3U+MBFAFqNw.0 + - JHijcUlRjUqewdrOZI3dvg.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 70ms + - 289ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_read_receipt.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_read_receipt.yaml index 8ce715454af3..97371cd4df48 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_read_receipt.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_read_receipt.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:01 GMT + - Thu, 26 Nov 2020 01:28:07 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:01 GMT + - Thu, 26 Nov 2020 01:28:07 GMT ms-cv: - - 2NL+sWgV00eHrxyL1QonUw.0 - strict-transport-security: - - max-age=2592000 + - mjHNjmWZI0m8Zn033cNYjA.0 transfer-encoding: - chunked x-processing-time: - - 205ms + - 203ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:50:02 GMT + - Thu, 26 Nov 2020 01:28:07 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:50:01.3598198+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:28:07.2996862+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:02 GMT + - Thu, 26 Nov 2020 01:28:08 GMT ms-cv: - - V70jxqqZ80aqpUvTvj6+1g.0 - strict-transport-security: - - max-age=2592000 + - /vvMGot9YEC1Np0vMVWEog.0 transfer-encoding: - chunked x-processing-time: - - 276ms + - 300ms status: code: 200 message: OK @@ -91,35 +87,33 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:02 GMT + - Thu, 26 Nov 2020 01:28:08 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:02 GMT + - Thu, 26 Nov 2020 01:28:08 GMT ms-cv: - - wMGSEqIS1ke1TUc/T1DE/w.0 - strict-transport-security: - - max-age=2592000 + - yOgWL6LNX0OHrHfvzcK7Xw.0 transfer-encoding: - chunked x-processing-time: - - 204ms + - 147ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -128,33 +122,35 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:28:09Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20b-d3fc-b274-5a3a0d000127", + "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:02 GMT + - Thu, 26 Nov 2020 01:28:09 GMT ms-cv: - - o/EBnanYV0qRliUZvt/mWw.0 + - OuXAccdOwUSuSG8/oat08w.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 297ms + - 850ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -170,26 +166,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:03 GMT + - Thu, 26 Nov 2020 01:28:10 GMT ms-cv: - - 5vGw1XBHc06aZsmcRTkmYg.0 + - IgSr4GCdoUO1r+XB6M4kcw.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 65ms + - 703ms status: code: 201 message: Created @@ -207,25 +203,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-length: - '0' date: - - Thu, 01 Oct 2020 22:50:04 GMT + - Thu, 26 Nov 2020 01:28:11 GMT ms-cv: - - y+4Q3revMkSksBXJjWFe7w.0 + - LthArghR3Eq/5+icvinOrg.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 42ms + - 607ms status: code: 201 message: Created @@ -241,27 +237,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:04 GMT + - Thu, 26 Nov 2020 01:28:11 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:04 GMT + - Thu, 26 Nov 2020 01:28:27 GMT ms-cv: - - cGFxifVgfk+eS1Ku04w2dQ.0 - strict-transport-security: - - max-age=2592000 + - SgCET7UrQ0SmsaWXZcD5Eg.0 x-processing-time: - - 705ms + - 16493ms status: code: 204 message: No Content @@ -277,27 +271,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:05 GMT + - Thu, 26 Nov 2020 01:28:27 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:05 GMT + - Thu, 26 Nov 2020 01:28:44 GMT ms-cv: - - USWh214NHkmms6sECX7qmg.0 - strict-transport-security: - - max-age=2592000 + - sjICsoC46kG23f8Uv5GKuw.0 x-processing-time: - - 640ms + - 16165ms status: code: 204 message: No Content @@ -313,23 +305,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:50:05 GMT + - Thu, 26 Nov 2020 01:28:43 GMT ms-cv: - - PwYvezTmckK0e0xqC8SilA.0 + - Hj7nFy28eUO/48W0q3cS5A.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 53ms + - 294ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_typing_notification.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_typing_notification.yaml index 459c8140623f..c8468d5cca21 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_typing_notification.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_send_typing_notification.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:06 GMT + - Thu, 26 Nov 2020 01:28:44 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:06 GMT + - Thu, 26 Nov 2020 01:28:43 GMT ms-cv: - - VmM8wDvzrkiHIHNE0XbzaQ.0 - strict-transport-security: - - max-age=2592000 + - hlqRfaPk0keeVSgIRnHbdQ.0 transfer-encoding: - chunked x-processing-time: - - 200ms + - 149ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:50:06 GMT + - Thu, 26 Nov 2020 01:28:44 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:50:06.0334401+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:28:44.3074943+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:06 GMT + - Thu, 26 Nov 2020 01:28:44 GMT ms-cv: - - s8+qa7zvMUC/6Gy6a2lFqA.0 - strict-transport-security: - - max-age=2592000 + - 66khv998k06Heglol7uOJw.0 transfer-encoding: - chunked x-processing-time: - - 275ms + - 305ms status: code: 200 message: OK @@ -91,35 +87,33 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:07 GMT + - Thu, 26 Nov 2020 01:28:45 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:07 GMT + - Thu, 26 Nov 2020 01:28:44 GMT ms-cv: - - 506Tzg4W+EmIdZKp4AP6MA.0 - strict-transport-security: - - max-age=2592000 + - ax7WKHTpUkOWXXVtzKq6yw.0 transfer-encoding: - chunked x-processing-time: - - 207ms + - 145ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -128,33 +122,35 @@ interactions: Connection: - keep-alive Content-Length: - - '201' + - '205' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:28:46Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20c-6482-557d-5a3a0d0000e5", + "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:07 GMT + - Thu, 26 Nov 2020 01:28:46 GMT ms-cv: - - Evz/tIUBqEOOn9c4Gnz6bg.0 + - 0xalPEIS4keKeCFWJpN9iQ.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 225ms + - 854ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: null headers: @@ -167,25 +163,25 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/typing?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/typing?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-length: - '0' date: - - Thu, 01 Oct 2020 22:50:08 GMT + - Thu, 26 Nov 2020 01:28:47 GMT ms-cv: - - zs31jIqMLEaOPdZMlRbQyQ.0 + - bQdJB63V5kemmf3CVQNUeA.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 65ms + - 809ms status: code: 200 message: OK @@ -201,27 +197,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:08 GMT + - Thu, 26 Nov 2020 01:28:47 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:09 GMT + - Thu, 26 Nov 2020 01:29:03 GMT ms-cv: - - E20ATDs6Uk6wKtSoNHNfug.0 - strict-transport-security: - - max-age=2592000 + - M4UEQmh3vk2culX9BlK3Tw.0 x-processing-time: - - 742ms + - 15919ms status: code: 204 message: No Content @@ -237,27 +231,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:09 GMT + - Thu, 26 Nov 2020 01:29:03 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:09 GMT + - Thu, 26 Nov 2020 01:29:19 GMT ms-cv: - - KbIsxuu9LUOUo7o1uQLZ7g.0 - strict-transport-security: - - max-age=2592000 + - 0M7+dJE7n0Ghg4ZhjVGCbQ.0 x-processing-time: - - 620ms + - 16290ms status: code: 204 message: No Content @@ -273,23 +265,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:50:10 GMT + - Thu, 26 Nov 2020 01:29:20 GMT ms-cv: - - 2GTWx80uIkqOBcAVkCc0gg.0 + - IHF2oEx7AEa98F8J92fLew.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 59ms + - 292ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_update_message.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_update_message.yaml index 6698f9ec29df..becc48e7400a 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_update_message.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_update_message.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:10 GMT + - Thu, 26 Nov 2020 01:29:20 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:10 GMT + - Thu, 26 Nov 2020 01:29:20 GMT ms-cv: - - HNojnIgb10WFDBGUh75Bbw.0 - strict-transport-security: - - max-age=2592000 + - cJB+MDpBBEqZAq3HqXkWqw.0 transfer-encoding: - chunked x-processing-time: - - 206ms + - 143ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:50:10 GMT + - Thu, 26 Nov 2020 01:29:21 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:50:10.3383697+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:29:20.9376251+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:11 GMT + - Thu, 26 Nov 2020 01:29:21 GMT ms-cv: - - /UT11m+/R06gfuTSBS5iqg.0 - strict-transport-security: - - max-age=2592000 + - +mUydaYWw0y1XyjahACEZw.0 transfer-encoding: - chunked x-processing-time: - - 277ms + - 792ms status: code: 200 message: OK @@ -91,35 +87,33 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:11 GMT + - Thu, 26 Nov 2020 01:29:21 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:11 GMT + - Thu, 26 Nov 2020 01:29:21 GMT ms-cv: - - hggVevMOQ0CPKSL12BbMvw.0 - strict-transport-security: - - max-age=2592000 + - Q+fRrF2xWkaRDCOZrCcTBg.0 transfer-encoding: - chunked x-processing-time: - - 204ms + - 147ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json @@ -128,33 +122,35 @@ interactions: Connection: - keep-alive Content-Length: - - '199' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:29:22Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20c-f1be-d67a-5a3a0d0001bc", + "participants": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:12 GMT + - Thu, 26 Nov 2020 01:29:22 GMT ms-cv: - - XuEqBLJ60Ea3CTknvIE97A.0 + - SVmLwbq/t06tiNSYhFTquA.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 454ms + - 861ms status: - code: 207 - message: Multi-Status + code: 201 + message: Created - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -170,26 +166,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:12 GMT + - Thu, 26 Nov 2020 01:29:23 GMT ms-cv: - - IWzlGZPNaEmsvsfwnu98pA.0 + - PcQGvGfEt0e7eu8HLPFAfg.0 strict-transport-security: - max-age=2592000 transfer-encoding: - chunked x-processing-time: - - 75ms + - 696ms status: code: 201 message: Created @@ -205,30 +201,28 @@ interactions: Content-Length: - '38' Content-Type: - - application/json + - application/merge-patch+json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: PATCH - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 - content-length: - - '0' + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:50:13 GMT + - Thu, 26 Nov 2020 01:29:24 GMT ms-cv: - - zN6AHjwvR0mgNBn1L6kDaQ.0 + - 3czilnpjLU+ZoZMuPsezYQ.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 94ms + - 647ms status: - code: 200 - message: OK + code: 204 + message: No Content - request: body: null headers: @@ -241,27 +235,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:13 GMT + - Thu, 26 Nov 2020 01:29:24 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:13 GMT + - Thu, 26 Nov 2020 01:29:40 GMT ms-cv: - - kHFbkRZRH0ukIPa6WdDurA.0 - strict-transport-security: - - max-age=2592000 + - gDTG9Rs5fkqnFqivKAR8oA.0 x-processing-time: - - 676ms + - 15864ms status: code: 204 message: No Content @@ -277,27 +269,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:14 GMT + - Thu, 26 Nov 2020 01:29:40 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:14 GMT + - Thu, 26 Nov 2020 01:29:57 GMT ms-cv: - - mDz38y4RQUGGEXWo2yCH/w.0 - strict-transport-security: - - max-age=2592000 + - r2U9G8TXE0qpYn1Mg/lf5Q.0 x-processing-time: - - 544ms + - 16769ms status: code: 204 message: No Content @@ -313,23 +303,23 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: api-supported-versions: - - 2020-09-21-preview2 + - 2020-09-21-preview2, 2020-11-01-preview3 date: - - Thu, 01 Oct 2020 22:50:14 GMT + - Thu, 26 Nov 2020 01:29:57 GMT ms-cv: - - EsOpCrfm6kePCxpuNH7UIQ.0 + - KMY6wxR01keuFPGjUL0M4A.0 strict-transport-security: - max-age=2592000 x-processing-time: - - 86ms + - 342ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_update_topic.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_update_topic.yaml new file mode 100644 index 000000000000..efd13585da1c --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e.test_update_topic.yaml @@ -0,0 +1,288 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:29:58 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:29:57 GMT + ms-cv: + - 6FvWkQjgmEaa8e3sfjfU0A.0 + transfer-encoding: + - chunked + x-processing-time: + - 147ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:29:58 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:29:58.0124434+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:29:58 GMT + ms-cv: + - O+wr+Q5eh06Gxc5SCmIotw.0 + transfer-encoding: + - chunked + x-processing-time: + - 303ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:29:59 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:29:58 GMT + ms-cv: + - PSLziG1+B0GFeJ+0dkzvKQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 145ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:29:59Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20d-8471-d67a-5a3a0d0001c0", + "participants": "sanitized"}' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:29:59 GMT + ms-cv: + - LGKB+K2LOU2iJwjukuvcXg.0 + strict-transport-security: + - max-age=2592000 + transfer-encoding: + - chunked + x-processing-time: + - 1116ms + status: + code: 201 + message: Created +- request: + body: '{"topic": "update topic"}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '25' + Content-Type: + - application/merge-patch+json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: PATCH + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + date: + - Thu, 26 Nov 2020 01:30:01 GMT + ms-cv: + - 7BSP98ULYk2qUVjneKqs8A.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 386ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:30:01 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:30:17 GMT + ms-cv: + - OcPauDoyr0CcNDEVhh4kUw.0 + x-processing-time: + - 16699ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:30:17 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:30:33 GMT + ms-cv: + - fYvM12YEbUW0FgYUBTdv1Q.0 + x-processing-time: + - 16018ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-09-21-preview2, 2020-11-01-preview3 + date: + - Thu, 26 Nov 2020 01:30:34 GMT + ms-cv: + - TyNx8N9ZwUyIwcq97aPzvA.0 + strict-transport-security: + - max-age=2592000 + x-processing-time: + - 294ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_add_participant.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_add_participant.yaml new file mode 100644 index 000000000000..d76db2ff4760 --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_add_participant.yaml @@ -0,0 +1,261 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:30:34 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:30:34 GMT + ms-cv: + - cvnmKZiNuk6BFwK9Nz8r8g.0 + transfer-encoding: + - chunked + x-processing-time: + - 190ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:30:35 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:30:34.8754582+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:30:34 GMT + ms-cv: + - daiJmDCJH0ebe0tSPhzXKA.0 + transfer-encoding: + - chunked + x-processing-time: + - 757ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:30:35 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:30:36 GMT + ms-cv: + - 0b0GEzY/1ES9yhEGsKYVnQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 148ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:30:36Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20e-12ae-b274-5a3a0d000129", + "participants": "sanitized"}' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + content-type: application/json; charset=utf-8 + date: Thu, 26 Nov 2020 01:30:36 GMT + ms-cv: 8RAmsd5Z00eynKICNh6htQ.0 + strict-transport-security: max-age=2592000 + transfer-encoding: chunked + x-processing-time: 819ms + status: + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 +- request: + body: '{"participants": "sanitized"}' + headers: + Accept: + - application/json + Content-Length: + - '183' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-11-01-preview3 + content-length: '0' + date: Thu, 26 Nov 2020 01:30:37 GMT + ms-cv: xR3KT//8d0WtEd8OEVKNtw.0 + strict-transport-security: max-age=2592000 + x-processing-time: 860ms + status: + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:30:38 GMT + ms-cv: 4IfY5xcLfEimFoVjDa56GQ.0 + strict-transport-security: max-age=2592000 + x-processing-time: 304ms + status: + code: 204 + message: No Content + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:30:38 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:30:54 GMT + ms-cv: + - an+Y7NjiwEGHg1hciwZutA.0 + x-processing-time: + - 16189ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:30:54 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:31:10 GMT + ms-cv: + - QQOQ33KEJ0igmUuz/Ru1nA.0 + x-processing-time: + - 16730ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_add_participants.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_add_participants.yaml new file mode 100644 index 000000000000..e5ea7794f4e1 --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_add_participants.yaml @@ -0,0 +1,261 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:31:11 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:31:11 GMT + ms-cv: + - siyNuR1A8Uab0RkHyAlqcQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 198ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:31:12 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:31:11.5151238+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:31:11 GMT + ms-cv: + - GjXwMs1P+U+a0SDP9bffsw.0 + transfer-encoding: + - chunked + x-processing-time: + - 310ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:31:12 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:31:11 GMT + ms-cv: + - p94jcl5bHECnSv4hq3L0RA.0 + transfer-encoding: + - chunked + x-processing-time: + - 145ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:31:13Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20e-a386-d67a-5a3a0d0001c2", + "participants": "sanitized"}' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + content-type: application/json; charset=utf-8 + date: Thu, 26 Nov 2020 01:31:13 GMT + ms-cv: diW0SYWc90WNmugc28HlFQ.0 + strict-transport-security: max-age=2592000 + transfer-encoding: chunked + x-processing-time: 828ms + status: + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 +- request: + body: '{"participants": "sanitized"}' + headers: + Accept: + - application/json + Content-Length: + - '183' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-11-01-preview3 + content-length: '0' + date: Thu, 26 Nov 2020 01:31:14 GMT + ms-cv: Ce6UfXXIukG9puEZuIugrQ.0 + strict-transport-security: max-age=2592000 + x-processing-time: 398ms + status: + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:31:14 GMT + ms-cv: TDBjboMDyEyEdtD+D/peDw.0 + strict-transport-security: max-age=2592000 + x-processing-time: 340ms + status: + code: 204 + message: No Content + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:31:14 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:31:30 GMT + ms-cv: + - 6lyL+ObKy021r/HPY7P2Jg.0 + x-processing-time: + - 16332ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:31:31 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:31:47 GMT + ms-cv: + - ZxtyVQPb8UWOGIEDTW3VHg.0 + x-processing-time: + - 16620ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_delete_message.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_delete_message.yaml index fb116bc6eb77..67ac37685204 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_delete_message.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_delete_message.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:23 GMT + - Thu, 26 Nov 2020 01:31:47 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:23 GMT + - Thu, 26 Nov 2020 01:31:48 GMT ms-cv: - - v3TMDj1D0Um09fxCXw+1Sw.0 - strict-transport-security: - - max-age=2592000 + - E0kfk2LnzEmIwwqQFf1SAw.0 transfer-encoding: - chunked x-processing-time: - - 205ms + - 315ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:50:24 GMT + - Thu, 26 Nov 2020 01:31:48 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:50:23.7114719+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:31:47.8855465+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:24 GMT + - Thu, 26 Nov 2020 01:31:48 GMT ms-cv: - - KnAreO90k0iyjLoJNS6ISQ.0 - strict-transport-security: - - max-age=2592000 + - fPlQdobqJE+2Ghq/o7C3jw.0 transfer-encoding: - chunked x-processing-time: - - 280ms + - 389ms status: code: 200 message: OK @@ -91,60 +87,60 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:24 GMT + - Thu, 26 Nov 2020 01:31:48 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:24 GMT + - Thu, 26 Nov 2020 01:31:48 GMT ms-cv: - - Ej2eNO22FEuni3lZ6uY1gg.0 - strict-transport-security: - - max-age=2592000 + - Is5VPhK6MUGiOavucGXV1w.0 transfer-encoding: - chunked x-processing-time: - - 203ms + - 145ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:31:49Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20f-3156-ea7c-5a3a0d000126", + "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:25 GMT - ms-cv: 9atEWqszcUmYGFTT6JtHgw.0 + date: Thu, 26 Nov 2020 01:31:49 GMT + ms-cv: 4EQ2dApNHE+7E/Y0/KnG8w.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 223ms + x-processing-time: 1313ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -156,67 +152,67 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:25 GMT - ms-cv: L7LSiiDNpUe3+4Ldq3sYmw.0 + date: Thu, 26 Nov 2020 01:31:51 GMT + ms-cv: Azyo2mbep0G21oRxK4H5Eg.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 63ms + x-processing-time: 1021ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:50:25 GMT - ms-cv: AbkyGCr+YECMVhiQHwb+sA.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:31:52 GMT + ms-cv: BKUM4J/qlkylC4La7rM3xQ.0 strict-transport-security: max-age=2592000 - x-processing-time: 79ms + x-processing-time: 398ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:50:25 GMT - ms-cv: wR1vYfm950edBonlVmLdVg.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:31:51 GMT + ms-cv: 8mhKaV9jr0ykGTyFuMcQPw.0 strict-transport-security: max-age=2592000 - x-processing-time: 55ms + x-processing-time: 291ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -229,27 +225,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:26 GMT + - Thu, 26 Nov 2020 01:31:52 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:27 GMT + - Thu, 26 Nov 2020 01:32:10 GMT ms-cv: - - JrjN4h+WPk+/fZBncoYzGw.0 - strict-transport-security: - - max-age=2592000 + - Fv9AOsu5i0mkgl/fDO83aA.0 x-processing-time: - - 1302ms + - 18263ms status: code: 204 message: No Content @@ -265,27 +259,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:27 GMT + - Thu, 26 Nov 2020 01:32:11 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:27 GMT + - Thu, 26 Nov 2020 01:32:27 GMT ms-cv: - - T6XAfdJ0H0eRzvlp3+xixQ.0 - strict-transport-security: - - max-age=2592000 + - fHBIc+asxEOQh4qvvrLraA.0 x-processing-time: - - 446ms + - 16723ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_get_message.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_get_message.yaml index 41b752c586f2..f77315b416c7 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_get_message.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_get_message.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:28 GMT + - Thu, 26 Nov 2020 01:32:27 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:28 GMT + - Thu, 26 Nov 2020 01:32:27 GMT ms-cv: - - 9+nA7UhyOU6jee3+JvpISw.0 - strict-transport-security: - - max-age=2592000 + - KkFL319PQUuyl3g0vdL2UA.0 transfer-encoding: - chunked x-processing-time: - - 202ms + - 137ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:50:28 GMT + - Thu, 26 Nov 2020 01:32:28 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:50:28.3048923+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:32:27.8098648+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:28 GMT + - Thu, 26 Nov 2020 01:32:28 GMT ms-cv: - - uh9E2zGsXE+DgklDWrDxFA.0 - strict-transport-security: - - max-age=2592000 + - JGeP7DAilUSbxjr9giGQRg.0 transfer-encoding: - chunked x-processing-time: - - 273ms + - 300ms status: code: 200 message: OK @@ -91,60 +87,60 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:29 GMT + - Thu, 26 Nov 2020 01:32:28 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:28 GMT + - Thu, 26 Nov 2020 01:32:28 GMT ms-cv: - - /FcSAxa8NkSxwwBoYT4kKw.0 - strict-transport-security: - - max-age=2592000 + - 2n803HlffkKEUMXpkzoHTA.0 transfer-encoding: - chunked x-processing-time: - - 199ms + - 145ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:32:29Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a20f-cd91-8a72-5a3a0d0000de", + "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:29 GMT - ms-cv: tqdNTCJBMkOxGAfLMEdk3g.0 + date: Thu, 26 Nov 2020 01:32:30 GMT + ms-cv: rHpGfRDitUSORdbQjV5NtQ.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 190ms + x-processing-time: 830ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -156,70 +152,70 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:30 GMT - ms-cv: SbS5W6lgNUebZZB7rBQ5HQ.0 + date: Thu, 26 Nov 2020 01:32:30 GMT + ms-cv: 5EL9YGpEKkCqTGgN46+mxA.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 70ms + x-processing-time: 747ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 response: - body: '{"id": "sanitized", "type": "Text", "priority": "Normal", "version": "1601592630391", - "content": "hello world", "senderDisplayName": "sender name", "createdOn": "2020-10-01T22:50:30Z", + body: '{"id": "sanitized", "type": "Text", "priority": "Normal", "version": "1606354350532", + "content": "hello world", "senderDisplayName": "sender name", "createdOn": "2020-11-26T01:32:30Z", "senderId": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:30 GMT - ms-cv: 4VlZeh9HkUaid3lVErpD1g.0 + date: Thu, 26 Nov 2020 01:32:31 GMT + ms-cv: Cd8GfPYrEEOqHZIOSv5tKg.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 32ms + x-processing-time: 287ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:50:30 GMT - ms-cv: EGm8pZ5rE0COvgq+PqOQYQ.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:32:31 GMT + ms-cv: WwLvD7e6YUSygUuast1GHQ.0 strict-transport-security: max-age=2592000 - x-processing-time: 54ms + x-processing-time: 285ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -232,27 +228,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:30 GMT + - Thu, 26 Nov 2020 01:32:31 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:30 GMT + - Thu, 26 Nov 2020 01:32:48 GMT ms-cv: - - QnU6Q7f2wUizMuUlvagulA.0 - strict-transport-security: - - max-age=2592000 + - T2GYRZ5aDk+fs+K10t/JlA.0 x-processing-time: - - 746ms + - 16657ms status: code: 204 message: No Content @@ -268,27 +262,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:31 GMT + - Thu, 26 Nov 2020 01:32:48 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:31 GMT + - Thu, 26 Nov 2020 01:33:04 GMT ms-cv: - - obgUaNfQ30WqUEogYLlnLA.0 - strict-transport-security: - - max-age=2592000 + - tTyzwTrLxkOKEVqtIdrLSg.0 x-processing-time: - - 534ms + - 16505ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_messages.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_messages.yaml index a6727328e6ac..1291eb9c0339 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_messages.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_messages.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:36 GMT + - Thu, 26 Nov 2020 01:33:05 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:36 GMT + - Thu, 26 Nov 2020 01:33:04 GMT ms-cv: - - sUl1Xag2w0i2dvBDVcHatg.0 - strict-transport-security: - - max-age=2592000 + - SzMURT8+80Cs/aGlxMbIxA.0 transfer-encoding: - chunked x-processing-time: - - 199ms + - 147ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:50:37 GMT + - Thu, 26 Nov 2020 01:33:05 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:50:36.4024084+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:33:04.8467433+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:36 GMT + - Thu, 26 Nov 2020 01:33:04 GMT ms-cv: - - 4Da0dlsQxkWXhTkkXcr1Rg.0 - strict-transport-security: - - max-age=2592000 + - nd4GBu+14UyPRR4cjpycrA.0 transfer-encoding: - chunked x-processing-time: - - 274ms + - 342ms status: code: 200 message: OK @@ -91,60 +87,60 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:37 GMT + - Thu, 26 Nov 2020 01:33:05 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:37 GMT + - Thu, 26 Nov 2020 01:33:05 GMT ms-cv: - - a2rfvZ9VoU6x3DtJ3j7SbQ.0 - strict-transport-security: - - max-age=2592000 + - L2l2f0QRbk+/WoGUDSce7g.0 transfer-encoding: - chunked x-processing-time: - - 200ms + - 146ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '200' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:33:06Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a210-5e28-d67a-5a3a0d0001c6", + "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:37 GMT - ms-cv: yEgkVNGOc0WLOsr8CEnn+A.0 + date: Thu, 26 Nov 2020 01:33:06 GMT + ms-cv: S24MhqU7U0asqkuzdWPndQ.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 210ms + x-processing-time: 838ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -156,137 +152,137 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:38 GMT - ms-cv: tIDnrWUM6kCtvhgn+50A1A.0 + date: Thu, 26 Nov 2020 01:33:07 GMT + ms-cv: bDGQj7B5A0uLjthqKV2/2Q.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 93ms + x-processing-time: 729ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized", "nextLink": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:40 GMT - ms-cv: kDUMkfOW+02xZQod07iqfg.0 + date: Thu, 26 Nov 2020 01:33:09 GMT + ms-cv: rlEto5Ze7kGF4N9aex4EEw.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 48ms + x-processing-time: 268ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?maxPageSize=1&api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?maxPageSize=1&api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized", "nextLink": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:40 GMT - ms-cv: zlhRW1IIS0SyEG5ZDRycpg.0 + date: Thu, 26 Nov 2020 01:33:10 GMT + ms-cv: S5yCOK+gXUm3nyjyKn1s1g.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 49ms + x-processing-time: 357ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized", "nextLink": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:40 GMT - ms-cv: Zw3ivc0Wx0OzUXIVGslbLQ.0 + date: Thu, 26 Nov 2020 01:33:10 GMT + ms-cv: ICHqAILSYkCDIPoEMP6L5A.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 74ms + x-processing-time: 368ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-11-01-preview3 response: body: '{"value": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:40 GMT - ms-cv: qxpFNRaMVkiwuo1BYXKtJg.0 + date: Thu, 26 Nov 2020 01:33:10 GMT + ms-cv: /zr2u9jn902Xwm4a62xszA.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 45ms + x-processing-time: 357ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?syncState=sanitized&startTime=1/1/1970%2012:00:00%20AM%20%2B00:00&maxPageSize=1&api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:50:40 GMT - ms-cv: Umh5IyKJJUSy7YzMENCMHw.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:33:11 GMT + ms-cv: SvgyDqrx/kaRAnKxBmIbqg.0 strict-transport-security: max-age=2592000 - x-processing-time: 55ms + x-processing-time: 294ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -299,27 +295,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:41 GMT + - Thu, 26 Nov 2020 01:33:12 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:41 GMT + - Thu, 26 Nov 2020 01:33:28 GMT ms-cv: - - ey6USD06DkK0IW5u5fZ9aQ.0 - strict-transport-security: - - max-age=2592000 + - l+qbq/n5N0GBkkLEKNYi9Q.0 x-processing-time: - - 1079ms + - 16209ms status: code: 204 message: No Content @@ -335,27 +329,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:42 GMT + - Thu, 26 Nov 2020 01:33:28 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:42 GMT + - Thu, 26 Nov 2020 01:33:43 GMT ms-cv: - - F0C0g25g4UaxRnEOPr8BiQ.0 - strict-transport-security: - - max-age=2592000 + - K+9l+OPQUkW1e+3cKQfiFw.0 x-processing-time: - - 618ms + - 16048ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_participants.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_participants.yaml new file mode 100644 index 000000000000..f162f3630d5f --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_participants.yaml @@ -0,0 +1,257 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:33:44 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:33:44 GMT + ms-cv: + - y0vL8iGu9kSISUXgKL1SJQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 146ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:33:44 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:33:44.2419698+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:33:45 GMT + ms-cv: + - vJ/qIPfn2Eqa4DKO12rVWQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 300ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:33:45 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:33:45 GMT + ms-cv: + - H7rgAX/6NkCh0C+eYIpUwA.0 + transfer-encoding: + - chunked + x-processing-time: + - 145ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:33:45Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a210-f826-557d-5a3a0d0000e7", + "participants": "sanitized"}' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + content-type: application/json; charset=utf-8 + date: Thu, 26 Nov 2020 01:33:46 GMT + ms-cv: 8Zq+55ejRUi28uPej8ipFQ.0 + strict-transport-security: max-age=2592000 + transfer-encoding: chunked + x-processing-time: 838ms + status: + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: GET + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 + response: + body: '{"value": "sanitized"}' + headers: + api-supported-versions: 2020-11-01-preview3 + content-type: application/json; charset=utf-8 + date: Thu, 26 Nov 2020 01:33:46 GMT + ms-cv: QsPk8Ayoik2kO6GzEByDsA.0 + strict-transport-security: max-age=2592000 + transfer-encoding: chunked + x-processing-time: 728ms + status: + code: 200 + message: OK + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:33:47 GMT + ms-cv: WgRInbZhnUOfEkcuwLWyNA.0 + strict-transport-security: max-age=2592000 + x-processing-time: 287ms + status: + code: 204 + message: No Content + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:33:47 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:34:03 GMT + ms-cv: + - aLdr7oRxr0+SNMWVdcNlUA.0 + x-processing-time: + - 16341ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:34:04 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:34:19 GMT + ms-cv: + - DNV9Hc695k2+c1TiUkkboA.0 + x-processing-time: + - 16170ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_read_receipts.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_read_receipts.yaml index b76d815d29bc..9d39f15c1181 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_read_receipts.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_list_read_receipts.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:43 GMT + - Thu, 26 Nov 2020 01:34:20 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:43 GMT + - Thu, 26 Nov 2020 01:34:19 GMT ms-cv: - - sK70q2MIOkuK0myYXjF9AA.0 - strict-transport-security: - - max-age=2592000 + - qVG5DfgLr02fVLBrSp2pHA.0 transfer-encoding: - chunked x-processing-time: - - 221ms + - 143ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:50:44 GMT + - Thu, 26 Nov 2020 01:34:20 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:50:43.5874705+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:34:20.1917523+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:44 GMT + - Thu, 26 Nov 2020 01:34:20 GMT ms-cv: - - 7bxlSS6VHUCmsEKKnxfoWQ.0 - strict-transport-security: - - max-age=2592000 + - HO/kaOsySkaNaxovpPkIAQ.0 transfer-encoding: - chunked x-processing-time: - - 272ms + - 298ms status: code: 200 message: OK @@ -91,60 +87,60 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:44 GMT + - Thu, 26 Nov 2020 01:34:21 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:44 GMT + - Thu, 26 Nov 2020 01:34:20 GMT ms-cv: - - hnuooiF+t0yhxv2v8juecg.0 - strict-transport-security: - - max-age=2592000 + - 0HiCWJ+NJ0G+2SahcNmLlA.0 transfer-encoding: - chunked x-processing-time: - - 206ms + - 150ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:34:21Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a211-8498-557d-5a3a0d0000e9", + "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:44 GMT - ms-cv: kjbqUF/LwUGvbNBLq/c++Q.0 + date: Thu, 26 Nov 2020 01:34:21 GMT + ms-cv: rew/+Eh1NE+0AgM80oNhqg.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 179ms + x-processing-time: 830ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -156,23 +152,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:45 GMT - ms-cv: 50IEwp4usU+sAuc6QP91aw.0 + date: Thu, 26 Nov 2020 01:34:22 GMT + ms-cv: VSZeo9bdgkGAMCBRF6JuoA.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 126ms + x-processing-time: 729ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 - request: body: '{"chatMessageId": "sanitized"}' headers: @@ -183,68 +179,68 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-length: '0' - date: Thu, 01 Oct 2020 22:50:45 GMT - ms-cv: dy+/I60mUEKplYLDd8fGxQ.0 + date: Thu, 26 Nov 2020 01:34:23 GMT + ms-cv: ajcsQu2gVkmlpbvy5kJSxA.0 strict-transport-security: max-age=2592000 - x-processing-time: 86ms + x-processing-time: 673ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: GET - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 response: body: '{"value": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:47 GMT - ms-cv: nlnT6e2Zb06ZZLaNAzMItw.0 + date: Thu, 26 Nov 2020 01:34:25 GMT + ms-cv: vHRuIcrR00G3VL8egyCwDQ.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 28ms + x-processing-time: 254ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:50:47 GMT - ms-cv: fUAVNq3/Uk2YQqmL0A8Hqw.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:34:26 GMT + ms-cv: zc7Jrp5E50qsSlzLpPuNsg.0 strict-transport-security: max-age=2592000 - x-processing-time: 60ms + x-processing-time: 293ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -257,27 +253,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:48 GMT + - Thu, 26 Nov 2020 01:34:26 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:48 GMT + - Thu, 26 Nov 2020 01:34:42 GMT ms-cv: - - VY930vaGDkGaA+pTNNewtg.0 - strict-transport-security: - - max-age=2592000 + - XQ8vkqFun0WcYBPV9F++/g.0 x-processing-time: - - 700ms + - 16141ms status: code: 204 message: No Content @@ -293,27 +287,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:49 GMT + - Thu, 26 Nov 2020 01:34:43 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:50:49 GMT + - Thu, 26 Nov 2020 01:34:58 GMT ms-cv: - - Lu58EmAspkuixCust3zBcw.0 - strict-transport-security: - - max-age=2592000 + - KV556O+jUkmHGylV2zWLgQ.0 x-processing-time: - - 572ms + - 16302ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_remove_participant.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_remove_participant.yaml new file mode 100644 index 000000000000..d21134bec2be --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_remove_participant.yaml @@ -0,0 +1,283 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:34:59 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:34:59 GMT + ms-cv: + - oQrZbF4GQEypiqfU08s+9w.0 + transfer-encoding: + - chunked + x-processing-time: + - 142ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:34:59 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:34:58.1634305+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:34:59 GMT + ms-cv: + - n5c2h2z7Vk+4gzHWj68zxA.0 + transfer-encoding: + - chunked + x-processing-time: + - 310ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:35:00 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:35:00 GMT + ms-cv: + - FQK3oL3EG0GsKEqJWVt5Rw.0 + transfer-encoding: + - chunked + x-processing-time: + - 146ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:35:00Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a212-1ccd-d67a-5a3a0d0001cb", + "participants": "sanitized"}' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + content-type: application/json; charset=utf-8 + date: Thu, 26 Nov 2020 01:35:01 GMT + ms-cv: RRYgCrWY1ESu0YFD1duVQQ.0 + strict-transport-security: max-age=2592000 + transfer-encoding: chunked + x-processing-time: 886ms + status: + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 +- request: + body: '{"participants": "sanitized"}' + headers: + Accept: + - application/json + Content-Length: + - '183' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-11-01-preview3 + content-length: '0' + date: Thu, 26 Nov 2020 01:35:02 GMT + ms-cv: edYRbuxHsUuOg0JW27TZKQ.0 + strict-transport-security: max-age=2592000 + x-processing-time: 403ms + status: + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants/8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a212-1f00-d67a-5a3a0d0001cc?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:35:02 GMT + ms-cv: 0fKc3/555kKjnjYNQmwzRQ.0 + strict-transport-security: max-age=2592000 + x-processing-time: 450ms + status: + code: 204 + message: No Content + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/participants/8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a212-1f00-d67a-5a3a0d0001cc?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:35:02 GMT + ms-cv: m6iUQzJRZEG611S2pDe/2Q.0 + strict-transport-security: max-age=2592000 + x-processing-time: 294ms + status: + code: 204 + message: No Content + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:35:02 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:35:18 GMT + ms-cv: + - ZbmySYRAHU6qAiF6JsWz8Q.0 + x-processing-time: + - 16366ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:35:19 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:35:35 GMT + ms-cv: + - tVMr8+mtWU6LZG7uF/yihA.0 + x-processing-time: + - 15791ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_message.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_message.yaml index ba0bb7555791..ebdeb24bcff2 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_message.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_message.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:55 GMT + - Thu, 26 Nov 2020 01:35:35 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:55 GMT + - Thu, 26 Nov 2020 01:35:35 GMT ms-cv: - - BPU+aUX95EqVZq9b5rRO3A.0 - strict-transport-security: - - max-age=2592000 + - J7gqJw6bRkCsHfgyy/oTjA.0 transfer-encoding: - chunked x-processing-time: - - 201ms + - 149ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:50:56 GMT + - Thu, 26 Nov 2020 01:35:35 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:50:55.574861+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:35:35.1844546+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:55 GMT + - Thu, 26 Nov 2020 01:35:36 GMT ms-cv: - - KGcpoXRr4kKEUbO+D5RrKw.0 - strict-transport-security: - - max-age=2592000 + - BZDCih5O9k6HnxFKf68K3g.0 transfer-encoding: - chunked x-processing-time: - - 275ms + - 301ms status: code: 200 message: OK @@ -91,60 +87,60 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:56 GMT + - Thu, 26 Nov 2020 01:35:36 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:50:56 GMT + - Thu, 26 Nov 2020 01:35:36 GMT ms-cv: - - Wp5CiTkhy0628lYMUTVWdw.0 - strict-transport-security: - - max-age=2592000 + - YQNACfJlA0qC3+bhjRWniQ.0 transfer-encoding: - chunked x-processing-time: - - 202ms + - 144ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:35:36Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a212-a997-d67a-5a3a0d0001cd", + "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:56 GMT - ms-cv: QHQ/qlMCcUSVnmEix9IJSg.0 + date: Thu, 26 Nov 2020 01:35:36 GMT + ms-cv: Pc4d/2p2pE+ndamI7Q/yyw.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 345ms + x-processing-time: 836ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -156,45 +152,45 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:50:57 GMT - ms-cv: clo0gTjlq0uwVqd6REttLA.0 + date: Thu, 26 Nov 2020 01:35:38 GMT + ms-cv: jesVyMlSfkShPs3vk9dWTw.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 74ms + x-processing-time: 713ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:50:57 GMT - ms-cv: OePjRSymykab17YmuIsetg.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:35:38 GMT + ms-cv: 2Zyr3xwjbEOSZuQN3pYT2w.0 strict-transport-security: max-age=2592000 - x-processing-time: 86ms + x-processing-time: 291ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -207,27 +203,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:50:58 GMT + - Thu, 26 Nov 2020 01:35:38 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:51:14 GMT + - Thu, 26 Nov 2020 01:35:54 GMT ms-cv: - - bVaIOF97Pk2iAwF1mB+big.0 - strict-transport-security: - - max-age=2592000 + - Xdx00sbXlU+b3aOJ8LxyPQ.0 x-processing-time: - - 17275ms + - 16683ms status: code: 204 message: No Content @@ -243,27 +237,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:15 GMT + - Thu, 26 Nov 2020 01:35:55 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:51:15 GMT + - Thu, 26 Nov 2020 01:36:10 GMT ms-cv: - - tqBzXy5eT0SkrG95kdsj4Q.0 - strict-transport-security: - - max-age=2592000 + - HjmmS6PM8E2QVUJev7Im7Q.0 x-processing-time: - - 644ms + - 15625ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_read_receipt.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_read_receipt.yaml index f46a4c9be467..4fd8fb12eac8 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_read_receipt.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_read_receipt.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:16 GMT + - Thu, 26 Nov 2020 01:36:11 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:16 GMT + - Thu, 26 Nov 2020 01:36:10 GMT ms-cv: - - Ke6DbY2bVEaAq6l4OLVKHQ.0 - strict-transport-security: - - max-age=2592000 + - k2q749trqEqL2UDw50CM0A.0 transfer-encoding: - chunked x-processing-time: - - 203ms + - 144ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:51:17 GMT + - Thu, 26 Nov 2020 01:36:11 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:51:16.3859242+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:36:10.8133027+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:16 GMT + - Thu, 26 Nov 2020 01:36:11 GMT ms-cv: - - HXK2gd4CQUOAIM3uKaStFA.0 - strict-transport-security: - - max-age=2592000 + - pZs4QVOs1k6SJgcVZ6AXvw.0 transfer-encoding: - chunked x-processing-time: - - 273ms + - 303ms status: code: 200 message: OK @@ -91,60 +87,60 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:17 GMT + - Thu, 26 Nov 2020 01:36:11 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:17 GMT + - Thu, 26 Nov 2020 01:36:11 GMT ms-cv: - - XgDJb/JLb0GqTR9z0IqelA.0 - strict-transport-security: - - max-age=2592000 + - 9xvyVE1JsUeIC0/dijFQjA.0 transfer-encoding: - chunked x-processing-time: - - 200ms + - 147ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:36:12Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a213-34b8-d67a-5a3a0d0001cf", + "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:51:17 GMT - ms-cv: iMt9jIEoUEa5+CQ68n9DOg.0 + date: Thu, 26 Nov 2020 01:36:12 GMT + ms-cv: 8kp0E64MxkafYOfwcXKP3Q.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 193ms + x-processing-time: 823ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -156,23 +152,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:51:17 GMT - ms-cv: X+TmPzJJwEm7Cxlx0RfkIg.0 + date: Thu, 26 Nov 2020 01:36:13 GMT + ms-cv: +MnzAI1IZkCAUA7Sw3/RcQ.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 84ms + x-processing-time: 696ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 - request: body: '{"chatMessageId": "sanitized"}' headers: @@ -183,45 +179,45 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-length: '0' - date: Thu, 01 Oct 2020 22:51:18 GMT - ms-cv: faVVDHL/cUmEfeooJfGQcw.0 + date: Thu, 26 Nov 2020 01:36:14 GMT + ms-cv: np6O1exdTkmdY6jpelGRCQ.0 strict-transport-security: max-age=2592000 - x-processing-time: 54ms + x-processing-time: 1054ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/readreceipts?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/readreceipts?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:51:18 GMT - ms-cv: KWu4qZGGmUi2BUxz/Uqdqw.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:36:14 GMT + ms-cv: wVU4WewVYEeim0TbvPteKA.0 strict-transport-security: max-age=2592000 - x-processing-time: 53ms + x-processing-time: 291ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -234,27 +230,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:18 GMT + - Thu, 26 Nov 2020 01:36:15 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:51:19 GMT + - Thu, 26 Nov 2020 01:36:31 GMT ms-cv: - - PYEcRHnJ4E6s/V2uso/ZMg.0 - strict-transport-security: - - max-age=2592000 + - jGmnRPPi4U2r3B5fI2TvAg.0 x-processing-time: - - 1049ms + - 16665ms status: code: 204 message: No Content @@ -270,27 +264,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:20 GMT + - Thu, 26 Nov 2020 01:36:32 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:51:20 GMT + - Thu, 26 Nov 2020 01:36:48 GMT ms-cv: - - VntmqAP1e0+hwOOS8wqGEw.0 - strict-transport-security: - - max-age=2592000 + - bR3F85hcqEGnM3hyhGekCw.0 x-processing-time: - - 630ms + - 15998ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_typing_notification.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_typing_notification.yaml index 46c53ffa5ae0..7bc6460edd8a 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_typing_notification.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_send_typing_notification.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:20 GMT + - Thu, 26 Nov 2020 01:36:48 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:21 GMT + - Thu, 26 Nov 2020 01:36:48 GMT ms-cv: - - YGTxha89b0W6sHk4lkjKEw.0 - strict-transport-security: - - max-age=2592000 + - 5dfd6S68+0ON0FgQKe2BHA.0 transfer-encoding: - chunked x-processing-time: - - 204ms + - 147ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:51:21 GMT + - Thu, 26 Nov 2020 01:36:48 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:51:20.86266+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:36:47.9731258+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:21 GMT + - Thu, 26 Nov 2020 01:36:48 GMT ms-cv: - - 4aTyTPALbEi9B2mX6szSog.0 - strict-transport-security: - - max-age=2592000 + - ARI2J6FfUUeacfogHwIBuA.0 transfer-encoding: - chunked x-processing-time: - - 276ms + - 305ms status: code: 200 message: OK @@ -91,105 +87,105 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:21 GMT + - Thu, 26 Nov 2020 01:36:49 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:21 GMT + - Thu, 26 Nov 2020 01:36:48 GMT ms-cv: - - /dcOSL70NEClgAkb9NRQRg.0 - strict-transport-security: - - max-age=2592000 + - gOo1oxdvV0iEEMdquiWLnQ.0 transfer-encoding: - chunked x-processing-time: - - 204ms + - 147ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:36:49Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a213-c5d3-d67a-5a3a0d0001d1", + "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:51:22 GMT - ms-cv: gaxAU4lfYEyR6JoWSiB5JA.0 + date: Thu, 26 Nov 2020 01:36:49 GMT + ms-cv: hVsPHh2h7UCb4zyTr4V09A.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 207ms + x-processing-time: 819ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/typing?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/typing?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-length: '0' - date: Thu, 01 Oct 2020 22:51:22 GMT - ms-cv: Y46F01o3XkS8ukixmGrLow.0 + date: Thu, 26 Nov 2020 01:36:49 GMT + ms-cv: Ugs6QMBZB0Sa0KjcVdJ/OA.0 strict-transport-security: max-age=2592000 - x-processing-time: 57ms + x-processing-time: 350ms status: code: 200 message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized/typing?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/typing?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:51:23 GMT - ms-cv: FeGxBYYFyUq7eN+Lfi/SaA.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:36:50 GMT + ms-cv: jfiKGmFYIkKtmUX49ENjWQ.0 strict-transport-security: max-age=2592000 - x-processing-time: 65ms + x-processing-time: 293ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -202,27 +198,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:23 GMT + - Thu, 26 Nov 2020 01:36:51 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:51:23 GMT + - Thu, 26 Nov 2020 01:37:06 GMT ms-cv: - - FguqR21IfkeKSKg2IYfQ2A.0 - strict-transport-security: - - max-age=2592000 + - RZoO3HhFo0OwIv5gA1twZA.0 x-processing-time: - - 942ms + - 16249ms status: code: 204 message: No Content @@ -238,27 +232,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:24 GMT + - Thu, 26 Nov 2020 01:37:07 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:51:24 GMT + - Thu, 26 Nov 2020 01:37:22 GMT ms-cv: - - Zr+lF+jy5UWB2G2WEN9inQ.0 - strict-transport-security: - - max-age=2592000 + - HwAld85ROEuFlUgOzhOl8w.0 x-processing-time: - - 676ms + - 15724ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_update_message.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_update_message.yaml index edd9c26e40d6..f87e84004dd7 100644 --- a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_update_message.yaml +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_update_message.yaml @@ -11,30 +11,28 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:25 GMT + - Thu, 26 Nov 2020 01:37:23 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:25 GMT + - Thu, 26 Nov 2020 01:37:23 GMT ms-cv: - - wsVH465ioE+/x9hYGbnqaQ.0 - strict-transport-security: - - max-age=2592000 + - pr4hJTNfY02Ob3HQWgo0+Q.0 transfer-encoding: - chunked x-processing-time: - - 205ms + - 193ms status: code: 200 message: OK @@ -52,30 +50,28 @@ interactions: Content-Type: - application/json Date: - - Thu, 01 Oct 2020 22:51:25 GMT + - Thu, 26 Nov 2020 01:37:23 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities/sanitized/token?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 response: - body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-10-02T22:51:25.3203233+00:00"}' + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:37:22.5212159+00:00"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:26 GMT + - Thu, 26 Nov 2020 01:37:23 GMT ms-cv: - - YGii/fRmXkyxh5CfS9n1Lw.0 - strict-transport-security: - - max-age=2592000 + - Fx82Mbw6nECeET5we1lTmQ.0 transfer-encoding: - chunked x-processing-time: - - 282ms + - 799ms status: code: 200 message: OK @@ -91,60 +87,60 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:26 GMT + - Thu, 26 Nov 2020 01:37:24 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: POST - uri: https://sanitized.communication.azure.com/identities?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 response: body: '{"id": "sanitized"}' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 content-type: - application/json; charset=utf-8 date: - - Thu, 01 Oct 2020 22:51:26 GMT + - Thu, 26 Nov 2020 01:37:24 GMT ms-cv: - - /h67hiZTaU27ashWwFMRew.0 - strict-transport-security: - - max-age=2592000 + - iZCNwDoNr0aswypDFZtPbw.0 transfer-encoding: - chunked x-processing-time: - - 207ms + - 147ms status: code: 200 message: OK - request: - body: '{"topic": "test topic", "members": "sanitized"}' + body: '{"topic": "test topic", "participants": "sanitized"}' headers: Accept: - application/json Content-Length: - - '201' + - '206' Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 response: - body: '{"multipleStatus": "sanitized"}' + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:37:25Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a214-4ec4-557d-5a3a0d0000eb", + "participants": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:51:26 GMT - ms-cv: Yy2rEZCNdUKVVrfmcMbN0Q.0 + date: Thu, 26 Nov 2020 01:37:24 GMT + ms-cv: Jx6RuC+vCUGEGH3W1Rd2uw.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 223ms + x-processing-time: 824ms status: - code: 207 - message: Multi-Status - url: https://sanitized.communication.azure.com/chat/threads?api-version=2020-09-21-preview2 + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 - request: body: '{"priority": "Normal", "content": "hello world", "senderDisplayName": "sender name"}' @@ -156,23 +152,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: POST - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 response: body: '{"id": "sanitized"}' headers: - api-supported-versions: 2020-09-21-preview2 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 content-type: application/json; charset=utf-8 - date: Thu, 01 Oct 2020 22:51:27 GMT - ms-cv: 9Fz/Icff9kmG58hFOlCvTQ.0 + date: Thu, 26 Nov 2020 01:37:26 GMT + ms-cv: s5ds7ENduUW3IcrgyAHc2w.0 strict-transport-security: max-age=2592000 transfer-encoding: chunked - x-processing-time: 67ms + x-processing-time: 1189ms status: code: 201 message: Created - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages?api-version=2020-11-01-preview3 - request: body: '{"content": "updated message content"}' headers: @@ -181,47 +177,46 @@ interactions: Content-Length: - '38' Content-Type: - - application/json + - application/merge-patch+json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: PATCH - uri: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - content-length: '0' - date: Thu, 01 Oct 2020 22:51:27 GMT - ms-cv: 1r626ex0o0G2tiGOuTQZtA.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:37:27 GMT + ms-cv: ADPtiWXcvUGsA+NIakBLVg.0 strict-transport-security: max-age=2592000 - x-processing-time: 124ms + x-processing-time: 644ms status: - code: 200 - message: OK - url: https://sanitized.communication.azure.com/chat/threads/sanitized/messages/sanitized?api-version=2020-09-21-preview2 + code: 204 + message: No Content + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized/messages/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: Accept: - application/json User-Agent: - - azsdk-python-communication-chat/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) method: DELETE - uri: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 response: body: string: '' headers: - api-supported-versions: 2020-09-21-preview2 - date: Thu, 01 Oct 2020 22:51:27 GMT - ms-cv: 0F+uuYwMKEeC2CDZ1yHkfw.0 + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:37:27 GMT + ms-cv: 89G73Qkbzk2xsrd+NB2pew.0 strict-transport-security: max-age=2592000 - x-processing-time: 60ms + x-processing-time: 297ms status: code: 204 message: No Content - url: https://sanitized.communication.azure.com/chat/threads/sanitized?api-version=2020-09-21-preview2 + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 - request: body: null headers: @@ -234,27 +229,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:27 GMT + - Thu, 26 Nov 2020 01:37:28 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:51:28 GMT + - Thu, 26 Nov 2020 01:37:44 GMT ms-cv: - - a1BlSagxrUarQn4FpMHXXw.0 - strict-transport-security: - - max-age=2592000 + - Do0PbPBpokuzAtYTRVnGEQ.0 x-processing-time: - - 739ms + - 16576ms status: code: 204 message: No Content @@ -270,27 +263,25 @@ interactions: Content-Length: - '0' Date: - - Thu, 01 Oct 2020 22:51:28 GMT + - Thu, 26 Nov 2020 01:37:45 GMT User-Agent: - - azsdk-python-communication-administration/1.0.0b1 Python/3.8.5 (Windows-10-10.0.19041-SP0) + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) x-ms-return-client-request-id: - 'true' method: DELETE - uri: https://sanitized.communication.azure.com/identities/sanitized?api-version=2020-07-20-preview2 + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 response: body: string: '' headers: api-supported-versions: - - 2020-07-20-preview1, 2020-07-20-preview2 + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 date: - - Thu, 01 Oct 2020 22:51:29 GMT + - Thu, 26 Nov 2020 01:38:01 GMT ms-cv: - - RbcELvRydkSRY4FFsemzAw.0 - strict-transport-security: - - max-age=2592000 + - 6QuQdG+lOU2AvQ4gESHRCg.0 x-processing-time: - - 867ms + - 16160ms status: code: 204 message: No Content diff --git a/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_update_topic.yaml b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_update_topic.yaml new file mode 100644 index 000000000000..8cbebdb95275 --- /dev/null +++ b/sdk/communication/azure-communication-chat/tests/recordings/test_chat_thread_client_e2e_async.test_update_topic.yaml @@ -0,0 +1,260 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:38:01 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:38:01 GMT + ms-cv: + - xOTsMZpPDE6VSFdb4pUG9g.0 + transfer-encoding: + - chunked + x-processing-time: + - 145ms + status: + code: 200 + message: OK +- request: + body: '{"scopes": ["chat"]}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '20' + Content-Type: + - application/json + Date: + - Thu, 26 Nov 2020 01:38:01 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities/sanitized/token?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized", "token": "sanitized", "expiresOn": "2020-11-27T01:38:01.2688559+00:00"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:38:01 GMT + ms-cv: + - xAGb2zCDrk2Ic8aWRhHLPg.0 + transfer-encoding: + - chunked + x-processing-time: + - 307ms + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:38:02 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: POST + uri: https://sanitized.dev.communication.azure.net/identities?api-version=2020-07-20-preview2 + response: + body: '{"id": "sanitized"}' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + content-type: + - application/json; charset=utf-8 + date: + - Thu, 26 Nov 2020 01:38:01 GMT + ms-cv: + - Y/yo9RuBmUOZRSjZTQC0oQ.0 + transfer-encoding: + - chunked + x-processing-time: + - 146ms + status: + code: 200 + message: OK +- request: + body: '{"topic": "test topic", "participants": "sanitized"}' + headers: + Accept: + - application/json + Content-Length: + - '206' + Content-Type: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: POST + uri: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 + response: + body: '{"id": "sanitized", "topic": "test topic", "createdOn": "2020-11-26T01:38:02Z", + "createdBy": "8:acs:9b665d53-8164-4923-ad5d-5e983b07d2e7_00000006-a214-e42a-557d-5a3a0d0000ed", + "participants": "sanitized"}' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + content-type: application/json; charset=utf-8 + date: Thu, 26 Nov 2020 01:38:03 GMT + ms-cv: ikYbvwWd0EeQKe0qSkCWTw.0 + strict-transport-security: max-age=2592000 + transfer-encoding: chunked + x-processing-time: 835ms + status: + code: 201 + message: Created + url: https://sanitized.dev.communication.azure.net/chat/threads?api-version=2020-11-01-preview3 +- request: + body: '{"topic": "update topic"}' + headers: + Accept: + - application/json + Content-Length: + - '25' + Content-Type: + - application/merge-patch+json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: PATCH + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:38:04 GMT + ms-cv: B9zAEHFeoEWGADIp0yKqGQ.0 + strict-transport-security: max-age=2592000 + x-processing-time: 402ms + status: + code: 204 + message: No Content + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - application/json + User-Agent: + - azsdk-python-communication-chat/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + method: DELETE + uri: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 + response: + body: + string: '' + headers: + api-supported-versions: 2020-09-21-preview2, 2020-11-01-preview3 + date: Thu, 26 Nov 2020 01:38:04 GMT + ms-cv: cDCCSUJ76kKa8dg8Xs/naA.0 + strict-transport-security: max-age=2592000 + x-processing-time: 297ms + status: + code: 204 + message: No Content + url: https://sanitized.dev.communication.azure.net/chat/threads/sanitized?api-version=2020-11-01-preview3 +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:38:04 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:38:21 GMT + ms-cv: + - SnhqKrzJHkicq9V0u8C5Dg.0 + x-processing-time: + - 16662ms + status: + code: 204 + message: No Content +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '0' + Date: + - Thu, 26 Nov 2020 01:38:21 GMT + User-Agent: + - azsdk-python-communication-administration/1.0.0b2 Python/3.9.0 (Windows-10-10.0.19041-SP0) + x-ms-return-client-request-id: + - 'true' + method: DELETE + uri: https://sanitized.dev.communication.azure.net/identities/sanitized?api-version=2020-07-20-preview2 + response: + body: + string: '' + headers: + api-supported-versions: + - 2020-01-15-preview3, 2020-07-20-preview1, 2020-07-20-preview2 + date: + - Thu, 26 Nov 2020 01:38:36 GMT + ms-cv: + - RFQIEh9xhkaGo9n3KT4dmg.0 + x-processing-time: + - 15852ms + status: + code: 204 + message: No Content +version: 1 diff --git a/sdk/communication/azure-communication-chat/tests/test_chat_client.py b/sdk/communication/azure-communication-chat/tests/test_chat_client.py index 1b6e5ac8c520..866f86646873 100644 --- a/sdk/communication/azure-communication-chat/tests/test_chat_client.py +++ b/sdk/communication/azure-communication-chat/tests/test_chat_client.py @@ -11,7 +11,7 @@ from msrest.serialization import TZ_UTC from azure.communication.chat import ( ChatClient, - ChatThreadMember, + ChatThreadParticipant, CommunicationUser, CommunicationUserCredential ) @@ -37,19 +37,19 @@ def test_create_chat_thread(self): raised = False def mock_send(*_, **__): - return mock_response(status_code=207, json_payload={"multipleStatus": [{"id": thread_id, "statusCode": 201, "type": "Thread"}]}) + return mock_response(status_code=201, json_payload={"id": thread_id}) chat_client = ChatClient("https://endpoint", TestChatClient.credential, transport=Mock(send=mock_send)) topic="test topic" user = CommunicationUser("8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041") - members=[ChatThreadMember( + participants=[ChatThreadParticipant( user=user, display_name='name', share_history_time=datetime.utcnow() )] try: - chat_thread_client = chat_client.create_chat_thread(topic, members) + chat_thread_client = chat_client.create_chat_thread(topic, participants) except: raised = True raise @@ -64,13 +64,13 @@ def mock_send(*_, **__): topic="test topic", user = CommunicationUser("8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041") - thread_members=[ChatThreadMember( + thread_participants=[ChatThreadParticipant( user=user, display_name='name', share_history_time=datetime.utcnow() )] - self.assertRaises(HttpResponseError, chat_client.create_chat_thread, topic=topic, thread_members=thread_members) + self.assertRaises(HttpResponseError, chat_client.create_chat_thread, topic=topic, thread_participants=thread_participants) def test_delete_chat_thread(self): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" @@ -95,7 +95,7 @@ def mock_send(*_, **__): return mock_response(status_code=200, json_payload={ "id": thread_id, "created_by": "8:acs:resource_user", - "members": [{"id": "", "display_name": "name", "share_history_time": "1970-01-01T00:00:00Z"}] + "participants": [{"id": "", "display_name": "name", "share_history_time": "1970-01-01T00:00:00Z"}] }) chat_client = ChatClient("https://endpoint", TestChatClient.credential, transport=Mock(send=mock_send)) diff --git a/sdk/communication/azure-communication-chat/tests/test_chat_client_async.py b/sdk/communication/azure-communication-chat/tests/test_chat_client_async.py index 7b35b95299d2..22f515ca53f6 100644 --- a/sdk/communication/azure-communication-chat/tests/test_chat_client_async.py +++ b/sdk/communication/azure-communication-chat/tests/test_chat_client_async.py @@ -9,7 +9,7 @@ CommunicationUserCredential ) from azure.communication.chat import ( - ChatThreadMember, + ChatThreadParticipant, CommunicationUser ) from unittest_helpers import mock_response @@ -32,18 +32,18 @@ async def test_create_chat_thread(): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" async def mock_send(*_, **__): - return mock_response(status_code=207, json_payload={"multipleStatus": [{"id": thread_id, "statusCode": 201, "type": "Thread"}]}) + return mock_response(status_code=201, json_payload={"id": thread_id}) chat_client = ChatClient("https://endpoint", credential, transport=Mock(send=mock_send)) topic="test topic" user = CommunicationUser("8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041") - members=[ChatThreadMember( + participants=[ChatThreadParticipant( user=user, display_name='name', share_history_time=datetime.utcnow() )] - chat_thread_client = await chat_client.create_chat_thread(topic, members) + chat_thread_client = await chat_client.create_chat_thread(topic, participants) assert chat_thread_client.thread_id == thread_id @pytest.mark.asyncio @@ -54,7 +54,7 @@ async def mock_send(*_, **__): topic="test topic", user = CommunicationUser("8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041") - members=[ChatThreadMember( + participants=[ChatThreadParticipant( user=user, display_name='name', share_history_time=datetime.utcnow() @@ -62,7 +62,7 @@ async def mock_send(*_, **__): raised = False try: - await chat_client.create_chat_thread(topic=topic, thread_members=members) + await chat_client.create_chat_thread(topic=topic, thread_participants=participants) except: raised = True @@ -94,7 +94,7 @@ async def mock_send(*_, **__): return mock_response(status_code=200, json_payload={ "id": thread_id, "created_by": "8:acs:resource_user", - "members": [{"id": "", "display_name": "name", "share_history_time": "1970-01-01T00:00:00Z"}] + "participants": [{"id": "", "display_name": "name", "share_history_time": "1970-01-01T00:00:00Z"}] }) chat_client = ChatClient("https://endpoint", credential, transport=Mock(send=mock_send)) diff --git a/sdk/communication/azure-communication-chat/tests/test_chat_client_e2e.py b/sdk/communication/azure-communication-chat/tests/test_chat_client_e2e.py index 194878492270..2e32d55f3d48 100644 --- a/sdk/communication/azure-communication-chat/tests/test_chat_client_e2e.py +++ b/sdk/communication/azure-communication-chat/tests/test_chat_client_e2e.py @@ -14,7 +14,7 @@ from azure.communication.chat import ( ChatClient, CommunicationUserCredential, - ChatThreadMember + ChatThreadParticipant ) from azure.communication.chat._shared.utils import parse_connection_str @@ -32,7 +32,7 @@ def setUp(self): super(ChatClientTest, self).setUp() self.recording_processors.extend([ - BodyReplacerProcessor(keys=["id", "token", "createdBy", "members", "multipleStatus", "value"]), + BodyReplacerProcessor(keys=["id", "token", "createdBy", "participants", "multipleStatus", "value"]), URIIdentityReplacer(), ChatURIReplacer()]) @@ -63,12 +63,12 @@ def _create_thread(self): topic = "test topic" share_history_time = datetime.utcnow() share_history_time = share_history_time.replace(tzinfo=TZ_UTC) - members = [ChatThreadMember( + participants = [ChatThreadParticipant( user=self.user, display_name='name', share_history_time=share_history_time )] - chat_thread_client = self.chat_client.create_chat_thread(topic, members) + chat_thread_client = self.chat_client.create_chat_thread(topic, participants) self.thread_id = chat_thread_client.thread_id @pytest.mark.live_test_only diff --git a/sdk/communication/azure-communication-chat/tests/test_chat_client_e2e_async.py b/sdk/communication/azure-communication-chat/tests/test_chat_client_e2e_async.py index 289998c7a290..ddd269516fbe 100644 --- a/sdk/communication/azure-communication-chat/tests/test_chat_client_e2e_async.py +++ b/sdk/communication/azure-communication-chat/tests/test_chat_client_e2e_async.py @@ -15,7 +15,7 @@ CommunicationUserCredential ) from azure.communication.chat import ( - ChatThreadMember + ChatThreadParticipant ) from azure.communication.administration._shared.utils import parse_connection_str from azure_devtools.scenario_tests import RecordingProcessor @@ -30,7 +30,7 @@ def setUp(self): super(ChatClientTestAsync, self).setUp() self.recording_processors.extend([ - BodyReplacerProcessor(keys=["id", "token", "createdBy", "members", "multipleStatus", "value"]), + BodyReplacerProcessor(keys=["id", "token", "createdBy", "participants", "multipleStatus", "value"]), URIIdentityReplacer(), ResponseReplacerProcessor(keys=[self._resource_name]), ChatURIReplacer()]) @@ -60,12 +60,12 @@ async def _create_thread(self): topic = "test topic" share_history_time = datetime.utcnow() share_history_time = share_history_time.replace(tzinfo=TZ_UTC) - members = [ChatThreadMember( + participants = [ChatThreadParticipant( user=self.user, display_name='name', share_history_time=share_history_time )] - chat_thread_client = await self.chat_client.create_chat_thread(topic, members) + chat_thread_client = await self.chat_client.create_chat_thread(topic, participants) self.thread_id = chat_thread_client.thread_id @pytest.mark.live_test_only diff --git a/sdk/communication/azure-communication-chat/tests/test_chat_thread_client.py b/sdk/communication/azure-communication-chat/tests/test_chat_thread_client.py index b63ffc10df45..108597e6a214 100644 --- a/sdk/communication/azure-communication-chat/tests/test_chat_thread_client.py +++ b/sdk/communication/azure-communication-chat/tests/test_chat_thread_client.py @@ -12,7 +12,7 @@ from azure.communication.chat import ( ChatThreadClient, ChatMessagePriority, - ChatThreadMember, + ChatThreadParticipant, CommunicationUser, CommunicationUserCredential ) @@ -30,17 +30,17 @@ def setUpClass(cls, credential): credential.get_token = Mock(return_value=AccessToken("some_token", datetime.now().replace(tzinfo=TZ_UTC))) TestChatThreadClient.credential = credential - def test_update_thread(self): + def test_update_topic(self): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" raised = False def mock_send(*_, **__): - return mock_response(status_code=200) + return mock_response(status_code=204) chat_thread_client = ChatThreadClient("https://endpoint", TestChatThreadClient.credential, thread_id, transport=Mock(send=mock_send)) topic = "update topic" try: - chat_thread_client.update_thread(topic=topic) + chat_thread_client.update_topic(topic=topic) except: raised = True @@ -61,7 +61,7 @@ def mock_send(*_, **__): content='hello world' sender_display_name='sender name' - create_message_result = chat_thread_client.send_message( + create_message_result_id = chat_thread_client.send_message( content, priority=priority, sender_display_name=sender_display_name) @@ -69,7 +69,7 @@ def mock_send(*_, **__): raised = True self.assertFalse(raised, 'Expected is no excpetion raised') - assert create_message_result.id == message_id + assert create_message_result_id == message_id def test_get_message(self): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" @@ -141,7 +141,7 @@ def test_update_message(self): raised = False def mock_send(*_, **__): - return mock_response(status_code=200) + return mock_response(status_code=204) chat_thread_client = ChatThreadClient("https://endpoint", TestChatThreadClient.credential, thread_id, transport=Mock(send=mock_send)) try: @@ -168,52 +168,73 @@ def mock_send(*_, **__): self.assertFalse(raised, 'Expected is no excpetion raised') - def test_list_members(self): + def test_list_participants(self): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" - member_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" + participant_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" raised = False def mock_send(*_, **__): - return mock_response(status_code=200, json_payload={"value": [{"id": member_id}]}) + return mock_response(status_code=200, json_payload={"value": [{"id": participant_id}]}) chat_thread_client = ChatThreadClient("https://endpoint", TestChatThreadClient.credential, thread_id, transport=Mock(send=mock_send)) - chat_thread_members = None + chat_thread_participants = None try: - chat_thread_members = chat_thread_client.list_members() + chat_thread_participants = chat_thread_client.list_participants() except: raised = True self.assertFalse(raised, 'Expected is no excpetion raised') - for chat_thread_member_page in chat_thread_members.by_page(): - l = list(chat_thread_member_page) + for chat_thread_participant_page in chat_thread_participants.by_page(): + l = list(chat_thread_participant_page) assert len(l) == 1 - l[0].user.id = member_id + l[0].user.id = participant_id - def test_add_members(self): + def test_add_participant(self): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" - new_member_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" + new_participant_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" raised = False def mock_send(*_, **__): - return mock_response(status_code=207) + return mock_response(status_code=201) + chat_thread_client = ChatThreadClient("https://endpoint", TestChatThreadClient.credential, thread_id, transport=Mock(send=mock_send)) + + new_participant = ChatThreadParticipant( + user=CommunicationUser(new_participant_id), + display_name='name', + share_history_time=datetime.utcnow()) + + try: + chat_thread_client.add_participant(new_participant) + except: + raised = True + + self.assertFalse(raised, 'Expected is no excpetion raised') + + def test_add_participants(self): + thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" + new_participant_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" + raised = False + + def mock_send(*_, **__): + return mock_response(status_code=201) chat_thread_client = ChatThreadClient("https://endpoint", TestChatThreadClient.credential, thread_id, transport=Mock(send=mock_send)) - new_member = ChatThreadMember( - user=CommunicationUser(new_member_id), + new_participant = ChatThreadParticipant( + user=CommunicationUser(new_participant_id), display_name='name', share_history_time=datetime.utcnow()) - members = [new_member] + participants = [new_participant] try: - chat_thread_client.add_members(members) + chat_thread_client.add_participants(participants) except: raised = True self.assertFalse(raised, 'Expected is no excpetion raised') - def test_remove_member(self): + def test_remove_participant(self): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" - member_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" + participant_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" raised = False def mock_send(*_, **__): @@ -221,7 +242,7 @@ def mock_send(*_, **__): chat_thread_client = ChatThreadClient("https://endpoint", TestChatThreadClient.credential, thread_id, transport=Mock(send=mock_send)) try: - chat_thread_client.remove_member(CommunicationUser(member_id)) + chat_thread_client.remove_participant(CommunicationUser(participant_id)) except: raised = True diff --git a/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_async.py b/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_async.py index afddfedce47a..be1e02cf6316 100644 --- a/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_async.py +++ b/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_async.py @@ -9,7 +9,7 @@ from azure.communication.chat.aio import ChatThreadClient from azure.communication.chat import ( ChatMessagePriority, - ChatThreadMember, + ChatThreadParticipant, CommunicationUser, ) from unittest_helpers import mock_response @@ -26,17 +26,17 @@ credential.get_token = Mock(return_value=AccessToken("some_token", datetime.now().replace(tzinfo=TZ_UTC))) @pytest.mark.asyncio -async def test_update_thread(): +async def test_update_topic(): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" raised = False async def mock_send(*_, **__): - return mock_response(status_code=200) + return mock_response(status_code=204) chat_thread_client = ChatThreadClient("https://endpoint", credential, thread_id, transport=Mock(send=mock_send)) topic = "update topic" try: - await chat_thread_client.update_thread(topic=topic) + await chat_thread_client.update_topic(topic=topic) except: raised = True @@ -52,13 +52,13 @@ async def mock_send(*_, **__): return mock_response(status_code=201, json_payload={"id": message_id}) chat_thread_client = ChatThreadClient("https://endpoint", credential, thread_id, transport=Mock(send=mock_send)) - create_message_result = None + create_message_result_id = None try: priority=ChatMessagePriority.NORMAL content='hello world' sender_display_name='sender name' - create_message_result = await chat_thread_client.send_message( + create_message_result_id = await chat_thread_client.send_message( content, priority=priority, sender_display_name=sender_display_name) @@ -66,7 +66,7 @@ async def mock_send(*_, **__): raised = True assert raised == False - assert create_message_result.id == message_id + assert create_message_result_id == message_id @pytest.mark.asyncio async def test_get_message(): @@ -149,7 +149,7 @@ async def test_update_message(): raised = False async def mock_send(*_, **__): - return mock_response(status_code=200) + return mock_response(status_code=204) chat_thread_client = ChatThreadClient("https://endpoint", credential, thread_id, transport=Mock(send=mock_send)) try: @@ -178,56 +178,78 @@ async def mock_send(*_, **__): assert raised == False @pytest.mark.asyncio -async def test_list_members(): +async def test_list_participants(): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" - member_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" + participant_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" raised = False async def mock_send(*_, **__): - return mock_response(status_code=200, json_payload={"value": [{"id": member_id}]}) + return mock_response(status_code=200, json_payload={"value": [{"id": participant_id}]}) chat_thread_client = ChatThreadClient("https://endpoint", credential, thread_id, transport=Mock(send=mock_send)) - chat_thread_members = None + chat_thread_participants = None try: - chat_thread_members = chat_thread_client.list_members() + chat_thread_participants = chat_thread_client.list_participants() except: raised = True assert raised == False items = [] - async for item in chat_thread_members: + async for item in chat_thread_participants: items.append(item) assert len(items) == 1 @pytest.mark.asyncio -async def test_add_members(): +async def test_add_participant(): + thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" + new_participant_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" + raised = False + + async def mock_send(*_, **__): + return mock_response(status_code=201) + chat_thread_client = ChatThreadClient("https://endpoint", credential, thread_id, transport=Mock(send=mock_send)) + + new_participant = ChatThreadParticipant( + user=CommunicationUser(new_participant_id), + display_name='name', + share_history_time=datetime.utcnow()) + + try: + await chat_thread_client.add_participant(new_participant) + except: + raised = True + + assert raised == False + +@pytest.mark.asyncio +async def test_add_participants(): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" - new_member_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" + new_participant_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" raised = False async def mock_send(*_, **__): - return mock_response(status_code=207) + return mock_response(status_code=201) chat_thread_client = ChatThreadClient("https://endpoint", credential, thread_id, transport=Mock(send=mock_send)) - new_member = ChatThreadMember( - user=CommunicationUser(new_member_id), + new_participant = ChatThreadParticipant( + user=CommunicationUser(new_participant_id), display_name='name', share_history_time=datetime.utcnow()) - members = [new_member] + participants = [new_participant] try: - await chat_thread_client.add_members(members) + await chat_thread_client.add_participants(participants) except: raised = True assert raised == False @pytest.mark.asyncio -async def test_remove_member(): +async def test_remove_participant(): thread_id = "19:bcaebfba0d314c2aa3e920d38fa3df08@thread.v2" - member_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" + participant_id="8:acs:57b9bac9-df6c-4d39-a73b-26e944adf6ea_9b0110-08007f1041" raised = False async def mock_send(*_, **__): @@ -235,7 +257,7 @@ async def mock_send(*_, **__): chat_thread_client = ChatThreadClient("https://endpoint", credential, thread_id, transport=Mock(send=mock_send)) try: - await chat_thread_client.remove_member(CommunicationUser(member_id)) + await chat_thread_client.remove_participant(CommunicationUser(participant_id)) except: raised = True diff --git a/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_e2e.py b/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_e2e.py index 671c0ee0476c..9d6615fa145f 100644 --- a/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_e2e.py +++ b/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_e2e.py @@ -14,7 +14,7 @@ from azure.communication.chat import ( ChatClient, CommunicationUserCredential, - ChatThreadMember, + ChatThreadParticipant, ChatMessagePriority ) from azure.communication.chat._shared.utils import parse_connection_str @@ -32,7 +32,7 @@ class ChatThreadClientTest(CommunicationTestCase): def setUp(self): super(ChatThreadClientTest, self).setUp() self.recording_processors.extend([ - BodyReplacerProcessor(keys=["id", "token", "senderId", "chatMessageId", "nextLink", "members", "multipleStatus", "value"]), + BodyReplacerProcessor(keys=["id", "token", "senderId", "chatMessageId", "nextLink", "participants", "multipleStatus", "value"]), URIIdentityReplacer(), ChatURIReplacer()]) @@ -67,12 +67,12 @@ def _create_thread(self): topic = "test topic" share_history_time = datetime.utcnow() share_history_time = share_history_time.replace(tzinfo=TZ_UTC) - members = [ChatThreadMember( + participants = [ChatThreadParticipant( user=self.user, display_name='name', share_history_time=share_history_time )] - self.chat_thread_client = self.chat_client.create_chat_thread(topic, members) + self.chat_thread_client = self.chat_client.create_chat_thread(topic, participants) self.thread_id = self.chat_thread_client.thread_id @pytest.mark.live_test_only @@ -81,17 +81,17 @@ def _send_message(self): priority = ChatMessagePriority.NORMAL content = 'hello world' sender_display_name = 'sender name' - create_message_result = self.chat_thread_client.send_message( + create_message_result_id = self.chat_thread_client.send_message( content, priority=priority, sender_display_name=sender_display_name) - self.message_id = create_message_result.id + self.message_id = create_message_result_id @pytest.mark.live_test_only - def test_update_thread(self): + def test_update_topic(self): self._create_thread() topic = "update topic" - self.chat_thread_client.update_thread(topic=topic) + self.chat_thread_client.update_topic(topic=topic) @pytest.mark.live_test_only def test_send_message(self): @@ -101,12 +101,12 @@ def test_send_message(self): content = 'hello world' sender_display_name = 'sender name' - create_message_result = self.chat_thread_client.send_message( + create_message_result_id = self.chat_thread_client.send_message( content, priority=priority, sender_display_name=sender_display_name) - assert create_message_result.id is not None + assert create_message_result_id is not None @pytest.mark.live_test_only def test_get_message(self): @@ -144,49 +144,62 @@ def test_delete_message(self): self.chat_thread_client.delete_message(self.message_id) @pytest.mark.live_test_only - def test_list_members(self): + def test_list_participants(self): self._create_thread() if self.is_live: time.sleep(2) - chat_thread_members = self.chat_thread_client.list_members() + chat_thread_participants = self.chat_thread_client.list_participants() - for chat_thread_member_page in chat_thread_members.by_page(): - li = list(chat_thread_member_page) + for chat_thread_participant_page in chat_thread_participants.by_page(): + li = list(chat_thread_participant_page) assert len(li) == 1 li[0].user.id = self.user.identifier @pytest.mark.live_test_only - def test_add_members(self): + def test_add_participant(self): self._create_thread() share_history_time = datetime.utcnow() share_history_time = share_history_time.replace(tzinfo=TZ_UTC) - new_member = ChatThreadMember( + new_participant = ChatThreadParticipant( + user=self.new_user, + display_name='name', + share_history_time=share_history_time) + + self.chat_thread_client.add_participant(new_participant) + + @pytest.mark.live_test_only + def test_add_participants(self): + self._create_thread() + + share_history_time = datetime.utcnow() + share_history_time = share_history_time.replace(tzinfo=TZ_UTC) + new_participant = ChatThreadParticipant( user=self.new_user, display_name='name', share_history_time=share_history_time) - members = [new_member] + participants = [new_participant] - self.chat_thread_client.add_members(members) + self.chat_thread_client.add_participants(participants) @pytest.mark.live_test_only - def test_remove_member(self): + def test_remove_participant(self): self._create_thread() - # add member first + # add participant first share_history_time = datetime.utcnow() share_history_time = share_history_time.replace(tzinfo=TZ_UTC) - new_member = ChatThreadMember( + new_participant = ChatThreadParticipant( user=self.new_user, display_name='name', share_history_time=share_history_time) - members = [new_member] + participants = [new_participant] - self.chat_thread_client.add_members(members) + self.chat_thread_client.add_participants(participants) - # test remove member - self.chat_thread_client.remove_member(self.new_user) + # test remove participant + self.chat_thread_client.remove_participant(self.new_user) @pytest.mark.live_test_only def test_send_typing_notification(self): diff --git a/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_e2e_async.py b/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_e2e_async.py index aea980942a7d..0a4d4bc22cf9 100644 --- a/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_e2e_async.py +++ b/sdk/communication/azure-communication-chat/tests/test_chat_thread_client_e2e_async.py @@ -15,7 +15,7 @@ CommunicationUserCredential ) from azure.communication.chat import ( - ChatThreadMember, + ChatThreadParticipant, ChatMessagePriority ) from azure.communication.administration._shared.utils import parse_connection_str @@ -31,7 +31,7 @@ def setUp(self): super(ChatThreadClientTestAsync, self).setUp() self.recording_processors.extend([ - BodyReplacerProcessor(keys=["id", "token", "senderId", "chatMessageId", "nextLink", "members", "multipleStatus", "value"]), + BodyReplacerProcessor(keys=["id", "token", "senderId", "chatMessageId", "nextLink", "participants", "multipleStatus", "value"]), URIIdentityReplacer(), ResponseReplacerProcessor(keys=[self._resource_name]), ChatURIReplacer()]) @@ -65,12 +65,12 @@ async def _create_thread(self): topic = "test topic" share_history_time = datetime.utcnow() share_history_time = share_history_time.replace(tzinfo=TZ_UTC) - members = [ChatThreadMember( + participants = [ChatThreadParticipant( user=self.user, display_name='name', share_history_time=share_history_time )] - self.chat_thread_client = await self.chat_client.create_chat_thread(topic, members) + self.chat_thread_client = await self.chat_client.create_chat_thread(topic, participants) self.thread_id = self.chat_thread_client.thread_id async def _send_message(self): @@ -78,21 +78,21 @@ async def _send_message(self): priority = ChatMessagePriority.NORMAL content = 'hello world' sender_display_name = 'sender name' - create_message_result = await self.chat_thread_client.send_message( + create_message_result_id = await self.chat_thread_client.send_message( content, priority=priority, sender_display_name=sender_display_name) - self.message_id = create_message_result.id + self.message_id = create_message_result_id @pytest.mark.live_test_only @AsyncCommunicationTestCase.await_prepared_test - async def test_update_thread(self): + async def test_update_topic(self): async with self.chat_client: await self._create_thread() topic = "update topic" async with self.chat_thread_client: - await self.chat_thread_client.update_thread(topic=topic) + await self.chat_thread_client.update_topic(topic=topic) # delete chat threads if not self.is_playback(): @@ -109,12 +109,12 @@ async def test_send_message(self): content = 'hello world' sender_display_name = 'sender name' - create_message_result = await self.chat_thread_client.send_message( + create_message_result_id = await self.chat_thread_client.send_message( content, priority=priority, sender_display_name=sender_display_name) - self.assertTrue(create_message_result.id) + self.assertTrue(create_message_result_id) # delete chat threads if not self.is_playback(): @@ -191,15 +191,15 @@ async def test_delete_message(self): @pytest.mark.live_test_only @AsyncCommunicationTestCase.await_prepared_test - async def test_list_members(self): + async def test_list_participants(self): async with self.chat_client: await self._create_thread() async with self.chat_thread_client: - chat_thread_members = self.chat_thread_client.list_members() + chat_thread_participants = self.chat_thread_client.list_participants() items = [] - async for item in chat_thread_members: + async for item in chat_thread_participants: items.append(item) assert len(items) == 1 @@ -210,44 +210,63 @@ async def test_list_members(self): @pytest.mark.live_test_only @AsyncCommunicationTestCase.await_prepared_test - async def test_add_members(self): + async def test_add_participant(self): async with self.chat_client: await self._create_thread() async with self.chat_thread_client: share_history_time = datetime.utcnow() share_history_time = share_history_time.replace(tzinfo=TZ_UTC) - new_member = ChatThreadMember( + new_participant = ChatThreadParticipant( + user=self.new_user, + display_name='name', + share_history_time=share_history_time) + + await self.chat_thread_client.add_participant(new_participant) + + if not self.is_playback(): + await self.chat_client.delete_chat_thread(self.thread_id) + + @pytest.mark.live_test_only + @AsyncCommunicationTestCase.await_prepared_test + async def test_add_participants(self): + async with self.chat_client: + await self._create_thread() + + async with self.chat_thread_client: + share_history_time = datetime.utcnow() + share_history_time = share_history_time.replace(tzinfo=TZ_UTC) + new_participant = ChatThreadParticipant( user=self.new_user, display_name='name', share_history_time=share_history_time) - members = [new_member] + participants = [new_participant] - await self.chat_thread_client.add_members(members) + await self.chat_thread_client.add_participants(participants) if not self.is_playback(): await self.chat_client.delete_chat_thread(self.thread_id) @pytest.mark.live_test_only @AsyncCommunicationTestCase.await_prepared_test - async def test_remove_member(self): + async def test_remove_participant(self): async with self.chat_client: await self._create_thread() async with self.chat_thread_client: - # add member first + # add participant first share_history_time = datetime.utcnow() share_history_time = share_history_time.replace(tzinfo=TZ_UTC) - new_member = ChatThreadMember( + new_participant = ChatThreadParticipant( user=self.new_user, display_name='name', share_history_time=share_history_time) - members = [new_member] + participants = [new_participant] - await self.chat_thread_client.add_members(members) + await self.chat_thread_client.add_participants(participants) - # test remove member - await self.chat_thread_client.remove_member(self.new_user) + # test remove participant + await self.chat_thread_client.remove_participant(self.new_user) if not self.is_playback(): await self.chat_client.delete_chat_thread(self.thread_id)