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

# Update approvers for a member

> 
        This endpoint allows updating the approvers for a specific member based on the chosen approval process.
        Depending on the provided configuration:
        - If Microsoft profile managers are used, department and custom approvers are ignored.
        - If department settings are used, Microsoft profile managers and custom approvers are ignored.
        - If custom approvers are provided, Microsoft profile managers and department settings are ignored.

        **No Approver (Self-Approval):**
        To set "no approver" for a member, provide an empty array: `approvers: []`.
        The system will automatically configure the member as their own approver (self-approval),
        which is internally recognized as "no approver" throughout the application.

        The 'id' and 'approval_process' fields are always required.
      



## OpenAPI

````yaml https://api.absentify.com/api/v1/openapi.json put /members/{id}/approvers
openapi: 3.1.0
info:
  title: absentify CRUD API
  description: OpenAPI compliant REST API
  version: 1.0.0
servers:
  - url: https://api.absentify.com/api/v1
security: []
tags:
  - name: Departments
  - name: Leave types
  - name: Members
  - name: Requests
  - name: Public holidays
  - name: Workspace
  - name: Absences
  - name: Allowance Management
externalDocs:
  url: https://absentify.com/docs/en/api-reference
paths:
  /members/{id}/approvers:
    put:
      tags:
        - Members
      summary: Update approvers for a member
      description: |2-

                This endpoint allows updating the approvers for a specific member based on the chosen approval process.
                Depending on the provided configuration:
                - If Microsoft profile managers are used, department and custom approvers are ignored.
                - If department settings are used, Microsoft profile managers and custom approvers are ignored.
                - If custom approvers are provided, Microsoft profile managers and department settings are ignored.

                **No Approver (Self-Approval):**
                To set "no approver" for a member, provide an empty array: `approvers: []`.
                The system will automatically configure the member as their own approver (self-approval),
                which is internally recognized as "no approver" throughout the application.

                The 'id' and 'approval_process' fields are always required.
              
      operationId: member-updateMemberApprovers
      parameters:
        - in: path
          name: id
          schema:
            type: string
            format: uuid
            pattern: >-
              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          required: true
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                approval_process:
                  type: string
                  enum:
                    - Linear_all_have_to_agree
                    - Linear_one_has_to_agree
                    - Parallel_all_have_to_agree
                    - Parallel_one_has_to_agree
                microsoft_settings:
                  type: object
                  properties:
                    use_profile_managers:
                      type: boolean
                    profile_managers_level:
                      anyOf:
                        - type: integer
                          minimum: -9007199254740991
                          maximum: 9007199254740991
                        - type: 'null'
                  required:
                    - use_profile_managers
                    - profile_managers_level
                department_settings:
                  type: object
                  properties:
                    use_department_settings:
                      type: boolean
                    department_id:
                      anyOf:
                        - type: string
                        - type: 'null'
                  required:
                    - use_department_settings
                    - department_id
                approvers:
                  type: array
                  items:
                    type: object
                    properties:
                      member_id:
                        type: string
                      predecessor_manager_id:
                        anyOf:
                          - type: string
                          - type: 'null'
                    required:
                      - member_id
                      - predecessor_manager_id
              required:
                - approval_process
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: string
                format: uuid
                pattern: >-
                  ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
        '400':
          description: Invalid input data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error.BAD_REQUEST'
        '401':
          description: Authorization not provided
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error.UNAUTHORIZED'
        '403':
          description: Insufficient access
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error.FORBIDDEN'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error.NOT_FOUND'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error.INTERNAL_SERVER_ERROR'
      security:
        - ApiKey: []
components:
  schemas:
    error.BAD_REQUEST:
      type: object
      properties:
        message:
          type: string
          description: The error message
          example: Invalid input data
        code:
          type: string
          description: The error code
          example: BAD_REQUEST
        issues:
          description: An array of issues that were responsible for the error
          example: []
          type: array
          items:
            type: object
            properties:
              message:
                type: string
            required:
              - message
            additionalProperties: false
      required:
        - message
        - code
      additionalProperties: false
      title: Invalid input data error (400)
      description: The error information
      example:
        code: BAD_REQUEST
        message: Invalid input data
        issues: []
    error.UNAUTHORIZED:
      type: object
      properties:
        message:
          type: string
          description: The error message
          example: Authorization not provided
        code:
          type: string
          description: The error code
          example: UNAUTHORIZED
        issues:
          description: An array of issues that were responsible for the error
          example: []
          type: array
          items:
            type: object
            properties:
              message:
                type: string
            required:
              - message
            additionalProperties: false
      required:
        - message
        - code
      additionalProperties: false
      title: Authorization not provided error (401)
      description: The error information
      example:
        code: UNAUTHORIZED
        message: Authorization not provided
        issues: []
    error.FORBIDDEN:
      type: object
      properties:
        message:
          type: string
          description: The error message
          example: Insufficient access
        code:
          type: string
          description: The error code
          example: FORBIDDEN
        issues:
          description: An array of issues that were responsible for the error
          example: []
          type: array
          items:
            type: object
            properties:
              message:
                type: string
            required:
              - message
            additionalProperties: false
      required:
        - message
        - code
      additionalProperties: false
      title: Insufficient access error (403)
      description: The error information
      example:
        code: FORBIDDEN
        message: Insufficient access
        issues: []
    error.NOT_FOUND:
      type: object
      properties:
        message:
          type: string
          description: The error message
          example: Not found
        code:
          type: string
          description: The error code
          example: NOT_FOUND
        issues:
          description: An array of issues that were responsible for the error
          example: []
          type: array
          items:
            type: object
            properties:
              message:
                type: string
            required:
              - message
            additionalProperties: false
      required:
        - message
        - code
      additionalProperties: false
      title: Not found error (404)
      description: The error information
      example:
        code: NOT_FOUND
        message: Not found
        issues: []
    error.INTERNAL_SERVER_ERROR:
      type: object
      properties:
        message:
          type: string
          description: The error message
          example: Internal server error
        code:
          type: string
          description: The error code
          example: INTERNAL_SERVER_ERROR
        issues:
          description: An array of issues that were responsible for the error
          example: []
          type: array
          items:
            type: object
            properties:
              message:
                type: string
            required:
              - message
            additionalProperties: false
      required:
        - message
        - code
      additionalProperties: false
      title: Internal server error error (500)
      description: The error information
      example:
        code: INTERNAL_SERVER_ERROR
        message: Internal server error
        issues: []
  securitySchemes:
    ApiKey:
      type: apiKey
      name: X-API-KEY
      in: header

````