Closed Serg86 closed 2 years ago
I can confirm this is also happening when trying to submit TicketNotesChild resources as well, the parentID is not being applied.
I created a new module because this seemed unfinished and abandoned: https://www.powershellgallery.com/packages/AutotaskRestAPI/0.1
Fixed.
Describe the bug Set-AutotaskAPIResource does not work with TicketChecklistItemsChild, perhaps with other resources as well.
To Reproduce Steps to reproduce the behavior: PS :> Set-AutotaskAPIResource -ID $ParentTicketID -Resource TicketChecklistItemsChild -body $ChecklistItemBody
Expected behavior Modifications to the checklist item in the ticket.
Desktop (please complete the following information):
Additional context For debugging purposes I modified the Set-AutotaskAPIResource.ps1 file to output the $ResourceURL and it appears that the parentID is not being applied. I then modified the Invoke-RestMethod line to replace the parentId manually:
This resulted in successful Api responses and the checklist items were modified correctly.