cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
212
Views
0
Helpful
0
Comments
cdnadmin
Community Member
This document was generated from CDN thread

Created by: Lizabeth Li on 19-10-2010 10:35:18 PM
Hi, I'm trying to add a user device profile using addDeviceProfile, but I'm getting an error in response.
 
Here's my request:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header/>
 <soapenv:Body>
  <ns:addDeviceProfile sequence="1">
   <deviceProfile>
    <name>First.Last DP</name>
    <description>Device Profile for First.Last</description>
    <product>Cisco 7975</product>
    <class>Device Profile</class>
    <protocol>SCCP</protocol>
    <protocolSide>User</protocolSide>
    <phoneTemplateName>Standard 7975 SCCP</phoneTemplateName>
    <userLocale>English United Status</userLocale>
    <loginUserId>First.Last</loginUserId>
    <emccCallingSearchSpace>Unrestricted</emccCallingSearchSpace>
    <alwaysUsePrimeLine>Off</alwaysUsePrimeLine>
    <alwaysUsePrimeLineForVoiceMessage>Off</alwaysUsePrimeLineForVoiceMessage>
    <lines>
     <line>
      <index>0</index>
      <dirn>
       <pattern>1503</pattern>
       <routePartitionName>AllUsers</routePartitionName>
      </dirn>
      <ringSettingIdlePickupAlert>Ring Once</ringSettingIdlePickupAlert>
      <ringSettingActivePickupAlert>Ring Once</ringSettingActivePickupAlert>
      <mwlPolicy>None</mwlPolicy>
      <maxNumCalls>200</maxNumCalls>
      <callInfoDisplay>
       <redirectedNumber>f</redirectedNumber>
       <callerNumber>t</callerNumber>
      </callInfoDisplay>
      <monitoringCssName>Unrestricted</monitoringCssName>
      <audibleMwi>On</audibleMwi>
      <associatedEndUsers>
       <enduser>
        <userId>First.Last</userId>
       </enduser>
      </associatedEndUsers>
      <missedCallLogging>t</missedCallLogging>
     </line>
     <lineIdentifier>
      <directoryNumber>1503</directoryNumber>
      <routePartitionName>AllUsers</routePartitionName>
     </lineIdentifier>
    </lines>
   </deviceProfile>
  </ns:addDeviceProfile>
 </soapenv:Body>
</soapenv:Envelope>
In response, I get:
<?xml version='1.0' encoding='UTF-8'?><soapenv:Envelope xmlns:soapenv="[url=http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Body><soapenv:Fault><faultcode>soapenv:Client</faultcode><faultstring>Cannot]http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Body><soapenv:Fault><faultcode>soapenv:Client</faultcode><faultstring>Cannot insert a null into column (devicenumplanmap.fknumplan).</faultstring><detail><axlError><axlcode>-391</axlcode><axlmessage>Cannot insert a null into column (devicenumplanmap.fknumplan).</axlmessage><request>addDeviceProfile</request></axlError></detail></soapenv:Fault></soapenv:Body></soapenv:Envelope>
 
Is there a prerequisite before adding a device profile and associating a line with it?  Can anyone identify what I'm doing wrong?
 
Thanks.

Subject: RE: Issue adding a device profile
Replied by: Sascha Monteiro on 20-10-2010 02:40:51 AM
Hi,
You need to create the line first, then use uuid to apply it to the device profile

Subject: RE: Issue adding a device profile
Replied by: Lizabeth Li on 20-10-2010 11:15:12 PM
How do you go about doing that?  I tried doing addDeviceProfile:
 
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header/>
 <soap<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header/>
 <soapenv:Body>
  <ns:addDeviceProfile sequence="1">
   <deviceProfile>
    <name>First.Last DP</name>
    <description>Device Profile for First.Last</description>
    <product>Cisco 7975</product>
    <class>Device Profile</class>
    <protocol>SCCP</protocol>
    <protocolSide>User</protocolSide>
    <phoneTemplateName>Standard 7975 SCCP</phoneTemplateName>
    <userLocale>English United Status</userLocale>
    <loginUserId>First.Last</loginUserId>
    <emccCallingSearchSpace>Unrestricted</emccCallingSearchSpace>
    <alwaysUsePrimeLine>Off</alwaysUsePrimeLine>
    <alwaysUsePrimeLineForVoiceMessage>Off</alwaysUsePrimeLineForVoiceMessage>
   </deviceProfile>
  </ns:addDeviceProfile>
 </soapenv:Body>
</soapenv:Envelope>
That was successful.  Then I tried to do updateDeviceProfile, adding in the line:
 
<soapenv:Envelope
 xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
 xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header />
 <soapenv:Body>
  <ns:updateDeviceProfile sequence="1">
   <name>First.Last DP</name>
   <lines>
    <line>
     <index>0</index>
     <dirn>
      <pattern>1503</pattern>
      <routePartitionName>AllUsers</routePartitionName>
     </dirn>
     <ringSettingIdlePickupAlert>Ring Once</ringSettingIdlePickupAlert>
     <mwlPolicy>None</mwlPolicy>
     <maxNumCalls>200</maxNumCalls>
     <callInfoDisplay>
      <redirectedNumber>f</redirectedNumber>
      <callerNumber>t</callerNumber>
     </callInfoDisplay>
     <monitoringCssName>Unrestricted</monitoringCssName>
     <audibleMwi>On</audibleMwi>
     <associatedEndUsers>
      <enduser>
       <userId>First.Last</userId>
      </enduser>
     </associatedEndUsers>
     <missedCallLogging>t</missedCallLogging>
    </line>
    <lineIdentifier>
     <directoryNumber>1503</directoryNumber>
     <routePartitionName>AllUsers</routePartitionName>
    </lineIdentifier>
   </lines>
  </ns:updateDeviceProfile>
 </soapenv:Body>
</soapenv:Envelope>
But that gave me the same error as before.  So then I tried to do addLine to add the line separately:
<soapenv:Envelope
 xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
 xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header />
 <soapenv:Body>
  <ns:addLine>
   <line>
    <description>1503</description>
    <pattern>1503</pattern>
    <routePartitionName>AllUsers</routePartitionName>
    <autoAnswer>f</autoAnswer>
    <presenceGroupName>Standard Presence group</presenceGroupName>
   </line>
  </ns:addLine>
 </soapenv:Body>
</soapenv:Envelope>
 
That gave me an even more cryptic error:
<?xml version='1.0' encoding='UTF-8'?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Body><soapenv:Fault><faultcode>soapenv:Server</faultcode><faultstring></faultstring><detail><axlError><axlcode>-1</axlcode><axlmessage></axlmessage><request>addPhone</request></axlError></detail></s...>
 
Is this the process you were suggesting?  What am I missing?
 
Thanks.
 

Hi,
You need to create the line first, then use uuid to apply it to the device profile

Subject: RE: Issue adding a device profile
Replied by: Lizabeth Li on 21-10-2010 05:44:36 PM
Figured it out.  the index in the updateDeviceProfile needs to be 1 or 2, not 0.  In my opinion, this should be a constraint - the request with index 0 goes through and is successful, but when I check the device profile in CUCM, I get "Unmapped Exception."  Instead, the request with the illegal index should not be allowed to go through at all.
 

How do you go about doing that?  I tried doing addDeviceProfile:
 
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header/>
 <soap<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header/>
 <soapenv:Body>
  <ns:addDeviceProfile sequence="1">
   <deviceProfile>
    <name>First.Last DP</name>
    <description>Device Profile for First.Last</description>
    <product>Cisco 7975</product>
    <class>Device Profile</class>
    <protocol>SCCP</protocol>
    <protocolSide>User</protocolSide>
    <phoneTemplateName>Standard 7975 SCCP</phoneTemplateName>
    <userLocale>English United Status</userLocale>
    <loginUserId>First.Last</loginUserId>
    <emccCallingSearchSpace>Unrestricted</emccCallingSearchSpace>
    <alwaysUsePrimeLine>Off</alwaysUsePrimeLine>
    <alwaysUsePrimeLineForVoiceMessage>Off</alwaysUsePrimeLineForVoiceMessage>
   </deviceProfile>
  </ns:addDeviceProfile>
 </soapenv:Body>
</soapenv:Envelope>
That was successful.  Then I tried to do updateDeviceProfile, adding in the line:
 
<soapenv:Envelope
 xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
 xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header />
 <soapenv:Body>
  <ns:updateDeviceProfile sequence="1">
   <name>First.Last DP</name>
   <lines>
    <line>
     <index>0</index>
     <dirn>
      <pattern>1503</pattern>
      <routePartitionName>AllUsers</routePartitionName>
     </dirn>
     <ringSettingIdlePickupAlert>Ring Once</ringSettingIdlePickupAlert>
     <mwlPolicy>None</mwlPolicy>
     <maxNumCalls>200</maxNumCalls>
     <callInfoDisplay>
      <redirectedNumber>f</redirectedNumber>
      <callerNumber>t</callerNumber>
     </callInfoDisplay>
     <monitoringCssName>Unrestricted</monitoringCssName>
     <audibleMwi>On</audibleMwi>
     <associatedEndUsers>
      <enduser>
       <userId>First.Last</userId>
      </enduser>
     </associatedEndUsers>
     <missedCallLogging>t</missedCallLogging>
    </line>
    <lineIdentifier>
     <directoryNumber>1503</directoryNumber>
     <routePartitionName>AllUsers</routePartitionName>
    </lineIdentifier>
   </lines>
  </ns:updateDeviceProfile>
 </soapenv:Body>
</soapenv:Envelope>
But that gave me the same error as before.  So then I tried to do addLine to add the line separately:
<soapenv:Envelope
 xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
 xmlns:ns="http://www.cisco.com/AXL/API/8.0">
 <soapenv:Header />
 <soapenv:Body>
  <ns:addLine>
   <line>
    <description>1503</description>
    <pattern>1503</pattern>
    <routePartitionName>AllUsers</routePartitionName>
    <autoAnswer>f</autoAnswer>
    <presenceGroupName>Standard Presence group</presenceGroupName>
   </line>
  </ns:addLine>
 </soapenv:Body>
</soapenv:Envelope>
 
That gave me an even more cryptic error:
<?xml version='1.0' encoding='UTF-8'?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Body><soapenv:Fault><faultcode>soapenv:Server</faultcode><faultstring></faultstring><detail><axlError><axlcode>-1</axlcode><axlmessage></axlmessage><request>addPhone</request></axlError></detail></s...>
 
Is this the process you were suggesting?  What am I missing?
 
Thanks.
 

Hi,
You need to create the line first, then use uuid to apply it to the device profile
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:

Quick Links