Stock News

Get Stock News

Request Class:NewsStockListRequest

Description

Retrieves the news list of a specified stock, corresponding to the news_stock_list method.

  • Only a single symbol is supported; batch queries are not supported. Query multiple stocks one at a time.
  • Paginated by pageCount / pageSize; the first page (pageCount=1) contains the latest articles.

Parameters

NewsStockListRequest.newRequest(String symbol, Language lang, Integer pageCount, Integer pageSize)

ParameterTypeRequiredDescription
symbolStringYesStock symbol, e.g. AAPL. Single symbol only; batch queries are not supported
langLanguageNoLanguage enum: zh_CN / zh_TW / en_US
pageCountIntegerNoPage number, starting from 1, default 1, value >= 1
pageSizeIntegerNoPage size, default 20, range 1–50

Response

com.tigerbrokers.stock.openapi.client.https.response.news.NewsStockListResponse

The returned data can be accessed via NewsStockListResponse.getNewsPageItem(), which returns a NewsPageItem (com.tigerbrokers.stock.openapi.client.https.domain.news.item.NewsPageItem) object with the following fields:

FieldTypeDescription
itemsList<NewsItem>News article list
pageCountIntegerCurrent page number
pageSizeIntegerPage size
totalPageIntegerTotal number of pages
totalSizeIntegerTotal number of articles

Each NewsItem (com.tigerbrokers.stock.openapi.client.https.domain.news.item.NewsItem) has the following fields:

FieldTypeDescription
idStringArticle ID
titleStringTitle
summaryStringSummary
pubTimestampLongPublication timestamp (seconds)
urlStringArticle URL

Example Request

TigerHttpClient client = TigerHttpClient.getInstance().clientConfig(
    ClientConfig.DEFAULT_CONFIG);

NewsStockListRequest request = NewsStockListRequest.newRequest("AAPL", Language.en_US, 1, 20);
NewsStockListResponse response = client.execute(request);
if (response.isSuccess()) {
  for (NewsItem item : response.getNewsPageItem().getItems()) {
    System.out.println(item.getTitle() + " — " + item.getUrl());
  }
} else {
  System.out.println("response error:" + response.getMessage());
}

Example Response

{
  "items": [
    {
      "id": "",
      "title": "",
      "summary": "",
      "pubTimestamp": 1793906282,
      "url": "https://xxxx"
    }
  ],
  "pageCount": 1,
  "pageSize": 20,
  "totalPage": 14,
  "totalSize": 265
}

Rate Limit

The base rate limit is 60 requests/min.


Did this page help you?