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

# Search companies or people

> Read one page of matching source rows. Search counts are not Import counts. Search needs company criteria: a company rule, a searching_rule, or an account_view_id. Criteria that bound no company (none, or only the title checkbox or contact_location) are refused with 422 'Company search criteria are required'. searching_rule is the company name on every view, as in Preview: on people results it returns people at companies with that name, never a job-title match, and a domain matches that website exactly. On people results a name matching more than 1,000 companies returns 422; add a company filter. company_website values must be domains like stripe.com and always match the domain exactly; any other value is refused with 422.



## OpenAPI

````yaml https://api.monaco.com/openapi.json post /v1/tam/search
openapi: 3.1.0
info:
  title: Monaco Public API
  description: Public API for Monaco
  version: 1.0.0
servers:
  - url: https://api.monaco.com
security: []
paths:
  /v1/tam/search:
    post:
      tags:
        - TAM
      summary: Search companies or people
      description: >-
        Read one page of matching source rows. Search counts are not Import
        counts. Search needs company criteria: a company rule, a searching_rule,
        or an account_view_id. Criteria that bound no company (none, or only the
        title checkbox or contact_location) are refused with 422 'Company search
        criteria are required'. searching_rule is the company name on every
        view, as in Preview: on people results it returns people at companies
        with that name, never a job-title match, and a domain matches that
        website exactly. On people results a name matching more than 1,000
        companies returns 422; add a company filter. company_website values must
        be domains like stripe.com and always match the domain exactly; any
        other value is refused with 422.
      operationId: search_tam
      parameters:
        - name: view
          in: query
          required: false
          schema:
            enum:
              - account
              - contact
              - swarm_contact
            type: string
            default: account
            title: View
        - name: current_page
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            default: 1
            title: Current Page
        - name: page_size
          in: query
          required: false
          schema:
            type: integer
            maximum: 500
            minimum: 1
            default: 50
            title: Page Size
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TamSearchRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicItemResponse_TamSearchResponse_'
        4XX:
          description: Client error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicErrorResponse'
