我用于自定义连接器的宽大JSON如下所示:
"/roles({roleid})/Microsoft.Dynamics.CRM.RetrieveRolePrivilegesRole": {
"post": {
"responses": {
"200": {
"description": "Success Operation"
}
},
"parameters": [
{
"name": "roleid",
"in": "path",
"type": "string",
"required": true
}
],
"operationId": "_POST_RetrieveRolePrivilegesRole",
"description": "Retrieve Role Privileges",
"summary": "Retrieve Role Privileges"
}
},
当我用它创建一个自定义连接器并测试呼叫时,出现以下错误:
{
"error": {
"code": "0x0",
"message": "Resource not found for the segment 'Microsoft.Dynamics.CRM.RetrieveRolePrivilegesRole'",
"innererror": {
"message": "Resource not found for the segment 'Microsoft.Dynamics.CRM.RetrieveRolePrivilegesRole'",
"type": "Microsoft.Crm.CrmHttpException",
"stacktrace": " at Microsoft.Crm.Extensibility.ODataV4.Routing.CrmODataRoutingConvention.ThrowUnresolvedSegmentException(ODataPath odataPath)\r\n at Microsoft.Crm.Extensibility.ODataV4.Routing.CrmODataRoutingConvention.SelectActionImplementation(ODataPath odataPath, HttpControllerContext controllerContext, ILookup`2 actionMap)\r\n at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute[TResult](ILogger logger, EventId eventId, ActivityType activityType, Func`1 func, IEnumerable`1 additionalCustomProperties)\r\n at Microsoft.Xrm.Telemetry.XrmTelemetryExtensions.Execute[TResult](ILogger logger, XrmTelemetryActivityType activityType, Func`1 func)\r\n at System.Web.OData.Routing.ODataActionSelector.SelectAction(HttpControllerContext controllerContext)\r\n at System.Web.Http.ApiController.ExecuteAsync(HttpControllerContext controllerContext, CancellationToken cancellationToken)\r\n at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__1.MoveNext()"
}
}
}