Jump to content
Welcome to our new Citrix community!
  • 0

Internal server error during Invoke_RestMethod query

Martin Kovac1709158740




during Invoke-RestMethod query against CLOUD API I get often the Internal server error. It means, if I execute the command on for example first time I get an answer, same for 2nd time and for 3rd I get an error:


Invoke-RestMethod : { "statusCode": 500, "message": "Internal server error", "activityId": "0fca9e74-e4d6-48e7-8a8e-d6500e916d99" }
At line:56 char:23
+ ...   $newJob = Invoke-RestMethod -Uri $coreURL -Method Get -Headers $hea ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-RestMethod], WebException
    + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand

On 4th time I get again correct results. What could be the reason for that ?  Internal server error means that it comes from server(cloud) side, not from client(me) or ?

Link to comment

1 answer to this question

Recommended Posts

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...