年度財務報表
curl --request GET \
--url https://api.tickdb.ai/v1/fundamentals/financials/annual \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.tickdb.ai/v1/fundamentals/financials/annual"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.tickdb.ai/v1/fundamentals/financials/annual', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tickdb.ai/v1/fundamentals/financials/annual",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tickdb.ai/v1/fundamentals/financials/annual"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.tickdb.ai/v1/fundamentals/financials/annual")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tickdb.ai/v1/fundamentals/financials/annual")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"code": 0,
"data": {
"symbol": "<string>",
"kind": "IS",
"rows": [
{
"kind": "IS",
"field_name": "<string>",
"indicator_title": "<string>",
"value": "<string>",
"fiscal_year": 123,
"fiscal_period": "<string>",
"period_type": "<string>",
"period_end": "2023-12-25",
"field_display": "<string>",
"currency": "<string>",
"is_percent": true,
"yoy": "<string>",
"ratio": "<string>"
}
]
}
}財務報表
年度財務報表
查詢最近若干年的利潤表、資產負債表或現金流量表指標數據。
GET
/
v1
/
fundamentals
/
financials
/
annual
年度財務報表
curl --request GET \
--url https://api.tickdb.ai/v1/fundamentals/financials/annual \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.tickdb.ai/v1/fundamentals/financials/annual"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.tickdb.ai/v1/fundamentals/financials/annual', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tickdb.ai/v1/fundamentals/financials/annual",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tickdb.ai/v1/fundamentals/financials/annual"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.tickdb.ai/v1/fundamentals/financials/annual")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tickdb.ai/v1/fundamentals/financials/annual")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"code": 0,
"data": {
"symbol": "<string>",
"kind": "IS",
"rows": [
{
"kind": "IS",
"field_name": "<string>",
"indicator_title": "<string>",
"value": "<string>",
"fiscal_year": 123,
"fiscal_period": "<string>",
"period_type": "<string>",
"period_end": "2023-12-25",
"field_display": "<string>",
"currency": "<string>",
"is_percent": true,
"yoy": "<string>",
"ratio": "<string>"
}
]
}
}套餐權限
| 套餐 | 可用 |
|---|---|
| 免費版 | ❌ |
| 基礎版 | ✅ |
| 專業版 | ✅ |
| 全量套餐(A 股、港股、美股) | ✅ |
| 企業版 | ✅ |
注意事項
rows是字段級記錄;同一年度可能對應多條財務指標。
支持的市場
| 市場 | 示例 |
|---|---|
| 美股 | AAPL.US |
| 港股 | 700.HK |
| A股 | 600519.SH |
請求參數
| 參數 | 是否必須 | 說明 |
|---|---|---|
symbol | 是 | 股票代碼 |
type | 否 | 產品類型,當前支持 stock |
kind | 是 | 報表類型:IS 利潤表、BS 資產負債表、CF 現金流量表 |
n | 否 | 返回年度數,范圍 1–20 |
請求示例
curl -H "X-API-Key: YOUR_API_KEY" \
"https://api.tickdb.ai/v1/fundamentals/financials/annual?symbol=AAPL&type=stock&kind=IS&n=5"
返回字段說明
以下列出data 中的字段;外層 code=0 表示成功。
| 字段 | 說明 |
|---|---|
| symbol | 股票代碼。 |
| kind | 報表類型:IS 利潤表、BS 資產負債表、CF 現金流量表。 |
| rows | 各年度的報表指標記錄;同一年度通常有多條。 |
| └─ kind | 該記錄所屬報表類型:IS 利潤表、BS 資產負債表、CF 現金流量表。 |
| └─ field_name | 財務字段代碼;查看財務字段字典。 |
| └─ field_display | 展示名稱。 |
| └─ indicator_title | 指標標題。 |
| └─ value | 字段數值,以字符串返回。 |
| └─ currency | 幣種。 |
| └─ is_percent | 是否為百分比字段。 |
| └─ fiscal_year | 財年。 |
| └─ fiscal_period | 報告期。 |
| └─ period_type | 財務周期類型;年度數據通常為 af(年度),也可能以 q4(第四季度)表示年末報告期。 |
| └─ period_end | 期末日期,格式 YYYY-MM-DD。 |
| └─ yoy | 同比變化;可能為 null。 |
| └─ ratio | 比率;可能為 null。 |
n 控制年度數。授權
查詢參數
股票代碼
範例:
"AAPL"
"700"
"600519"
"AAPL.US"
"700.HK"
"600519.SH"
產品類型,當前支援 stock
可用選項:
stock 報表類型:IS 利潤表、BS 資產負債表、CF 現金流量表
可用選項:
IS, BS, CF 返回期數,范圍 1–20
必填範圍:
1 <= x <= 20