GET
/v1/tadig/:code/global-title-ranges用途与边界
GT 只用于网络节点路由,不参与用户号码原始归属匹配。空结果表示目录未提供该声明,不代表运营商没有 GT。完整快照和授权网络变更可携带 global_title_ranges;普通网络查询不附带此清单。 任一网络或 GT 来源尚未生效都会令 status=scheduled,source 为 GT 自身来源,网络来源可从 TADIG 接口获取。匿名仅返回关联字段,不返回 status;demo 可匿名完整展示。不接受 at。
请求参数
| 参数 | 类型 / 位置 | 说明 |
|---|---|---|
code | string · path | 五位 TADIG,大小写不敏感。 |
cursor / limit | string / integer · query | 分页游标与条数,默认20,最大500。版本变化返回409,请重新查询。 |
请求示例
cURL / 合成示例
curl 'https://YOUR_IR21DATA_HOST/api/v1/tadig/DEMO1/global-title-ranges?limit=20' -H "X-API-Key: $IR21DATA_API_KEY"成功响应示例
以下是结构示例,不是当前在线目录的查询结果。
JSON
{
"code": 0,
"data": {
"tadig": "DEMO1",
"access": "full",
"items": [
{
"id": "example-gt",
"network_id": "example-network",
"operator_id": "example-operator",
"tadig": "DEMO1",
"operator_name": "Synthetic carrier",
"country_code": "1",
"ndc": "202",
"sn_start": "0000",
"sn_end": "0099",
"prefix": "1202",
"start": "12020000",
"end": "12020099",
"number_length": 8,
"source": {
"source": "synthetic-example",
"source_published_at": null,
"effective_at": null,
"ingested_at": "2026-09-08T00:00:00Z"
},
"status": "declared"
}
],
"total": 1,
"next_cursor": null
},
"meta": {
"request_id": "example-request-id",
"dataset_version": "example-v1",
"source_mode": "demo",
"source_published_at": null,
"ingested_at": "2026-09-08T00:00:00Z"
}
}data 字段语义
| 字段 | 类型 | 说明 |
|---|---|---|
access | preview | full | 真实匿名预览不含号段及来源详情;登录或 API Key 返回完整字段。 |
items / total / next_cursor | array / number / string | null | 网络关联号段分页结果,不折叠多个网络。 |
country_code / ndc / sn_start / sn_end | string | null | 源声明分段,保留前导零;不从完整号码猜测缺失分段。 |
prefix / start / end / number_length | string / string | null / number | null | 完整前缀、区间及声明长度。 |
status / source | declared | scheduled / SourceInfo | 未来生效必须标为 scheduled;来源保留原始时间。 |
id / network_id / operator_id / tadig / operator_name | string / string | null | 匿名也可见的记录关联与运营商名称。 |
响应、鉴权与错误
数据接口支持X-API-Key 或同源 Cookie 会话。匿名访问为受限公共投影,完整字段权限由 API 服务执行。JSON 成功响应统一为{code:0,data,meta};文件导出直接返回文件。
| 字段 | 说明 |
|---|---|
meta.request_id | 本次请求标识,用于排查错误,不包含密钥。 |
meta.dataset_version / source_mode | 当前数据版本与 demo / ir21 / reference / mixed 来源模式。 |
meta.source_published_at | 源发布时间;未知为 null。 |
meta.ingested_at | 平台导入时间,ISO 格式 UTC。 |
400 表示参数不符,401 表示需要有效凭证,403 表示权限不足,409 表示目录或游标版本冲突,429 表示调用限制,503 表示服务或数据源暂不可用。请读取错误响应的 code、message、request_id,详见错误与重试。
ERROR / 示意结构
{
"code": "EXAMPLE_ERROR_CODE",
"message": "具体错误原因由服务端返回",
"request_id": "example-request-id"
}