Some things I have learned using the Fresh PowerShell Automation App
I’ve been working with Freshservice automation and its PowerShell Orchestration App for over a year now, and I thought I’d share some of the things I’ve learned. The PowerShell App times out after around 23 seconds. This is apparently the length of time it takes to poll the process 10 times - if there’s no response after this, the Orchestration/Workflow just forgets about it. Errors are different depending on whether you’re running a PowerShell function or a PowerShell script. If you’re anticipating an error in the Automation workflow, you can usually capture it by looking for a response from the app that isn’t 200 (or greater than 299, if oyu might expect another 2xx code). Whilst this works fine for PowerShell functions, it doesn’t work for PowerShell scripts - call a .ps1 file, and the result will always be ‘200’, even if your script fails. Tagging a ticket does not trigger an ‘Updated’ event. Workflows begin with triggers, such as ‘Service Request raised’ or ‘Ticket updated’. But j