I am trying to add a note to a ticket with an attachment in Powershell but I always receive a 400 HTTP code (bad request)
I’ve already used a lot FreshService’s API and I always managed to make it work (adding note without attachment, creating service requests…).
But this time, attachments are really making me struggling a lot.
I’ve never send an attachment through an API (FreshService or something else) in any programming languages.
I’ve some problem understanding what should I send (type of object ?, path of the file ?, bytesof the files ?) in the body so FreshService’s API can recognize my file and I even tried to achieve that with other method (such as cURL) but I always failed.
If you have any tips or PowerShell code sample to help me, it would be very cool from you
Newbie to the whole Fresh universe, me & Google are pretty OK with Powershell.
What I’m attempting to do is, with PowerShell, using a Managed Identity on an Azure VM, mapped to an Az AD object, after having a ticket number in the mix from a support person, write a note to the Change, with the results of my validation script that runs against a newly created database in SQL Server.
Reading configuration out of an Azure SQL database, validating against SQL Server and writing to a PowerShell custom object.
1 piece left. The note on the change.
I would certainly appreciate anyone pointing me in a direction.