> ## 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.

# Update Organization Insurance Details



## OpenAPI

````yaml /api-reference/preview.json patch /organizations/{organization_id}/insurance-details/{insurance_details_id}
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers: []
security: []
paths:
  /organizations/{organization_id}/insurance-details/{insurance_details_id}:
    patch:
      tags:
        - Core
        - Organizations
        - Insurance Details
      summary: Update Organization Insurance Details
      operationId: >-
        update_organization_insurance_details_organizations__organization_id__insurance_details__insurance_details_id__patch
      parameters:
        - name: organization_id
          in: path
          required: true
          schema:
            anyOf:
              - type: string
              - type: string
                format: uuid
            title: Organization Id
        - name: insurance_details_id
          in: path
          required: true
          schema:
            type: integer
            title: Insurance Details Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              anyOf:
                - $ref: >-
                    #/components/schemas/DEOrganizationInsuranceDetailsUpdateRequest
                - $ref: >-
                    #/components/schemas/GBOrganizationInsuranceDetailsUpdateRequest
              title: Request
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: >-
                      #/components/schemas/DEOrganizationInsuranceDetailsResponse
                  - $ref: >-
                      #/components/schemas/GBOrganizationInsuranceDetailsResponse
                discriminator:
                  propertyName: insurance_country
                  mapping:
                    DE:
                      $ref: >-
                        #/components/schemas/DEOrganizationInsuranceDetailsResponse
                    GB:
                      $ref: >-
                        #/components/schemas/GBOrganizationInsuranceDetailsResponse
                title: >-
                  Response Update Organization Insurance Details Organizations 
                  Organization Id  Insurance Details  Insurance Details Id 
                  Patch
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - BearerToken: []
components:
  schemas:
    DEOrganizationInsuranceDetailsUpdateRequest:
      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
        unrs:
          anyOf:
            - type: string
              description: >-
                German UNR.S (15 digits: company number + check digit +
                identifier)
              examples:
                - '031041220222001'
                - '029057320227001'
                - '018552220224001'
            - type: 'null'
          title: Unrs
        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
        accident_insurance_pin:
          anyOf:
            - type: string
              description: German accident insurance PIN (5 digits)
              examples:
                - '12345'
                - '56789'
                - '98765'
            - type: 'null'
          title: Accident Insurance 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
        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
        economic_sector:
          anyOf:
            - $ref: '#/components/schemas/EconomicSector'
            - type: 'null'
        u1_selected:
          anyOf:
            - type: boolean
            - type: 'null'
          title: U1 Selected
        u2_selected:
          anyOf:
            - type: boolean
            - type: 'null'
          title: U2 Selected
        u3_selected:
          anyOf:
            - type: boolean
            - type: 'null'
          title: U3 Selected
        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: DEOrganizationInsuranceDetailsUpdateRequest
    GBOrganizationInsuranceDetailsUpdateRequest:
      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: GBOrganizationInsuranceDetailsUpdateRequest
    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
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    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.
    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
  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

````