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

# Segment technology stats API

> How much of one technology's live footprint belongs to a slice of companies. Returns three self-consistent counts. Costs 1 credit, cache hits included.

## Frequently asked questions

<AccordionGroup>
  <Accordion title="What are the three counts?">
    `live_active_domains` is every domain currently running the technology. `matched_domains` is the subset with a matched company record. `segment_domains` is the subset of *those* that pass your predicates. They come from a single pass, so `segment_domains ≤ matched_domains ≤ live_active_domains` always holds and the ratios are internally consistent.
  </Accordion>

  <Accordion title="Why do I need a filter at all?">
    A request with a technology but no predicate is rejected with `MISSING_SEGMENT`. Without a predicate this endpoint would just re-derive global technology stats at much greater cost — use [the technology stats endpoint](/docs/api-reference/market-intelligence/technology-stats-api) for that.
  </Accordion>

  <Accordion title="Do cached results still cost a credit?">
    Yes. Results are cached for 24 hours, and a cache hit still costs 1 credit — the response tells you with `cache.hit` and `cache.age_seconds`. This is deliberate: a change to our caching should never become a silent change to your price.
  </Accordion>

  <Accordion title="Can I use a saved audience instead of inline filters?">
    Yes, pass `segment_id`. It is mutually exclusive with inline firmographic parameters. Note that only firmographic audiences replay here — other kinds are rejected with a pointer to [the technology report](/docs/api-reference/audiences/audience-technologies-api), which is the right endpoint for their per-technology numbers.
  </Accordion>

  <Accordion title="Why did I get a 503?">
    A broad segment over a very large technology can exceed the 30-second query limit. It is surfaced as `SEGMENT_QUERY_TIMEOUT` and is never retried server-side. Narrow the segment — add an employee band, an industry or a city.
  </Accordion>
</AccordionGroup>


## OpenAPI

````yaml GET /v1/segments/stats
openapi: 3.1.0
info:
  title: TechnologyChecker API
  description: >-
    Discover technology stacks, track market trends, and enrich data with
    company intelligence.
  version: 1.0.0
  contact:
    name: TechnologyChecker Support
    email: support@technologychecker.io
    url: https://technologychecker.io
servers:
  - url: https://api.technologychecker.io
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Domain technologies
    description: Look up technologies detected on any domain
  - name: Technology data
    description: Search, look up, and get details on tracked technologies
  - name: Market intelligence
    description: Technology stats, trends, and market share
  - name: Company data
    description: Firmographic and company intelligence
  - name: Live detection
    description: Real-time technology detection with browser rendering
  - name: Signals
    description: >-
      Intent signals derived from technology state transitions: who adopted, who
      churned, who switched, and who has a gap in their stack.
  - name: Alerts
    description: >-
      Saved signal queries delivered to your webhook. Every signal you can
      query, you can subscribe to.
  - name: Audiences
    description: >-
      Saved groups of domains — uploaded lists or computed recipes — that you
      can profile, slice and monitor.
  - name: Lead lists
    description: >-
      Build and export targeted domain lists combining technology detection with
      company data.
paths:
  /v1/segments/stats:
    get:
      tags:
        - Audiences
      summary: Segment technology stats API
      description: >-
        How much of one technology's live footprint belongs to a slice of
        companies. Returns three self-consistent counts from a single pass, so
        `segment_domains ≤ matched_domains ≤ live_active_domains` always holds:


        - `live_active_domains` — domains currently running the technology

        - `matched_domains` — of those, the ones with a matched company record

        - `segment_domains` — of those, the ones passing your predicates


        Requires a technology scope and **at least one** firmographic predicate,
        or a saved `segment_id`. Without a predicate this would just re-derive
        global stats expensively, so it is rejected.


        Results are cached for 24 hours. **Cache hits still cost 1 credit** — a
        cache tuning must never become a silent price change.
      operationId: getSegmentTechnologyStats
      parameters:
        - name: technology_id
          in: query
          required: false
          description: The technology to measure. Provide this or `technology`.
          schema:
            type: integer
          example: 2184
        - name: technology
          in: query
          required: false
          description: The technology to measure, by exact name.
          schema:
            type: string
          example: Shopify
        - $ref: '#/components/parameters/FirmoCountry'
        - $ref: '#/components/parameters/FirmoCity'
        - $ref: '#/components/parameters/FirmoState'
        - $ref: '#/components/parameters/FirmoIndustry'
        - $ref: '#/components/parameters/FirmoIndustryCode'
        - $ref: '#/components/parameters/FirmoEmployees'
        - $ref: '#/components/parameters/FirmoCompanyType'
        - $ref: '#/components/parameters/FirmoFoundedMin'
        - $ref: '#/components/parameters/FirmoFoundedMax'
        - $ref: '#/components/parameters/WebHasEmail'
        - $ref: '#/components/parameters/WebHasPhone'
        - $ref: '#/components/parameters/WebSocial'
        - $ref: '#/components/parameters/WebLanguage'
        - $ref: '#/components/parameters/WebCountry'
        - $ref: '#/components/parameters/SegmentId'
      responses:
        '200':
          description: Three self-consistent counts plus the share of matched companies
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    example: true
                  data:
                    type: object
                    properties:
                      technology:
                        type: object
                        properties:
                          id:
                            type: integer
                            example: 2184
                          name:
                            type: string
                            example: Shopify
                          category:
                            type: string
                            nullable: true
                            example: Ecommerce Platforms
                      segment:
                        type: object
                        properties:
                          applied:
                            type: object
                            additionalProperties: true
                            example:
                              country: united states
                              employees: 51-200
                          coverage_note:
                            type: string
                      stats:
                        type: object
                        properties:
                          live_active_domains:
                            type: integer
                            example: 2314529
                          matched_domains:
                            type: integer
                            example: 578632
                          segment_domains:
                            type: integer
                            example: 32311
                          segment_share_of_matched:
                            type: number
                            format: float
                            nullable: true
                            example: 0.0559
                      cache:
                        type: object
                        properties:
                          hit:
                            type: boolean
                            example: false
                          age_seconds:
                            type: integer
                            example: 0
                      generated_at:
                        type: string
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '402':
          $ref: '#/components/responses/PaymentRequired'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '429':
          $ref: '#/components/responses/RateLimited'
        '503':
          $ref: '#/components/responses/QueryTimeout'
