On Sun, Apr 6, 2025 at 12:58 AM Nigel Stewart via Boost-users <boost-users@lists.boost.org> wrote: > 1. Generate a C++17 struct from a JSON Schema, names, types, optionality, > nested data, arrays. > 2. Generate C++17 code for serialising to/from the natve C++17 struct. > 3. Generate validation code that can emit informative messages about failed > validation.
Not sure about your #3, but #1 and #2 are covered by some existing tools. Most from other ecosystems (JS/TS, Go, etc...) and many based on OpenAPI rather than Json schemas. Another team than mine uses Pistache for example, which generates C++ but uses nlohmann/json, and that's Linux only I think, because it does the "RPC part" also, using the Reactor pattern. > Seems to me this problem isn't specific to our application stack. > Essentially we want to pass state between NodeJS and core C++ modules > and have those interfaces evolve over time in a maintainable way. Quite common indeed, except for the part of the backend using C++ :). Many more backends are in JS/TS, Go, Rust, etc... than C++ I'm afraid. Thus interop with the C++ world is poorly supported by most tools. --DD _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org https://lists.boost.org/mailman/listinfo.cgi/boost-users