web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Service | Customer Service, Contact Center, Fie...
Unanswered

CCaaS_AcceptConversation: Operation is not supported in Open state (Microsoft Teams Extensibility)

(0) ShareShare
ReportReport
Posted on by 4
Hi,
 
Our organisation is currently implementing Dynamics 365 Contact Center but we've come across a very strange bug/issue during development and testing. We have configured voice via Microsoft Teams extensibility to route inbound voice calls but we are facing an issue whereby an agent will accept the incoming call from within our CRM environment with the accept toast notification, but when doing this in the background there is a 400 Bad Request API error occurring on the following endpoint (our sandbox environment URL removed):
 
The payload data being sent in the request:
 
{
  "ApiVersion": "1.0",
  "SessionId": "c28b2a9a-bc32-4541-98b7-10c7614361d7"
}
 
The error response being returned by the original request is:
 
{
  "error": {
    "code": "0x80048d0b",
    "message": "CoreServices Request returned error response. Exception: The remote server returned an error: (400) Bad Request., Status: ProtocolError, Status Code : BadRequest, Status Description : Bad Request, Response: {\"errorCode\":400801,\"message\":\"API Error : Operation is not supported in Open state\"}",
    "@Microsoft.PowerApps.CDS.ErrorDetails.OperationStatus": "0",
    "@Microsoft.PowerApps.CDS.ErrorDetails.SubErrorCode": "400801",
    "@Microsoft.PowerApps.CDS.ErrorDetails.Plugin.ExceptionFromPluginExecute": "Microsoft.Dynamics.OmnichannelCCaaSApi.Plugins.AcceptConversationAPIPlugin",
    "@Microsoft.PowerApps.CDS.ErrorDetails.Plugin.ExceptionRetriable": "False",
    "@Microsoft.PowerApps.CDS.ErrorDetails.Plugin.ExceptionSource": "PluginExecution",
    "@Microsoft.PowerApps.CDS.ErrorDetails.Plugin.OriginalException": "PluginExecution",
    "@Microsoft.PowerApps.CDS.ErrorDetails.Plugin.PluginTrace": "",
    "@Microsoft.PowerApps.CDS.HelpLink": "http://go.microsoft.com/fwlink/?LinkID=398563&error=Microsoft.Crm.CrmException%3a80048d0b&client=platform",
    "@Microsoft.PowerApps.CDS.TraceText": "\r\n[Microsoft.Dynamics.OmnichannelCCaaSApi.Plugins: Microsoft.Dynamics.OmnichannelCCaaSApi.Plugins.AcceptConversationAPIPlugin]\r\n[7909b123-ef14-f111-8342-6045bdf1fd43: CustomApi 'CCaaS_AcceptConversation' implementation]\r\n\r\n",
    "@Microsoft.PowerApps.CDS.InnerError.Message": "CoreServices Request returned error response. Exception: The remote server returned an error: (400) Bad Request., Status: ProtocolError, Status Code : BadRequest, Status Description : Bad Request, Response: {\"errorCode\":400801,\"message\":\"API Error : Operation is not supported in Open state\"}"
  }
}
The fwlink unfortunately just goes to the general Dynamics 365 support page and searching the specific error code being referenced does not provide any specific information on this error. We have an open ticket with Microsoft about this issue.

The main factor appears to be related to the conversation state and CCaaS_AcceptConversation, given the error: "Operation is not supported in Open state", but we don't know the actual cause of the error. Various attempts at trying to make sense of the error with AI tools suggest a timing issue with the Conversation State being mismatched and a potential race condition, but it could be completely wrong.

The issue appears to be specific to when routing calls via Microsoft Teams Extensibility, if we use an alternative option such as ACS instead, things seem to work fine without issues, so we have narrowed it down to being somehow related to Microsoft Teams in some form, but have no idea configuration wise where we can begin to try and fix this.

We have checked that the appropriate resource groups have been configured in Azure and are correct when deploying the Teams number and testing calls. Clearly it is working as the call is being routed to our CRM environment, but as soon as you accept a call, this 400 error occurs.

