GuidesAPI ReferenceChangelog
Changelog
improved

v2.1.72

EOR Additional Fields, worker creation endpoints and legal entities


Updated: POST Create EOR Worker

We simplified the payload by removing the emailproperty from payload. We are now getting this information from the employee email provided during Create an EOR contract.

Endpoint: POST /rest/v2/eor/worker

API Reference: Create EOR Worker

Example:

curl --request POST \
     --url https://api.letsdeel.com/rest/v2/eor/worker \
     --header 'accept: application/json' \
     --header 'authorization: Bearer {YOUR_ORG_TOKEN}' \
     --data '{
  "data": {
    "contract_id": "mp4y66j"
  }
}'

Updated: GET Worker Additional Fields for EOR by Country

We updated this endpoint to retrieve all required fields common across all countries. The fields are:

  • street: Worker's address street (required)
  • city: Worker's address city (required)
  • state: Worker's address state/province (optional)
  • zip_code: Worker's address zip code (required)
  • phone: Worker's phone (required)
  • tax_residence: Worker's tax residency country (required)
  • is_payslip_access_allowed: Determine if worker will have access to payslip's.
  • is_compliance_access_allowed: Determine if worker will have access to compliance.

Note: We still retrieve all other fields that are country specific.

Endpoint: GET /rest/v2/forms/eor/worker-additional-fields/{country_code}

API Reference: Get worker additional fields for EOR


Added: POST EOR Worker Additional Information

A new endpoint has been implemented to save the additional fields related to an Employee of Record (EOR) worker. The endpoint payload is dynamic and the payload available properties can be retrieved using Get worker additional fields for (EOR) endpoint .

Endpoint: POST /rest/v2/eor/workers/contracts/:contract_id/additional-information

API Reference: Add additional information

Example

curl --request POST \
    --url \
    https://api.letsdeel.com/v2/rest/v2/eor/workers/contracts/{CONTRACT_ID}/additional-information --header 'accept: application/json' \
    --header 'authorization: Bearer {API_TOKEN}' \
    --header 'content-type: application/json' \
    --data '
      {
         "data": {
            "tax_residence": "United States",
            "phone": "+1-555-123-4567",
            "street": "123 Main St",
            "city": "New York",
            "zip_code": "10001",
            "is_payslip_access_allowed": true,
            "is_compliance_access_allowed": true,
            "dob": "1990-01-01",
            "id_type": "Passport",
            "passport_number": "AB1234"
         }
      }
    '

Updated: List of legal entities API

Added new response fields: phone, address, created_at, sic_number, updated_at, archived_at, industry_name .

Added new query filters: cursor, sort_order, limit, include_payroll_settings, include_archived, global_payroll, legal_entity_id and type.

Endpoint: GET /v2/legal-entities

API Reference: List of legal entities