openapi: 3.0.0
info:
  title: Resources
  version: 1.0.0
  description: >-
    The core entities of ListAlpha CRM are Deals, Companies, Contacts, and
    Investors. Deals track potential and active investments. Companies represent
    legal entities, while Contacts capture people such as executives, advisers,
    and bankers. 


    The API give access to programmatically change deals entity.
servers:
  - url: https://api.listalpha.com
    description: API server
tags:
  - name: Deals
    description: >-
      A **deal** represents the process of acquiring a company. Every deal on
      the platform belongs to a **pipeline** and is associated with a specific
      **stage** within that pipeline. The Deal entity supports configurable
      **custom fields**.
paths:
  /v1/deals/pipelines:
    get:
      operationId: PublicDealMetadataController.getPipelinesWithStages
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ViewAllPipelinesDto'
          description: ''
      summary: List Pipelines
      tags:
        - Deals
      description: >-
        A **pipeline** represents the sequence of **stages** a deal passes
        through from initiation to completion. The Deal and Credit teams use
        different **pipelines** to manage their workflows effectively.
      security:
        - ApiKeyAuth: []
  /v1/deals/custom-fields:
    get:
      operationId: PublicDealMetadataController.getCustomFields
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CustomFieldsDto'
          description: ''
      summary: List Custom Fields
      tags:
        - Deals
      description: >-
        **Custom fields** allow users to store additional information alongside
        a deal. EBITDA, revenue multiple, and other financial metrics can be
        tracked using **custom fields**.
      security:
        - ApiKeyAuth: []
  /v1/deals:
    get:
      operationId: PublicDealController.getDeals
      parameters:
        - in: query
          name: search
          required: false
          schema:
            type: string
        - in: query
          name: stages
          required: false
          schema:
            items:
              type: string
            type: array
        - in: query
          name: pipelines
          required: false
          schema:
            items:
              type: string
            type: array
        - in: query
          name: limit
          required: true
          schema:
            maximum: 100
            type: integer
            minimum: 1
        - in: query
          name: offset
          required: true
          schema:
            maximum: 1000000
            type: integer
            minimum: 0
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ViewAllDealsDto'
          description: ''
      summary: List Deals
      tags:
        - Deals
      description: >-
        Return **deals** based on search criteria, with filtering, sorting, and
        pagination.
      security:
        - ApiKeyAuth: []
    post:
      operationId: PublicDealController.createDeal
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DealCreateDto'
        description: DealCreateDto
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DealDto'
          description: ''
      summary: Create Deal
      tags:
        - Deals
      security:
        - ApiKeyAuth: []
  /v1/deals/{id}:
    patch:
      operationId: PublicDealController.updateDeal
      parameters:
        - in: path
          name: id
          required: true
          schema:
            pattern: '[^\/#\?]+?'
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DealPatchDto'
        description: DealPatchDto
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DealDto'
          description: ''
      summary: Patch Deal
      tags:
        - Deals
      security:
        - ApiKeyAuth: []
    delete:
      operationId: PublicDealController.deleteDeal
      parameters:
        - in: path
          name: id
          required: true
          schema:
            pattern: '[^\/#\?]+?'
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CommonResponseDto'
          description: ''
      summary: Delete Deal
      tags:
        - Deals
      security:
        - ApiKeyAuth: []
