Generate powerful clients for your Solana programs.
The Documentation of Kinobi can be found in the Metaplex Developer Hub.
Kinobi can also load IDLs that follow the Codama standard (v1) — for instance the idl.json shipped by solana-program/token-2022:
import { createFromJson, renderJavaScriptVisitor } from '@metaplex-foundation/kinobi';
import fs from 'node:fs';
const kinobi = createFromJson(fs.readFileSync('idl.json', 'utf8'));
kinobi.accept(renderJavaScriptVisitor('clients/js/src/generated-token2022'));On load, the tree is normalized to Kinobi conventions (names are camel-cased, defaults filled in, display-only metadata dropped).
