Custom script (powershell) does not work

Custom script (powershell) does not work

Hi Everyone! 

I wrote script which will add new request, SD said  Action Executed is : test2  Message:  successfully executed, but nothing changes. 
Command in custom scripts cmd /c start /wait powershell.exe  -file C:\ManageEngine\ServiceDesk\integration\custom_scripts\test.ps1 $COMPLETE_JSON_FILE.
PS version 3.0, also i manage execution policy, now it unrestricted. Maybe someone can tell what wrong? 

p.s. Run this script on server manually, it create request, but without params (line 11-13).

Script text:
  1. param (
  2.     [string]$json = "none"
  3.  )

  4. $jsondata = Get-Content $json
  5. write-host $jsondata

  6. $obj = ConvertFrom-Json $jsondata
  7. #Ticket Information
  8. $ticket = $obj.request.WORKORDERID
  9. $requester = $obj.request.REQUESTER
  10. $site = $obj.request

  11. $inputData  =  @"
  12. <Operation>
  13. <Details>
  14. <requester>$requester</requester>
  15. <category>Category1</category>
  16. <subcategory>Subcategory1</subcategory>
  17. <item>Item1</item>
  18. <subject>Test</subject>
  19. <site>$site</site>
  20. <rating>15.0</rating> #my additional field
  21. <description>test message id $ticket. </description>
  22. <requesttemplate>Default Request</requesttemplate>
  23. <group>Group 1</group>
  24. </Details>
  25. </Operation>
  26. "@
  27. $postParams  = @{OPERATION_NAME = 'ADD_REQUEST' ;TECHNICIAN_KEY = 'key' ;INPUT_DATA = $inputData}

  28. $URI       =       "http://localhost:8080/sdpapi/request"
  29. Invoke-WebRequest -Uri $URI -Method Post -Body $postParams

                New to ADManager Plus?

                  New to ADSelfService Plus?