Apologies for no posts

Hi all!

I’ve been very busy with a project at work and rebuilding and upgrading my lab.

I’ve received a few questions lately and I’d like to answer.

For changing the user PIN, I’ll see if I can get something put together sometime in the not too distant future.

As far as making the generated .cs file smaller I think that might be possible but I’ve not tried. A better option might be to write your own SOAP requests. I’ve found that in debug mode the code runs very slow but after creating the .exe it runs at an acceptable speed. We must remember that Cisco throttles requests to not degrade system performance.

Posted in Uncategorized | Leave a comment

Regarding Upload requests…

Don’t bother requesting.  I’ll not upload any of my code as I only provide examples to get you on the right track so you don’t struggle like I have.  My reasons why are numerous but the main ones are as follows:

1. I don’t need accusations that my files harmed someones production CUCM environment, their PC or their network.  It’s not worth the trouble.

2. I’ve customized a majority of my wsdl generated files beyond the point of being useful to anyone but me.  I’d be glad to offer pointers at generating your own and modifying them per the Cisco instructions but that is the only way I can help.  I’m sorry if this is a disappointment to anyone.

3. It doesn’t teach you ANYTHING.  Everyone wants answers but too many aren’t willing to work for them!

With that said, I should have some new content in the next couple of days.  Stay tuned.   I’ll be going over some useful items when dealing with LDAP integrated end users and even some tricks with remote destinations for mobility.  If you aren’t already, get familiar with the data dictionary for your version of CUCM.

 

For those having trouble generating the AXLAPIService.cs….

Create a directory to keep all your wsdl related files in.

Find your wsdl.exe file and copy (not cut) it to the location you just created.

Copy the .wsdl file and any other files Cisco says you need into this folder.

Open a command prompt and navigate to the directory you created.

type wsdl.exe followed by the file names Cisco tells you to use.

This will most likely create your .cs file.  If not, you have .net framework issues.

Posted in Uncategorized | 2 Comments

Device Profiles

Here’s one which will be important if you’re intent on using Extension Mobility.  The line association is similar to what we did previously with the phone.

AddDeviceProfileReq addUDP = new AddDeviceProfileReq();
XDeviceProfile devProf = new XDeviceProfile();
XAddOnModule dpModule = new XAddOnModule();
dpModule.model = "7916 24-Button Line Expansion Module";
dpModule.index = "1";
XAddOnModule[] dpModules = new XAddOnModule[1];
dpModules[0] = dpModule;
XSubscribedService dpAssignService = new XSubscribedService();
dpAssignService.name = "Extension Mobility";
XFkType dpAddService = new XFkType();
dpAddService.Value = "Extension Mobility";
dpAssignService.telecasterServiceName = dpAddService;
XSubscribedService[] dpPhoneService = new XSubscribedService[1];
dpPhoneService[0] = dpAssignService;
devProf.name = "DP-XXXXX";
devProf.description = "Name";
devProf.product = "Cisco 7975";
devProf.@class = "Device Profile";
devProf.protocol = "SCCP";
devProf.phoneTemplateName = buttonTemplateToClass();
devProf.softkeyTemplateName = softkeyTemplateToClass();
devProf.addOnModules = dpModules;
devProf.services = dpPhoneService;
addUDP.deviceProfile = devProf;
axl.addDeviceProfile(addUDP);

Posted in Uncategorized | Comments Off on Device Profiles

Let’s start off basic – Adding a phone with a line associated

What’s more important in a telephone system than phones and lines?  Not a very good phone system without them!  Here is a simple example of adding a new phone and a line and associating the line to the phone.  I even show you how to associate an extension mobility service and a 7916 24 line module!

An explanation.  axl is the name I’ve given AXLAPIService.  Wherever you see axl, that is what it means.

First let’s add a line.


XFkType partition = new XFkType();
partition.Value = "XXXX_PT_Phones";
XFkType vmProfile = new XFkType();
vmProfile.Value = "Default";
XCallForwardBusy fwdBusy = new XCallForwardBusy();
fwdBusy.forwardToVoiceMail = "true";
AddLineReq newLine = new AddLineReq();
XLine line = new XLine();
line.alertingName = "ALerting Name";
line.asciiAlertingName = "Alerting Name ASCII";
line.callForwardBusy = fwdBusy;
line.description = "Description";
line.pattern = "5555";
line.routePartitionName = partition;
line.voiceMailProfileName = vmProfile;
newLine.line = line;
axl.addLine(newLine);

Now let’s  prepare the information needed to associate the line to the phone.


XDirn dirn = new XDirn();
dirn.pattern = "5555";
dirn.routePartitionName = partition;
XPhoneLine phoneLine = new XPhoneLine();
phoneLine.dirn = dirn;
phoneLine.asciiLabel = "Name";
phoneLine.busyTrigger = "2";
phoneLine.display = "Name";
phoneLine.displayAscii = "Name";
phoneLine.e164Mask = "555555XXXX";
phoneLine.index = "1";
phoneLine.label = "Name";
phoneLine.maxNumCalls = "4";
XPhoneLine[] phoneLineArray = new XPhoneLine[1];
phoneLineArray[0] = phoneLine;
XPhoneLines xphoneLines = new XPhoneLines();
xphoneLines.Items = phoneLineArray;

Finally lets add the phone with an associated line.


AddPhoneReq newPhone = new AddPhoneReq();
XPhone phone = new XPhone();
XFkType devPool = new XFkType();
devPool.Value = "XXXX_DP_Dev";
XFkType css = new XFkType();
css.Value = "XXXX_CSS_Device_Unrestricted";
XFkType cdc = new XFkType();
cdc.Value = "test cdc";
XFkType buttonTemplate = new XFkType();
buttonTemplate.Value = "Standard 7975 SCCP";
XAddOnModule module = new XAddOnModule();
module.model = "7916 24-Button Line Expansion Module";
module.index = "1";
XAddOnModule[] modules = new XAddOnModule[1];
modules[0] = module;
XSubscribedService assignService = new XSubscribedService();
assignService.name = "Extension Mobility";
XFkType addService = new XFkType();
addService.Value = "Extension Mobility";
assignService.telecasterServiceName = addService;
XSubscribedService[] phoneService = new XSubscribedService[1];
phoneService[0] = assignService;
phone.name = "SEP000000111111";
phone.description = "Name";
phone.product = "Cisco 7975";
phone.@class = "Phone";
phone.protocol = "SCCP";
phone.devicePoolName = devPool;
phone.callingSearchSpaceName = css;
phone.phoneTemplateName = buttonTemplate;
phone.commonDeviceConfigName = cdc;
phone.addOnModules = modules;
phone.lines = xphoneLines;
phone.services = phoneService;
newPhone.phone = phone;
axl.addPhone(newPhone);

So, there you have it.  We have added a line, prepared the line for association and added a phone with services, lines and modules associated.

Happy programmming!

Posted in Uncategorized | Leave a comment

Hello and Welcome!

Hello everyone!  Welcome to what I hope becomes a good source for C#programmers looking for Cisco Administration XML code examples.  I’ve not found much of anything worthwhile on the internet so far and most of my code has been developed through trial and error.

My code examples will be from the AXLAPIService.cs created with the .wsdl file from Communications Manager 8.x and  the .net Framework 4.x.  The code examples I post will be verified against Communications Manager 8.0.x and 8.5.x.

The very first thing you need to do is get yourself the AXL Schema documentation from the Cisco Developer Network here: http://developer.cisco.com/web/axl/docs

Hopefully I’ll have some examples up later in the week.

Posted in Uncategorized | 2 Comments