jiminy-schema 0.14.0

Layout Manifest v1 for Jiminy: structured account schema descriptions with canonical type normalization. Enables TypeScript codegen, indexer integration, and cross-language tooling.
Documentation
  • Coverage
  • 70.18%
    40 out of 57 items documented2 out of 16 items with examples
  • Size
  • Source code size: 29.88 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 3.2 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 14s Average build duration of successful builds.
  • all releases: 14s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • QuarksBlueFoot/jiminy
    3 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • QuarksBlueFoot

jiminy-schema

Layout Manifest v1 for Jiminy account schemas. Structured descriptions of account layouts for cross-language tooling, TypeScript decoder generation, indexer integration, and schema validation.

#![no_std] compatible (std/codegen/indexer features gated)

[dependencies]

jiminy-schema = "0.14"

What's in here

LayoutManifest Describes one account type: name, version, discriminator, layout_id, field list
FieldDescriptor Per-field metadata: name, canonical type, size
CanonicalType Language-independent type identifiers (U8, U64, Pubkey, Header, etc.)
codegen TypeScript decoder generation (feature: codegen)
indexer Account matching and decoding for off-chain indexers (feature: std)

Example

use jiminy_schema::*;

let manifest = LayoutManifest {
    name: "Vault",
    version: 1,
    discriminator: 1,
    layout_id: [0xAB, 0xCD, 0xEF, 0x01, 0x23, 0x45, 0x67, 0x89],
    fields: &[
        FieldDescriptor { name: "header", canonical_type: CanonicalType::Header, size: 16 },
        FieldDescriptor { name: "balance", canonical_type: CanonicalType::U64, size: 8 },
        FieldDescriptor { name: "authority", canonical_type: CanonicalType::Pubkey, size: 32 },
    ],
};

assert_eq!(manifest.total_size(), 56);
assert_eq!(manifest.field_offset("balance"), Some(16));

About

Built by MoonManQuark / Bluefoot Labs.

Donations: solanadevdao.sol (F42ZovBoRJZU4av5MiESVwJWnEx8ZQVFkc1RM29zMxNT)

License

Apache-2.0