// Copyright (c) Microsoft Corporation. // Licensed under the MIT License. using Microsoft.Bot.Connector; using Microsoft.Rest; using Newtonsoft.Json; namespace Microsoft.Teams.Apps.BotBuilder { /// /// Provides a stub implementation of for compatibility with Bot Framework SDK. /// /// /// This class serves as a minimal adapter to satisfy Bot Framework's requirement for an IConnectorClient instance. /// Only the property is implemented; all other members throw . /// This design allows legacy bots to access conversation operations through the CompatConversations adapter without /// requiring full implementation of unused connector client features. /// /// The conversations adapter that handles conversation-related operations. internal sealed class CompatConnectorClient(CompatConversations conversations) : IConnectorClient { /// /// Gets the conversations interface for managing bot conversations. /// public IConversations Conversations => conversations; public Uri BaseUri { get => throw new NotImplementedException(); set => throw new NotImplementedException(); } public JsonSerializerSettings SerializationSettings => throw new NotImplementedException(); public JsonSerializerSettings DeserializationSettings => throw new NotImplementedException(); public ServiceClientCredentials Credentials => throw new NotImplementedException(); public IAttachments Attachments => throw new NotImplementedException(); public void Dispose() { // No resources to dispose; method required by IConnectorClient. } } }