components:
  schemas:
    TamSearchRequest:
      properties:
        filtering_rules:
          anyOf:
            - $ref: '#/components/schemas/TamSearchFilterGroup'
            - items:
                anyOf:
                  - $ref: '#/components/schemas/TamSearchFilterRule'
                  - $ref: '#/components/schemas/TamSearchFilterGroup'
              type: array
            - type: 'null'
          title: Filtering Rules
        searching_rule:
          anyOf:
            - $ref: '#/components/schemas/TamSearchRule'
            - type: 'null'
        sorting_rules:
          items:
            $ref: '#/components/schemas/TamSortRule'
          type: array
          title: Sorting Rules
        query_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Query Id
          description: >-
            The query_id a previous page of this search returned, echoed back
            with the same criteria to page, or a saved TAM search config UUID.
            Authorized when saved; never applied as a filter source.
        exclude_companies_in_tam:
          type: boolean
          title: Exclude Companies In Tam
          default: false
        title_enrichment:
          anyOf:
            - $ref: '#/components/schemas/TamTitleEnrichment'
            - type: 'null'
        with_titles:
          type: boolean
          title: With Titles
          default: false
        title_search:
          items:
            type: string
          type: array
          title: Title Search
        account_view_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Account View Id
      additionalProperties: false
      type: object
      title: TamSearchRequest
      description: >-
        The public Search input. grouping_rule and max_candidates are not
        offered: Search

        never applied either (sources/tam.py), so the public schema refuses them
        (422)

        rather than accept and ignore them.
    PublicItemResponse_TamSearchResponse_:
      properties:
        data:
          $ref: '#/components/schemas/TamSearchResponse'
        meta:
          $ref: '#/components/schemas/ResponseMeta'
      type: object
      required:
        - data
      title: PublicItemResponse[TamSearchResponse]
    PublicErrorResponse:
      properties:
        error:
          $ref: '#/components/schemas/ErrorDetail'
      type: object
      required:
        - error
      title: PublicErrorResponse
    TamSearchFilterGroup:
      properties:
        operator:
          type: string
          enum:
            - and
            - or
          title: Operator
          default: and
        filters:
          items:
            anyOf:
              - $ref: '#/components/schemas/TamSearchFilterRule'
              - $ref: '#/components/schemas/TamSearchFilterGroup'
          type: array
          title: Filters
      additionalProperties: false
      type: object
      required:
        - filters
      title: TamSearchFilterGroup
    TamSearchFilterRule:
      properties:
        field:
          type: string
          title: Field
        condition:
          type: string
          title: Condition
        value:
          anyOf:
            - {}
            - type: 'null'
          title: Value
      additionalProperties: false
      type: object
      required:
        - field
        - condition
      title: TamSearchFilterRule
    TamSearchRule:
      properties:
        value:
          type: string
          title: Value
      additionalProperties: false
      type: object
      required:
        - value
      title: TamSearchRule
    TamSortRule:
      properties:
        field:
          type: string
          title: Field
        direction:
          type: string
          title: Direction
          default: desc
      additionalProperties: false
      type: object
      required:
        - field
      title: TamSortRule
    TamTitleEnrichment:
      properties:
        condition:
          type: string
          enum:
            - AND
            - OR
          title: Condition
          description: >-
            Combines positive criteria. Negated criteria always exclude their
            matches. Each criterion separately combines its title phrase and
            seniority groups.
          default: OR
        criterias:
          items:
            $ref: '#/components/schemas/TamTitleCriteria'
          type: array
          title: Criterias
      additionalProperties: false
      type: object
      title: TamTitleEnrichment
    TamSearchResponse:
      properties:
        query_id:
          type: string
          format: uuid
          title: Query Id
        items:
          items:
            $ref: '#/components/schemas/TamSearchRow'
          type: array
          title: Items
        pagination_meta:
          $ref: '#/components/schemas/PaginationMeta'
        search_engine:
          type: string
          enum:
            - swarm
            - legacy
          title: Search Engine
        account_view_source:
          anyOf:
            - $ref: '#/components/schemas/TamSearchAccountViewSource'
            - type: 'null'
      type: object
      required:
        - query_id
        - items
        - pagination_meta
        - search_engine
      title: TamSearchResponse
    ResponseMeta:
      properties:
        timestamp:
          type: string
          format: date-time
          title: Timestamp
          description: Server timestamp of the response
      type: object
      title: ResponseMeta
    ErrorDetail:
      properties:
        code:
          type: string
          title: Code
          description: Machine-readable error code
          examples:
            - not_found
        message:
          type: string
          title: Message
          description: Human-readable error message
          examples:
            - Resource not found
      type: object
      required:
        - code
        - message
      title: ErrorDetail
    TamTitleCriteria:
      properties:
        condition:
          type: string
          enum:
            - AND
            - OR
          title: Condition
          description: >-
            Combines the job_function phrase group with the seniority group, not
            the phrases inside job_function. Use AND for requested titles with a
            seniority floor. OR also accepts people matching only the seniority
            group, even when their title matches none of the requested phrases.
          default: AND
        job_function:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Job Function
          description: >-
            Title keyword phrases: any listed phrase may match. Keep each whole
            phrase as one entry; all its normalized tokens must match. The list
            already means OR, so do not set condition=OR merely to allow
            multiple titles.
        seniority:
          anyOf:
            - items:
                type: string
                enum:
                  - Individual Contributor
                  - Senior Individual Contributor
                  - Manager
                  - Senior Manager
                  - Director
                  - Senior Director
                  - VP
                  - SVP
                  - EVP
                  - C-Level
                  - Founder
              type: array
            - type: 'null'
          title: Seniority
          description: >-
            Customer-selected minimum seniority levels, including higher levels.
            Omit when no floor was selected; do not infer a floor from title
            keywords. Use condition=AND to require both a requested title and
            this floor.
        negate:
          type: boolean
          title: Negate
          description: >-
            Exclude people matching this whole criterion. Use a separate
            keyword-only negated criterion for excluded title phrases.
          default: false
      additionalProperties: false
      type: object
      title: TamTitleCriteria
    TamSearchRow:
      properties:
        id:
          anyOf:
            - type: string
              format: uuid
            - type: string
          title: Id
      additionalProperties: true
      type: object
      required:
        - id
      title: TamSearchRow
    PaginationMeta:
      properties:
        current_page:
          type: integer
          title: Current Page
        page_size:
          type: integer
          title: Page Size
        total_pages:
          type: integer
          title: Total Pages
        total_count:
          anyOf:
            - type: integer
            - type: 'null'
          title: Total Count
      type: object
      required:
        - current_page
        - page_size
        - total_pages
      title: PaginationMeta
    TamSearchAccountViewSource:
      properties:
        account_view_id:
          type: string
          format: uuid
          title: Account View Id
        accounts_in_view:
          type: integer
          minimum: 0
          title: Accounts In View
        source_companies:
          type: integer
          minimum: 0
          title: Source Companies
          description: Distinct resolved source company identities.
        unresolved_source_count:
          type: integer
          minimum: 0
          title: Unresolved Source Count
          description: >-
            Accounts without a linked company plus distinct linked company
            identities that could not resolve into the current source. Not a
            Search match count.
        unresolved_source_names:
          items:
            type: string
          type: array
          title: Unresolved Source Names
        unresolved_names_omitted:
          type: integer
          minimum: 0
          title: Unresolved Names Omitted
        incomplete_source_count:
          type: integer
          minimum: 0
          title: Incomplete Source Count
          description: >-
            Of unresolved_source_count, identities the bounded source lookup
            stopped before checking: they may exist in the source, unlike the
            rest, which were not found.
          default: 0
        warnings:
          items:
            type: string
          type: array
          title: Warnings
          description: >-
            Rules of the saved view that were skipped, one line per field this
            organization no longer has; the view's other rules still apply. Tell
            the user.
      type: object
      required:
        - account_view_id
        - accounts_in_view
        - source_companies
        - unresolved_source_count
        - unresolved_source_names
        - unresolved_names_omitted
      title: TamSearchAccountViewSource

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.