---
title: "Get the historical price series for a company"
url: "https://developer.argaam.com/apis/market-data-layer-api-production-v1/versions/ca86b5b0-4709-486f-b41b-f80ad96b0d25/operations/getCompaniesByStockSymbolPriceHistory"
---

> Full API specification: https://developer.argaam.com/apis/market-data-layer-api-production-v1/versions/ca86b5b0-4709-486f-b41b-f80ad96b0d25.md

# Get the historical price series for a company

`GET` `/api/v1.1/companies/{stockSymbol}/price/history`

Operation ID: `getCompaniesByStockSymbolPriceHistory`

Returns end-of-day OHLC price history for the company. Bound the result with `from`/`to` or `period` - unbounded calls return the full available history and are heavily rate limited. Bound the result with the `from` and `to` date parameters.

## Path parameters

- `stockSymbol` (string, required) - Tadawul stock symbol of the company, e.g. `2222` (Saudi Aramco).

## Query parameters

- `marketId` (integer, int32, optional) - Numeric market identifier (e.g. `1` = Tadawul / Saudi main market). Use `GET /api/v1.1/markets` to list valid values.
- `from` (string, optional) - Start of the date range, inclusive. Format `YYYY-MM-DD`.
- `to` (string, optional) - End of the date range, inclusive. Format `YYYY-MM-DD`.

## Responses

- `200` - Success

## OpenAPI definition

```yaml
openapi: 3.0.1
info:
  title: Market Data Layer API
  version: v1.1
servers:
  - url: https://api.argaam.com
    description: Argaam API Gateway (Production)
paths:
  /api/v1.1/companies/{stockSymbol}/price/history:
    get:
      tags:
        - Companies
      parameters:
        - name: stockSymbol
          in: path
          required: true
          schema:
            type: string
          example: "2222"
          description: Tadawul stock symbol of the company, e.g. `2222` (Saudi Aramco).
        - name: marketId
          in: query
          schema:
            type: integer
            format: int32
            default: 3
          example: 3
          description: Numeric market identifier (e.g. `1` = Tadawul / Saudi main market).
            Use `GET /api/v1.1/markets` to list valid values.
        - name: from
          in: query
          schema:
            type: string
          example: 2024-01-01
          description: Start of the date range, inclusive. Format `YYYY-MM-DD`.
        - name: to
          in: query
          schema:
            type: string
          example: 2024-03-31
          description: End of the date range, inclusive. Format `YYYY-MM-DD`.
      responses:
        "200":
          description: Success
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ApiV1Response"
      summary: Get the historical price series for a company
      description: >-
        Returns end-of-day OHLC price history for the company. Bound the result
        with `from`/`to` or `period` - unbounded calls return the full available
        history and are heavily rate limited.


        Bound the result with the `from` and `to` date parameters.
      operationId: getCompaniesByStockSymbolPriceHistory
security:
  - ApiKeyAuth: []
components:
  schemas:
    ApiV1Response:
      type: object
      properties:
        success:
          type: boolean
        apiVersion:
          type: string
          nullable: true
        timestamp:
          type: string
          format: date-time
        requestId:
          type: string
          nullable: true
        data:
          nullable: true
        meta:
          $ref: "#/components/schemas/ApiV1Meta"
        rateLimit:
          $ref: "#/components/schemas/ApiV1RateLimit"
      additionalProperties: false
    ApiV1Meta:
      type: object
      properties:
        page:
          type: integer
          format: int32
        pageSize:
          type: integer
          format: int32
        totalRecords:
          type: integer
          format: int32
        totalPages:
          type: integer
          format: int32
          readOnly: true
        hasNextPage:
          type: boolean
          readOnly: true
        hasPreviousPage:
          type: boolean
          readOnly: true
      additionalProperties: false
    ApiV1RateLimit:
      type: object
      properties:
        limit:
          type: integer
          format: int32
        remaining:
          type: integer
          format: int32
        reset:
          type: string
          format: date-time
      additionalProperties: false
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: apikey
```
