TCPLab TCPLab

ICP Filing Lookup API

Last updated: 2026-10-19

GET /api/v2/icp/query?domain={domain}

Returns ICP filing records for a domain filed in mainland China. Base URL, response format and rate limits are shared across endpoints — see the API documentation.

Parameter In Description
domain query Domain or URL to look up. Whitespace, scheme, userinfo, path, query, port and a trailing dot are stripped. IP addresses are not supported. IDNs may be passed in Unicode or punycode.

The API extracts the registrable domain before querying: www.baidu.com becomes baidu.com, and a.b.example.com.cn becomes example.com.cn. The suffix is checked against the MIIT-approved list (171 suffixes). .com, .cn, .net, .top, .xyz, .中国, .公司 and similar suffixes are supported; .org, .io, .us and other unapproved suffixes return api.param.domain.suffix_unsupported.

Example:

curl "https://tcp.lc/api/v2/icp/query?domain=baidu.com"

Response data fields:

Field Description
domain Registrable domain that was queried. IDNs are returned in Unicode.
suffix Top-level suffix used for validation, such as .com or .中国. For example.com.cn this is .cn.
filed true when at least one filing record was found.
records Filing records; empty when filed is false.
source primary (preferred source) or fallback (secondary source).
fetchedAt ISO 8601 time when the data was fetched from the source. Cache hits keep the original fetch time.
cached true when this response was served from the server-side cache.

Each record contains:

Field Description
domain Domain covered by the record.
mainLicence Entity filing number (主体备案号).
serviceLicence Website filing number (网站备案号).
unitName Registrant or entity name.
natureName Entity type, such as 企业 or 个人; usually in Chinese.
contentType Pre-approval items, when present.
limitAccess Access restriction flag, when present.
siteName Website name when the source provides it; otherwise null.
updatedAt Approval / last update time from the filing system.

Example:

{
  "code": 200,
  "msg": "ok",
  "data": {
    "domain": "baidu.com",
    "suffix": ".com",
    "filed": true,
    "records": [
      {
        "domain": "baidu.com",
        "mainLicence": "京ICP证030173号",
        "serviceLicence": "京ICP证030173号-1",
        "unitName": "北京百度网讯科技有限公司",
        "natureName": "企业",
        "contentType": "",
        "limitAccess": "",
        "siteName": null,
        "updatedAt": "2019-05-16 16:06:21"
      }
    ],
    "source": "primary",
    "fetchedAt": "2026-10-19T04:12:00.000Z",
    "cached": false
  }
}

A domain with no filing is not an error. The response is still code: 200, with filed: false and an empty records array:

{
  "code": 200,
  "msg": "ok",
  "data": {
    "domain": "example.com",
    "suffix": ".com",
    "filed": false,
    "records": [],
    "source": "primary",
    "fetchedAt": "2026-10-19T04:12:00.000Z",
    "cached": false
  }
}

Errors

Failures use code: -1000, with msg set to a stable identifier. data.args may carry details.

msg Meaning
api.param.domain.missing No domain parameter was provided.
api.param.domain.invalid The input could not be parsed as a domain. data.args.name carries the input.
api.param.domain.ip_unsupported IP addresses are not supported.
api.param.domain.suffix_unsupported The suffix is not on the MIIT-approved list. data.args.suffix carries it, e.g. .org.
api.rate.limitedDaily The daily quota is exhausted. A Retry-After header is included.
api.upstream.icp.error Both filing sources are unavailable, a source timed out, or its response was invalid.
api.server.internal Server or configuration error.

Example:

{
  "code": -1000,
  "msg": "api.param.domain.suffix_unsupported",
  "data": {
    "args": {
      "suffix": ".org"
    }
  }
}

Notes

  • filed: false means no record was found. The domain may be unfiled, registered outside mainland China, or its filing may have been cancelled.
  • Chinese IDN domains are supported. If the preferred source is unavailable, an IDN query may return api.upstream.icp.error instead of a possibly incorrect filed: false, because the fallback source cannot reliably resolve IDN names.
  • Filing data changes slowly but is not real-time. Use fetchedAt and the official MIIT filing system for verification.

Rate limits and caching

20 upstream lookups per day per client IP. Cache hits are free and do not consume the quota. The daily quota resets at 00:00 UTC+8; when exhausted, the endpoint returns api.rate.limitedDaily with a Retry-After header in seconds.

Filed results are cached for 7 days and unfiled results for 24 hours. The API response is sent with Cache-Control: no-store; caching happens on the server. Check cached to see whether the result came from the cache.