02-24-2015 03:03 AM
Hi
I want to do a list request on users that just returns userId and primary extension (if there's one). My requests do work, however, they all only contain the userid even though several users have primary extensions defined.
I'm adding <primaryExtension/pattern/> and <primaryExtension/routePartitionName/> to my <returnTags> but it doesn't work (actually, I encode the slash within the tag with 0x2f so it's valid XML. If I just add <pattern/> and <routePartitionName/> I have the same story.. all users are returned, none with a primary extension.
Has anybody managed to write a request that gets you both userid and primary extension?
02-24-2015 06:37 AM
Maybe I don't understand the problem, but this works fine for me:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/10.5">
<soapenv:Header/>
<soapenv:Body>
<ns:listUser sequence="?">
<searchCriteria>
<userid>%</userid>
</searchCriteria>
<returnedTags uuid="?">
<userid/>
<primaryExtension>
<pattern/>
<routePartitionName/>
</primaryExtension>
</returnedTags>
</ns:listUser>
</soapenv:Body>
</soapenv:Envelope>
02-24-2015 07:26 AM
Thanks Nicholas. Somehow the tag with inner tags thing slipped my mind. I blame my former colleague who didn't quite test return tags in our custom lib (it wasn't set up to support inner tags so my query ended up being <returnedTags><userId/><primaryExtension/pattern/><primaryExtension/routePartitionName/></returnTags> which didn't work out. Supporting inner tags in a return tag fixed the issue.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide