Industry Hierarchy
curl --request GET \
--url https://api.tickdb.ai/v1/fundamentals/industries/tree \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.tickdb.ai/v1/fundamentals/industries/tree"
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/industries/tree', 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/industries/tree",
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/industries/tree"
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/industries/tree")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tickdb.ai/v1/fundamentals/industries/tree")
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": {
"market": "<string>",
"industry_counter_id": "<string>",
"top": {
"name": "<string>",
"market": "<string>"
},
"chain": {
"name": "<string>",
"level": 123,
"market": "<string>",
"counter_id": "<string>",
"next": "<array>",
"parent_code": "<string>",
"sharelist_id": "<string>",
"symbol": "<string>",
"stock_num": 1,
"chg": "<string>",
"ytd_chg": "<string>"
}
}
}Valuation and Industries
Industry Hierarchy
Retrieve an industry’s top-level classification and lower-level industry categories.
GET
/
v1
/
fundamentals
/
industries
/
tree
Industry Hierarchy
curl --request GET \
--url https://api.tickdb.ai/v1/fundamentals/industries/tree \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.tickdb.ai/v1/fundamentals/industries/tree"
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/industries/tree', 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/industries/tree",
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/industries/tree"
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/industries/tree")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tickdb.ai/v1/fundamentals/industries/tree")
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": {
"market": "<string>",
"industry_counter_id": "<string>",
"top": {
"name": "<string>",
"market": "<string>"
},
"chain": {
"name": "<string>",
"level": 123,
"market": "<string>",
"counter_id": "<string>",
"next": "<array>",
"parent_code": "<string>",
"sharelist_id": "<string>",
"symbol": "<string>",
"stock_num": 1,
"chg": "<string>",
"ytd_chg": "<string>"
}
}
}Plan Access
| Plan | Available |
|---|---|
| Free | ❌ |
| Starter | ❌ |
| Professional | ✅ |
| Full-Market Plans (A-Shares, HK Stocks, US Stocks) | ✅ |
| Enterprise | ✅ |
Notes
- Obtain
industry_counter_idfrom Industry Metric Rankings. Industry nodes from different markets cannot be mixed. marketis case-insensitive. This documentation uses uppercase market codes consistently.
Supported Markets
| Market | Examples |
|---|---|
| US Stocks | US |
| HK Stocks | HK |
| A-Shares | CN |
Request Parameters
| Parameter | Required | Description |
|---|---|---|
market | Yes | Market code: US US stocks, HK Hong Kong stocks, or CN A-shares |
industry_counter_id | Yes | Industry node ID returned by Industry Metric Rankings |
Request Example
curl -H "X-API-Key: YOUR_API_KEY" \
"https://api.tickdb.ai/v1/fundamentals/industries/tree?market=US&industry_counter_id=BK%2FUS%2FIN00260"
Response Fields
The table below lists fields indata; an outer code=0 indicates success.
| Field | Description |
|---|---|
| market | Queried market. |
| industry_counter_id | Industry node ID. |
| top | Top-level industry classification. |
| └─ name | Top-level industry name. |
| └─ market | Top-level industry market. |
| chain | Hierarchy containing the current industry and its children. |
| └─ name | Node name. |
| └─ counter_id | Industry node ID. |
| └─ level | Node level. |
| └─ parent_code | Parent node code. |
| └─ market | Market. |
| └─ stock_num | Number of stocks. |
| └─ chg | Change value. |
| └─ ytd_chg | Year-to-date change. |
| └─ symbol | Associated node symbol. |
| └─ sharelist_id | Stock-list ID. |
| └─ next | Child industry categories; each element recursively uses the same node structure. |
Authorizations
Query Parameters
Market code: US US stocks, HK Hong Kong stocks, or CN A-shares
Available options:
US, HK, CN Industry node ID returned by Industry Metric Rankings
