12 releases (3 stable)
new 5.0.1 | Jan 13, 2025 |
---|---|
2.1.3 | Oct 8, 2024 |
0.4.1 | Jul 3, 2024 |
0.2.1 | Dec 8, 2023 |
0.1.6 | Jul 7, 2023 |
#633 in Magic Beans
91 downloads per month
Used in architect-sdk
485KB
13K
SLoC
architect-api
GraphQL support via Juniper
Trivial types, and types with only one obvious schema, come with implementations of
GraphQL traits for use with the juniper
crate. These can be enabled using the
juniper
feature flag. In general, however, the user should write their own wrapper
types for a bespoke GraphQL schema.
JSONSchema generation
We generate a metadata + JSONSchema representation of our gRPC APIs to assist in generating client SDKs.
This is accomplished via two modules:
schema/builder
-- logic and types for generating schema definitions fromtonic_build
service definitionsschema
-- a stub crate/phony target that uses the generated schema definitions to build a schema.json file
[!NOTE]
New gRPC stubs/services must be added toschema/build.rs
as well asbuild.rs
to be included in the generatedschema.json
file.
The dependency graph induces a build order: schema/builder
-> architect-api
-> schema
. This build order naturally regenerates the schema.json file whenever this crate changes.
Downstream SDKs:
Dependencies
~22–66MB
~1M SLoC