Skip to main content
Contributing templates helps other users simplify their extraction workflows with predefined schemas for common document types.

How to add a new template

1. Navigate to the templates folder

Open the templates folder in your forked repo extractor/src/templates.

2. Create a JSON file for your template

Add a new JSON file with the template name, e.g. invoice.json.

3. Define the Schema

Follow the Documind format to define your template. Here’s an example schema for an invoice:
invoice.json

4. Test your template

Use the following code snippet to test your template locally:
You can also add an example invoice pdf in the examples folder.

5. Submit a pull request

Submit a pull request with a brief description of your template. Additional guidelines
  • Ensure all field names are in camelCase.
  • Use appropriate data types (string, number, array, object).
  • Add clear and concise descriptions for each field.
  • Include nested fields for complex structures under children.