This document is generated by Gname.com.
https://tools.gname.com/v1/querymultipart/form-data.| Field | Parameter | Type | Required | Description |
|---|---|---|---|---|
| APPID | appid | String | Yes | API application ID. See Common Parameters. |
| Timestamp | timestamp | Integer | Yes | Current Unix timestamp in seconds. The difference from server time must not exceed 300 seconds. |
| Signature | sign | String | Yes | Request signature. See Signature Method. |
| Query Type | code | String | Yes | Always pass baiduydkwpm. |
| Domain | ym | String | Yes | Domain to query, such as baidu.com, without a protocol, port, or path. |
| Keyword | kw | String | Yes | A single keyword whose ranking is to be queried, such as 今日热搜 (today's trending searches). It must not be empty and must be included in the signature calculation. |
appid, timestamp, code, ym, kw, and any additional fields actually sent must be included in the signature calculation. Exclude sign itself.kw is missing, the response is 缺少关键词 (missing keyword). The example response uses domain baidu.com and keyword 今日热搜 (today's trending searches).| Field | Parameter | Type | Description |
|---|---|---|---|
| Status Code | code | Integer | Request processing status. 1 indicates success; other values indicate failure. |
| Message | msg | String | Message describing the request processing result. |
| Response Data | data | Object / Array | An object containing the query result on success. On failure, this may be an error details object or an empty array; not all fields are guaranteed to be present. |
data.| Field | Parameter | Type | Description |
|---|---|---|---|
| APPID | appid | String | API application ID used for this request. |
| Query Type | code | String | Query type for this request. The value is baiduydkwpm. |
| Domain | ym | String | Domain queried in this request. |
| Points Charged | cost_points | Integer | Query package points actually charged for this query, based on the current price of the query type. |
| Query Record ID | rw_id | String | Unique ID for this query record, used for tracing and reconciliation. |
| Query Result | result | Object | Baidu Mobile Keyword Rankings result. |
data.result.| Field | Parameter | Type | Description |
|---|---|---|---|
| Request Status | err_code | String / Integer | Request status. 200 indicates a successful HTTP request. You must also check the inner query status, data.code. |
| Request Message | err_msg | String | Request message, such as ok. This alone does not establish business success. |
| Query Response | data | Object | Query status and the specific business result. |
| Result Updated At | gxsj | String | Time when the query result was updated, in YYYY-MM-DD HH:mm:ss format. |
data.result.data.| Field | Parameter | Type | Description |
|---|---|---|---|
| Query Status | code | String / Integer | 1 indicates query success; other values indicate failure. Read the business result for indexing, SEO weight, or risk status. |
| Query Message | msg | String | Result message. It may be empty or omitted. Determine success from the status code. |
| Detailed Result | data | Object | Detailed business result. See the fields below. |
data.result.data.data.| Field | Parameter | Type | Description |
|---|---|---|---|
| Keyword Ranking | rank | String | Position in the search results, returned as a string. The example on this page is 4. Interpret the ranking separately from the query success status, code. |
| Matching Page URL | link | String | URL of the matching search result page. Empty if unavailable. |
| Matching Page Title | title | String | Title of the matching search result page. Empty if unavailable. |
{
"code": 1,
"msg": "查询成功",
"data": {
"appid": "2026102222460250146194",
"code": "baiduydkwpm",
"ym": "baidu.com",
"cost_points": 2,
"rw_id": "20261028204125_f54ad184778fe09b085a7401d506a5ac",
"result": {
"err_code": "200",
"err_msg": "ok",
"data": {
"code": "1",
"msg": "查询成功",
"data": {
"rank": "4",
"link": "http://www.baidu.com",
"title": ""
}
},
"gxsj": "2026-10-28 20:41:25"
}
}
}