02-19-2019 09:18 AM
I have built a PowerShell script that will check Active Directory for new users. Once it has found the users it proceeds to use the API to addLine passing information from AD. Once the lines are created then i use addDeviceProfile. The script then builds the profile based on AD information. The script works without errors, adding 1 or 2 lines for each person and the device profile. The problem that I am running into is the External Phone Number Mask for the lines added to the device profile. I am unable to find a field that will allow me to add/update the number mask. I have attempted to using Enterprise Alternate Number and +E.164 Alternate Number to resolve this. Both failed. Is there anyone that can point me in the right direction to overcome this?
Solved! Go to Solution.
02-19-2019 11:22 AM
I was able to figure it out. The field is <e164Mask>. I have included the XML that I used for reference for the next person.
<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/12.0">
<soapenv:Body>
<ns:addDeviceProfile>
<deviceProfile>
<name>UDP-$($SamAccountName)</name>
<description>$($User.DisplayName)</description>
<product>Cisco 8841</product>
<class>Device Profile</class>
<protocol>SIP</protocol>
<protocolSide>User</protocolSide>
<userHoldMohAudioSourceId/>
<vendorConfig/>
<traceFlag>false</traceFlag>
<mlppDomainId/>
<mlppIndicationStatus>Off</mlppIndicationStatus>
<preemption>Default</preemption>
<lines>
<line>
<index>1</index>
<label>Agent $($User.extensionAttribute10)</label>
<display>Agent $($User.DisplayName)</display>
<dirn>
<pattern>$($User.extensionAttribute10)</pattern>
<routePartitionName>On Cluster</routePartitionName>
</dirn>
<ringSetting>Use System Default</ringSetting>
<consecutiveRingSetting>Use System Default</consecutiveRingSetting>
<displayAscii>Agent $($User.DisplayName)</displayAscii>
<e164Mask>XXXXXXXXXX</e164Mask>
<mwlPolicy>Use System Policy</mwlPolicy>
<maxNumCalls>2</maxNumCalls>
<busyTrigger>1</busyTrigger>
<callInfoDisplay>
<callerName>true</callerName>
<callerNumber>false</callerNumber>
<redirectedNumber>false</redirectedNumber>
<dialedNumber>true</dialedNumber>
</callInfoDisplay>
<recordingProfileName>Verint-BIB</recordingProfileName>
<monitoringCssName>System Call Recording Monitoring</monitoringCssName>
<recordingFlag>Automatic Call Recording Enabled</recordingFlag>
<audibleMwi>Default</audibleMwi>
<partitionUsage>General</partitionUsage>
<missedCallLogging>true</missedCallLogging>
<recordingMediaSource>Phone Preferred</recordingMediaSource>
</line>
<line>
<index>2</index>
<label>$($User.DisplayName) $($User.telephoneNumber)</label>
<display>$($User.DisplayName)</display>
<dirn>
<pattern>$($User.telephoneNumber)</pattern>
<routePartitionName>On Cluster</routePartitionName>
</dirn>
<ringSetting>Use System Default</ringSetting>
<consecutiveRingSetting>Use System Default</consecutiveRingSetting>
<displayAscii>$($User.DisplayName) $($User.telephoneNumber)</displayAscii>
<e164Mask>XXXXXXXXXX</e164Mask>
<mwlPolicy>Use System Policy</mwlPolicy>
<maxNumCalls>2</maxNumCalls>
<busyTrigger>1</busyTrigger>
<callInfoDisplay>
<callerName>true</callerName>
<callerNumber>false</callerNumber>
<redirectedNumber>false</redirectedNumber>
<dialedNumber>true</dialedNumber>
</callInfoDisplay>
<recordingProfileName>Verint-BIB</recordingProfileName>
<monitoringCssName>System Call Recording Monitoring</monitoringCssName>
<recordingFlag>Automatic Call Recording Enabled</recordingFlag>
<audibleMwi>Default</audibleMwi>
<partitionUsage>General</partitionUsage>
<missedCallLogging>true</missedCallLogging>
<recordingMediaSource>Phone Preferred</recordingMediaSource>
</line>
</lines>
<phoneTemplateName>7945 SIP 2L</phoneTemplateName>
</deviceProfile>
</ns:addDeviceProfile>
</soapenv:Body>
</soapenv:Envelope>
02-19-2019 11:22 AM
I was able to figure it out. The field is <e164Mask>. I have included the XML that I used for reference for the next person.
<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.cisco.com/AXL/API/12.0">
<soapenv:Body>
<ns:addDeviceProfile>
<deviceProfile>
<name>UDP-$($SamAccountName)</name>
<description>$($User.DisplayName)</description>
<product>Cisco 8841</product>
<class>Device Profile</class>
<protocol>SIP</protocol>
<protocolSide>User</protocolSide>
<userHoldMohAudioSourceId/>
<vendorConfig/>
<traceFlag>false</traceFlag>
<mlppDomainId/>
<mlppIndicationStatus>Off</mlppIndicationStatus>
<preemption>Default</preemption>
<lines>
<line>
<index>1</index>
<label>Agent $($User.extensionAttribute10)</label>
<display>Agent $($User.DisplayName)</display>
<dirn>
<pattern>$($User.extensionAttribute10)</pattern>
<routePartitionName>On Cluster</routePartitionName>
</dirn>
<ringSetting>Use System Default</ringSetting>
<consecutiveRingSetting>Use System Default</consecutiveRingSetting>
<displayAscii>Agent $($User.DisplayName)</displayAscii>
<e164Mask>XXXXXXXXXX</e164Mask>
<mwlPolicy>Use System Policy</mwlPolicy>
<maxNumCalls>2</maxNumCalls>
<busyTrigger>1</busyTrigger>
<callInfoDisplay>
<callerName>true</callerName>
<callerNumber>false</callerNumber>
<redirectedNumber>false</redirectedNumber>
<dialedNumber>true</dialedNumber>
</callInfoDisplay>
<recordingProfileName>Verint-BIB</recordingProfileName>
<monitoringCssName>System Call Recording Monitoring</monitoringCssName>
<recordingFlag>Automatic Call Recording Enabled</recordingFlag>
<audibleMwi>Default</audibleMwi>
<partitionUsage>General</partitionUsage>
<missedCallLogging>true</missedCallLogging>
<recordingMediaSource>Phone Preferred</recordingMediaSource>
</line>
<line>
<index>2</index>
<label>$($User.DisplayName) $($User.telephoneNumber)</label>
<display>$($User.DisplayName)</display>
<dirn>
<pattern>$($User.telephoneNumber)</pattern>
<routePartitionName>On Cluster</routePartitionName>
</dirn>
<ringSetting>Use System Default</ringSetting>
<consecutiveRingSetting>Use System Default</consecutiveRingSetting>
<displayAscii>$($User.DisplayName) $($User.telephoneNumber)</displayAscii>
<e164Mask>XXXXXXXXXX</e164Mask>
<mwlPolicy>Use System Policy</mwlPolicy>
<maxNumCalls>2</maxNumCalls>
<busyTrigger>1</busyTrigger>
<callInfoDisplay>
<callerName>true</callerName>
<callerNumber>false</callerNumber>
<redirectedNumber>false</redirectedNumber>
<dialedNumber>true</dialedNumber>
</callInfoDisplay>
<recordingProfileName>Verint-BIB</recordingProfileName>
<monitoringCssName>System Call Recording Monitoring</monitoringCssName>
<recordingFlag>Automatic Call Recording Enabled</recordingFlag>
<audibleMwi>Default</audibleMwi>
<partitionUsage>General</partitionUsage>
<missedCallLogging>true</missedCallLogging>
<recordingMediaSource>Phone Preferred</recordingMediaSource>
</line>
</lines>
<phoneTemplateName>7945 SIP 2L</phoneTemplateName>
</deviceProfile>
</ns:addDeviceProfile>
</soapenv:Body>
</soapenv:Envelope>
01-29-2021 11:49 AM
thank you! was looking for this!
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