> ## Documentation Index
> Fetch the complete documentation index at: https://docs.intermezzo.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Orgs Bulk

> Create multiple organizations in bulk



## OpenAPI

````yaml /api-reference/preview.json post /organizations/list
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers: []
security: []
paths:
  /organizations/list:
    post:
      tags:
        - Core
        - Organizations
      summary: Create Orgs Bulk
      description: Create multiple organizations in bulk
      operationId: create_orgs_bulk_organizations_list_post
      requestBody:
        content:
          application/json:
            schema:
              items:
                oneOf:
                  - $ref: '#/components/schemas/DEOrganizationRequest'
                  - $ref: '#/components/schemas/GBOrganizationRequest'
                discriminator:
                  propertyName: registration_country
                  mapping:
                    DE:
                      $ref: '#/components/schemas/DEOrganizationRequest'
                    GB:
                      $ref: '#/components/schemas/GBOrganizationRequest'
              type: array
              title: Requests
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BulkOperationResponse_OrgResponse_'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - BearerToken: []
components:
  schemas:
    DEOrganizationRequest:
      properties:
        validate_legal_name_against_blacklist:
          type: boolean
          title: Validate Legal Name Against Blacklist
          description: >-
            Whether or not the legal name should be checked for terms on
            blacklist
          default: true
        legal_name:
          type: string
          title: Legal Name
        registration_country:
          type: string
          const: DE
          title: Registration Country
          default: DE
        address:
          $ref: '#/components/schemas/AddressRequest'
        correspondence_address:
          anyOf:
            - $ref: '#/components/schemas/AddressRequest'
            - type: 'null'
        dba_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Dba Name
        incorporation_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Incorporation Date
        website:
          anyOf:
            - type: string
            - type: 'null'
          title: Website
        external_ref:
          anyOf:
            - type: string
              maxLength: 255
            - type: 'null'
          title: External Ref
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        work_sites:
          items:
            $ref: '#/components/schemas/WorksiteRequest'
          type: array
          title: Work Sites
        bank_accounts:
          items:
            $ref: '#/components/schemas/BankAccountRequest'
          type: array
          title: Bank Accounts
        contacts:
          anyOf:
            - items:
                $ref: '#/components/schemas/ContactRequest'
              type: array
            - type: 'null'
          title: Contacts
        sepa_mandates:
          anyOf:
            - items:
                $ref: '#/components/schemas/SepaMandateRequest'
              type: array
            - type: 'null'
          title: Sepa Mandates
        insurance_data:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/DEOrganizationInsuranceDetailsRequest'
                - $ref: '#/components/schemas/GBOrganizationInsuranceDetailsRequest'
              discriminator:
                propertyName: insurance_country
                mapping:
                  DE:
                    $ref: '#/components/schemas/DEOrganizationInsuranceDetailsRequest'
                  GB:
                    $ref: '#/components/schemas/GBOrganizationInsuranceDetailsRequest'
            - type: 'null'
          title: Insurance Data
        tax_identifiers:
          anyOf:
            - $ref: '#/components/schemas/TaxIdentifiersRequest'
            - type: 'null'
        preferences:
          oneOf:
            - $ref: '#/components/schemas/DEOrganizationPreferencesRequest'
            - $ref: '#/components/schemas/GBOrganizationPreferencesRequest'
          title: Preferences
          discriminator:
            propertyName: preferences_country
            mapping:
              DE:
                $ref: '#/components/schemas/DEOrganizationPreferencesRequest'
              GB:
                $ref: '#/components/schemas/GBOrganizationPreferencesRequest'
      additionalProperties: true
      type: object
      required:
        - legal_name
        - bank_accounts
        - preferences
      title: DEOrganizationRequest
    GBOrganizationRequest:
      properties:
        registration_country:
          type: string
          const: GB
          title: Registration Country
          default: GB
        legal_name:
          type: string
          maxLength: 35
          minLength: 1
          title: Legal Name
        address:
          $ref: '#/components/schemas/AddressRequest'
        correspondence_address:
          anyOf:
            - $ref: '#/components/schemas/AddressRequest'
            - type: 'null'
        dba_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Dba Name
        incorporation_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Incorporation Date
        website:
          anyOf:
            - type: string
            - type: 'null'
          title: Website
        external_ref:
          anyOf:
            - type: string
              maxLength: 255
            - type: 'null'
          title: External Ref
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        work_sites:
          items:
            $ref: '#/components/schemas/WorksiteRequest'
          type: array
          title: Work Sites
        bank_accounts:
          items:
            $ref: '#/components/schemas/BankAccountRequest'
          type: array
          title: Bank Accounts
        contacts:
          anyOf:
            - items:
                $ref: '#/components/schemas/ContactRequest'
              type: array
            - type: 'null'
          title: Contacts
        sepa_mandates:
          anyOf:
            - items:
                $ref: '#/components/schemas/SepaMandateRequest'
              type: array
            - type: 'null'
          title: Sepa Mandates
        insurance_data:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/DEOrganizationInsuranceDetailsRequest'
                - $ref: '#/components/schemas/GBOrganizationInsuranceDetailsRequest'
              discriminator:
                propertyName: insurance_country
                mapping:
                  DE:
                    $ref: '#/components/schemas/DEOrganizationInsuranceDetailsRequest'
                  GB:
                    $ref: '#/components/schemas/GBOrganizationInsuranceDetailsRequest'
            - type: 'null'
          title: Insurance Data
        tax_identifiers:
          anyOf:
            - $ref: '#/components/schemas/TaxIdentifiersRequest'
            - type: 'null'
        preferences:
          oneOf:
            - $ref: '#/components/schemas/DEOrganizationPreferencesRequest'
            - $ref: '#/components/schemas/GBOrganizationPreferencesRequest'
          title: Preferences
          discriminator:
            propertyName: preferences_country
            mapping:
              DE:
                $ref: '#/components/schemas/DEOrganizationPreferencesRequest'
              GB:
                $ref: '#/components/schemas/GBOrganizationPreferencesRequest'
      additionalProperties: true
      type: object
      required:
        - legal_name
        - bank_accounts
        - preferences
      title: GBOrganizationRequest
    BulkOperationResponse_OrgResponse_:
      properties:
        total:
          type: integer
          title: Total
          description: Total number of records in the request
        data:
          items:
            $ref: '#/components/schemas/OrgResponse'
          type: array
          title: Data
          description: Successfully processed records
        errors:
          items:
            $ref: '#/components/schemas/OperationError'
          type: array
          title: Errors
          description: Failed records with error details
        succeeded:
          type: integer
          title: Succeeded
          description: Number of successfully processed records
          readOnly: true
        failed:
          type: integer
          title: Failed
          description: Number of failed records
          readOnly: true
        unprocessed:
          type: integer
          title: Unprocessed
          description: Number of records that passed validation but were not processed
          readOnly: true
      additionalProperties: true
      type: object
      required:
        - total
        - succeeded
        - failed
        - unprocessed
      title: BulkOperationResponse[OrgResponse]
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    AddressRequest:
      properties:
        address:
          type: string
          title: Address
        content:
          oneOf:
            - $ref: '#/components/schemas/DEAddressContentRequest'
            - $ref: '#/components/schemas/GBAddressContentRequest'
          title: Content
      additionalProperties: true
      type: object
      required:
        - address
        - content
      title: AddressRequest
    WorksiteRequest:
      properties:
        name:
          type: string
          title: Name
        address:
          $ref: '#/components/schemas/AddressRequest'
        correspondence_address:
          anyOf:
            - $ref: '#/components/schemas/AddressRequest'
            - type: 'null'
        is_active:
          type: boolean
          title: Is Active
        is_primary:
          type: boolean
          title: Is Primary
        valid_from:
          type: string
          format: date
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        contacts:
          anyOf:
            - items:
                $ref: '#/components/schemas/ContactRequest'
              type: array
            - type: 'null'
          title: Contacts
        tax_identifiers:
          anyOf:
            - $ref: '#/components/schemas/TaxIdentifiersRequest'
            - type: 'null'
        insurance_data:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/DEWorksiteInsuranceDetailsRequest'
              discriminator:
                propertyName: insurance_country
                mapping:
                  DE:
                    $ref: '#/components/schemas/DEWorksiteInsuranceDetailsRequest'
            - type: 'null'
          title: Insurance Data
      additionalProperties: true
      type: object
      required:
        - name
        - address
        - is_active
        - is_primary
        - valid_from
      title: WorksiteRequest
    BankAccountRequest:
      properties:
        financial_institution_name:
          type: string
          title: Financial Institution Name
          examples:
            - Deutsche Bank
            - Lloyds Bank
        account_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Account Number
          examples:
            - 'DE: DE89370400440532013000'
            - 'GB: 31926819'
        routing_number:
          anyOf:
            - type: string
              maxLength: 9
              minLength: 9
            - type: 'null'
          title: Routing Number
          examples:
            - 'DE: 370400440'
            - 'GB: 226073523'
        iban:
          anyOf:
            - type: string
              maxLength: 34
              title: IBAN
            - type: 'null'
          title: Iban
          examples:
            - 'DE: DE89370400440532013000'
            - 'GB: GB29NWBK60161331926819'
        swift_code:
          anyOf:
            - type: string
              maxLength: 11
              minLength: 8
              pattern: '[A-Z0-9]{4}[A-Z]{2}[A-Z0-9]{2}(:?[A-Z0-9]{3})?'
              title: BIC
            - type: 'null'
          title: Swift Code
          examples:
            - 'DE: COBADEFFXXX'
            - 'GB: NWBK6016'
        account_details:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Account Details
        is_active:
          type: boolean
          title: Is Active
          default: true
        is_primary:
          type: boolean
          title: Is Primary
          default: false
      additionalProperties: true
      type: object
      required:
        - financial_institution_name
      title: BankAccountRequest
      description: Schema for creating bank accounts
    ContactRequest:
      properties:
        name:
          type: string
          title: Name
        email:
          anyOf:
            - type: string
              format: email
            - type: 'null'
          title: Email
        phone:
          anyOf:
            - $ref: '#/components/schemas/DEPhoneNumber'
            - type: 'null'
        roles:
          items:
            type: string
          type: array
          title: Roles
          default: []
      additionalProperties: true
      type: object
      required:
        - name
      title: ContactRequest
    SepaMandateRequest:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        mandate_reference:
          anyOf:
            - type: string
            - type: 'null'
          title: Mandate Reference
        creditor_id:
          type: string
          title: Creditor Id
        bank_account_id:
          anyOf:
            - type: string
            - type: string
              format: uuid
          title: Bank Account Id
        is_recurring:
          type: boolean
          title: Is Recurring
          default: true
      additionalProperties: true
      type: object
      required:
        - creditor_id
        - bank_account_id
      title: SepaMandateRequest
    DEOrganizationInsuranceDetailsRequest:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        insurance_country:
          type: string
          const: DE
          title: Insurance Country
          default: DE
        company_number:
          anyOf:
            - type: string
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Company Number
          description: 'DE: BBNR'
        unrs:
          anyOf:
            - type: string
              description: >-
                German UNR.S (15 digits: company number + check digit +
                identifier)
              examples:
                - '031041220222001'
                - '029057320227001'
                - '018552220224001'
            - type: 'null'
          title: Unrs
          description: 'DE: UNRS'
          examples:
            - DE987654321
        accident_insurance_company_number:
          anyOf:
            - type: string
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Accident Insurance Company Number
          description: 'DE: BBNR UV'
        accident_insurance_pin:
          anyOf:
            - type: string
              description: German accident insurance PIN (5 digits)
              examples:
                - '12345'
                - '56789'
                - '98765'
            - type: 'null'
          title: Accident Insurance Pin
          description: 'DE: UV PIN'
        payroll_service_provider_number:
          anyOf:
            - type: string
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Payroll Service Provider Number
          description: 'DE: BBNRAS'
        payroll_processing_location_number:
          anyOf:
            - type: string
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Payroll Processing Location Number
          description: 'DE: BBNR LB'
        economic_sector:
          anyOf:
            - $ref: '#/components/schemas/EconomicSector'
            - type: 'null'
          description: 'DE: Wirtschaftssektor'
        u1_selected:
          type: boolean
          title: U1 Selected
          default: false
        u2_selected:
          type: boolean
          title: U2 Selected
          default: false
        u3_selected:
          type: boolean
          title: U3 Selected
          default: false
        agency_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Agency Id
        alternate_agency_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Alternate Agency Id
        contact_id:
          anyOf:
            - type: string
            - type: string
              format: uuid
            - type: 'null'
          title: Contact Id
      additionalProperties: true
      type: object
      title: DEOrganizationInsuranceDetailsRequest
    GBOrganizationInsuranceDetailsRequest:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        insurance_country:
          type: string
          const: GB
          title: Insurance Country
          default: GB
      additionalProperties: true
      type: object
      title: GBOrganizationInsuranceDetailsRequest
    TaxIdentifiersRequest:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        tax_data:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/DETaxIdentifier'
                - $ref: '#/components/schemas/GBTaxIdentifier'
              discriminator:
                propertyName: country
                mapping:
                  DE:
                    $ref: '#/components/schemas/DETaxIdentifier'
                  GB:
                    $ref: '#/components/schemas/GBTaxIdentifier'
            - type: 'null'
          title: Tax Data
      additionalProperties: true
      type: object
      title: TaxIdentifiersRequest
    DEOrganizationPreferencesRequest:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        is_insolvent:
          type: boolean
          title: Is Insolvent
          default: false
        insolvency_start_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Insolvency Start Date
        insolvency_end_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Insolvency End Date
        insolvency_company_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Insolvency Company Number
        insurance_subsidy_method:
          anyOf:
            - type: string
              enum:
                - remuneration
                - assessment_ceiling
            - type: 'null'
          title: Insurance Subsidy Method
        extra_paid_leave_days:
          anyOf:
            - type: integer
            - type: 'null'
          title: Extra Paid Leave Days
        first_payroll_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: First Payroll Date
          description: First payroll (ever) run by the company
        last_payroll_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Last Payroll Date
          description: Last payroll run in other system before Intermezzo's first payroll
        first_payroll_intermezzo:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: First Payroll Intermezzo
          description: First date Intermezzo software is used for payroll
        logo_id:
          anyOf:
            - type: string
            - type: string
              format: uuid
            - type: 'null'
          title: Logo Id
        preferences_country:
          type: string
          const: DE
          title: Preferences Country
          default: DE
        insurance_credit_preference:
          anyOf:
            - type: string
            - type: 'null'
          title: Insurance Credit Preference
          description: >-
            Für die Möglichkeit der Überweisung, Verrechnung oder Gutschrift ist
            eine entsprechende Eingabemöglichkeit vorzusehen.
        days_for_sickness_certificate:
          anyOf:
            - type: integer
            - type: 'null'
          title: Days For Sickness Certificate
          default: 4
        additional_childcare_sick_days_reason:
          anyOf:
            - $ref: '#/components/schemas/ChildcareSickDaysReason'
            - type: 'null'
          description: >-
            Reason for the selection of the number of additional paid sick days
            for childcare.
      additionalProperties: true
      type: object
      title: DEOrganizationPreferencesRequest
    GBOrganizationPreferencesRequest:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        is_insolvent:
          type: boolean
          title: Is Insolvent
          default: false
        insolvency_start_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Insolvency Start Date
        insolvency_end_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Insolvency End Date
        insolvency_company_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Insolvency Company Number
        insurance_subsidy_method:
          anyOf:
            - type: string
              enum:
                - remuneration
                - assessment_ceiling
            - type: 'null'
          title: Insurance Subsidy Method
        extra_paid_leave_days:
          anyOf:
            - type: integer
            - type: 'null'
          title: Extra Paid Leave Days
        first_payroll_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: First Payroll Date
          description: First payroll (ever) run by the company
        last_payroll_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Last Payroll Date
          description: Last payroll run in other system before Intermezzo's first payroll
        first_payroll_intermezzo:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: First Payroll Intermezzo
          description: First date Intermezzo software is used for payroll
        logo_id:
          anyOf:
            - type: string
            - type: string
              format: uuid
            - type: 'null'
          title: Logo Id
        preferences_country:
          type: string
          const: GB
          title: Preferences Country
          default: GB
        sender_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Sender Id
        sender_pass:
          anyOf:
            - type: string
            - type: 'null'
          title: Sender Pass
        sender_email:
          anyOf:
            - type: string
            - type: 'null'
          title: Sender Email
        sender_type:
          anyOf:
            - $ref: '#/components/schemas/SenderType'
            - type: 'null'
        ea_eligible:
          type: boolean
          title: Ea Eligible
          default: false
        ea_annual_allowance:
          anyOf:
            - type: number
            - type: string
              pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
          title: Ea Annual Allowance
          default: '10500'
        bacs_sun:
          anyOf:
            - type: string
              pattern: ^\d{6}$
            - type: 'null'
          title: Bacs Sun
      additionalProperties: true
      type: object
      title: GBOrganizationPreferencesRequest
    OrgResponse:
      properties:
        registration_country:
          $ref: '#/components/schemas/CountryCode'
        legal_name:
          type: string
          title: Legal Name
        address:
          $ref: '#/components/schemas/AddressResponse'
        correspondence_address:
          anyOf:
            - $ref: '#/components/schemas/AddressResponse'
            - type: 'null'
        dba_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Dba Name
        incorporation_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Incorporation Date
        website:
          anyOf:
            - type: string
            - type: 'null'
          title: Website
        external_ref:
          anyOf:
            - type: string
              maxLength: 255
            - type: 'null'
          title: External Ref
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        id:
          type: string
          title: Id
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        shutdown_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Shutdown Date
        work_sites:
          anyOf:
            - items:
                $ref: '#/components/schemas/WorksiteResponse'
              type: array
            - type: 'null'
          title: Work Sites
        bank_accounts:
          anyOf:
            - items:
                $ref: '#/components/schemas/BankAccountResponse'
              type: array
            - type: 'null'
          title: Bank Accounts
        contacts:
          anyOf:
            - items:
                $ref: '#/components/schemas/ContactResponse'
              type: array
            - type: 'null'
          title: Contacts
        tax_identifiers:
          anyOf:
            - $ref: '#/components/schemas/TaxIdentifiersResponse'
            - type: 'null'
        insurance_data:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/DEOrganizationInsuranceDetailsResponse'
                - $ref: '#/components/schemas/GBOrganizationInsuranceDetailsResponse'
              discriminator:
                propertyName: insurance_country
                mapping:
                  DE:
                    $ref: >-
                      #/components/schemas/DEOrganizationInsuranceDetailsResponse
                  GB:
                    $ref: >-
                      #/components/schemas/GBOrganizationInsuranceDetailsResponse
            - type: 'null'
          title: Insurance Data
        sepa_mandates:
          items:
            $ref: '#/components/schemas/SepaMandateResponse'
          type: array
          title: Sepa Mandates
        preferences:
          oneOf:
            - $ref: '#/components/schemas/DEOrganizationPreferencesResponse'
            - $ref: '#/components/schemas/GBOrganizationPreferencesResponse'
          title: Preferences
          discriminator:
            propertyName: preferences_country
            mapping:
              DE:
                $ref: '#/components/schemas/DEOrganizationPreferencesResponse'
              GB:
                $ref: '#/components/schemas/GBOrganizationPreferencesResponse'
      type: object
      required:
        - registration_country
        - legal_name
        - address
        - id
        - created_at
        - updated_at
        - work_sites
        - bank_accounts
        - preferences
      title: OrgResponse
    OperationError:
      properties:
        input_index:
          type: integer
          title: Input Index
          description: Index in the bulk request
        errors:
          items:
            $ref: '#/components/schemas/ErrorDetail'
          type: array
          title: Errors
          description: List of errors that occurred
      additionalProperties: true
      type: object
      required:
        - input_index
        - errors
      title: OperationError
      description: Represents a failed operation with its input context
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    DEAddressContentRequest:
      properties:
        country_code:
          type: string
          const: DE
          title: Country Code
          default: DE
        address_type:
          $ref: '#/components/schemas/CorrespondenceAddressType'
          default: HAUSANSCHRIFT
      additionalProperties: true
      type: object
      title: DEAddressContentRequest
    GBAddressContentRequest:
      properties:
        country_code:
          type: string
          const: GB
          title: Country Code
          default: GB
      additionalProperties: true
      type: object
      title: GBAddressContentRequest
    DEWorksiteInsuranceDetailsRequest:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        insurance_country:
          type: string
          const: DE
          title: Insurance Country
          default: DE
        worksite_location_number:
          anyOf:
            - type: string
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Worksite Location Number
          description: 'DE: BBNRVU'
        accident_insurance_company_number:
          anyOf:
            - type: string
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Accident Insurance Company Number
          description: 'DE: BBNR UV'
        accident_insurance_pin:
          anyOf:
            - type: string
              description: German accident insurance PIN (5 digits)
              examples:
                - '12345'
                - '56789'
                - '98765'
            - type: 'null'
          title: Accident Insurance Pin
          description: 'DE: UV PIN'
          examples:
            - DE-WS-PIN-456
        payroll_service_provider_number:
          anyOf:
            - type: string
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Payroll Service Provider Number
          description: 'DE: BBNR AS'
        payroll_processing_location_number:
          anyOf:
            - type: string
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Payroll Processing Location Number
          description: 'DE: BBNR LB'
      additionalProperties: true
      type: object
      title: DEWorksiteInsuranceDetailsRequest
    DEPhoneNumber:
      properties:
        phone_number:
          type: string
          format: phone
          title: Phone Number
        phone_type:
          $ref: '#/components/schemas/payroll__gb__schema__employee__PhoneType'
      additionalProperties: true
      type: object
      required:
        - phone_number
        - phone_type
      title: DEPhoneNumber
    EconomicSector:
      type: integer
      enum:
        - 1
        - 2
        - 3
        - 4
        - 5
        - 6
        - 7
        - 8
        - 9
        - 10
        - 11
        - 12
        - 13
        - 14
        - 15
        - 16
        - 17
        - 18
        - 19
        - 20
        - 21
        - 22
      title: EconomicSector
      description: >-
        Wirtschaftssektor (Economic Sector) enumeration for German
        organizations.
    DETaxIdentifier:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        country:
          type: string
          const: DE
          title: Country
        tax_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Tax Number
          description: Steuernummer
        business_type:
          anyOf:
            - $ref: '#/components/schemas/DEBusinessType'
            - type: 'null'
        is_employee_flat_tax:
          type: boolean
          title: Is Employee Flat Tax
          default: false
        is_employee_mini_job_flat_tax:
          type: boolean
          title: Is Employee Mini Job Flat Tax
          default: false
        tax_filing_frequency:
          anyOf:
            - type: string
              enum:
                - monthly
                - quarterly
                - yearly
            - type: 'null'
          title: Tax Filing Frequency
      additionalProperties: true
      type: object
      required:
        - country
      title: DETaxIdentifier
    GBTaxIdentifier:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        country:
          type: string
          const: GB
          title: Country
        business_type:
          $ref: '#/components/schemas/GBBusinessType'
        paye_reference_number:
          type: string
          pattern: ^\d{3}/[a-zA-Z0-9]{1,10}$
          title: Paye Reference Number
        accounts_office_reference:
          type: string
          pattern: ^\d{3}P[a-zA-Z](\d{8}|\d{7}X)$
          title: Accounts Office Reference
        corporation_tax_reference:
          anyOf:
            - type: string
              pattern: ^\d{10}$
            - type: 'null'
          title: Corporation Tax Reference
      additionalProperties: true
      type: object
      required:
        - country
        - business_type
        - paye_reference_number
        - accounts_office_reference
      title: GBTaxIdentifier
    ChildcareSickDaysReason:
      type: integer
      enum:
        - 0
        - 1
        - 2
        - 3
      title: ChildcareSickDaysReason
    SenderType:
      type: string
      enum:
        - EMPLOYER
        - AGENT
        - BUREAU
      title: SenderType
      description: Sender type enumeration.
    CountryCode:
      type: string
      enum:
        - DE
        - IE
        - GB
        - US
        - GB
      title: CountryCode
      description: Enum for CountryAlpha2 codes
    AddressResponse:
      properties:
        id:
          type: string
          title: Id
        address:
          type: string
          title: Address
        components:
          $ref: '#/components/schemas/AddressComponents'
        content:
          oneOf:
            - $ref: '#/components/schemas/DEAddressContentResponse'
            - $ref: '#/components/schemas/GBAddressContentResponse'
          title: Content
      additionalProperties: true
      type: object
      required:
        - id
        - address
        - components
        - content
      title: AddressResponse
    WorksiteResponse:
      properties:
        name:
          type: string
          title: Name
        address:
          $ref: '#/components/schemas/AddressResponse'
        correspondence_address:
          anyOf:
            - $ref: '#/components/schemas/AddressResponse'
            - type: 'null'
        is_active:
          type: boolean
          title: Is Active
        is_primary:
          type: boolean
          title: Is Primary
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        id:
          type: string
          title: Id
        org_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Org Id
        contacts:
          anyOf:
            - items:
                $ref: '#/components/schemas/ContactResponse'
              type: array
            - type: 'null'
          title: Contacts
        tax_identifiers:
          anyOf:
            - $ref: '#/components/schemas/TaxIdentifiersResponse'
            - type: 'null'
        insurance_data:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/DEWorksiteInsuranceDetailsResponse'
              discriminator:
                propertyName: insurance_country
                mapping:
                  DE:
                    $ref: '#/components/schemas/DEWorksiteInsuranceDetailsResponse'
            - type: 'null'
          title: Insurance Data
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
      type: object
      required:
        - name
        - address
        - is_active
        - is_primary
        - id
        - created_at
        - updated_at
      title: WorksiteResponse
    BankAccountResponse:
      properties:
        financial_institution_name:
          type: string
          title: Financial Institution Name
          examples:
            - Deutsche Bank
            - Lloyds Bank
        account_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Account Number
          examples:
            - 'DE: DE89370400440532013000'
            - 'GB: 31926819'
        routing_number:
          anyOf:
            - type: string
              maxLength: 9
              minLength: 9
            - type: 'null'
          title: Routing Number
          examples:
            - 'DE: 370400440'
            - 'GB: 226073523'
        iban:
          anyOf:
            - type: string
              title: IBAN
            - type: 'null'
          title: Iban
          examples:
            - 'DE: DE89370400440532013000'
            - 'GB: GB29NWBK60161331926819'
        swift_code:
          anyOf:
            - type: string
              title: BIC
            - type: 'null'
          title: Swift Code
          examples:
            - 'DE: COBADEFFXXX'
            - 'GB: NWBK6016'
        account_details:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Account Details
        is_active:
          type: boolean
          title: Is Active
          default: true
        is_primary:
          type: boolean
          title: Is Primary
          default: false
        id:
          type: string
          title: Id
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
      additionalProperties: true
      type: object
      required:
        - financial_institution_name
        - id
        - created_at
        - updated_at
      title: BankAccountResponse
      description: Schema for bank account responses
    ContactResponse:
      properties:
        name:
          type: string
          title: Name
        email:
          anyOf:
            - type: string
              format: email
            - type: 'null'
          title: Email
        phone:
          anyOf:
            - $ref: '#/components/schemas/DEPhoneNumber'
            - type: 'null'
        id:
          type: string
          title: Id
        roles:
          items:
            type: string
          type: array
          title: Roles
          default: []
      additionalProperties: true
      type: object
      required:
        - name
        - id
      title: ContactResponse
    TaxIdentifiersResponse:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        id:
          type: integer
          title: Id
        tax_data:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/DETaxIdentifier'
                - $ref: '#/components/schemas/GBTaxIdentifier'
              discriminator:
                propertyName: country
                mapping:
                  DE:
                    $ref: '#/components/schemas/DETaxIdentifier'
                  GB:
                    $ref: '#/components/schemas/GBTaxIdentifier'
            - type: 'null'
          title: Tax Data
      additionalProperties: true
      type: object
      required:
        - id
      title: TaxIdentifiersResponse
    DEOrganizationInsuranceDetailsResponse:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        insurance_country:
          type: string
          const: DE
          title: Insurance Country
          default: DE
        company_number:
          anyOf:
            - type: string
              pattern: ^\d{8}$
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Company Number
          description: 'DE: BBNR'
        unrs:
          anyOf:
            - type: string
              pattern: ^\d{15}$
              description: >-
                German UNR.S (15 digits: company number + check digit +
                identifier)
              examples:
                - '031041220222001'
                - '029057320227001'
                - '018552220224001'
            - type: 'null'
          title: Unrs
          description: 'DE: UNRS'
          examples:
            - DE987654321
        accident_insurance_company_number:
          anyOf:
            - type: string
              pattern: ^\d{8}$
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Accident Insurance Company Number
          description: 'DE: BBNR UV'
        accident_insurance_pin:
          anyOf:
            - type: string
              pattern: ^\d{5}$
              description: German accident insurance PIN (5 digits)
              examples:
                - '12345'
                - '56789'
                - '98765'
            - type: 'null'
          title: Accident Insurance Pin
          description: 'DE: UV PIN'
        payroll_service_provider_number:
          anyOf:
            - type: string
              pattern: ^\d{8}$
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Payroll Service Provider Number
          description: 'DE: BBNRAS'
        payroll_processing_location_number:
          anyOf:
            - type: string
              pattern: ^\d{8}$
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Payroll Processing Location Number
          description: 'DE: BBNR LB'
        economic_sector:
          anyOf:
            - $ref: '#/components/schemas/EconomicSector'
            - type: 'null'
          description: 'DE: Wirtschaftssektor'
        u1_selected:
          type: boolean
          title: U1 Selected
          default: false
        u2_selected:
          type: boolean
          title: U2 Selected
          default: false
        u3_selected:
          type: boolean
          title: U3 Selected
          default: false
        agency_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Agency Id
        alternate_agency_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Alternate Agency Id
        contact_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Contact Id
        id:
          type: integer
          title: Id
      additionalProperties: true
      type: object
      required:
        - id
      title: DEOrganizationInsuranceDetailsResponse
    GBOrganizationInsuranceDetailsResponse:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        insurance_country:
          type: string
          const: GB
          title: Insurance Country
          default: GB
        id:
          type: integer
          title: Id
      additionalProperties: true
      type: object
      required:
        - id
      title: GBOrganizationInsuranceDetailsResponse
    SepaMandateResponse:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        mandate_reference:
          anyOf:
            - type: string
            - type: 'null'
          title: Mandate Reference
        creditor_id:
          type: string
          title: Creditor Id
        bank_account_id:
          type: string
          title: Bank Account Id
        is_recurring:
          type: boolean
          title: Is Recurring
        id:
          type: string
          title: Id
        created_by:
          type: string
          title: Created By
      additionalProperties: true
      type: object
      required:
        - creditor_id
        - bank_account_id
        - is_recurring
        - id
        - created_by
      title: SepaMandateResponse
    DEOrganizationPreferencesResponse:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        is_insolvent:
          type: boolean
          title: Is Insolvent
          default: false
        insolvency_start_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Insolvency Start Date
        insolvency_end_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Insolvency End Date
        insolvency_company_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Insolvency Company Number
        insurance_subsidy_method:
          anyOf:
            - type: string
              enum:
                - remuneration
                - assessment_ceiling
            - type: 'null'
          title: Insurance Subsidy Method
        extra_paid_leave_days:
          anyOf:
            - type: integer
            - type: 'null'
          title: Extra Paid Leave Days
        first_payroll_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: First Payroll Date
          description: First payroll (ever) run by the company
        last_payroll_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Last Payroll Date
          description: Last payroll run in other system before Intermezzo's first payroll
        first_payroll_intermezzo:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: First Payroll Intermezzo
          description: First date Intermezzo software is used for payroll
        logo_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Logo Id
        preferences_country:
          type: string
          const: DE
          title: Preferences Country
          default: DE
        insurance_credit_preference:
          anyOf:
            - type: string
            - type: 'null'
          title: Insurance Credit Preference
          description: >-
            Für die Möglichkeit der Überweisung, Verrechnung oder Gutschrift ist
            eine entsprechende Eingabemöglichkeit vorzusehen.
        days_for_sickness_certificate:
          anyOf:
            - type: integer
            - type: 'null'
          title: Days For Sickness Certificate
          default: 4
        additional_childcare_sick_days_reason:
          anyOf:
            - $ref: '#/components/schemas/ChildcareSickDaysReason'
            - type: 'null'
          description: >-
            Reason for the selection of the number of additional paid sick days
            for childcare.
        id:
          type: integer
          title: Id
      additionalProperties: true
      type: object
      required:
        - id
      title: DEOrganizationPreferencesResponse
    GBOrganizationPreferencesResponse:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        is_insolvent:
          type: boolean
          title: Is Insolvent
          default: false
        insolvency_start_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Insolvency Start Date
        insolvency_end_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Insolvency End Date
        insolvency_company_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Insolvency Company Number
        insurance_subsidy_method:
          anyOf:
            - type: string
              enum:
                - remuneration
                - assessment_ceiling
            - type: 'null'
          title: Insurance Subsidy Method
        extra_paid_leave_days:
          anyOf:
            - type: integer
            - type: 'null'
          title: Extra Paid Leave Days
        first_payroll_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: First Payroll Date
          description: First payroll (ever) run by the company
        last_payroll_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Last Payroll Date
          description: Last payroll run in other system before Intermezzo's first payroll
        first_payroll_intermezzo:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: First Payroll Intermezzo
          description: First date Intermezzo software is used for payroll
        logo_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Logo Id
        preferences_country:
          type: string
          const: GB
          title: Preferences Country
          default: GB
        sender_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Sender Id
        sender_pass:
          anyOf:
            - type: string
            - type: 'null'
          title: Sender Pass
        sender_email:
          anyOf:
            - type: string
            - type: 'null'
          title: Sender Email
        sender_type:
          anyOf:
            - $ref: '#/components/schemas/SenderType'
            - type: 'null'
        ea_eligible:
          type: boolean
          title: Ea Eligible
          default: false
        ea_annual_allowance:
          type: string
          pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
          title: Ea Annual Allowance
          default: '10500'
        bacs_sun:
          anyOf:
            - type: string
              pattern: ^\d{6}$
            - type: 'null'
          title: Bacs Sun
        id:
          type: integer
          title: Id
      additionalProperties: true
      type: object
      required:
        - id
      title: GBOrganizationPreferencesResponse
    ErrorDetail:
      properties:
        code:
          anyOf:
            - $ref: '#/components/schemas/ErrorCode'
            - $ref: '#/components/schemas/PydanticErrorCode'
          title: Code
          description: Unique error code for i18n lookup
        message:
          type: string
          title: Message
          description: English fallback error message
        field:
          anyOf:
            - type: string
            - type: 'null'
          title: Field
          description: Field that caused the error
        params:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Params
          description: Parameters for translation interpolation
      additionalProperties: true
      type: object
      required:
        - code
        - message
      title: ErrorDetail
      description: |-
        Represents an error that occurred during processing.

        Designed for client-side i18n:
        - code: Use this to look up translation (e.g., "ORG_NOT_FOUND")
        - message: English fallback if translation not available
        - field: Field name for form validation highlighting
        - params: Dynamic values for translation interpolation
    CorrespondenceAddressType:
      type: string
      enum:
        - HAUSANSCHRIFT
        - POSTFACH
        - GROSSEMPFAENGER
        - AUSLANDSANSCHRIFT
      title: CorrespondenceAddressType
    payroll__gb__schema__employee__PhoneType:
      type: string
      enum:
        - mobile
        - home
        - work
      title: PhoneType
    DEBusinessType:
      type: integer
      enum:
        - 170
        - 180
        - 210
        - 211
        - 220
        - 221
        - 222
        - 223
        - 230
        - 231
        - 232
        - 240
        - 241
        - 242
        - 250
        - 251
        - 260
        - 270
        - 280
        - 290
        - 310
        - 320
        - 321
        - 322
        - 323
        - 324
        - 350
        - 351
        - 355
        - 356
        - 360
        - 400
        - 450
        - 510
        - 590
        - 610
        - 611
        - 700
        - 790
        - 911
        - 912
        - 921
        - 991
        - 992
        - 999
      title: DEBusinessType
      description: German Business Types based on Federal Employment Agency (BA) codes
    GBBusinessType:
      type: string
      enum:
        - Sole Trader
        - Partnership
        - Limited Company
        - Public Limited Company
        - Limited Liability Partnership
        - Community Interest Company
      title: GBBusinessType
    AddressComponents:
      properties:
        formatted_address:
          anyOf:
            - type: string
            - type: 'null'
          title: Formatted Address
        street_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Street Number
        road:
          anyOf:
            - type: string
            - type: 'null'
          title: Road
        city:
          anyOf:
            - type: string
            - type: 'null'
          title: City
        state:
          anyOf:
            - type: string
            - type: 'null'
          title: State
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
        postal_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Postal Code
        postal_code_suffix:
          anyOf:
            - type: string
            - type: 'null'
          title: Postal Code Suffix
        latitude:
          anyOf:
            - type: number
            - type: 'null'
          title: Latitude
        longitude:
          anyOf:
            - type: number
            - type: 'null'
          title: Longitude
      type: object
      title: AddressComponents
    DEAddressContentResponse:
      properties:
        country_code:
          type: string
          const: DE
          title: Country Code
          default: DE
        address_type:
          $ref: '#/components/schemas/CorrespondenceAddressType'
          default: HAUSANSCHRIFT
        normalized_address:
          type: string
          title: Normalized Address
      additionalProperties: true
      type: object
      required:
        - normalized_address
      title: DEAddressContentResponse
    GBAddressContentResponse:
      properties: {}
      additionalProperties: true
      type: object
      title: GBAddressContentResponse
    DEWorksiteInsuranceDetailsResponse:
      properties:
        valid_from:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid From
        valid_to:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Valid To
        insurance_country:
          type: string
          const: DE
          title: Insurance Country
          default: DE
        worksite_location_number:
          anyOf:
            - type: string
              pattern: ^\d{8}$
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Worksite Location Number
          description: 'DE: BBNRVU'
        accident_insurance_company_number:
          anyOf:
            - type: string
              pattern: ^\d{8}$
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Accident Insurance Company Number
          description: 'DE: BBNR UV'
        accident_insurance_pin:
          anyOf:
            - type: string
              pattern: ^\d{5}$
              description: German accident insurance PIN (5 digits)
              examples:
                - '12345'
                - '56789'
                - '98765'
            - type: 'null'
          title: Accident Insurance Pin
          description: 'DE: UV PIN'
          examples:
            - DE-WS-PIN-456
        payroll_service_provider_number:
          anyOf:
            - type: string
              pattern: ^\d{8}$
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Payroll Service Provider Number
          description: 'DE: BBNR AS'
        payroll_processing_location_number:
          anyOf:
            - type: string
              pattern: ^\d{8}$
              description: 'German Betriebsnummer (8 digits: xxx-yyyy-z format)'
              examples:
                - '98797889'
                - '15186676'
                - '99302952'
            - type: 'null'
          title: Payroll Processing Location Number
          description: 'DE: BBNR LB'
        id:
          type: integer
          title: Id
      additionalProperties: true
      type: object
      required:
        - id
      title: DEWorksiteInsuranceDetailsResponse
    ErrorCode:
      type: string
      enum:
        - ADDRESS_NOT_FOUND
        - ADDRESS_CREATION_ERROR
        - ADDRESS_UPDATING_ERROR
        - ADDRESS_COUNTRY_CODE_MISMATCH
        - ORG_NOT_FOUND
        - ORG_DUPLICATE_EXTERNAL_REF
        - ORG_HAS_ACTIVE_EMPLOYEES
        - ORG_ALREADY_SHUTDOWN
        - ORG_COUNTRY_CHANGE_NOT_ALLOWED
        - ORG_BELONGS_TO_A_DIFFERENT_COUNTRY
        - CONTACT_NOT_FOUND
        - CONTACT_ACCESS_DENIED
        - WORKSITE_NOT_FOUND
        - BANK_ACCOUNT_NOT_FOUND
        - BANK_ACCOUNT_MISSING_SWIFT
        - BANK_ACCOUNT_MISSING_IBAN
        - BANK_ACCOUNT_INVALID_COMBINATION
        - BANK_ACCOUNT_NOT_ASSOCIATED_WITH_EMPLOYEE
        - BANK_ACCOUNT_NOT_ASSOCIATED_WITH_ORG
        - BANK_ACCOUNT_REFERENCED_BY_SEPA_MANDATE
        - EMPLOYEE_NOT_FOUND
        - EMPLOYEE_ACCESS_DENIED
        - EMPLOYEES_ACCESS_DENIED
        - EMPLOYEE_OPERATION_FAILED
        - EMPLOYEES_DO_NOT_BELONG_TO_PAY_GROUP
        - EMPLOYEES_ASSIGNED_TO_PAY_GROUP
        - DUPLICATE_EMPLOYEE_IDS
        - PAYROLL_STATUS_NOT_FOUND
        - TASK_STATUS_CHECKER_NOT_FOUND
        - PAYROLL_TASK_INVALID_STATUS
        - CALCULATION_TASK_NOT_FOUND_IN_PAYROLL
        - PAYRUN_NOT_FOUND
        - PAYRUN_NOT_IN_DRAFT_STATUS
        - PAYRUN_NOT_APPROVED
        - PAYRUN_STILL_PROCESSING
        - PAYRUN_MISSING_PAYSLIPS
        - PAYRUN_OPERATION_FAILED
        - PAYRUN_CONTAINS_EMPLOYEES_NOT_IN_PAY_GROUP
        - PAYRUN_EMPTY_PAY_DETAILS
        - PAYRUN_NMW_VIOLATIONS
        - SACRIFICE_NOT_ALLOWED
        - PAY_GROUP_NOT_FOUND
        - ONE_OR_MORE_PAY_GROUP_NOT_FOUND
        - PAY_GROUP_IS_IN_RUNNING_PAYROLL
        - PAY_CALENDAR_NOT_FOUND
        - PAY_PERIOD_UNRESOLVED
        - SEPA_MANDATE_NOT_FOUND
        - SEPA_MANDATE_DUPLICATE_REFERENCE
        - INSURANCE_DATA_NOT_FOUND
        - INSURANCE_LEVEL_CHOICE_NOT_FOUND
        - INSURANCE_LEVEL_CHOICE_ALREADY_EXISTS
        - INSURANCE_LEVEL_CHOICE_INVALID
        - INSURANCE_AGENCY_NOT_FOUND
        - INVALID_COMPANY_NUMBER
        - INVALID_WORKSITE_LOCATION_NUMBER
        - U1_CHANGES_NOT_ALLOWED
        - NON_GERMAN_ORGANIZATION
        - INSURANCE_OPERATION_FAILED
        - PREFERENCES_NOT_FOUND
        - EMPLOYEE_DETAIL_NOT_FOUND
        - EMPLOYEE_DETAIL_OPERATION_FAILED
        - TAX_IDENTIFIER_NOT_FOUND
        - TAX_DATA_REQUIRED
        - PAYSLIP_OPERATION_FAILED
        - PAYSLIP_PDF_GENERATION_FAILED
        - PAYSLIP_FPS_VALIDATION_FAILED
        - PAYSLIP_FPS_SUBMISSION_FAILED
        - PAYSLIP_FPS_POLLING_FAILED
        - PAYSLIP_NOT_FOUND
        - DOCUMENT_NOT_FOUND
        - DOCUMENT_ACCESS_DENIED
        - DOCUMENT_UPLOAD_FAILED
        - DOCUMENT_DOWNLOAD_FAILED
        - DOCUMENT_DELETION_FAILED
        - DOCUMENT_OPERATION_FAILED
        - DOCUMENT_INVALID_TYPE
        - DOCUMENT_SIZE_EXCEEDED
        - DOCUMENT_UNSUPPORTED_FILE_TYPE
        - DOCUMENT_RATE_LIMIT_EXCEEDED
        - DOCUMENT_TEMPLATE_NOT_FOUND
        - DOCUMENT_TEMPLATE_INVALID_SYNTAX
        - DOCUMENT_TEMPLATE_ALREADY_ACTIVE
        - DOCUMENT_TEMPLATE_OPERATION_FAILED
        - WAGE_TYPE_NOT_FOUND
        - WAGE_TYPE_ALREADY_EXISTS
        - WAGE_TYPE_DRAFT_EXISTS
        - WAGE_TYPE_INVALID_DATE
        - COMPENSATION_EFFECTIVE_DATE_TOO_OLD
        - PENSION_SCHEME_NOT_FOUND
        - PENSION_SCHEME_ALREADY_EXISTS
        - PENSION_SCHEME_INVALID_VALID_FROM
        - PENSION_MEMBERSHIP_NOT_FOUND
        - PENSION_MEMBERSHIP_ALREADY_ACTIVE
        - PENSION_MEMBERSHIP_NOT_ACTIVE
        - PENSION_MEMBERSHIP_INVALID_VALID_FROM
        - PENSION_WAGE_TYPE_OVERRIDE_INCOMPLETE
        - PENSION_WAGE_TYPE_MISMATCH
        - PENSION_RATE_BELOW_MINIMUM
        - P32_EA_INELIGIBLE
        - P32_RECORD_NOT_FOUND
        - P32_NO_SURPLUS
        - P32_REPAYMENT_EXCEEDS_SURPLUS
        - HMRC_STATUS_NOT_FOUND
        - HMRC_INVALID_STATE_TRANSITION
        - EPS_NOT_FOUND
        - EPS_DATE_SCHEME_CEASED_IN_FUTURE
        - EPS_FINAL_SUBMISSION_NO_TYPE
        - EPS_DATE_SCHEME_CEASED_WITHOUT_SCHEME_CEASED
        - EPS_RECOVERABLE_AMOUNTS_NO_FIELDS
        - EPS_NO_SECTIONS_PROVIDED
        - P11D_INVALID_TAX_YEAR
        - P11D_OUTSIDE_FILING_WINDOW
        - P11D_NOT_FOUND
        - P11D_DELETE_BLOCKED
        - BACS_SUN_NOT_CONFIGURED
        - BACS_FILE_NOT_FOUND
        - BACS_TASK_NOT_SCHEDULED
        - BACS_TASK_IN_PROGRESS
        - BACS_TASK_FAILED
        - BACS_NO_PAYMENTS
        - GB_RTI_ID_DUPLICATE
        - GB_RTI_ID_REUSED_IN_TAX_YEAR
        - GB_PAYROLL_CALCULATION_RESULTS_NOT_READY
        - EXB_SUBMISSION_ALREADY_EXISTS
        - EXB_SUBMISSION_NOT_FOUND
        - EXB_OUTSIDE_FILING_WINDOW
        - EXB_INVALID_TAX_YEAR
        - P46_CAR_NOT_FOUND
        - P46_CAR_LOCKED
      title: ErrorCode
      description: |-
        Centralized error codes for i18n translation.

        Naming convention: {RESOURCE}_{ERROR_TYPE}
        - ORG_NOT_FOUND - Organization not found
    PydanticErrorCode:
      type: string
      enum:
        - FIELD_REQUIRED
        - FIELD_INVALID_TYPE_STRING
        - FIELD_INVALID_TYPE_INT
        - FIELD_INVALID_TYPE_FLOAT
        - FIELD_INVALID_TYPE_BOOL
        - FIELD_INVALID_TYPE_DICT
        - FIELD_INVALID_TYPE_LIST
        - FIELD_STRING_TOO_SHORT
        - FIELD_STRING_TOO_LONG
        - FIELD_STRING_PATTERN_MISMATCH
        - FIELD_VALUE_TOO_SMALL
        - FIELD_VALUE_TOO_LARGE
        - FIELD_INVALID_DATE
        - FIELD_INVALID_DATETIME
        - FIELD_INVALID_TIME
        - FIELD_INVALID_DATE_FORMAT
        - FIELD_INVALID_DATETIME_FORMAT
        - FIELD_INVALID_ENUM_VALUE
        - FIELD_INVALID_EMAIL
        - FIELD_INVALID_URL
        - FIELD_LIST_TOO_SHORT
        - FIELD_LIST_TOO_LONG
        - FIELD_VALIDATION_ERROR
      title: PydanticErrorCode
      description: |-
        Error codes for Pydantic validation errors.

        Maps Pydantic error types to our error codes for i18n.
  securitySchemes:
    BearerToken:
      type: oauth2
      flows:
        password:
          scopes:
            read:all: Read all
            write:all: Write all
            read:health_check: Read health check
            write:health_check: Write health check
            read:wage_types: Read wage types
            write:wage_types: Write wage types
          tokenUrl: >-
            https://auth-preview.intermezzo.ai/authorize?audience=api-preview.intermezzo.ai

````