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

# Peer Valuation Comparison

> Retrieve peer companies and comparable valuation, earnings-per-share, and related metrics.

## Plan Access

| Plan | Available |
| - | :-: |
| Free | ❌ |
| Starter | ❌ |
| Professional | ✅ |
| Full-Market Plans (A-Shares, HK Stocks, US Stocks) | ✅ |
| Enterprise | ✅ |

## Notes

* Peer samples and metric availability vary by market and company. Financial ratios are normally returned as strings.

## Supported Markets

| Market | Examples |
| - | - |
| US Stocks | AAPL.US |
| HK Stocks | 700.HK |
| A-Shares | 600519.SH |

## Request Parameters

| Parameter | Required | Description |
| - | :-: | - |
| `symbol` | Yes | Stock symbol |
| `type` | No | Product type; currently supports `stock` |

## Request Example

```bash theme={null}
curl -H "X-API-Key: YOUR_API_KEY" \
  "https://api.tickdb.ai/v1/fundamentals/industry/peers?symbol=AAPL&type=stock"
```

## Response Fields

The table below lists fields in `data`; an outer `code=0` indicates success.

| Field | Description |
| - | - |
| parent\_symbol | Queried stock symbol. |
| peers | Peer companies and comparable metrics. |
| └─ peer\_symbol | Peer stock symbol. |
| └─ peer\_name | Peer company name. |
| └─ currency | Metric currency. |
| └─ pe | Price-to-earnings ratio. |
| └─ eps | Earnings per share. |
| └─ bps | Book value per share. |
| └─ assets | Asset metric. |
| └─ dps | Dividend per share. |
| └─ div\_yield | Dividend yield. |
| └─ div\_payout\_ratio | Dividend payout ratio. |
| └─ five\_y\_avg\_dps | Five-year average dividend per share. |

Returns peer valuation, earnings per share, book value per share, dividend, and related metrics for cross-company comparison.


## OpenAPI

````yaml openapi.en.yaml GET /v1/fundamentals/industry/peers
openapi: 3.1.0
info:
  title: TickDB API
  description: TickDB unified real-time market data API via REST and WebSocket.
  version: 1.0.3
  contact:
    email: support@tickdb.ai
servers:
  - url: https://api.tickdb.ai
    description: Production server
security:
  - ApiKeyAuth: []
paths:
  /v1/fundamentals/industry/peers:
    get:
      tags:
        - fundamentals-valuation-industry
      summary: Peer Valuation Comparison
      description: >-
        Retrieve peer companies and comparable valuation, earnings-per-share,
        and related metrics.
      operationId: getFundamentalsIndustryPeers
      parameters:
        - $ref: '#/components/parameters/SymbolQuery'
        - $ref: '#/components/parameters/TypeQuery'
      responses:
        '200':
          $ref: '#/components/responses/IndustryPeersResponse'
        default:
          $ref: '#/components/responses/ErrorResponse'
components:
  parameters:
    SymbolQuery:
      name: symbol
      in: query
      required: true
      schema:
        type: string
        examples:
          - AAPL
          - '700'
          - '600519'
          - AAPL.US
          - 700.HK
          - 600519.SH
      description: Stock symbol
    TypeQuery:
      name: type
      in: query
      required: false
      schema:
        type: string
        enum:
          - stock
      description: Product type; currently supports `stock`
  responses:
    IndustryPeersResponse:
      description: Peer Valuation Comparison response.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/IndustryPeersEnvelope'
    ErrorResponse:
      description: >-
        Error response. Common HTTP statuses include 400 (invalid parameters),
        401 (authentication failed), 403 (permission or quota restriction), 404
        (no matching data), 429 (rate limit), and 503 (service temporarily
        unavailable).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorEnvelope'
          examples:
            missingAPIKey:
              summary: Missing API key
              value:
                code: '1002'
                message: API key is required. Provide via X-API-Key header
                error: '1002'
            missingKind:
              summary: Missing required parameter
              value:
                code: 40001
                message: kind is required
                data: null
            endpointForbidden:
              summary: API key cannot access this endpoint
              value:
                code: 3009
                message: This endpoint is not allowed for your API key
                data: null
            marketForbidden:
              summary: API key cannot access this market
              value:
                code: 3010
                message: Fundamentals market not allowed for your API key
                data:
                  market: US
            noAvailableSource:
              summary: Data temporarily unavailable
              value:
                code: 5003
                message: Data is temporarily unavailable
                data: null
            notFound:
              summary: No matching data
              value:
                code: 40404
                message: shareholder detail not found
                data: null
            businessNoData:
              summary: No business data matches the query
              value:
                code: 40405
                message: valuation time series not found
                data: null
  schemas:
    IndustryPeersEnvelope:
      allOf:
        - $ref: '#/components/schemas/SuccessEnvelope'
        - type: object
          properties:
            data:
              $ref: '#/components/schemas/IndustryPeersData'
    ErrorEnvelope:
      type: object
      required:
        - code
        - message
      properties:
        code:
          description: >-
            TickDB API business error code; may be an integer or string. Convert
            it to a string before comparing.
          oneOf:
            - type: integer
            - type: string
        message:
          type: string
          description: Error description.
        error:
          type: string
          description: >-
            Compatibility error identifier; present only in some error
            responses.
        data:
          description: Optional error context; may be null, an object, or an array.
          oneOf:
            - type: 'null'
            - type: object
              additionalProperties: true
            - type: array
              items: {}
    SuccessEnvelope:
      type: object
      required:
        - code
        - data
      properties:
        code:
          type: integer
          const: 0
          description: Business status code; `0` means success.
    IndustryPeersData:
      type: object
      required:
        - parent_symbol
        - peers
      properties:
        parent_symbol:
          type: string
          description: Queried stock symbol.
        peers:
          type: array
          description: Peer companies and comparable metrics.
          items:
            $ref: '#/components/schemas/PeerItem'
      additionalProperties: true
    PeerItem:
      type: object
      required:
        - peer_symbol
        - peer_name
      properties:
        peer_symbol:
          type: string
          description: Peer stock symbol.
        peer_name:
          type: string
          description: Peer company name.
        currency:
          type:
            - string
            - 'null'
          description: Metric currency.
        assets:
          type:
            - string
            - number
            - 'null'
          description: Asset metric.
        bps:
          type:
            - string
            - number
            - 'null'
          description: Book value per share.
        eps:
          type:
            - string
            - number
            - 'null'
          description: Earnings per share.
        dps:
          type:
            - string
            - number
            - 'null'
          description: Dividend per share.
        div_yield:
          type:
            - string
            - number
            - 'null'
          description: Dividend yield.
        div_payout_ratio:
          type:
            - string
            - number
            - 'null'
          description: Dividend payout ratio.
        five_y_avg_dps:
          type:
            - string
            - number
            - 'null'
          description: Five-year average dividend per share.
        pe:
          type:
            - string
            - number
            - 'null'
          description: Price-to-earnings ratio.
      additionalProperties: true
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key

````

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