JSON to Go structコンバーター — JSONをペーストするとjsonタグ付きの適切に型付けされたGo structを生成。ネストされたオブジェクト、配列、混合型に対応。Go規約に従いPascalCaseでフィールドをエクスポート。 ToolNextの無料オンラインツールとして提供されています。
type Root struct {
Id int `json:"id"`
Name string `json:"name"`
Email string `json:"email"`
IsActive bool `json:"is_active"`
Score float64 `json:"score"`
Tags []string `json:"tags"`
Address Address `json:"address"`
}
type Address struct {
Street string `json:"street"`
City string `json:"city"`
Zip string `json:"zip"`
}