网站

注释
专家级
API 密钥应作为请求的授权标头中的承载令牌发送。 获取您的 API 密钥.
列表

API端点:

GET
https://www.rank.fan/api/v1/websites

请求示例:

curl --location --request GET 'https://www.rank.fan/api/v1/websites' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {api_key}'
参数
类型
描述
search
可选 string
搜索查询.
search_by
可选 string
搜索依据. 可能的值为:domain 代表 域名。 默认为:domain。
sort_by
可选 string
排序依据. 可能的值为:id 代表 创建日期, domain 代表 域名, reports_avg_score 代表 分数, reports_count 代表 报告。 默认为:id。
sort
可选 string
排序. 可能的值为:desc 代表 降序, asc 代表 升序。 默认为:desc。
per_page
可选 integer
每页结果. 可能的值为:10, 25, 50, 100。 默认为:10。
显示

API端点:

GET
https://www.rank.fan/api/v1/websites/{id}

请求示例:

curl --location --request GET 'https://www.rank.fan/api/v1/websites/{id}' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {api_key}'
更新

API端点:

PUT PATCH
https://www.rank.fan/api/v1/websites/{id}

请求示例:

curl --location --request PUT 'https://www.rank.fan/api/v1/websites/{id}' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--header 'Authorization: Bearer {api_key}'
参数
类型
描述
privacy
可选 integer
隐私. 可能的值为:0 代表 公共, 1 代表 私人, 2 代表 密码。
password
可选 string
密码. 仅适用于设置为 2 的 privacy 字段。
删除

API端点:

DELETE
https://www.rank.fan/api/v1/websites/{id}

请求示例:

curl --location --request DELETE 'https://www.rank.fan/api/v1/websites/{id}' \
--header 'Authorization: Bearer {api_key}'