Newtonsoft Json Error converting value {null} to type 'System.Int32'

Make your tabID nullable:

public int? tabID;

Value null could not be deserialized to integer. That's your 6-th part of json (or 5-th starting with 0):

{\"bmk\":\"test-m\",\"state\":\"on\",\"type\":\"motor\",\"tabID\":null}

You could see, that tabID is null there.


Depending on your use case, you may also want to consider having the JSON Serializer ignore nulls

Example:

Movie movie = new Movie();
movie.Name = "Bad Boys III";
movie.Description = "It's no Bad Boys";

string included = JsonConvert.SerializeObject(movie,
    Formatting.Indented,
    new JsonSerializerSettings { });

// {
//   "Name": "Bad Boys III",
//   "Description": "It's no Bad Boys",
//   "Classification": null,
//   "Studio": null,
//   "ReleaseDate": null,
//   "ReleaseCountries": null
// }

string ignored = JsonConvert.SerializeObject(movie,
    Formatting.Indented,
    new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore });

// {
//   "Name": "Bad Boys III",
//   "Description": "It's no Bad Boys"
// }