Has anyone encountered this issue or might have any further information that could help diagnose or troubleshoot the issue, with more specifics? We are at a loss as to why we are encountering this, with no much information to go on.

Thanks,

James
 
 
I have the same question (0)
  • James White Profile Picture
    4 on at
    Based on further testing, if the conversation is manually assigned to an agent in the Conversations view before clicking the accept notification for the voice call, this seems to prevent the 400 error. This isn't a solution, but allowed to proceed further, however the voice call never connects by the looks of it.
     
    Capturing logs/console logging, we seem to have the following issues:

    1. Invalid cancellation token
    Failed to cancel the invite notification
    Uncaught (in promise) Error: Max retry attempts reached: 3.
    Last error: {"message":"Invalid cancellation token","msdyn_name":"cancelEvent"}
    2. "Store or directline not initialized yet" — repeated UI rendering failures are observed. This warning fires repeatedly throughout the session, meaning the conversation body component kept trying to render before the DirectLine/ACS store was ready.
     
    3. Voice call never connects — polling loop runs indefinitely. Despite the session being up, the system entered an endless ACS polling loop (ACS_SEND_POLLING_REQUEST / ACS_CANCEL_POLLING_CALLBACK / ACS_CREATE_POLLING_CALLBACK cycling every ~1 second). No voice call state transition happened — the call stayed in a "connecting" banner state with no CallConnected event ever arriving.
     
    Example of repeated polling events occurring:
    [CONVCTRL]  {Event: 'ACS_SEND_POLLING_REQUEST', Description: 'ACS Adapter: Send polling request', TimeStamp: '2026-04-17T07:56:08.435Z', ChatThreadId: '19:acsV2_AJZSYFrcLwiFRk6Qba87Pc3jYJM41Z7HvlH_XmtLa-E1@thread.v2', ACSRequesterUserId: '8:acs:2f78b44b-cc35-4e61-a9e5-cbdcc5fcfd89_0000002e-362b-9ca5-e710-4c3a0d007fad'}
    [CONVCTRL]  {Event: 'ACS_CANCEL_POLLING_CALLBACK', Description: 'ACS Adapter: Canceling polling callback with Id 852', TimeStamp: '2026-04-17T07:56:08.591Z', ChatThreadId: '19:acsV2_AJZSYFrcLwiFRk6Qba87Pc3jYJM41Z7HvlH_XmtLa-E1@thread.v2', ACSRequesterUserId: '8:acs:2f78b44b-cc35-4e61-a9e5-cbdcc5fcfd89_0000002e-362b-9ca5-e710-4c3a0d007fad'}
    [CONVCTRL]  {Event: 'ACS_CREATE_POLLING_CALLBACK', Description: 'ACS Adapter: Created polling callback with Id 855', TimeStamp: '2026-04-17T07:56:08.592Z', ChatThreadId: '19:acsV2_AJZSYFrcLwiFRk6Qba87Pc3jYJM41Z7HvlH_XmtLa-E1@thread.v2', ACSRequesterUserId: '8:acs:2f78b44b-cc35-4e61-a9e5-cbdcc5fcfd89_0000002e-362b-9ca5-e710-4c3a0d007fad'}

    Then after 60 seconds, a timeout event is raised.
    [CONVCTRL] SCENARIO_FAILED: SCENARIO_INBOUND_ACCEPT2CONNECTED {ScenarioUniqueId: '630b0b4d-cdfb-4b40-9d1e-e32f36466c9a', ScenarioEventType: 2, Duration: 61240, ScenarioStartTime: 1776412510119, ScenarioEndTime: 1776412571359, â€¦}
    boot.js?ver=b60103b68ece336aa70d:2 [CC] SCENARIO_FAILED: SCENARIO_INBOUND_ACCEPT2CONNECTED {details: 'Taking too long to connect to the call', waitTimeInMs: 60000, closeConnectionScenarioReason: 'takingTooLongToConnectToCall', incomingCallTimestamp: undefined, ccaasAcceptConversation: {…}, â€¦} 
    While this doesn't provide any answers, it seems from the moment the accept action is done the call is never fully connected and therefore points to something in this area.

    The session is never fully established, but there is clearly some form of connection because the accept notification is raised, the joining and leaving of an active conversation is logged in the session. If the voice call is ended by the user, this is detected. If the conversation is forced closed from the contact cenre side, this is stated on the user end saying "Agent has ended the call" and the calls ends, so there is clearly a connection, just that is never fully connects when accepting conversations.
  • James White Profile Picture
    4 on at
    Additionally, plugin trace logging for the identified Plug-in which is coming from the CCaaS solution: Microsoft.Dynamics.OmnichannelCCaaSApi.Plugins.AcceptConversationAPIPlugin shows the CCaaS_AcceptConversation web API call failing, but does not provide further information.
    System.ServiceModel.FaultException`1[Microsoft.Xrm.Sdk.OrganizationServiceFault]: CoreServices Request returned error response. Exception: The remote server returned an error: (400) Bad Request., Status: ProtocolError, Status Code : BadRequest, Status Description : Bad Request, Response: [Redacted-Json]
    at Microsoft.Xrm.RemotePlugin.Grpc.SandboxFabricGrpcClient.ExecutePluginInternal(IRemotePluginRequest pluginRequest, ExecuteRequest executeRequest, Guid executionId, ISandboxFabricDuplexCommunicationHandler communicationHandler, Boolean returnTraceInfo, Guid organizationId, SandboxFabricCallTracker sandboxFabricCallTracker) +0x5d7
    at Microsoft.Xrm.RemotePlugin.Grpc.SandboxFabricGrpcClient.ExecutePlugin(IRemotePluginRequest pluginRequest, IPluginExecutionContext executionContext, IPluginTracingService pluginTracingService, ISandboxFabricDuplexCommunicationHandler communicationHandler, ISet`1 earlySerializedPropertiesList, SandboxFabricCallTracker sandboxFabricCallTracker, ISandboxMemoryStreamProvider memoryStreamProvider) +0x327
    at Microsoft.Xrm.RemotePlugin.Grpc.SandboxFabricCodeUnit.ExecutePlugin(ILifetimeScope scope, IExecutionContext context, ISandboxFabricDuplexCommunicationHandler communicationHandler, ISandboxClientSettings sandboxClientSettings, SandboxFabricCallTracker& sandboxFabricCallTracker, ISandboxFabricGrpcClient sandboxFabricGrpcClient, ISandboxMemoryStreamProvider memoryStreamProvider) +0x16
    at Microsoft.Xrm.RemotePlugin.Grpc.SandboxFabricCodeUnit.Execute(ILifetimeScope scope, IExecutionContext context, SandboxFabricCallTracker& sandboxFabricCallTracker, ISandboxMemoryStreamProvider memoryStreamProvider) +0xf8
    at Castle.Proxies.Invocations.ISandboxFabricCodeUnit_Execute.InvokeMethodOnTarget() +0x13
    at Castle.DynamicProxy.AbstractInvocation.Proceed() +0x2d
    at Microsoft.Xrm.RemotePlugin.Client.Interceptors.SandboxFabricPluginTraceInterceptor.Intercept(IInvocation invocation, IExecutionContext context, SandboxFabricCallTracker sandboxFabricCallTracker) +0x1f
    The redacted JSON is the original 400 error posted, which was obtained via network inspection/proxy sniffing.

    I feel this error is a symptom of something else, further up the chain. We deployed a very minimal/bare Dynamics 365 environment to rule out any solutions/configuration/customisation conflicts, but we still encountered the same issues in a fresh environment. We have to conclude that something with the Microsoft Teams Extensibility is the problem, given alternative numbers configured via Azure Communication Services work fine.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Service | Customer Service, Contact Center, Field Service, Guides

#1
11manish Profile Picture

11manish 35

#1
Jimmy Passeti Profile Picture

Jimmy Passeti 35 Most Valuable Professional

#3
Mallesh Deshapaga Profile Picture

Mallesh Deshapaga 32

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans