What this does
Paste a JSON sample, choose a target language, and adjust that target’s options to generate a type, validator, class, or object literal. Changing the language keeps the sample text and shows only its relevant options.
Example
JSON input:
{"id":7,"name":"Ada"}
TypeScript output:
export interface Root {
id: number;
name: string;
}| Target | Generated output |
|---|---|
| TypeScript | Types and interfaces |
| Zod | Runtime validators |
| Go, Rust, Java, Kotlin, C#, Swift, Dart, Python | Language model declarations |
| PHP | PHP array literals |
| JavaScript | Object literals |
Limits and behavior
- Targets emit TypeScript types, Zod validators, Go structs, Rust structs, Java classes, Kotlin data classes, C# classes, Swift models, Dart classes, Python models, PHP arrays, or JavaScript objects.
- Generated code is inferred from the sample and may need edits for application-specific rules. Inputs are limited to 20 MiB.