When using AutoTask’s API it’s required to lookup a various amount of picklist values that are used in updating you’re web request. This is a powershell way to pull those picklist values. The first part of the script validates your AT URI, the second part gets the entity data, in this case I was looking for “ticket” related fields.
Edit: Updated to give a more friendly output
# Username and password for Autotask $ATurl = "https://webservices1.autotask.net/atservices/1.5/atws.wsdl" $ATusername = "{AT Username}" $ATpassword = ConvertTo-SecureString "{AT Password}" -AsPlainText -Force $ATcredentials = New-Object System.Management.Automation.PSCredential($ATusername,$ATpassword) $atws = New-WebServiceProxy -URI $ATurl -Credential $ATcredentials $zoneInfo = $atws.getZoneInfo($ATusername) $ATurl = $zoneInfo.URL.Replace(".asmx",".wsdl") $atws = New-WebServiceProxy -URI $ATurl -Credential $ATcredentials $entity= $atws.getFieldInfo("Ticket") foreach ($picklist in $entity) { $picklist | select Name,Label,Description | ft foreach ($values in $picklist.PicklistValues) { $values | select Label,Value,IsActive } } $output= $atws.getThresholdAndUsageInfo() $output.EntityReturnInfoResults.message
This is a quick one, it's been forever since I've posted here. After moving back…
Simple command turned crazy. I ended up coming up with this due to the fact…
Phew, this one took a minute to figure out. ConnectWise has a form based documents…
I've found myself at a new job, recreating many of the processes that I spent…
Wow, it's been a while since I've done a real post on this site. I've…
This is a simple script to gather volume information including dedupe schedule and autogrow settings.…