My Api accepts object as a paramenter and I wanted to pass it from powershell. I have copied the powrshell code. Please advise as when the api is invoked null value comes into api as input.
Class JsonArray
{
    [String]$json
}
  $Json ='hi'
  $jsonArray = [JsonArray]::new()
  $jsonArray.json = $Json
  $params = $jsonArray
Invoke-WebRequest -Uri http://localhost:65452/api/e10/e10PostTCData/ Method Post -Body $params -TimeoutSec 600
Below is my API
    [Route("e10PostTCData/")]
    [HttpPost]
    public HttpResponseMessage PostResults(JsonArray jsonArray )
    {
    }
    public class JsonArray
    {
       public string json { get; set; }
    }