Skip to main content
A schema tells Darpan which fields a source carries and what type each one is, so every run that reads that source parses it the same way. You never type the fields out to get one: upload a schema you already have, or a sample of the data, and Darpan reads the fields from it. Typing comes later, and only if you want to adjust what it found.

Before you start

  • You need edit access to the active tenant. Without it, the Schema Library has no Create New Schema action.
  • Have one of these files ready:
    • a JSON Schema file (.json), or
    • a sample of the data: a representative JSON record (.json) or a CSV file whose first row is the header (.csv).
  • Know which system the data comes from. Each schema is assigned to one system.

Steps

From Ask Darpan, open Create Schema, or open Open Schema Library and choose Create New Schema.
  1. Are you uploading a schema file or a sample file? Choose Schema file (A) or Sample file (B).
  2. Upload the schema file or Upload the sample file. A schema file must be .json; a sample can be .json or .csv. Choose OK.
  3. Assign the system. Pick the system the data comes from and choose OK. For a sample, this is when Darpan reads the file.
  4. Review the interpreted schema (samples only). Darpan lists every field it found with its Field Path, Type and a Required checkbox. Tick Required for the fields every record must carry, then choose OK.
  5. Name the schema. The name starts as the file name; change it to something you will recognise in saved runs. Choose Save.
Darpan saves the schema and opens the Schema Library. If the name is already taken, the schema is saved as <name> (1).

What Darpan reads from each file

An inferred schema reports the shape Darpan found, not the contract you intend. Check it before you rely on it in a run.

Refine a schema

Field types and paths are edited after saving, in the Schema Editor. Open Open Schema Library and choose the schema.

Where a schema shows up

When you set up a run, each side lists only the schemas assigned to that side’s system. A CSV side lists only flat schemas: every field top-level, nothing nested. A schema inferred from a CSV header is always flat. A schema inferred from JSON with nested records is not, so it will not appear for a CSV side.

Troubleshooting

Keep one clear schema per source shape. A vague schema reused across shapes needs interpreting every time it is picked.
Next: Set up a reconciliation run.