OCaml Type Generator

Generate OCaml type definitions from JSON input. Automatically infers record types with proper field types including int, float, bool, string, lists, and nested records.

How to Use OCaml Type Generator

Paste your JSON data, optionally set a root type name, and click Generate. The tool infers OCaml record types with proper field types for all nested structures.

Step-by-Step Instructions

  1. Enter a root type name (optional)
  2. Paste your JSON object or array into the input
  3. Click Generate OCaml Types
  4. Copy the generated type definitions

Related Tools

More Free Tools