components:
  parameters:
    FirmoCountry:
      name: country
      in: query
      required: false
      description: Filter to companies in this country (case-insensitive).
      schema:
        type: string
      example: united states
    FirmoCity:
      name: city
      in: query
      required: false
      description: Filter to companies in this city (case-insensitive).
      schema:
        type: string
    FirmoState:
      name: state
      in: query
      required: false
      description: Filter to companies in this state or region (case-insensitive).
      schema:
        type: string
    FirmoIndustry:
      name: industry
      in: query
      required: false
      description: Filter to companies in this industry (case-insensitive).
      schema:
        type: string
      example: retail
    FirmoIndustryCode:
      name: industry_code
      in: query
      required: false
      description: Filter by exact LinkedIn industry code.
      schema:
        type: integer
    FirmoEmployees:
      name: employees
      in: query
      required: false
      description: >-
        Filter by exact LinkedIn employee band. Unknown bands are rejected with
        `INVALID_EMPLOYEE_BAND` and the allowed list.
      schema:
        type: string
      example: 51-200
    FirmoCompanyType:
      name: company_type
      in: query
      required: false
      description: Filter by exact company type.
      schema:
        type: string
      example: Privately Held
    FirmoFoundedMin:
      name: founded_min
      in: query
      required: false
      description: Only companies founded in or after this year.
      schema:
        type: integer
        minimum: 1800
        maximum: 2025
    FirmoFoundedMax:
      name: founded_max
      in: query
      required: false
      description: Only companies founded in or before this year.
      schema:
        type: integer
        minimum: 1800
        maximum: 2025
    WebHasEmail:
      name: has_email
      in: query
      required: false
      description: >-
        Filter to domains where the crawler found (or did not find) an email
        address. `false` is a real filter, not a no-op.
      schema:
        type: boolean
    WebHasPhone:
      name: has_phone
      in: query
      required: false
      description: >-
        Filter to domains where the crawler found (or did not find) a phone
        number.
      schema:
        type: boolean
    WebSocial:
      name: social
      in: query
      required: false
      description: Filter to domains publishing a profile on this platform.
      schema:
        type: string
        enum:
          - linkedin
          - x
          - facebook
          - instagram
          - youtube
          - github
          - tiktok
          - discord
          - reddit
          - crunchbase
          - slack
      example: instagram
    WebLanguage:
      name: language
      in: query
      required: false
      description: Filter by the site's primary language.
      schema:
        type: string
      example: de
    WebCountry:
      name: web_country
      in: query
      required: false
      description: >-
        Filter by the country the site declares in its schema.org markup.
        Accepts ISO-2, English name or common variants.
      schema:
        type: string
      example: USA
    SegmentId:
      name: segment_id
      in: query
      required: false
      description: >-
        Apply a saved audience instead of inline filters. Filter audiences
        replay their firmographic predicates; list audiences restrict rows to
        their member domains. Mutually exclusive with inline firmographic
        parameters.
      schema:
        type: string
      example: seg_8f3a2c1b
  responses:
    BadRequest:
      description: Invalid or missing parameters
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
          example:
            success: false
            error:
              code: VALIDATION_ERROR
              message: >-
                Provide exactly one scope: technology_id, technology or
                category_id.
    Unauthorized:
      description: Missing or invalid API key
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    PaymentRequired:
      description: Not enough credits, or the plan does not include this feature
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
          example:
            success: false
            error:
              code: INSUFFICIENT_CREDITS
              message: Insufficient credits for this request.
              details:
                required: 1
                available: 0
    Forbidden:
      description: The plan does not allow this action, or a plan limit was reached
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
          example:
            success: false
            error:
              code: PLAN_LIMIT
              message: >-
                Your plan allows up to 2 saved audiences. Delete one to create
                another.
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    RateLimited:
      description: Rate limit exceeded
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    QueryTimeout:
      description: >-
        The query exceeded the 30-second server-side limit. Narrow the query and
        retry.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
          example:
            success: false
            error:
              code: SEGMENT_QUERY_TIMEOUT
              message: The segment query exceeded the 30s server-side limit.
              details:
                suggestion: >-
                  Narrow the segment — add an employees band, industry, or city
                  — and try again.
  schemas:
    ApiError:
      type: object
      properties:
        success:
          type: boolean
          example: false
        error:
          type: object
          properties:
            code:
              type: string
              example: UNAUTHORIZED
            message:
              type: string
              example: Missing or invalid API key
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key in format `tapi_live_[32-char]` (live) or `tapi_test_[32-char]`
        (test)

````