components:
  schemas:
    EntityPermissionDto:
      properties:
        users:
          items:
            type: string
          type: array
        allOrganization:
          type: boolean
        owner:
          type: string
        folders:
          items:
            type: string
          type: array
        roles:
          items:
            type: string
          type: array
        shareCode:
          type: string
      type: object
      required:
        - users
        - allOrganization
        - owner
        - folders
        - roles
        - shareCode
    AgGridRequestDto:
      properties:
        startRow:
          type: number
        endRow:
          type: number
        rowGroupCols:
          items:
            $ref: '#/components/schemas/RowGroupColDto'
          type: array
        valueCols:
          items: {}
          type: array
        pivotCols:
          items: {}
          type: array
        pivotMode:
          type: boolean
        groupKeys:
          items: {}
          type: array
        filterModel:
          type: object
        filterModelOr:
          type: object
        sortModel:
          items:
            $ref: '#/components/schemas/SortModelDto'
          type: array
        tz:
          type: string
      type: object
      required:
        - startRow
        - endRow
        - rowGroupCols
        - valueCols
        - pivotCols
        - pivotMode
        - groupKeys
        - filterModel
    SortModelDto:
      properties:
        sort:
          type: string
        colId:
          type: string
      type: object
      required:
        - sort
        - colId
    RowGroupColDto:
      properties:
        id:
          type: string
        displayName:
          type: string
        field:
          type: string
      type: object
      required:
        - id
        - displayName
        - field
    FieldExtraConfig:
      properties:
        formatting:
          type: string
        decimalPoints:
          maximum: 10
          type: number
          minimum: 0
        suffix:
          type: string
      type: object
    ContactField:
      properties:
        label:
          type: string
        fieldId:
          type: string
        type:
          enum:
            - input
            - textarea
            - dropdown
            - datepicker
            - multiselect
            - users-array
            - contacts-list
            - checkbox
            - number
            - texteditor
            - tags
            - formula
            - deal
            - company
            - company-list
            - attachment
          type: string
        formula:
          type: string
        tabName:
          type: string
        externalServiceType:
          enum:
            - none
            - apollo
            - pdl
          type: string
        externalServiceFieldPath:
          type: string
        invisibleField:
          type: boolean
        invisibleLabel:
          type: boolean
        leftMenu:
          type: boolean
        extraConfig:
          $ref: '#/components/schemas/FieldExtraConfig'
        default:
          type: string
        category:
          type: string
        options:
          items:
            type: string
          type: array
        required:
          type: boolean
        description:
          type: string
      type: object
      required:
        - label
        - fieldId
        - type
    ContactFieldsSchema:
      properties:
        fields:
          items:
            $ref: '#/components/schemas/ContactField'
          minItems: 0
          type: array
      type: object
      required:
        - fields
    NotesDigestRequestDto:
      properties:
        name:
          type: string
        rrule:
          type: string
        organization:
          type: string
        active:
          type: boolean
      type: object
      required:
        - name
        - rrule
        - organization
    NotesDigestUpdateDto:
      properties:
        name:
          type: string
        rrule:
          type: string
        organization:
          type: string
        active:
          type: boolean
      type: object
    UpdateReportDto:
      properties:
        name:
          maxLength: 255
          type: string
        configuration:
          type: object
        presets:
          type: object
      type: object
    CreateActivityReportDto:
      properties:
        name:
          maxLength: 255
          type: string
        configuration:
          type: object
      type: object
    ActivityReportDto:
      properties:
        _id:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        name:
          maxLength: 255
          type: string
        entityType:
          enum:
            - deal
            - investor
            - fundraising
            - company
            - notes
            - contact
            - fees
            - user
            - list
            - report
            - recent-activity
            - notes-digest
          type: string
        configuration:
          type: object
        organization:
          type: string
        creatorId:
          type: string
        groupId:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        type:
          enum:
            - REPORT
            - GROUP
            - FUNDRAISING_PIPELINE
          type: string
        order:
          type: number
        createdAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        updatedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
      type: object
      required:
        - name
        - entityType
        - configuration
        - organization
        - creatorId
        - type
        - order
        - createdAt
        - updatedAt
    ActivityReportResponseDto:
      properties:
        success:
          type: boolean
      type: object
      required:
        - success
    CreateReportDto:
      properties:
        name:
          maxLength: 255
          type: string
          minLength: 1
        entityType:
          enum:
            - deal
            - investor
            - fundraising
            - company
            - notes
            - contact
            - fees
            - user
            - list
            - report
          type: string
        configuration:
          type: object
        presets:
          type: object
        type:
          enum:
            - REPORT
            - GROUP
            - FUNDRAISING_PIPELINE
          type: string
        groupId:
          type: string
        order:
          type: number
        permissionType:
          enum:
            - share
            - private
          type: string
      type: object
      required:
        - name
        - entityType
        - configuration
    MoveReportDto:
      properties:
        groupId:
          type: string
      type: object
    OrderItemDto:
      properties:
        _id:
          type: string
        type:
          enum:
            - REPORT
            - GROUP
            - FUNDRAISING_PIPELINE
          type: string
        position:
          type: number
      type: object
      required:
        - _id
        - type
        - position
    UnifiedOrderDto:
      properties:
        order:
          items:
            $ref: '#/components/schemas/OrderItemDto'
          type: array
      type: object
      required:
        - order
    UpdatePipelinePresetsDto:
      properties:
        presets:
          type: object
        dryRun:
          type: boolean
      type: object
      required:
        - presets
    UpdatePipelinePresetsResponseDto:
      properties:
        success:
          type: boolean
        updated:
          type: boolean
      type: object
      required:
        - success
        - updated
    GetPipelinePresetsResponseDto:
      properties:
        success:
          type: boolean
        presets:
          type: object
      type: object
      required:
        - success
    EntityReportResponseDto:
      properties:
        success:
          type: boolean
        entity:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - entity
    EntityReportsResponseDto:
      properties:
        success:
          type: boolean
        entities:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - entities
    UpdateOrderResponseDto:
      properties:
        success:
          type: boolean
      type: object
      required:
        - success
    DeleteReportResponseDto:
      properties:
        success:
          type: boolean
      type: object
      required:
        - success
    CreateFolderDto:
      properties:
        name:
          maxLength: 255
          type: string
        entityType:
          type: string
        order:
          type: number
        permissionType:
          enum:
            - share
            - private
          type: string
      type: object
      required:
        - entityType
    UpdateFolderDto:
      properties:
        name:
          maxLength: 255
          type: string
          minLength: 1
      type: object
      required:
        - name
    EntityReportFolderResponseDto:
      properties:
        success:
          type: boolean
        entity:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - entity
    EntityReportFoldersResponseDto:
      properties:
        success:
          type: boolean
        entities:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - entities
    EntityReportFoldersWithTotalResponseDto:
      properties:
        success:
          type: boolean
        entities:
          minLength: 1
          type: string
        total:
          type: string
          minLength: 1
      type: object
      required:
        - success
        - entities
        - total
    EntityReportFoldersWithReportsResponseDto:
      properties:
        success:
          type: boolean
        entities:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - entities
    DeleteReportFolderResponseDto:
      properties:
        success:
          type: boolean
      type: object
      required:
        - success
    CreateFavoriteDto:
      properties:
        entityType:
          enum:
            - deal
            - investor
            - fundraising
            - company
            - notes
            - contact
            - fees
            - user
            - list
            - report
          type: string
        entityId:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
          minLength: 1
        metadata:
          type: object
      type: object
      required:
        - entityType
        - entityId
    CreateBulkFavoritesDto:
      properties:
        favorites:
          items:
            $ref: '#/components/schemas/CreateFavoriteDto'
          type: array
          maxItems: 100
          minItems: 1
      type: object
      required:
        - favorites
    UpdateFavoriteDto:
      properties:
        metadata:
          type: object
      type: object
    FavoriteOrderItemDto:
      properties:
        entityId:
          type: string
        order:
          type: number
      type: object
      required:
        - entityId
        - order
    ReorderFavoritesDto:
      properties:
        entityType:
          enum:
            - deal
            - investor
            - fundraising
            - company
            - notes
            - contact
            - fees
            - user
            - list
            - report
          type: string
        favorites:
          items:
            $ref: '#/components/schemas/FavoriteOrderItemDto'
          type: array
      type: object
      required:
        - entityType
        - favorites
    ResearchPromptDto:
      properties:
        text:
          minLength: 1
          maxLength: 2000
          type: string
        context:
          items: {}
          type: array
      type: object
      required:
        - text
    Theme:
      properties:
        _id:
          type: string
        name:
          type: string
      type: object
      required:
        - _id
        - name
    Location:
      properties:
        city:
          type: string
        state:
          type: string
        country:
          type: string
        location:
          type: string
        coordinates:
          items: {}
          maxItems: 2
          type: array
          minItems: 2
      type: object
    EmailDetail:
      properties:
        email_status:
          type: string
        email:
          type: string
      type: object
    YearMonthImpl:
      properties:
        year:
          type: number
        month:
          type: number
      type: object
    Job:
      properties:
        _id:
          type: string
        company_id:
          type: string
        company_name:
          type: string
        company_url:
          type: string
        company_image:
          type: string
        title:
          type: string
        description:
          type: string
        location:
          $ref: '#/components/schemas/Location'
        started_on:
          $ref: '#/components/schemas/YearMonthImpl'
        ended_on:
          $ref: '#/components/schemas/YearMonthImpl'
        apolloOrganizationId:
          type: string
        pdlOrganizationId:
          type: string
        rocketReachCompanyId:
          type: string
      type: object
    SocialLinks:
      properties:
        linkedin_url:
          type: string
        github_url:
          type: string
        facebook_url:
          type: string
        twitter_url:
          type: string
      type: object
    File:
      properties:
        id:
          type: string
        name:
          type: string
        url:
          type: string
      type: object
      required:
        - id
        - name
        - url
    ConnectionUser:
      properties:
        id:
          minLength: 1
          type: string
        name:
          type: string
        first_name:
          type: string
        middle_name:
          type: string
        last_name:
          type: string
        title:
          type: string
        headline:
          type: string
        headlineCompany:
          type: string
        photo_url:
          type: string
        apollo_photo_url:
          type: string
        email_detail:
          $ref: '#/components/schemas/EmailDetail'
        email_detail_second:
          $ref: '#/components/schemas/EmailDetail'
        email_detail_third:
          $ref: '#/components/schemas/EmailDetail'
        email_detail_fourth:
          $ref: '#/components/schemas/EmailDetail'
        phone:
          type: string
        business_phone:
          type: string
        third_phone:
          type: string
        fourth_phone:
          type: string
        location:
          $ref: '#/components/schemas/Location'
        home_location:
          $ref: '#/components/schemas/Location'
        microsoftGraphIds:
          items: {}
          type: array
        googleIds:
          items: {}
          type: array
        industry:
          type: string
        activeCompany:
          type: string
        jobs:
          items:
            $ref: '#/components/schemas/Job'
          type: array
        enrichStatus:
          enum:
            - 'TRUE'
            - 'FALSE'
            - FAILED
          type: string
        tags:
          items: {}
          type: array
        themes:
          items:
            $ref: '#/components/schemas/Theme'
          type: array
        knownTo:
          items: {}
          type: array
        known_to_user:
          items: {}
          type: array
        knownToAll:
          type: boolean
        notes:
          type: string
        group_id:
          type: string
        order:
          type: number
        connection_type:
          type: string
        social_links:
          $ref: '#/components/schemas/SocialLinks'
        files:
          items:
            $ref: '#/components/schemas/File'
          type: array
        dynamicInfo:
          type: object
        strongestRelation:
          type: object
        apolloContactId:
          type: string
        rocketReachContactId:
          type: string
        pdlContactId:
          type: string
        lastEnrichedDate:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
      type: object
      required:
        - id
        - name
        - first_name
        - last_name
    ConnectionUserFromClient:
      properties:
        _PROFILE: {}
        id:
          minLength: 1
          type: string
        name:
          type: string
        first_name:
          type: string
        middle_name:
          type: string
        last_name:
          type: string
        title:
          type: string
        headline:
          type: string
        headlineCompany:
          type: string
        photo_url:
          type: string
        apollo_photo_url:
          type: string
        email_detail:
          $ref: '#/components/schemas/EmailDetail'
        email_detail_second:
          $ref: '#/components/schemas/EmailDetail'
        email_detail_third:
          $ref: '#/components/schemas/EmailDetail'
        email_detail_fourth:
          $ref: '#/components/schemas/EmailDetail'
        phone:
          type: string
        business_phone:
          type: string
        third_phone:
          type: string
        fourth_phone:
          type: string
        location:
          $ref: '#/components/schemas/Location'
        home_location:
          $ref: '#/components/schemas/Location'
        microsoftGraphIds:
          items: {}
          type: array
        googleIds:
          items: {}
          type: array
        industry:
          type: string
        activeCompany:
          type: string
        jobs:
          items:
            $ref: '#/components/schemas/Job'
          type: array
        enrichStatus:
          enum:
            - 'TRUE'
            - 'FALSE'
            - FAILED
          type: string
        tags:
          items: {}
          type: array
        themes:
          items:
            $ref: '#/components/schemas/Theme'
          type: array
        knownTo:
          items: {}
          type: array
        known_to_user:
          items: {}
          type: array
        knownToAll:
          type: boolean
        notes:
          type: string
        group_id:
          type: string
        order:
          type: number
        connection_type:
          type: string
        social_links:
          $ref: '#/components/schemas/SocialLinks'
        files:
          items:
            $ref: '#/components/schemas/File'
          type: array
        dynamicInfo:
          type: object
        strongestRelation:
          type: object
        apolloContactId:
          type: string
        rocketReachContactId:
          type: string
        pdlContactId:
          type: string
        lastEnrichedDate:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
      type: object
      required:
        - id
        - name
        - first_name
        - last_name
    EntityChangeDto:
      properties:
        action:
          minLength: 1
          type: string
          enum:
            - added
            - removed
            - updated
        newValue: {}
        oldValue: {}
        type:
          type: string
        field:
          type: string
      type: object
      required:
        - action
    CreateEntityChangeHistoryDtoBuilder:
      properties:
        contactId:
          minLength: 1
          type: string
        ownerId:
          minLength: 1
          type: string
        type:
          enum:
            - manual_enrich
            - auto_enrich
            - manual_edit
          type: string
          minLength: 1
        changes:
          items:
            $ref: '#/components/schemas/EntityChangeDto'
          type: array
          minItems: 1
        organization:
          minLength: 1
          type: string
        requestId:
          type: string
      type: object
      required:
        - contactId
        - ownerId
        - type
        - changes
        - organization
    UpdatePredictionSettingsDto:
      properties:
        entityType:
          minLength: 1
          type: string
          enum:
            - deal
            - investor
            - fundraising
            - company
            - notes
            - contact
            - fees
            - user
            - list
            - report
            - recent-activity
            - notes-digest
        enabledPredictionFields:
          items:
            type: string
          type: array
          uniqueItems: true
      type: object
      required:
        - entityType
        - enabledPredictionFields
    CommonResponseDto:
      properties:
        success:
          type: boolean
      type: object
      required:
        - success
    EntityHistoryDto:
      properties:
        entityId:
          type: string
        entityType:
          enum:
            - deal
            - investor
            - fundraising
            - company
            - notes
            - contact
            - fees
            - user
            - list
            - report
            - recent-activity
            - notes-digest
          type: string
        fieldName:
          type: string
        oldValue: {}
        newValue: {}
        changeType:
          enum:
            - create
            - update
            - delete
            - array_or_object_changed
          type: string
        userId:
          type: string
        userName:
          type: string
        undoableUntil:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        createdAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        updatedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        organization:
          type: string
        isUndone:
          type: boolean
        batchId:
          type: string
        fieldLabel:
          type: string
        fieldId:
          type: string
      type: object
      required:
        - entityId
        - entityType
        - fieldName
        - changeType
        - userId
        - undoableUntil
        - createdAt
        - updatedAt
        - organization
        - isUndone
        - batchId
    EntityHistoryChangeDto:
      properties:
        entityId:
          type: string
        entityType:
          enum:
            - deal
            - investor
            - fundraising
            - company
            - notes
            - contact
            - fees
            - user
            - list
            - report
            - recent-activity
            - notes-digest
          type: string
        organization:
          type: string
        isUndone:
          type: boolean
        oldValue: {}
        newValue: {}
        userId:
          type: string
        changeType:
          enum:
            - create
            - update
            - delete
            - array_or_object_changed
          type: string
        createdAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        undoableUntil:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        updatedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        batchId:
          type: string
        userName:
          type: string
        fieldLabel:
          type: string
        fieldId:
          type: string
        fieldName:
          type: string
      type: object
      required:
        - entityId
        - entityType
        - organization
        - isUndone
        - userId
        - changeType
        - createdAt
        - undoableUntil
        - updatedAt
        - batchId
        - fieldLabel
        - fieldId
        - fieldName
    GroupedEntityHistoryDto:
      properties:
        timeBucket:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        userId:
          type: string
        userName:
          type: string
        entityType:
          enum:
            - deal
            - investor
            - fundraising
            - company
            - notes
            - contact
            - fees
            - user
            - list
            - report
            - recent-activity
            - notes-digest
          type: string
        entityId:
          type: string
        organization:
          type: string
        isUndone:
          type: boolean
        changeCount:
          type: number
        changes:
          items:
            $ref: '#/components/schemas/EntityHistoryChangeDto'
          type: array
      type: object
      required:
        - timeBucket
        - userId
        - entityType
        - entityId
        - organization
        - isUndone
        - changeCount
        - changes
    EntityHistoryListResponseDto:
      properties:
        items:
          items:
            $ref: '#/components/schemas/EntityHistoryDto'
          type: array
        success:
          type: boolean
      type: object
      required:
        - items
        - success
    GroupedEntityHistoryListResponseDto:
      properties:
        items:
          items:
            $ref: '#/components/schemas/GroupedEntityHistoryDto'
          type: array
        success:
          type: boolean
      type: object
      required:
        - items
        - success
    EntityHistoryResponseDto:
      properties:
        items:
          items:
            $ref: '#/components/schemas/EntityHistoryDto'
          type: array
        success:
          type: boolean
      type: object
      required:
        - items
        - success
    SearchNotesQuery:
      properties:
        folderId:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        keyword:
          enum:
            - ALL
            - MY
            - SHARED
            - GENERAL
            - TAGGED_IN
            - tag
          type: string
        tagId:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        page:
          maxLength: 3
          type: string
        limit:
          maxLength: 3
          type: string
        filter:
          maxLength: 256
          type: string
      type: object
    ConnectedPreviewCompanyDto:
      properties:
        name:
          type: string
        logo:
          type: string
        domain:
          type: string
      type: object
      required:
        - name
        - logo
        - domain
    ConnectedInvestorDto:
      properties:
        _id:
          type: string
        name:
          type: string
        logo:
          type: string
        domain:
          type: string
      type: object
      required:
        - _id
        - name
        - logo
        - domain
    ConnectionUserDto:
      properties:
        id:
          type: string
        name:
          type: string
        email:
          type: string
        organization:
          type: string
        first_name:
          type: string
        last_name:
          type: string
        createdAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        updatedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
      type: object
    NoteFileDto:
      properties:
        id:
          type: string
        name:
          type: string
        url:
          type: string
      type: object
      required:
        - id
        - name
        - url
    NoteFolderDto:
      properties:
        _id:
          type: string
        name:
          type: string
        color:
          type: string
        organization:
          type: string
        owner:
          type: string
      type: object
    NoteDto:
      properties:
        _id:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        title:
          type: string
        owner:
          type: string
        creation_date:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        text:
          type: string
        connectionsUsers:
          items:
            $ref: '#/components/schemas/ConnectionUserDto'
          type: array
        folder_id:
          type: string
        in_folder:
          type: boolean
        connectedDeals:
          items:
            type: string
          type: array
        connectedPreviewCompanies:
          items:
            $ref: '#/components/schemas/ConnectedPreviewCompanyDto'
          type: array
        connectedInvestors:
          items:
            $ref: '#/components/schemas/ConnectedInvestorDto'
          type: array
        companies:
          items:
            type: string
          type: array
        taggedUsers:
          items:
            type: string
          type: array
        files:
          items:
            $ref: '#/components/schemas/NoteFileDto'
          type: array
        order:
          type: number
        organization:
          type: string
        UID:
          type: string
        permission:
          $ref: '#/components/schemas/EntityPermissionDto'
        createdAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        updatedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        folder:
          $ref: '#/components/schemas/NoteFolderDto'
        highlights:
          items: {}
          type: array
        highlight:
          type: string
      type: object
      required:
        - connectionsUsers
        - in_folder
        - connectedDeals
        - connectedPreviewCompanies
        - connectedInvestors
        - companies
        - taggedUsers
        - files
        - order
        - organization
        - permission
        - createdAt
        - updatedAt
    CreateNoteDto:
      properties:
        title:
          type: string
        text:
          type: string
        folder_id:
          type: string
        connectionsUsers:
          items:
            $ref: '#/components/schemas/ConnectionUserDto'
          type: array
        connectedDeals:
          items:
            type: string
          type: array
        connectedPreviewCompanies:
          items:
            $ref: '#/components/schemas/ConnectedPreviewCompanyDto'
          type: array
        companies:
          items:
            type: string
          type: array
        taggedUsers:
          items:
            type: string
          type: array
        files:
          items:
            $ref: '#/components/schemas/NoteFileDto'
          type: array
        order:
          type: number
        permission:
          $ref: '#/components/schemas/EntityPermissionDto'
      type: object
      required:
        - title
    UpdateNoteDto:
      properties:
        title:
          type: string
        text:
          type: string
        folder_id:
          type: string
        connectionsUsers:
          items:
            $ref: '#/components/schemas/ConnectionUserDto'
          type: array
        connectedDeals:
          items:
            type: string
          type: array
        connectedPreviewCompanies:
          items:
            $ref: '#/components/schemas/ConnectedPreviewCompanyDto'
          type: array
        companies:
          items:
            type: string
          type: array
        taggedUsers:
          items:
            type: string
          type: array
        files:
          items:
            $ref: '#/components/schemas/NoteFileDto'
          type: array
        order:
          type: number
        permission:
          $ref: '#/components/schemas/EntityPermissionDto'
      type: object
    GetNoteResponseDto:
      properties:
        note:
          $ref: '#/components/schemas/NoteDto'
        success:
          type: boolean
      type: object
      required:
        - note
        - success
    GetNotesResponseDto:
      properties:
        notes:
          items:
            $ref: '#/components/schemas/NoteDto'
          type: array
        total:
          type: number
        success:
          type: boolean
      type: object
      required:
        - notes
        - total
        - success
    GetNoteParamsDto:
      properties:
        noteId:
          type: string
      type: object
      required:
        - noteId
    AttachConnectionUserDto:
      properties:
        noteId:
          type: string
        connectionUser:
          $ref: '#/components/schemas/ConnectionUserDto'
      type: object
      required:
        - noteId
        - connectionUser
    RemoveConnectionUserDto:
      properties:
        noteId:
          type: string
        connectionUserId:
          type: string
      type: object
      required:
        - noteId
        - connectionUserId
    AttachDealToNoteDto:
      properties:
        noteId:
          type: string
        dealId:
          type: string
      type: object
      required:
        - noteId
        - dealId
    RemoveDealFromNoteDto:
      properties:
        noteId:
          type: string
        dealId:
          type: string
      type: object
      required:
        - noteId
        - dealId
    EditNoteByIdDto:
      properties:
        noteId:
          type: string
        property:
          type: string
        value: {}
      type: object
      required:
        - noteId
        - property
    UpdateOrderDto:
      properties:
        orderMap:
          type: object
      type: object
      required:
        - orderMap
    DealNotesQuery:
      properties:
        domain:
          type: string
      type: object
      required:
        - domain
    DealNotesDto:
      properties:
        originEntityType:
          enum:
            - Contact
            - Deal
            - Company
            - Note
            - Fundraising
            - Investor
          type: string
        _id:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        title:
          type: string
        owner:
          type: string
        creation_date:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        text:
          type: string
        connectionsUsers:
          items:
            $ref: '#/components/schemas/ConnectionUserDto'
          type: array
        folder_id:
          type: string
        in_folder:
          type: boolean
        connectedDeals:
          items:
            type: string
          type: array
        connectedPreviewCompanies:
          items:
            $ref: '#/components/schemas/ConnectedPreviewCompanyDto'
          type: array
        connectedInvestors:
          items:
            $ref: '#/components/schemas/ConnectedInvestorDto'
          type: array
        companies:
          items:
            type: string
          type: array
        taggedUsers:
          items:
            type: string
          type: array
        files:
          items:
            $ref: '#/components/schemas/NoteFileDto'
          type: array
        order:
          type: number
        organization:
          type: string
        UID:
          type: string
        permission:
          $ref: '#/components/schemas/EntityPermissionDto'
        createdAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        updatedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        folder:
          $ref: '#/components/schemas/NoteFolderDto'
        highlights:
          items: {}
          type: array
        highlight:
          type: string
      type: object
      required:
        - originEntityType
        - _id
        - title
        - owner
        - creation_date
        - text
        - connectionsUsers
        - in_folder
        - connectedDeals
        - connectedPreviewCompanies
        - connectedInvestors
        - companies
        - taggedUsers
        - files
        - order
        - organization
        - permission
        - createdAt
        - updatedAt
    DealNotesResponse:
      properties:
        notes:
          items:
            $ref: '#/components/schemas/DealNotesDto'
          type: array
        success:
          type: boolean
      type: object
      required:
        - notes
        - success
    CreateTeamDto:
      properties:
        name:
          maxLength: 255
          type: string
          minLength: 1
        description:
          maxLength: 1000
          type: string
        order:
          type: number
      type: object
      required:
        - name
    UpdateTeamDto:
      properties:
        name:
          maxLength: 255
          type: string
        description:
          maxLength: 1000
          type: string
        order:
          type: number
      type: object
    TeamOrderDto:
      properties:
        teamId:
          type: string
        order:
          type: number
      type: object
      required:
        - teamId
        - order
    UpdateTeamsOrderDto:
      properties:
        teams:
          items:
            $ref: '#/components/schemas/TeamOrderDto'
          type: array
          minItems: 1
      type: object
      required:
        - teams
    AddMembersDto:
      properties:
        userIds:
          items:
            type: string
          type: array
          minItems: 1
      type: object
      required:
        - userIds
    RemoveMembersDto:
      properties:
        userIds:
          items:
            type: string
          type: array
          minItems: 1
      type: object
      required:
        - userIds
    PaginationQueryDto:
      properties:
        page:
          minimum: 0
          type: integer
        limit:
          maximum: 100
          type: integer
          minimum: 1
      type: object
    EntityTeamResponseDto:
      properties:
        success:
          type: boolean
        entity:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - entity
    EntityTeamsResponseDto:
      properties:
        success:
          type: boolean
        entities:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - entities
    EntityTeamsWithCountResponseDto:
      properties:
        success:
          type: boolean
        entities:
          minLength: 1
          type: string
        totalCount:
          minLength: 1
          type: string
        hasMore:
          type: boolean
      type: object
      required:
        - success
        - entities
        - totalCount
        - hasMore
    TeamMembersResponseDto:
      properties:
        success:
          type: boolean
        members:
          items: {}
          type: string
          minLength: 1
      type: object
      required:
        - success
        - members
    DeleteTeamResponseDto:
      properties:
        success:
          type: boolean
      type: object
      required:
        - success
    UpdateTeamOrderResponseDto:
      properties:
        success:
          type: boolean
      type: object
      required:
        - success
    UserIdDto:
      properties:
        userId:
          maxLength: 255
          type: string
          minLength: 1
        weeks:
          type: number
      type: object
      required:
        - userId
    EnabledStatusDto:
      properties:
        enabled:
          minLength: 1
          type: boolean
      type: object
      required:
        - enabled
    PitchbookInfoResponseDto:
      properties:
        success:
          type: boolean
        info:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - info
    PaginationDto:
      properties:
        page:
          type: number
        limit:
          type: number
        total:
          type: number
        totalPages:
          type: number
      type: object
      required:
        - page
        - limit
        - total
        - totalPages
    InvestorPortfolioDataDto:
      properties:
        investor:
          type: object
        portfolio:
          items: {}
          type: array
        fromCache:
          type: boolean
      type: object
      required:
        - investor
        - portfolio
        - fromCache
    InvestorPortfolioResponseDto:
      properties:
        success:
          type: boolean
        data:
          minLength: 1
          type: string
      type: object
      required:
        - success
        - data
    DealFieldSchemaDto:
      properties:
        default: {}
        fieldId:
          type: string
        label:
          type: string
        category:
          type: string
        options:
          items: {}
          type: array
        type:
          type: string
        formula:
          type: string
        extraConfig:
          type: object
      type: object
      required:
        - fieldId
        - label
        - options
        - type
    PeopleSchemaDto:
      properties:
        id:
          type: string
        label:
          type: string
        hide:
          type: boolean
      type: object
      required:
        - id
        - label
        - hide
    DealDialogLayoutDto:
      properties:
        fieldId:
          type: string
        type:
          type: string
        label:
          type: string
        category:
          type: string
        leftMenu:
          type: boolean
        invisibleLabel:
          type: boolean
        invisibleField:
          type: boolean
        condition:
          type: string
        mandatory:
          type: boolean
        schema:
          $ref: '#/components/schemas/DealFieldSchemaDto'
      type: object
      required:
        - fieldId
        - type
        - label
        - leftMenu
        - invisibleLabel
        - invisibleField
        - schema
    ChangeDealConfigurationDto:
      properties:
        schema:
          items:
            $ref: '#/components/schemas/DealFieldSchemaDto'
          type: array
        peopleSchema:
          items:
            $ref: '#/components/schemas/PeopleSchemaDto'
          type: array
        dealDialogLayouts:
          items:
            $ref: '#/components/schemas/DealDialogLayoutDto'
          type: array
      type: object
      required:
        - schema
        - peopleSchema
        - dealDialogLayouts
    ContactFieldSchemaDto:
      properties:
        default: {}
        fieldId:
          type: string
        label:
          type: string
        category:
          type: string
        invisibleField:
          type: boolean
        tabName:
          type: string
        options:
          items:
            type: string
          type: array
        type:
          type: string
        formula:
          type: string
        extraConfig:
          type: object
      type: object
      required:
        - fieldId
        - label
        - options
        - type
    ChangeContactEntityConfigurationDto:
      properties:
        schema:
          items:
            $ref: '#/components/schemas/ContactFieldSchemaDto'
          type: array
      type: object
      required:
        - schema
    SetFeatureFlagDto:
      properties:
        flag:
          type: string
        value:
          minLength: 1
          type: string
      type: object
      required:
        - flag
        - value
    AddDomainAliasDto:
      properties:
        current:
          type: string
        alias:
          type: string
      type: object
      required:
        - current
        - alias
    ChangeUserNameDto:
      properties:
        firstName:
          type: string
        lastName:
          type: string
        userDocId:
          type: string
      type: object
      required:
        - firstName
        - lastName
        - userDocId
    ChangeStatusDto:
      properties:
        newStatus:
          type: string
        userId:
          type: string
      type: object
      required:
        - newStatus
        - userId
    ChangeCompanyRoleDto:
      properties:
        newRole:
          enum:
            - ADMIN
            - LEADERSHIP
            - DEAL_TEAM
            - PORTFOLIO
            - FINANCE
            - INVESTOR_RELATIONS
            - ADMIN_SUPPORT
            - OTHER
          type: string
        userId:
          type: string
      type: object
      required:
        - newRole
        - userId
    ChangePlatformRoleDto:
      properties:
        newRole:
          enum:
            - Ordinary
            - Administrator
          type: string
        userId:
          type: string
      type: object
      required:
        - newRole
        - userId
    ResetEnrichStatusDto:
      properties:
        lastEnrichedDate:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
      type: object
      required:
        - lastEnrichedDate
    ChangePermissionRequestDto:
      properties:
        permission:
          enum:
            - DEAL_STAGES
            - DEAL_EDITOR
            - DEAL_TABLE_CONFIGURATIONS
            - ADVANCED_DEAL_REPORT
            - ADVANCED_DEAL_REPORT_SECOND
            - DEAL_FLOW
            - DEAL_TOP_OF_THE_FUNNEL
            - AI_ASSESSMENT
            - DEAL_FLOW_REPORT
            - DEAL_FLOW_META_DATA
            - ORIGINATION
            - FUNDRAISING_OPPORTUNITIES_STAGES
            - FUNDRAISING_OPPORTUNITY_ENTITY
            - FUNDRAISING_FLOW_REPORT
            - EMAIL_NOTIFICATIONS
            - TAG_ENTITY
            - PITCHBOOK_FUNCTIONALITY
            - GAIN_PRO_FUNCTIONALITY
            - HOMEPAGE_FUNCTIONALITY
            - COLLECTIONS_FUNCTIONALITY
            - MFA
            - RELATIONSHIP
            - INTERACTIONS
            - COMPANY_ENTITY
            - INVESTOR_ENTITY
            - FEE_ENTITY
            - FEE_FLOW_REPORT
            - ANALYTICS_MODULE
            - CF_NEWS_FUNCTIONALITY
            - CONTACT_ENTITY
          type: string
        changeType:
          type: string
          enum:
            - ALL
            - NONE
        value:
          type: boolean
        role:
          type: string
      type: object
      required:
        - permission
        - changeType
        - value
    ChangeConfigurationRequestDto:
      properties:
        permission:
          enum:
            - DEAL_STAGES
            - DEAL_EDITOR
            - DEAL_TABLE_CONFIGURATIONS
            - ADVANCED_DEAL_REPORT
            - ADVANCED_DEAL_REPORT_SECOND
            - DEAL_FLOW
            - DEAL_TOP_OF_THE_FUNNEL
            - AI_ASSESSMENT
            - DEAL_FLOW_REPORT
            - DEAL_FLOW_META_DATA
            - ORIGINATION
            - FUNDRAISING_OPPORTUNITIES_STAGES
            - FUNDRAISING_OPPORTUNITY_ENTITY
            - FUNDRAISING_FLOW_REPORT
            - EMAIL_NOTIFICATIONS
            - TAG_ENTITY
            - PITCHBOOK_FUNCTIONALITY
            - GAIN_PRO_FUNCTIONALITY
            - HOMEPAGE_FUNCTIONALITY
            - COLLECTIONS_FUNCTIONALITY
            - MFA
            - RELATIONSHIP
            - INTERACTIONS
            - COMPANY_ENTITY
            - INVESTOR_ENTITY
            - FEE_ENTITY
            - FEE_FLOW_REPORT
            - ANALYTICS_MODULE
            - CF_NEWS_FUNCTIONALITY
            - CONTACT_ENTITY
          type: string
        configuration:
          minLength: 1
          type: string
      type: object
      required:
        - permission
        - configuration
    DeleteDto:
      properties:
        all:
          type: boolean
        idsToDelete:
          items:
            pattern: ^[0-9a-fA-F]{24}$
            type: string
          type: array
      type: object
      required:
        - all
        - idsToDelete
    AddBlacklistEmailDto:
      properties:
        email:
          format: email
          type: string
        emails:
          items:
            format: email
            type: string
          type: array
      type: object
    RemoveBlacklistEmailDto:
      properties:
        email:
          minLength: 1
          type: string
          format: email
      type: object
      required:
        - email
    UpdateBlacklistEmailsDto:
      properties:
        emails:
          items:
            format: email
            type: string
          type: array
      type: object
      required:
        - emails
    ResponseBlacklistDto:
      properties:
        data:
          items:
            format: email
            type: string
          type: array
        success:
          type: boolean
      type: object
      required:
        - success
    CopyContactsToListDto:
      properties:
        contactIds:
          items:
            type: string
          type: array
          minItems: 1
        targetListId:
          minLength: 1
          type: string
      type: object
      required:
        - contactIds
        - targetListId
    CopyContactsResponseDto:
      properties:
        success:
          type: boolean
        copiedCount:
          type: number
        listId:
          type: string
        listName:
          type: string
      type: object
      required:
        - success
        - copiedCount
        - listId
        - listName
    CompanyDto:
      properties:
        company_image:
          type: string
        company_name:
          type: string
        company_location:
          type: string
        company_industry:
          type: string
        company_employees:
          type: number
        company_about:
          type: string
        company_tags:
          items: {}
          type: array
        company_url:
          type: string
        domain:
          type: string
      type: object
    PeopleDto:
      properties:
        introducer:
          items: {}
          type: array
        management:
          items: {}
          type: array
        advisers:
          items: {}
          type: array
      type: object
    DealInfoDto:
      properties:
        project_name:
          type: string
        deal_team_initials:
          type: string
        EV_estimate:
          type: string
        EBITDA:
          type: string
        cheque_size:
          type: string
        deal_type:
          enum:
            - New deal
            - Portfolio project
          type: string
        deal_lead:
          items: {}
          type: array
      type: object
    DealLeadDto:
      properties:
        id:
          type: string
        name:
          type: string
        email:
          type: string
        organization:
          type: string
        first_name:
          type: string
        last_name:
          type: string
      type: object
    FileDto:
      properties:
        id:
          type: string
        name:
          type: string
        url:
          type: string
      type: object
      required:
        - id
        - name
        - url
    TaskDto:
      properties:
        _id:
          type: string
        title:
          type: string
        description:
          type: string
        completed:
          type: boolean
        dueDate:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        assigneeId:
          type: string
        entityId:
          type: string
      type: object
    TagItemDto:
      properties:
        _id:
          type: string
        name:
          type: string
        color:
          type: string
        folderId:
          type: string
      type: object
    DealResponseDto:
      properties:
        _id:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        stage:
          type: string
        stageName:
          type: string
        pipelineId:
          type: string
        order:
          type: number
        type:
          type: string
        group_id:
          type: string
        RAG:
          type: string
        company: {}
        people: {}
        deal_info: {}
        dealInfo:
          type: object
        dealInfoObj:
          type: object
        deal_lead:
          items: {}
          type: array
        dealLead:
          items: {}
          type: array
        files:
          items: {}
          type: array
        entityFiles:
          items: {}
          type: array
        deal_comments:
          type: string
        added_date:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        organization:
          enum:
            - listAlpha
            - Mayfair Equity Partners
            - 33east
            - Geniusee Test
            - DIAManagement
          type: string
        creatorId:
          type: string
        metadata:
          type: object
        tags:
          items: {}
          type: array
        groupTags:
          items: {}
          type: array
        strongestRelation:
          type: object
        lastInteraction:
          type: object
        futureInteraction:
          type: object
        enrichStatus:
          type: boolean
        enrichStatusErrorDescription:
          type: string
        lastEnrichDate:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        createdAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        updatedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        notes:
          items: {}
          type: array
        tasksCount:
          type: number
        tasks:
          items: {}
          type: array
        tagItems:
          items: {}
          type: array
      type: object
      required:
        - stage
    GetDealResponseDto:
      properties:
        deal:
          $ref: '#/components/schemas/DealResponseDto'
        success:
          type: boolean
      type: object
      required:
        - deal
        - success
    GetDealParamsDto:
      properties:
        dealId:
          type: string
      type: object
      required:
        - dealId
    ListItemResponseDto:
      properties:
        list_name:
          type: string
        list_id:
          type: string
        list_order:
          type: number
        owner_id:
          type: string
        shared_id:
          type: string
        access:
          items: {}
          type: array
        count:
          type: number
        shared:
          type: boolean
        folder_id:
          type: string
        parent_folder_id:
          type: string
        list_type:
          type: string
        permissions:
          type: string
        lists:
          items:
            $ref: '#/components/schemas/ListItemResponseDto'
          type: array
      type: object
      required:
        - list_name
        - list_id
        - list_order
        - owner_id
        - access
        - count
        - shared
        - list_type
    ContactDto:
      properties:
        firstName:
          type: string
        id:
          type: string
        middleName:
          type: string
        lastName:
          type: string
        name:
          type: string
        companyName:
          type: string
        email:
          type: string
        linkedinUrl:
          type: string
        jobs:
          items:
            $ref: '#/components/schemas/CompanyDto'
          type: array
      type: object
    ResultDto:
      properties:
        correct:
          type: boolean
        reasoning:
          type: string
        mainMismatch:
          type: string
        score:
          type: number
        contact:
          $ref: '#/components/schemas/ContactDto'
      type: object
      required:
        - correct
        - reasoning
        - mainMismatch
        - score
    EnrichResultDto:
      properties:
        success:
          type: boolean
        result:
          $ref: '#/components/schemas/ResultDto'
      type: object
      required:
        - success
        - result
    EnrichValidateDto:
      properties:
        original:
          minLength: 1
          type: string
        new:
          minLength: 1
          type: string
      type: object
      required:
        - original
        - new
    CreateApiKeyDto:
      properties:
        name:
          type: string
        ttl:
          pattern: \d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d.\d+Z?
          type: string
      type: object
      required:
        - name
        - ttl
    ViewApiKeyDto:
      properties:
        _id:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        name:
          type: string
        ttl:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        userId:
          type: string
        userEmail:
          type: string
      type: object
      required:
        - _id
        - name
        - ttl
        - userId
        - userEmail
    ViewApiKeySecretDto:
      properties:
        key:
          type: string
      type: object
      required:
        - key
    ViewAllApiKeysDto:
      properties:
        keys:
          items:
            $ref: '#/components/schemas/ViewApiKeyDto'
          type: array
      type: object
      required:
        - keys
    UpdateContactFieldsRequestDto:
      properties:
        fields:
          type: object
      type: object
      required:
        - fields
    UpdateContactFieldsResponseDto:
      properties:
        success:
          type: boolean
        contact:
          type: object
        message:
          type: string
        error:
          type: string
      type: object
      required:
        - success
    ViewPipelineStageDto:
      properties:
        id:
          type: string
        name:
          type: string
      type: object
      required:
        - id
        - name
    ViewPipelineDto:
      properties:
        id:
          type: string
        name:
          type: string
        stages:
          items:
            $ref: '#/components/schemas/ViewPipelineStageDto'
          type: array
      type: object
      required:
        - id
        - name
        - stages
    ViewAllPipelinesDto:
      properties:
        pipelines:
          items:
            $ref: '#/components/schemas/ViewPipelineDto'
          type: array
      type: object
      required:
        - pipelines
    CustomFieldDto:
      properties:
        fieldId:
          type: string
        label:
          type: string
      type: object
      required:
        - fieldId
        - label
    CustomFieldsDto:
      properties:
        fields:
          items:
            $ref: '#/components/schemas/CustomFieldDto'
          type: array
      type: object
      required:
        - fields
    GetDealsDto:
      properties:
        search:
          type: string
        stages:
          items:
            type: string
          type: array
        pipelines:
          items:
            type: string
          type: array
        limit:
          maximum: 100
          type: integer
          minimum: 1
        offset:
          maximum: 1000000
          type: integer
          minimum: 0
      type: object
      required:
        - limit
        - offset
    DealCompanyDto:
      properties:
        name:
          type: string
        url:
          type: string
      type: object
    DealDto:
      properties:
        id:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
        company:
          $ref: '#/components/schemas/DealCompanyDto'
        comment:
          type: string
        tags:
          items:
            type: string
          type: array
        creatorId:
          type: string
        pipelineId:
          type: string
        stageId:
          type: string
        addedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        createdAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        updatedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        fields:
          type: object
      type: object
      required:
        - id
    ViewAllDealsDto:
      properties:
        deals:
          items:
            $ref: '#/components/schemas/DealDto'
          type: array
      type: object
      required:
        - deals
    DealCreateDto:
      properties:
        company:
          $ref: '#/components/schemas/DealCompanyDto'
        comment:
          type: string
        tags:
          items:
            type: string
          type: array
        pipelineId:
          type: string
        stageId:
          type: string
        addedAt:
          oneOf:
            - format: date
              type: string
            - format: date-time
              type: string
        fields:
          type: object
      type: object
      required:
        - pipelineId
        - stageId
    DealPatchDto:
      properties:
        company:
          $ref: '#/components/schemas/DealCompanyDto'
        comment:
          type: string
        tags:
          items:
            type: string
          type: array
        stageId:
          type: string
        fields:
          type: object
      type: object
    MongoIdDto:
      properties:
        id:
          pattern: ^[0-9a-fA-F]{24}$
          type: string
      type: object
      required:
        - id
    OkResponse:
      properties:
        success:
          type: boolean
      type: object
      required:
        - success
    UpdateCommentRequest:
      properties:
        comments:
          type: string
      type: object
      required:
        - comments
    Object:
      type: object
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
