# JSONSchema2Types.jl

**URL:** <https://discourse.julialang.org/t/jsonschema2types-jl/143168>\
**Category:** Package Announcements\
**Created:** [November 24, 2026, 7:20pm UTC](https://discourse.julialang.org/t/jsonschema2types-jl/143168 "2026-11-24T19:20:00Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ricardo\_Rosa](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ricardo_rosa/32/18564_2.png) [@Ricardo\_Rosa](https://discourse.julialang.org/u/Ricardo_Rosa)\
**Post date:** [November 24, 2026, 7:20pm UTC](https://discourse.julialang.org/t/jsonschema2types-jl/143168/1 "2026-11-24T19:20:01Z")

</div>

Hello, all.

I just finished this package [GitHub - rmsrosa/JSONSchema2Types.jl: Parse jsonschema to Julia composite types · GitHub](http://github.com/rmsrosa/JSONSchema2Types.jl) that takes a JSON schema and builds a module with all the types needed to hold JSON data that uses the schema. One has the option to add constructors to enforce all the conditions described in the schema (say a value in a certain interval or only one element in a list and so on) or only have the correct types (if speed is a concern).

There are some complementary packages handling JSON in JuliaIO and in other places but not this type of package. I needed it to create types for a very intricate schema ([beerjson](https://github.com/beerjson/beerjson) schema) that would take ages to do by hand and require more work when updating. Now I can read [beerjson](https://github.com/beerjson/beerjson) files in a breeze.

I did most of the coding by hand, but I was getting lazy at the more complicated jsonchema refs. Then came Claude and helped me wrap it up.

I did it for [beerjson](https://github.com/beerjson/beerjson) but it is a general package, reading (mostly) any kind of JSON schema. I think it might be useful to other people.
