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

# Fetch Company

> This endpoint offers seamless access to detailed information about Companies stored in our internal database. Whether you're looking to retrieve specific company details for analysis, integration, or other purposes, the Fetch Company endpoint provides a straightforward solution. Simply provide the company ID, and this endpoint will return comprehensive data about the specified Company.

<Warning>
  **Deprecated — July 15, EOD UTC.** Migrate to [Fetch Company (v3)](/docs/endpoints/v3/fetch-company).

  **During the transition window, this endpoint reads from the legacy Postgres database.** Some IDs returned by v2 search may not resolve here — fetch from v3 instead. Additional fields (e.g. `tags`) are **not maintained** in v2 during the transition. See the [Migrating to v3](/docs/getting-started/migrating-to-v3) guide.
</Warning>

By default, the response contains basic company info and firmographic data. The API user may specify additional data about the company in the `fields` object that accepts the following values:

|                |                                                                                                |
| -------------- | ---------------------------------------------------------------------------------------------- |
| `company_info` | Basic company information and firmograhpic data (returned by default if no field is specified) |
| `tags`         | Tags assigned to the company                                                                   |

<Note>
  Please note that `associated_profiles` is no longer a valid field in fetch requests.
</Note>

For more details see [Models > Company](/docs/enrichment-data/company).


## OpenAPI

````yaml openapi.json POST /companies/fetch
openapi: 3.1.0
info:
  title: Swarm API
  version: 1.0.0
  contact:
    name: The Swarm
    url: https://theswarm.com
    email: hello@theswarm.com
servers:
  - url: https://bee.theswarm.com
security:
  - ApiKeyAuth: []
tags:
  - name: profiles
    description: Operations related to profiles
  - name: companies
    description: Operations related to companies
  - name: teams
    description: Operations for managing teams and connectors
  - name: social
    description: Operations related to social media posts and interactions
  - name: mcp
    description: Model Context Protocol endpoint for AI assistant integrations
  - name: credits
    description: Operations related to credit usage
  - name: network-mapper
    description: Operations for mapping connections and relationships across your network
