<PackageReference Include="System.Text.Json" Version="6.0.9" />

JsonSerializerContext

public abstract class JsonSerializerContext
Provides metadata about a set of types that is relevant to JSON serialization.

The default run time options for the context. Its values are defined at design-time via JsonSourceGenerationOptionsAttribute.

Gets the run time specified options of the context. If no options were passed when instanciating the context, then a new instance is bound and returned.

Creates an instance of JsonSerializerContext and binds it with the indicated JsonSerializerOptions.

public abstract JsonTypeInfo GetTypeInfo(Type type)

Returns a JsonTypeInfo instance representing the given type.