Onboard Employees

Merge an employment contract, ID document, and tax form into a single employee onboarding record.

Who this is for

HR departments and onboarding platforms use this recipe to process new hire paperwork. Upload the employment contract, ID document scan, and tax form in a single API call — receive a complete employee record with personal details, contract terms, and tax information.

curl -X POST https://api.iterationlayer.com/document-extraction/v1/extract \
  -H "Authorization: Bearer $ITERATION_LAYER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "files": [
      {
        "type": "url",
        "name": "employment-contract.pdf",
        "url": "https://example.com/docs/employment-contract.pdf"
      },
      {
        "type": "url",
        "name": "id-document.pdf",
        "url": "https://example.com/docs/id-document.pdf"
      },
      {
        "type": "url",
        "name": "tax-form.pdf",
        "url": "https://example.com/docs/tax-form.pdf"
      }
    ],
    "schema": {
      "fields": [
        { "name": "full_name", "type": "TEXT", "description": "Employee full name" },
        { "name": "date_of_birth", "type": "DATE", "description": "Date of birth" },
        { "name": "nationality", "type": "TEXT", "description": "Nationality" },
        { "name": "tax_id", "type": "TEXT", "description": "Tax identification number" },
        { "name": "contract_start_date", "type": "DATE", "description": "Employment start date" },
        { "name": "job_title", "type": "TEXT", "description": "Job title" },
        { "name": "department", "type": "TEXT", "description": "Department" },
        { "name": "annual_salary", "type": "CURRENCY_AMOUNT", "description": "Annual salary amount" },
        { "name": "currency", "type": "TEXT", "description": "Salary currency code" },
        { "name": "probation_period_in_months", "type": "INTEGER", "description": "Probation period length in months" }
      ]
    }
  }'
import { IterationLayer } from "iterationlayer";
const client = new IterationLayer({ apiKey: "YOUR_API_KEY" });

const result = await client.extract({
  files: [
    {
      type: "url",
      name: "employment-contract.pdf",
      url: "https://example.com/docs/employment-contract.pdf",
    },
    {
      type: "url",
      name: "id-document.pdf",
      url: "https://example.com/docs/id-document.pdf",
    },
    {
      type: "url",
      name: "tax-form.pdf",
      url: "https://example.com/docs/tax-form.pdf",
    },
  ],
  schema: {
    fields: [
      { name: "full_name", type: "TEXT", description: "Employee full name" },
      { name: "date_of_birth", type: "DATE", description: "Date of birth" },
      { name: "nationality", type: "TEXT", description: "Nationality" },
      { name: "tax_id", type: "TEXT", description: "Tax identification number" },
      { name: "contract_start_date", type: "DATE", description: "Employment start date" },
      { name: "job_title", type: "TEXT", description: "Job title" },
      { name: "department", type: "TEXT", description: "Department" },
      { name: "annual_salary", type: "CURRENCY_AMOUNT", description: "Annual salary amount" },
      { name: "currency", type: "TEXT", description: "Salary currency code" },
      { name: "probation_period_in_months", type: "INTEGER", description: "Probation period length in months" },
    ],
  },
});

console.log(result);
from iterationlayer import IterationLayer
client = IterationLayer(api_key="YOUR_API_KEY")

result = client.extract(
    files=[
        {
            "type": "url",
            "name": "employment-contract.pdf",
            "url": "https://example.com/docs/employment-contract.pdf",
        },
        {
            "type": "url",
            "name": "id-document.pdf",
            "url": "https://example.com/docs/id-document.pdf",
        },
        {
            "type": "url",
            "name": "tax-form.pdf",
            "url": "https://example.com/docs/tax-form.pdf",
        },
    ],
    schema={
        "fields": [
            {"name": "full_name", "type": "TEXT", "description": "Employee full name"},
            {"name": "date_of_birth", "type": "DATE", "description": "Date of birth"},
            {"name": "nationality", "type": "TEXT", "description": "Nationality"},
            {"name": "tax_id", "type": "TEXT", "description": "Tax identification number"},
            {"name": "contract_start_date", "type": "DATE", "description": "Employment start date"},
            {"name": "job_title", "type": "TEXT", "description": "Job title"},
            {"name": "department", "type": "TEXT", "description": "Department"},
            {"name": "annual_salary", "type": "CURRENCY_AMOUNT", "description": "Annual salary amount"},
            {"name": "currency", "type": "TEXT", "description": "Salary currency code"},
            {"name": "probation_period_in_months", "type": "INTEGER", "description": "Probation period length in months"},
        ]
    },
)

print(result)
package main

import (
    "fmt"
    il "github.com/iterationlayer/sdk-go"
)

func main() {
    client := il.NewClient("YOUR_API_KEY")

    result, err := client.Extract(il.ExtractRequest{
        Files: []il.FileInput{
            il.NewFileFromURL("employment-contract.pdf", "https://example.com/docs/employment-contract.pdf"),
            il.NewFileFromURL("id-document.pdf", "https://example.com/docs/id-document.pdf"),
            il.NewFileFromURL("tax-form.pdf", "https://example.com/docs/tax-form.pdf"),
        },
        Schema: il.ExtractionSchema{
            "full_name":                   il.NewTextFieldConfig("full_name", "Employee full name"),
            "date_of_birth":               il.NewDateFieldConfig("date_of_birth", "Date of birth"),
            "nationality":                 il.NewTextFieldConfig("nationality", "Nationality"),
            "tax_id":                      il.NewTextFieldConfig("tax_id", "Tax identification number"),
            "contract_start_date":         il.NewDateFieldConfig("contract_start_date", "Employment start date"),
            "job_title":                   il.NewTextFieldConfig("job_title", "Job title"),
            "department":                  il.NewTextFieldConfig("department", "Department"),
            "annual_salary":               il.NewCurrencyAmountFieldConfig("annual_salary", "Annual salary amount"),
            "currency":                    il.NewTextFieldConfig("currency", "Salary currency code"),
            "probation_period_in_months":  il.NewIntegerFieldConfig("probation_period_in_months", "Probation period length in months"),
        },
    })
    if err != nil {
        panic(err)
    }

    fmt.Println(result)
}

Related Recipes

Start building in minutes

Free trial credits included. No credit card required.