Friends Data API独立数据服务

DATASET · ref

规范证券主表

ref.instrument
A 股标的与映射

Friends Data API 的统一标的入口,定义 instrument_id、代码、名称、市场、交易所和资产类型。

字段30
关键字段1
更新口径daily
时间列—
单页上限50000
分页Cursor
PIT不支持
规模100K-999K

WHAT IT ANSWERS

这张表适合回答什么

  • 用名称或代码解析 instrument_id
  • 联接跨数据集证券记录
  • 构建可查询标的宇宙

GRAIN & TIME

一行代表什么

业务粒度
每行代表“规范证券主表”的一条记录;逻辑粒度由 instrument_id 共同确定。
时间口径
该表没有单一主时间列;请使用业务日期或版本字段,并按关键字段确定范围。
更新节奏
通常按交易日或自然日更新;具体最新日期请以返回数据为准。

KEY FIELDS

先看这些字段

instrument_id
WarrenHub 统一证券标识;跨证券数据集优先用它联接。

RECOMMENDED JOINS

怎样和其他表关联

这是证券维表:market、fundamental、flow、ownership 等表只要含 instrument_id,就优先用该字段关联到这里补代码、名称、市场、交易所和资产类型。

HOW TO QUERY SAFELY

查询方法与已知限制

先用 catalog 确认当前契约;可按 catalog 中列出的 filters 进一步缩小范围;单页最多 50000 行,响应有 has_more 时原样传回 next_cursor 继续分页。

MACHINE CONTRACT

筛选、排序与分页

UNVERSIONED
默认排序
updated_at, instrument_id
唯一键
—
读取模式
canonical_final_active
最大时间窗
未单独限制

可用 filters

asset_type→ asset_type · string
exchange→ exchange · string
market→ market · string
symbol→ symbol · string

POINT IN TIME

可复现读取

NOT AVAILABLE

该资产没有 PIT 契约。普通 rows 端点仍按当前公开读模式返回数据;不要把它表述成历史时点快照。

COPY-READY CALLS

怎么调用

同一数据集可用 HTTP、Python SDK、CLI 或 MCP;Key 始终只通过环境变量/Bearer Header 传递。

READ ONLY
HTTP
curl --fail-with-body -H "Authorization: Bearer $FRIENDS_DATA_API_KEY" "https://api.alphahubs.uk/api/v1/data/datasets/ref/instrument/rows?limit=100&asset_type=equity"

FIELD DICTIONARY

30 个返回字段

descriptionSource 可在 JSON 中区分仓库注释、标准术语表和名称推导说明。

#字段ClickHouse 类型JSON可空角色说明
1instrument_idUInt64integernodefault_order, warehouse_primary_keyWarrenHub canonical instrument identifier; use it for cross-dataset joins.标准术语表
2symbolStringstringnofilterDisplay or trading symbol for the instrument.标准术语表
3marketLowCardinality(String)stringnofilterCanonical market or country-market code.标准术语表
4asset_typeLowCardinality(String)stringnofilterInstrument asset-class classification.标准术语表
5exchangeLowCardinality(String)stringnofilterListing or trading exchange.标准术语表
6nameStringstringnovalueCanonical human-readable name.标准术语表
7name_enStringstringnovalueEnglish human-readable name when available.标准术语表
8providerLowCardinality(String)stringnoprovenanceUpstream data provider identifier.标准术语表
9source_urlStringstringnoprovenanceURL of the upstream evidence or record when distributable.标准术语表
10source_record_idStringstringnoprovenanceProvider-side identifier for the source record.标准术语表
11raw_payload_hashStringstringnoprovenanceOpaque fingerprint of the normalized source payload for provenance checks.标准术语表
12parser_versionLowCardinality(String)stringnoprovenanceVersion of the parser or normalizer that produced the row.标准术语表
13quality_statusLowCardinality(String)stringnoprovenanceMachine-readable data-quality classification.标准术语表
14license_scopeLowCardinality(String)stringnoprovenanceLicense or redistribution scope attached to the row.标准术语表
15visibility_tierLowCardinality(String)stringnoprovenanceServing visibility tier attached to the row.标准术语表
16ingest_run_idStringstringnoprovenanceIdentifier of the ingestion run that produced the row.标准术语表
17versionUInt64integernoprovenanceMonotonic row version used for correction-aware reads.标准术语表
18is_deletedUInt8integernovalueSoft-delete marker; public serving excludes current tombstones.标准术语表
19created_atUTC_datetimeDateTime64(3, 'UTC')string / date-timenovalueUTC timestamp when the warehouse row was first created.标准术语表
20updated_atUTC_datetimeDateTime64(3, 'UTC')string / date-timenodefault_orderUTC timestamp when the warehouse row was last updated.标准术语表
21list_datedateNullable(Date)string / dateyesvalueCalendar date for list date (YYYY-MM-DD).名称推导
22delist_datedateNullable(Date)string / dateyesvalueCalendar date for delist date (YYYY-MM-DD).名称推导
23countryLowCardinality(String)stringnovalueSource-normalized field: country.名称推导
24currencyLowCardinality(String)stringnovalueISO-like currency code for monetary values.标准术语表
25sectorLowCardinality(String)stringnovalueSource-normalized field: sector.名称推导
26industryLowCardinality(String)stringnovalueSource-normalized field: industry.名称推导
27cusipStringstringnovalueSource-normalized field: cusip.名称推导
28isinStringstringnovalueSource-normalized field: isin.名称推导
29figiStringstringnovalueSource-normalized field: figi.名称推导
30is_activeUInt8integernovalueWhether active applies to the row.名称推导
字典口径

结构来自 Friends 只读身份可见的真实 serving relation;权限、过滤、排序、PIT 与分页来自可执行 DatasetSpec。Schema observed at 2026-10-06T18:08:52Z。