How to Serialize and Object

**string jsonString = JsonSerializer.Serialize(weatherForecast);**

How to serialize and deserialize JSON using C# - .NET

Parsing Enum Types

How to use Camel Case

var serializeOptions = new JsonSerializerOptions
{
    PropertyNamingPolicy = JsonNamingPolicy.CamelCase,
    WriteIndented = true
};
jsonString = JsonSerializer.Serialize(weatherForecast, serializeOptions);

How to customize property names and values with System.Text.Json