cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1210
Views
0
Helpful
3
Replies

AXLAPIService.cs file compatible with CUCM 11.5

f.aoun
Level 1
Level 1

Requirement: sync changes made on one application to another, all the changes made on CUCM to be reflected on domain controller.

of course this can be done using CUCM AXL Api; unfortunately the issue below is blocking us.


We are facing issues generating a working proxy class for AXL API in .NET

The generated cs file using wsdl.exe executable returns error when initializing a new axl api service :

Line

AXLAPIService service = new AXLAPIService(cucm_ip,ServiceUsername,ServicePassword);

Error

System.Net.WebException: The request failed with an empty response.

   at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)

  

applying the changes mentioned in the WSDL-NET README File, we are facing the below error

Error

{System.InvalidOperationException: Unable to generate a temporary class (result=1).

error CS0030: Cannot convert type 'UpdateSoftKeySetReqAddCallStates' to 'UpdateSoftKeySetReqRemoveCallStates'

error CS0030: Cannot convert type 'UpdateSoftKeySetReqAddCallStates' to 'UpdateSoftKeySetReqCallStates'

error CS0029: Cannot implicitly convert type 'UpdateSoftKeySetReqCallStates' to 'UpdateSoftKeySetReqAddCallStates'

error CS0029: Cannot implicitly convert type 'UpdateSoftKeySetReqRemoveCallStates' to 'UpdateSoftKeySetReqAddCallStates'

We have tried multiple solutions available in the forums with no success

can you provide us with a working AXLAPIService.cs file compatible with CUCM 11.5 ? Please note the same code runs with no errors on 8.5 with the 8.5 proxy class and this is a common practice

Please find attached the original and modified proxy files

3 Replies 3

dstaudt
Cisco Employee
Cisco Employee

As it turns out, one of the XML message definitions in the AXL schema (for several versions, including 11.5(1) ) is missing some extra layering (fortunately present in most other request definitions) which causes problems with downstream WSDL compilers, notably .NET.

The problematic definition is in the AXLSoap.xsd file, for the <updateSoftKeySetReq> message, which is why this message is noted in the .NET run-time stack trace.

You should be able to simply delete (or comment out) the element set identified by <xsd:complexType name="UpdateSoftKeySetReq"> (including sub-elements), save the AXLSoap.xsd, recompile, and get it to work.

Of course tying to use the 'updateSoftKeySetReq' request in the .NET app will not be available if you just remove the definition from the schema.  I've worked through what I think a 'fixed' version of the AXLSoap.xsd might look like (for 11.5(1) ), and during some very casual testing it seems to work OK.  I'll attach it here (feel free to use it as a basis for experimentation/learning - it's definitely not an official fix or a supported version of the schema.  A defect has been opened to address this issue in the release schema.)

Also attaching a VS Community 2017, C# WCF, .NET 4.x project representing several painful hours worth of learnings gleaned getting the full WSDL compile workflow to happen using 'modern' stuff.  To be honest, in my pretty long experience, it's just way easier to use AXL via HTTP request, building the XML either as strings or via something like System.XML.Linq/XDocument - especially when working in .NET.

Defect opened for tracking: CSCvj29301

Sandro Galletti
Level 1
Level 1
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: