cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
898
Views
2
Helpful
3
Replies

CUCM, UDP associate to application user using AXL SOAP SQL

jhongrack-choi
Level 1
Level 1

We have two types of devices for agent that UDP (EM profile) and Jabber, and need associate the devices to pguser (application user)
1) I can associate the devices using AXL 'updateAppuser' but I need get all existing devices and associate all again with the new devices. I don't want to this way because it requires re-association all whenever execute 'updateAppuser'
2) I can run SQL with AXL SOAP request but found problem with UDP
-Jabber can associate to the pguser with a syntax 'insert into applicationuserdevicemap (pkid,fkapplicationuser,fkdevice,tkuserassociation)' Jabber appeared on the controlled devices
-UDP case, no errors with the syntax but not appear on the 'CTI Controlled Device Profiles' section. If I run getAppuser after SQL insert, the UDP found from 'Controlled Devices' section

How run a SQL using AXL SOAP to associate UDP to pguser and appear on the 'CTI Controlled Device Profiles'?

Thanks, John Choi

1 Accepted Solution

Accepted Solutions

dstaudt
Cisco Employee
Cisco Employee

The below example works for me on CUCM v14:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/14.0">
   <soapenv:Header/>
   <soapenv:Body>
      <ns:executeSQLUpdate sequence="1">
         <sql>INSERT INTO applicationuserdevicemap (pkid,fkdevice,fkapplicationuser,tkuserassociation)
              VALUES (newid(),"dce13673-e174-064d-0234-9be199acdd0c","0085d951-9f27-a128-e2f7-378783caffc5",7);
              INSERT INTO applicationuserdevicemap (pkid,fkdevice,fkapplicationuser,tkuserassociation)
              VALUES (newid(),"736fac3b-b193-eeee-73b8-5e27f7230b45","0085d951-9f27-a128-e2f7-378783caffc5",1);
         </sql>
      </ns:executeSQLUpdate>
   </soapenv:Body>
</soapenv:Envelope>

Result in CUCM admin:

dstaudt_0-1688595480750.png

Perhaps are you not setting tkuserassociation as "7" for the EM profile..?

View solution in original post

3 Replies 3

dstaudt
Cisco Employee
Cisco Employee

The below example works for me on CUCM v14:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/14.0">
   <soapenv:Header/>
   <soapenv:Body>
      <ns:executeSQLUpdate sequence="1">
         <sql>INSERT INTO applicationuserdevicemap (pkid,fkdevice,fkapplicationuser,tkuserassociation)
              VALUES (newid(),"dce13673-e174-064d-0234-9be199acdd0c","0085d951-9f27-a128-e2f7-378783caffc5",7);
              INSERT INTO applicationuserdevicemap (pkid,fkdevice,fkapplicationuser,tkuserassociation)
              VALUES (newid(),"736fac3b-b193-eeee-73b8-5e27f7230b45","0085d951-9f27-a128-e2f7-378783caffc5",1);
         </sql>
      </ns:executeSQLUpdate>
   </soapenv:Body>
</soapenv:Envelope>

Result in CUCM admin:

dstaudt_0-1688595480750.png

Perhaps are you not setting tkuserassociation as "7" for the EM profile..?

Hi Dstaudt, I'm working with CUCM 12.5 and resolved with 'tkuserassociation as 7'. Can I have a link explaining the value (ex, 7=UDP)?

 

 

By convention, fields named tkXXX refer to corresponding enum tables named typeXXX, where the actual enums are available:

dstaudt_0-1688676302767.png

Also, I looked at the applicationuserdevicemap table for a user where I had manually added both device type associations, so I knew for sure which enum mapped to each:

dstaudt_1-1688676471472.png