title: How to parse multi-level JSON Array
body: <p>I am trying to parse multi-level json array, but I am getting the following exception:</p>
  
  <pre><code>Cannot deserialize the current JSON array (e.g. [1,2,3]) into type 'Tractor.Models.UserDetails' because the type requires a JSON object (e.g. {"name":"value"}) to deserialize correctly.
  </code></pre>
  
  <p>Here is the json response:</p>
  
  <pre><code>{
    "status": 1,
    "message": null,
    "userdetails": [
      {
        "ID": 9,
        "Name": "aleem",
        "Company_Name": null,
        "Email": null,
        "Password": null,
        "Created_Date": null,
        "Email_Confirm": null,
        "Token": null,
        "Phone": null,
        "Website": null,
        "allcompanies": [
          {
            "Name": "self",
            "allprojects": [
              {
                "ID": 1,
                "Name": "test"
              }
            ]
          }
        ],
        "screens": 3
      }
    ]
  }
  </code></pre>
  
  <p>Below are the classes I have added to get the JSON Response:</p>
  
  <pre><code>class LoginApiResponse
  {
          [JsonProperty("status")]
          public int Status { get; set; }
  
          [JsonProperty("message")]
          public string Message { get; set; }
  
          [JsonProperty("userdetails")]
          public UserDetails UserDetails { get; set; }
  
      }
  
  class UserDetails
  {
      [JsonProperty("ID")]
      public int ID { get; set; }
  
      [JsonProperty("Name")]
      public string Name { get; set; }
  
      [JsonProperty("Company_Name")]
      public string Company_Name { get; set; }
  
      [JsonProperty("Email")]
      public string Email { get; set; }
  
      [JsonProperty("Password")]
      public string Password { get; set; }
  
      [JsonProperty("Created_Date")]
      public string Created_Date { get; set; }
  
      [JsonProperty("Email_Confirm")]
      public string Email_Confirm { get; set; }
  
      [JsonProperty("Token")]
      public string Token { get; set; }
  
      [JsonProperty("Phone")]
      public string Phone { get; set; }
  
      [JsonProperty("Website")]
      public string Website { get; set; }
  
      [JsonProperty("allcompanies")]
      public List&lt;Company&gt; Companies { get; set; }
  
      [JsonProperty("screens")]
      public int Screens { get; set; }
  }
  
  class Company
      {
          [JsonProperty("Name")]
          public string Name { get; set; }
  
          [JsonProperty("allprojects")]
          public List&lt;Project&gt; Projects {get;set;}
      }
  
  class Project
      {
          [JsonProperty("ID")]
          public int ID { get; set; }
  
          [JsonProperty("Name")]
          public string Name { get; set; }
      }
  </code></pre>
  
  <p>I am using the below code to serialize this JSON:</p>
  
  <pre><code>var response = client.Execute(request); 
  var final = JsonConvert.DeserializeObject&lt;LoginApiResponse&gt;(response.Content);
  </code></pre>