Viewing: Stocks

Stocks

Get current stock quotes and prices for individual or multiple companies. For streaming updates, see Real-time WebSocket.

GET /quote/{symbol}/

Free

Get current price and trading data for a single stock symbol.

Endpoint

https://api.sahmk.sa/api/v1/quote/2222/?identifier=أرامكو

Parameters

(*) Required

ParameterTypeAllowed
symbol *string

stock ticker

identifierstring

company name or alias

data_modestring
realtimedelayed

plan default if omitted

Use symbol when identifier lookup is ambiguous.

Data availability by plan:

  • Free / Starter: Delayed prices (~15 minutes)
  • Pro+: Real-time prices
200 OKapplication/json
{
  "symbol": "2222",
  "name": "أرامكو السعودية",
  "name_en": "Saudi Arabian Oil Co",
  "price": 26.6,
  "change": 0.0,
  "change_percent": 0.0,
  "open": 26.6,
  "high": 26.68,
  "low": 26.52,
  "previous_close": 26.6,
  "volume": 6601208,
  "value": 175637052.96,
  "trade_count": 8330,
  "bid": 26.6,
  "bid_size": 9181,
  "ask": 26.62,
  "ask_size": 38155,
  "liquidity": {
    "inflow_value": 99498351.21,
    "inflow_volume": 3739041,
    "inflow_trades": 4858,
    "outflow_value": 76138701.51,
    "outflow_volume": 2862167,
    "outflow_trades": 3472,
    "net_value": 23359649.699999988
  },
  "auction": {
    "phase": "opening",
    "price": 26.58,
    "price_updated_at": "2026-10-07T06:31:01+00:00",
    "volume": 11646,
    "volume_updated_at": "2026-10-07T06:31:01+00:00",
    "symbol_state": null,
    "symbol_session": "pre-open"
  },
  "updated_at": "2026-08-12T12:20:00+00:00",
  "is_delayed": false,
  "resolved_instrument": {
    "input": "أرامكو",
    "symbol": "2222",
    "name": "أرامكو",
    "match_type": "alias_exact",
    "confidence": "high"
  }
}

Indicative auction

  • The same auction object is on the single quote, batch quotes, and the stocks WebSocket.
  • It is null outside a live opening or closing auction, and always null on a delayed plan.
  • price and updated_at stay the last official trade.
  • auction.phase is opening or closing.
View Temporary Price-Data Error
json
{
  "error": {
    "code": "PRICE_DATA_TEMPORARILY_UNAVAILABLE",
    "message": "Price data for '2222' is temporarily unavailable. Please retry shortly."
  }
}

GET /quotes/

Starter+

Get quotes for multiple companies in a single request. Requires Starter plan or higher.

Free tier fallback: GET /quote/{symbol}/ for single-company quotes.

Endpoint

https://api.sahmk.sa/api/v1/quotes/?symbols=2222,1120

Parameters

(*) Required

ParameterTypeAllowed
symbols *string

comma-separated tickers

identifiersstring

comma-separated company names

data_modestring
realtimedelayed

plan default if omitted

Use either symbols or identifiers, not both.

200 OKapplication/json
{
  "quotes": [
    {
      "symbol": "2222",
      "name": "أرامكو السعودية",
      "name_en": "Saudi Arabian Oil Co",
      "price": 26.6,
      "change": 0.0,
      "change_percent": 0.0,
      "open": 26.6,
      "high": 26.68,
      "low": 26.52,
      "previous_close": 26.6,
      "volume": 6601208,
      "value": 175637052.96,
      "trade_count": 8330,
      "bid": 26.6,
      "ask": 26.62,
      "bid_size": 9181,
      "ask_size": 38155,
      "liquidity": {
        "inflow_value": 99498351.21,
        "inflow_volume": 3739041,
        "inflow_trades": 4858,
        "outflow_value": 76138701.51,
        "outflow_volume": 2862167,
        "outflow_trades": 3472,
        "net_value": 23359649.699999988
      },
      "net_liquidity": 23359649.699999988,
      "auction": {
        "phase": "opening",
        "price": 26.58,
        "price_updated_at": "2026-10-07T06:31:01+00:00",
        "volume": 11646,
        "volume_updated_at": "2026-10-07T06:31:01+00:00",
        "symbol_state": null,
        "symbol_session": "pre-open"
      },
      "updated_at": "2026-09-23T01:03:00+03:00",
      "is_delayed": false
    },
    {
      "symbol": "1120",
      "name": "مصرف الراجحي",
      "name_en": "Al Rajhi Banking & Investment Corp SJSC",
      "price": 64.05,
      "change": -0.05,
      "change_percent": -0.08,
      "open": 64.1,
      "high": 64.3,
      "low": 63.7,
      "previous_close": 64.1,
      "volume": 3775688,
      "value": 241832816.4,
      "trade_count": 4120,
      "bid": 63.95,
      "ask": 64.05,
      "bid_size": 15,
      "ask_size": 43300,
      "liquidity": {
        "inflow_value": 80000000,
        "inflow_volume": 1250000,
        "inflow_trades": 1800,
        "outflow_value": 127806410.94999999,
        "outflow_volume": 2525688,
        "outflow_trades": 2320,
        "net_value": -47806410.94999999
      },
      "net_liquidity": -47806410.94999999,
      "auction": null,
      "updated_at": "2026-09-23T01:03:00+03:00",
      "is_delayed": false
    }
  ],
  "count": 2,
  "max_symbols": 50,
  "requested_count": 2
}

Batch limits

Requests are limited to 50 symbols. If more are requested, the response also includes truncated: true and a warning explaining that only the first 50 were processed.

Identifier resolution

When identifiers is used, the response also includes a resolution object with the requested count requested_count, the resolved count resolved_count, ambiguous names ambiguous, and names not found not_found.

Need symbols? Use GET /companies/

Quick conventions: use path params for a single resource (for example /quote/{symbol}/) and query params for list filtering (for example /events/?symbol=2222&limit=20). Common HTTP/API errors are centralized in Error Codes.

Last updated on