主题
按任务 ID 获取 Apple 应用搜索结果(高级版)
GET /v3/app_data/apple/app_searches/task_get/advanced/{id}
本接口使用 GET 方法,通过任务 ID 获取 Apple App Store 中指定的应用搜索排名结果。
请求方法与路径:
http
GET https://api.seermartech.cn/v3/app_data/apple/app_searches/task_get/advanced/{id}结果与创建任务时指定的、地区和语言。除应用排名外,还会返回应用 ID、图标、评论数、评分、价格等信息。
计费说明
创建任务时会产生费用。任务结果可在任务创建后的 30 天获取,重复调用本接口不会重复扣费。
扣费以响应头 X-SeerMarTech-Charge-CNY 为准。
请求参数
参数通过 URL 路径传递。
| 参数 | 类型 | 说明 |
|---|---|---|
id | string | 任务唯一标识,UUID 格式。任务创建成功后获得,可在 30 天用于获取任务结果。 |
示例:
text
06141103-2692-0309-1000-980b778b6d25响应说明
接口返回 JSON 数据,顶层 tasks 数组。每个任务对象任务状态、执行信息及搜索结果。
顶层响应字段
| 字段 | 类型 | 说明 |
|---|---|---|
version | string | 当前 API 版本。 |
status_code | integer | 通用响应状态码。成功通常为 20000。 |
status_message | string | 通用响应说明。 |
time | string | 接口执行耗时,单位为秒。 |
cost | float | 平台原始 USD 成本兼容字段;人民币实扣以 X-SeerMarTech-Charge-CNY 为准。 |
tasks_count | integer | tasks 数组中的任务数量。 |
tasks_error | integer | tasks 数组中返回错误的任务数量。 |
tasks | array | 任务结果数组。 |
tasks 任务字段
| 字段 | 类型 | 说明 |
|---|---|---|
id | string | 任务唯一标识,UUID 格式。 |
status_code | integer | 任务状态码,通常在 10000 至 60000 范围。 |
status_message | string | 任务状态说明。 |
time | string | 任务执行耗时,单位为秒。 |
cost | float | 平台原始 USD 成本兼容字段;人民币实扣以 X-SeerMarTech-Charge-CNY 为准。 |
result_count | integer | result 数组中的数量。 |
path | array | 请求路径信息。 |
data | object | 创建任务时提交的原始参数。 |
result | array | Apple 应用搜索结果数组。 |
result 结果字段
| 字段 | 类型 | 说明 |
|---|---|---|
keyword | string | 创建任务时提交的。 |
se_domain | string | 搜索引擎域名。 |
location_code | integer | 地区代码。 |
language_code | string | 语言代码。 |
check_url | string | 搜索结果页面直接 URL。本接口中通常为 null。 |
datetime | string | 结果获取时间,UTC 格式:yyyy-mm-dd hh-mm-ss +00:00。 |
se_results_count | integer | 搜索结果总数。 |
items_count | integer | items 数组中的应用数量。 |
items | array | 搜索到的应用列表。 |
items 应用字段
| 字段 | 类型 | 说明 |
|---|---|---|
type | string | 结果类型。可能值为 app_store_search_organic。 |
rank_group | integer | 在相同 type 结果组中的排名。不同类型结果之间不计算此排名。 |
rank_absolute | integer | 应用在结果中的绝对排名。 |
position | string | 结果在搜索页面中的对齐位置,可能值为 left。 |
app_id | string | 应用 ID。 |
title | string | 应用名称。 |
url | string | App Store 中的应用页 URL。 |
icon | string | 应用图标 URL。 |
reviews_count | integer | 应用评论总数。 |
rating | object | 应用平均评分。 |
is_free | boolean | 是否为应用。 |
price | object | 应用价格信息。 |
rating 评分字段
| 字段 | 类型 | 说明 |
|---|---|---|
rating_type | string | 评分类型,可能值为 Max5。 |
value | float | 当前平均评分。 |
votes_count | integer | 评分反馈数量。本接口中通常为 null。 |
rating_max | integer | 评分上限。Max5 类型的最大值为 5。 |
price 价格字段
| 字段 | 类型 | 说明 |
|---|---|---|
current | float | 当前价格,即结果中显示的当前售价。 |
regular | float | 常规价格。 |
max_value | float | 最高价格。适用于价格区间。 |
currency | string | 价格币种,使用 ISO 币种代码。 |
is_price_range | boolean | 是否以价格区间形式提供。 |
displayed_price | string | 原始价格文本,即搜索结果中展示的价格字符串。 |
请求示例
cURL
bash
id="04011058-0696-0199-0000-2196151a15cb"
curl --location --request GET \
"https://api.seermartech.cn/v3/app_data/apple/app_searches/task_get/advanced/${id}" \
--header "Authorization: Bearer smt_live_YOUR_KEY" \
--header "Content-Type: application/json"TypeScript
typescript
import axios from "axios";
const taskId = "02231934-2604-0066-2000-570459f04879";
axios({
method: "get",
url: `https://api.seermartech.cn/v3/app_data/apple/app_searches/task_get/advanced/${taskId}`,
headers: {
Authorization: "Bearer smt_live_YOUR_KEY",
"Content-Type": "application/json",
},
})
.then((response) => {
// 处理任务结果
console.log(response.data);
})
.catch((error) => {
console.error("请求失败:", error.response?.data || error.message);
});Python
python
import requests
task_id = "06141103-2692-0309-1000-980b778b6d25"
url = (
"https://api.seermartech.cn"
f"/v3/app_data/apple/app_searches/task_get/advanced/{task_id}"
)
headers = {
"Authorization": "Bearer smt_live_YOUR_KEY",
"Content-Type": "application/json",
}
response = requests.get(url, headers=headers, timeout=30)
data = response.json()
if data.get("status_code") == 20000:
print(data)
else:
print(
"请求失败,状态码:%s,消息:%s"
% (data.get("status_code"), data.get("status_message"))
)响应示例
json
{
"version": "0.1.20220422",
"status_code": 20000,
"status_message": "Ok.",
"time": "0.1347 sec.",
"cost": 0,
"tasks_count": 1,
"tasks_error": 0,
"tasks": [
{
"id": "04011058-0696-0199-0000-2196151a15cb",
"status_code": 20000,
"status_message": "Ok.",
"time": "0.1201 sec.",
"cost": 0,
"result_count": 1,
"path": [
"v3",
"app_data",
"apple",
"app_searches",
"task_get",
"advanced",
"04011058-0696-0199-0000-2196151a15cb"
],
"data": {
"se_type": "organic",
"se": "apple",
"api": "app_data",
"function": "app_searches",
"keyword": "vpn",
"location_code": 2840,
"language_code": "en",
"depth": 200,
"device": "desktop",
"os": "windows"
},
"result": [
{
"keyword": "vpn",
"se_domain": "apple.com",
"location_code": 2840,
"language_code": "en",
"check_url": null,
"datetime": "2019-11-15 12:57:46 +00:00",
"se_results_count": 200,
"items_count": 1,
"items": [
{
"type": "app_store_search_organic",
"rank_group": 1,
"rank_absolute": 1,
"position": "left",
"app_id": "example.app.id",
"title": "Example VPN",
"url": "https://apps.apple.com/app/example-vpn",
"icon": "https://example.com/icon.png",
"reviews_count": 1000,
"rating": {
"rating_type": "Max5",
"value": 4.8,
"votes_count": null,
"rating_max": 5
},
"is_free": true,
"price": {
"current": 0,
"regular": 0,
"max_value": 0,
"currency": "USD",
"is_price_range": false,
"displayed_price": "Free"
}
}
]
}
]
}
]
}状态码与异常处理
建议根据顶层 status_code 及任务级别的 tasks[].status_code 判断请求是否成功:
20000:请求或任务处理成功。40000及以上:通常表示任务处理失败或返回错误。- 当
tasks为空、任务状态码异常,或result为null时,应读取对应的status_message并执行重试、告警或人工排查。
实用场景
- 监控排名:定期获取目标对应的 App Store 应用排名,评估 ASO 优化效果与竞品变化。
- 对比竞品表现:汇总竞品的绝对排名、评分和评论数量,识别应用市场中的竞争位置。
- 分析地区差异:按地区代码和语言分别获取搜索结果,发现不同市场的应用差异。
- 跟踪应用口碑:持续记录评分、评论数和价格变化,为版本发布、产品定价和运营决策提供依据。
- 构建 ASO 报表:将应用名称、应用 ID、排名、图标、评分和价格等字段汇总到报表中,支持客户或团队进行周期性分析。