paths:
  /companies/fetch:
    post:
      tags:
        - companies
      summary: Fetch companies with corresponding data
      description: Fetch companies with corresponding data (e.g. tags)
      operationId: fetchCompanies
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                ids:
                  type: array
                  items:
                    type: string
                    format: uuid
                  description: The Swarm company IDs
                linkedinNames:
                  type: array
                  items:
                    type: string
                  description: LinkedIn company URL slugs
                linkedinIds:
                  type: array
                  items:
                    type: integer
                  description: LinkedIn numeric company IDs
                fields:
                  type: array
                  items:
                    type: string
                    enum:
                      - company_info
                      - tags
                  minItems: 1
                  default:
                    - company_info
              anyOf:
                - required:
                    - ids
                - required:
                    - linkedinNames
                - required:
                    - linkedinIds
      responses:
        '200':
          description: A list of companies with corresponding data
          content:
            application/json:
              schema:
                type: object
                properties:
                  results:
                    description: List of companies with corresponding data
                    type: array
                    items:
                      $ref: '#/components/schemas/Company'
                  notFound:
                    description: >-
                      List of company identifiers (ids / linkedinNames /
                      linkedinIds) that were not found
                    type: array
                    items:
                      type: string
                required:
                  - results
        '400':
          $ref: '#/components/responses/400'
        '401':
          $ref: '#/components/responses/401'
        '403':
          $ref: '#/components/responses/403'
        5XX:
          $ref: '#/components/responses/5XX'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    Company:
      type: object
      properties:
        id:
          type: string
          format: uuid
        company_info:
          type: object
          properties:
            id:
              type: string
            linkedin_slugs:
              type: array
              items:
                type: string
            name:
              type: string
            alternative_names:
              type: array
              items:
                type: string
            description:
              type: string
            summary:
              type: string
            contact_info:
              type: object
              properties:
                email:
                  type: string
                phone:
                  type: string
                url:
                  type: string
            canonical_name:
              type: string
            founded:
              type: string
              format: date-time
            industry:
              type: string
            website:
              type: string
            workforce:
              type: array
              items:
                type: object
                properties:
                  headcount:
                    type: integer
                  historical_headcount:
                    type: array
                    items:
                      type: object
                      properties:
                        timestamp:
                          type: integer
                        count:
                          type: integer
                  size_class:
                    type: string
            tech_stack:
              type: object
              properties:
                products:
                  type: array
                  items:
                    type: string
            business_data:
              type: object
              properties:
                identifiers:
                  type: object
                  properties:
                    stock_ticker:
                      type: string
                    duns_code:
                      type: string
                    cage_code:
                      type: string
                    naics_code:
                      type: string
                customer_types:
                  type: array
                  items:
                    type: string
                stock_exchange:
                  type: string
                is_acquired:
                  type: boolean
                is_exited:
                  type: boolean
                is_government:
                  type: boolean
                is_non_profit:
                  type: boolean
                is_shut_down:
                  type: boolean
                is_startup:
                  type: boolean
                is_stealth:
                  type: boolean
                ownership_status:
                  type: string
                ownership_status_detailed:
                  type: string
                patent_count:
                  type: integer
                financing_profile:
                  type: object
                  properties:
                    status:
                      type: string
                    ipo_date:
                      type: string
                      format: date-time
                    outstanding_shares:
                      type: number
                    market_cap:
                      type: number
            social_media:
              type: array
              items:
                $ref: '#/components/schemas/SocialMedia'
              description: The networks of the company
            locations:
              type: array
              items:
                type: object
                properties:
                  name:
                    type: string
                  country:
                    type: string
                  is_primary:
                    type: boolean
            logo_url:
              type: string
            type:
              type: array
              items:
                type: string
            specialities:
              type: array
              items:
                type: string
            investments:
              type: array
              items:
                type: string
            geography_focus:
              type: array
              items:
                type: string
            funding:
              type: object
              properties:
                last_round:
                  type: object
                  properties:
                    last_round_type:
                      type: string
                    last_round_amount_usd:
                      type: integer
                    last_round_date:
                      type: string
                      format: date-time
                    last_round_investors:
                      type: array
                      items:
                        type: object
                        properties:
                          id:
                            type: string
                            format: uuid
                          kind:
                            type: string
                            enum:
                              - Unknown
                              - Profile
                              - Company
                            description: Investor kind
                          name:
                            type: string
                          crunchbase_id:
                            type: string
                          crunchbase_slug:
                            type: string
                rounds:
                  type: array
                  items:
                    type: object
                    properties:
                      type:
                        type: string
                      amount_usd:
                        type: integer
                      date:
                        type: string
                        format: date-time
                      investors:
                        type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                              format: uuid
                            kind:
                              type: string
                              enum:
                                - Unknown
                                - Profile
                                - Company
                              description: Investor kind
                            name:
                              type: string
                            crunchbase_id:
                              type: string
                            crunchbase_slug:
                              type: string
                total_funding_amount_usd:
                  type: integer
            updated_at:
              type: string
              format: date-time
            data_updated_at:
              type: string
              format: date-time
            industries:
              type: array
              items:
                type: string
            websites:
              type: array
              items:
                type: string
            Size:
              type: object
              properties:
                class:
                  type: string
        tags:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
                format: uuid
              name:
                type: string
        found_by:
          $ref: '#/components/schemas/CompanyFoundBy'
      required:
        - id
    SocialMedia:
      type: object
      properties:
        network:
          type: string
          description: Social media network name
        id:
          type: string
          description: Identifier on the social network
        slug:
          type: string
          description: Slug / handle on the social network
        url:
          type: string
          description: Full profile URL
        url_status:
          type: string
          description: Status of the resolved URL
          enum:
            - ''
            - unknown
            - active
    CompanyFoundBy:
      type: object
      properties:
        ids:
          type: array
          items:
            type: string
            format: uuid
        linkedinNames:
          type: array
          items:
            type: string
        linkedinIds:
          type: array
          items:
            type: integer
      description: Which of the requested identifiers matched this result
    ErrorResponse:
      type: object
      properties:
        code:
          description: Error status code
          type: integer
        errors:
          type: array
          items:
            type:
              - string
              - object
      required:
        - code
  responses:
    '400':
      description: Bad request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    '401':
      description: Unauthorized
    '403':
      description: Forbidden
    5XX:
      description: Unexpected error
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````