From 450306b0ba82b489b2a77d2b8b083ce4c81baf43 Mon Sep 17 00:00:00 2001 From: Ganapathi Diddi Date: Thu, 18 Jul 2024 21:28:32 +0530 Subject: [PATCH] Add conversation id header in skill requests --- .../botbuilder/integration/aiohttp/bot_framework_http_client.py | 1 + .../aio/operations_async/_conversations_operations_async.py | 1 + .../connector/operations/_conversations_operations.py | 1 + 3 files changed, 3 insertions(+) diff --git a/libraries/botbuilder-integration-aiohttp/botbuilder/integration/aiohttp/bot_framework_http_client.py b/libraries/botbuilder-integration-aiohttp/botbuilder/integration/aiohttp/bot_framework_http_client.py index b09b3ac93..c57c042c2 100644 --- a/libraries/botbuilder-integration-aiohttp/botbuilder/integration/aiohttp/bot_framework_http_client.py +++ b/libraries/botbuilder-integration-aiohttp/botbuilder/integration/aiohttp/bot_framework_http_client.py @@ -116,6 +116,7 @@ async def _post_content( ) -> Tuple[int, object]: headers_dict = { "Content-type": "application/json; charset=utf-8", + "x-ms-conversation-id": activity.conversation.id, } if token: headers_dict.update( diff --git a/libraries/botframework-connector/botframework/connector/aio/operations_async/_conversations_operations_async.py b/libraries/botframework-connector/botframework/connector/aio/operations_async/_conversations_operations_async.py index e6416e42d..553248342 100644 --- a/libraries/botframework-connector/botframework/connector/aio/operations_async/_conversations_operations_async.py +++ b/libraries/botframework-connector/botframework/connector/aio/operations_async/_conversations_operations_async.py @@ -510,6 +510,7 @@ async def reply_to_activity( header_parameters = {} header_parameters["Accept"] = "application/json" header_parameters["Content-Type"] = "application/json; charset=utf-8" + header_parameters["x-ms-conversation-id"] = conversation_id if custom_headers: header_parameters.update(custom_headers) diff --git a/libraries/botframework-connector/botframework/connector/operations/_conversations_operations.py b/libraries/botframework-connector/botframework/connector/operations/_conversations_operations.py index 6834f7a28..48d3c23fc 100644 --- a/libraries/botframework-connector/botframework/connector/operations/_conversations_operations.py +++ b/libraries/botframework-connector/botframework/connector/operations/_conversations_operations.py @@ -495,6 +495,7 @@ def reply_to_activity( header_parameters = {} header_parameters["Accept"] = "application/json" header_parameters["Content-Type"] = "application/json; charset=utf-8" + header_parameters["x-ms-conversation-id"] = conversation_id if custom_headers: header_parameters.update(custom_headers)