Josef Ottosson

Josef Ottosson

Freelancing Developer ยท Microsoft MVP

Subscribe via RSS
© Josef Ottosson 2025

System.Text.Json

A collection of 5 posts

jos.enumeration

JOS.Enumeration - System.Text.Json support

Custom JsonConverter that only writes the integer value of our Enumeration class. It also supports deserialization by only supplying the Enumeration value.

2 years ago May 29th, 2023 3 min read
System.Text.Json

Some basic query support for System.Text.Json - (JSONPath inspired)

Shows how to select and remove properties on a JsonObject using some custom extension methods.

2 years ago April 22nd, 2023 4 min read
Protect yourself when deserializing - System.Text.Json
dotnet

Protect yourself when deserializing - System.Text.Json

When dealing with deserialization of JSON, it's always a good idea to validate that it in fact deserialized correctly. But, how do you do that using System.Text.Json?

3 years ago November 10th, 2022 4 min read
Polymorphic deserialization with System.Text.Json
dotnet core

Polymorphic deserialization with System.Text.Json

How to do polymorphic deserialization with System.Text.Json by using a custom JsonConverter

4 years ago December 20th, 2020 8 min read
Custom Dictionary JsonConverter using System.Text.Json
dotnet

Custom Dictionary JsonConverter using System.Text.Json

How to customize the deserialization/serialization of Dictionary<string, object> using System.Text.Json and a custom JsonConverter

5 years ago August 16th, 2020 8 min read
Subscribe via RSS
© Josef Ottosson 2025