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

# Assign team

> Assigns a resource to a team (head or side) for a date range. The result might create a new resource team association or update an existing one by extending or shortening it.



## OpenAPI

````yaml 26.06.25 post /api/directory/resources.assign-team
openapi: 3.1.0
info:
  title: tipee
  version: 26.06.25
servers: []
security:
  - basicAuth: []
tags:
  - name: Activity
    description: Activity
  - name: Balances
    description: Balances
  - name: Directory
    description: Directory
  - name: Schedule
    description: Schedule
  - name: Timeclock
    description: Timeclock
paths:
  /api/directory/resources.assign-team:
    post:
      tags:
        - Directory
      summary: Assign team
      description: >-
        Assigns a resource to a team (head or side) for a date range. The result
        might create a new resource team association or update an existing one
        by extending or shortening it.
      operationId: post_app_ui_api_directory_directorycommand_assignresourceteam
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AssignResourceTeamCommand'
      responses:
        '200':
          description: Resource successfully assigned to team.
        '409':
          description: Warning to explain potential conflicts
          content:
            application/json:
              schema:
                properties:
                  warning_type:
                    $ref: '#/components/schemas/ResourceTeamWarningType'
                  description:
                    type: string
                  details:
                    $ref: '#/components/schemas/ResourceTeamAssignWarningDetails'
                  required_action:
                    type: string
                type: object
components:
  schemas:
    AssignResourceTeamCommand:
      required:
        - resource_id
        - team_id
        - head
        - date_range
      properties:
        resource_id:
          $ref: '#/components/schemas/Snowflake'
        team_id:
          $ref: '#/components/schemas/Snowflake'
        head:
          type: boolean
        date_range:
          $ref: '#/components/schemas/LocalDateInterval'
        regrouping:
          type:
            - string
            - 'null'
        contract_number:
          type:
            - string
            - 'null'
        external_id:
          type:
            - string
            - 'null'
        warning_aware:
          description: >-
            Assigning resource to a team will be done only if you provide
            'warning_aware: true'.
          type: boolean
          default: false
      type: object
    ResourceTeamWarningType:
      type: string
      example: assign-conflicting-resource-teams
      enum:
        - assign-conflicting-resource-teams
        - unassign-remove-all-resource-teams
        - unassign-conflicting-resource-teams
    ResourceTeamAssignWarningDetails:
      required:
        - modifications
        - deletions
      properties:
        modifications:
          type: array
          items:
            $ref: '#/components/schemas/ResourceTeamWarningDetailsInfo'
          default: []
        deletions:
          type: array
          items:
            $ref: '#/components/schemas/ResourceTeamWarningDetailsInfo'
          default: []
      type: object
    Snowflake:
      type: string
      format: snowflake
      example: '872815618512410358'
    LocalDateInterval:
      type: string
      format: local-date-interval
      example: 2019-11-11/2019-12-12
    ResourceTeamWarningDetailsInfo:
      required:
        - team_id
        - date_range
        - head
      properties:
        team_id:
          $ref: '#/components/schemas/Snowflake'
        date_range:
          $ref: '#/components/schemas/LocalDateInterval'
        head:
          type: boolean
      type: object

````