Is there any equivalent to pydantic, serde, etc?

This page summarizes the projects mentioned and recommended in the original post on /r/golang

InfluxDB - Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
www.influxdata.com
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  • validator

    :100:Go Struct and Field validation, including Cross Field, Cross Struct, Map, Slice and Array diving

  • Go uses zero values to provide sensible default values. It's a design choice. With a quick Google you'll find several libraries such as https://github.com/go-playground/validator or https://github.com/asaskevich/govalidator. I use validator whenever I need to ensure any JSON I unmarshalled is correct.

  • gojsonschema

    An implementation of JSON Schema, draft v4 v6 & v7 - Go language

  • xeipuuv/gojsonschema

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • govalidator

    [Go] Package of validators and sanitizers for strings, numerics, slices and structs

  • Go uses zero values to provide sensible default values. It's a design choice. With a quick Google you'll find several libraries such as https://github.com/go-playground/validator or https://github.com/asaskevich/govalidator. I use validator whenever I need to ensure any JSON I unmarshalled is correct.

  • mapstructure

    Go library for decoding generic map values into native Go structures and vice versa.

  • Maybe https://github.com/mitchellh/mapstructure can do what you want? It has some options for Remainder Values and Omit Empty

  • godantic

    godantic is a Go package that provides functionality for decoding JSON data and validating it against a given object structure. It aims to simplify the process of decoding and validating JSON input in Go applications.

  • https://github.com/GraHms/godantic try this out

  • ozzo-validation

    An idiomatic Go (golang) validation package. Supports configurable and extensible validation rules (validators) using normal language constructs instead of error-prone struct tags.

  • go-ozzo/ozzo-validation

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Is there a module to determine a data type?

    2 projects | /r/golang | 1 Sep 2021
  • Runtime code generation and execution in Go

    8 projects | news.ycombinator.com | 29 May 2024
  • API completa em Golang - Parte 7

    3 projects | dev.to | 3 Feb 2024
  • Handling high-traffic HTTP requests with JSON payloads

    5 projects | /r/golang | 7 Dec 2023
  • Rob Pike: Gobs of data (2011)

    10 projects | news.ycombinator.com | 4 Dec 2023