查看原始 JSON
{
"type": "object",
"required": [
"queryParams"
],
"properties": {
"queryParams": {
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"target",
"date"
],
"~standard": {
"vendor": "zod",
"version": 1,
"jsonSchema": {}
},
"properties": {
"date": {
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$",
"description": "报告日期,格式 YYYY-MM-DD;查询当前值时使用今天的日期。"
},
"mode": {
"enum": [
"exact",
"prefix",
"domain",
"subdomains"
],
"type": "string",
"default": "subdomains",
"description": "目标范围:exact、prefix、domain 或 subdomains(默认)。"
},
"limit": {
"type": "integer",
"default": 100,
"maximum": 100,
"minimum": 1,
"description": "返回的最大行数,也是费用预算;按行计费,默认 100,最多 100。"
},
"where": {
"type": "string",
"minLength": 1,
"description": "JSON 筛选表达式,语法见 Ahrefs 文档;可筛选 keyword、best_position、best_position_url、volume、sum_traffic 和 cpc。"
},
"target": {
"type": "string",
"minLength": 1,
"description": "报告目标,可以是域名或 URL。"
},
"country": {
"type": "string",
"maxLength": 2,
"minLength": 2,
"description": "两位字母国家代码(ISO 3166-1 alpha-2),例如 us。"
},
"order_by": {
"type": "string",
"minLength": 1,
"description": "排序方式,格式为 field 或 field:desc,多个字段用逗号分隔;可排序字段包括 keyword、best_position、best_position_url、volume、sum_traffic 和 cpc。"
},
"protocol": {
"enum": [
"both",
"http",
"https"
],
"type": "string",
"default": "both",
"description": "目标协议:both(默认)、http 或 https。"
}
},
"additionalProperties": false
}
},
"additionalProperties": false
}