获取 Amazon 商品评论
curl --request POST \
--url https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"input": {
"asin": "<string>",
"format_type": "all",
"media_type": "all",
"query": "<string>",
"reviewer_type": "all",
"sort_by": "published_at",
"star_1_limit": 50,
"star_2_limit": 50,
"star_3_limit": 50,
"star_4_limit": 50,
"star_5_limit": 50
}
}
'import requests
url = "https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews"
payload = { "input": {
"asin": "<string>",
"format_type": "all",
"media_type": "all",
"query": "<string>",
"reviewer_type": "all",
"sort_by": "published_at",
"star_1_limit": 50,
"star_2_limit": 50,
"star_3_limit": 50,
"star_4_limit": 50,
"star_5_limit": 50
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
input: {
asin: '<string>',
format_type: 'all',
media_type: 'all',
query: '<string>',
reviewer_type: 'all',
sort_by: 'published_at',
star_1_limit: 50,
star_2_limit: 50,
star_3_limit: 50,
star_4_limit: 50,
star_5_limit: 50
}
})
};
fetch('https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'input' => [
'asin' => '<string>',
'format_type' => 'all',
'media_type' => 'all',
'query' => '<string>',
'reviewer_type' => 'all',
'sort_by' => 'published_at',
'star_1_limit' => 50,
'star_2_limit' => 50,
'star_3_limit' => 50,
'star_4_limit' => 50,
'star_5_limit' => 50
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews"
payload := strings.NewReader("{\n \"input\": {\n \"asin\": \"<string>\",\n \"format_type\": \"all\",\n \"media_type\": \"all\",\n \"query\": \"<string>\",\n \"reviewer_type\": \"all\",\n \"sort_by\": \"published_at\",\n \"star_1_limit\": 50,\n \"star_2_limit\": 50,\n \"star_3_limit\": 50,\n \"star_4_limit\": 50,\n \"star_5_limit\": 50\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"input\": {\n \"asin\": \"<string>\",\n \"format_type\": \"all\",\n \"media_type\": \"all\",\n \"query\": \"<string>\",\n \"reviewer_type\": \"all\",\n \"sort_by\": \"published_at\",\n \"star_1_limit\": 50,\n \"star_2_limit\": 50,\n \"star_3_limit\": 50,\n \"star_4_limit\": 50,\n \"star_5_limit\": 50\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"input\": {\n \"asin\": \"<string>\",\n \"format_type\": \"all\",\n \"media_type\": \"all\",\n \"query\": \"<string>\",\n \"reviewer_type\": \"all\",\n \"sort_by\": \"published_at\",\n \"star_1_limit\": 50,\n \"star_2_limit\": 50,\n \"star_3_limit\": 50,\n \"star_4_limit\": 50,\n \"star_5_limit\": 50\n }\n}"
response = http.request(request)
puts response.read_body{
"meta": {
"approximate_fields": [
"<string>"
],
"delivered": true,
"missing_fields": {}
},
"result": {
"country": "<string>",
"items": [
{
"date_text": "<string>",
"helpful_count": 123,
"rating_score": 123,
"requested_asin": "<string>",
"review_country": "<string>",
"review_id": "<string>",
"reviewer_name": "<string>",
"text": "<string>",
"title": "<string>",
"variant_asin": "<string>",
"variation_attributes": [
"<string>"
],
"verified_purchase": true,
"vine": true
}
],
"next_cursor": "<string>",
"platform": "amazon",
"rating_distribution": {
"basis": "percentage",
"star_1": 123,
"star_2": 123,
"star_3": 123,
"star_4": 123,
"star_5": 123
},
"requested_asin": "<string>"
},
"status": "found",
"task": "commerce.amazon.list_reviews",
"version": 1
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"request_id": "<string>",
"retry_hint": "never",
"retryable": true,
"param": "<string>",
"problems": [
"<string>"
],
"similar_tasks": [
"<string>"
],
"task_id": "<string>"
}
}Amazon
获取 Amazon 商品评论
按 ASIN 同步获取指定 Amazon 站点的单批商品评论,支持按星级配额(每星 0-100;全省略默认每星 10 条,指定任一星级时其余未指定星级为 0)及排序、变体、认证购买、媒体与关键词筛选。不支持翻页(next_cursor 始终为 null);仅有按星抽样评论时 rating_distribution 为 null。成功交付按请求页数计费(各星级配额分别每 10 条向上取整为页数后合计),无评论结果不收费。
POST
https://api.aisa.one
/
v1
/
tasks
/
commerce.amazon.list_reviews
获取 Amazon 商品评论
curl --request POST \
--url https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"input": {
"asin": "<string>",
"format_type": "all",
"media_type": "all",
"query": "<string>",
"reviewer_type": "all",
"sort_by": "published_at",
"star_1_limit": 50,
"star_2_limit": 50,
"star_3_limit": 50,
"star_4_limit": 50,
"star_5_limit": 50
}
}
'import requests
url = "https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews"
payload = { "input": {
"asin": "<string>",
"format_type": "all",
"media_type": "all",
"query": "<string>",
"reviewer_type": "all",
"sort_by": "published_at",
"star_1_limit": 50,
"star_2_limit": 50,
"star_3_limit": 50,
"star_4_limit": 50,
"star_5_limit": 50
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
input: {
asin: '<string>',
format_type: 'all',
media_type: 'all',
query: '<string>',
reviewer_type: 'all',
sort_by: 'published_at',
star_1_limit: 50,
star_2_limit: 50,
star_3_limit: 50,
star_4_limit: 50,
star_5_limit: 50
}
})
};
fetch('https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'input' => [
'asin' => '<string>',
'format_type' => 'all',
'media_type' => 'all',
'query' => '<string>',
'reviewer_type' => 'all',
'sort_by' => 'published_at',
'star_1_limit' => 50,
'star_2_limit' => 50,
'star_3_limit' => 50,
'star_4_limit' => 50,
'star_5_limit' => 50
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews"
payload := strings.NewReader("{\n \"input\": {\n \"asin\": \"<string>\",\n \"format_type\": \"all\",\n \"media_type\": \"all\",\n \"query\": \"<string>\",\n \"reviewer_type\": \"all\",\n \"sort_by\": \"published_at\",\n \"star_1_limit\": 50,\n \"star_2_limit\": 50,\n \"star_3_limit\": 50,\n \"star_4_limit\": 50,\n \"star_5_limit\": 50\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"input\": {\n \"asin\": \"<string>\",\n \"format_type\": \"all\",\n \"media_type\": \"all\",\n \"query\": \"<string>\",\n \"reviewer_type\": \"all\",\n \"sort_by\": \"published_at\",\n \"star_1_limit\": 50,\n \"star_2_limit\": 50,\n \"star_3_limit\": 50,\n \"star_4_limit\": 50,\n \"star_5_limit\": 50\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/v1/tasks/commerce.amazon.list_reviews")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"input\": {\n \"asin\": \"<string>\",\n \"format_type\": \"all\",\n \"media_type\": \"all\",\n \"query\": \"<string>\",\n \"reviewer_type\": \"all\",\n \"sort_by\": \"published_at\",\n \"star_1_limit\": 50,\n \"star_2_limit\": 50,\n \"star_3_limit\": 50,\n \"star_4_limit\": 50,\n \"star_5_limit\": 50\n }\n}"
response = http.request(request)
puts response.read_body{
"meta": {
"approximate_fields": [
"<string>"
],
"delivered": true,
"missing_fields": {}
},
"result": {
"country": "<string>",
"items": [
{
"date_text": "<string>",
"helpful_count": 123,
"rating_score": 123,
"requested_asin": "<string>",
"review_country": "<string>",
"review_id": "<string>",
"reviewer_name": "<string>",
"text": "<string>",
"title": "<string>",
"variant_asin": "<string>",
"variation_attributes": [
"<string>"
],
"verified_purchase": true,
"vine": true
}
],
"next_cursor": "<string>",
"platform": "amazon",
"rating_distribution": {
"basis": "percentage",
"star_1": 123,
"star_2": 123,
"star_3": 123,
"star_4": 123,
"star_5": 123
},
"requested_asin": "<string>"
},
"status": "found",
"task": "commerce.amazon.list_reviews",
"version": 1
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"request_id": "<string>",
"retry_hint": "never",
"retryable": true,
"param": "<string>",
"problems": [
"<string>"
],
"similar_tasks": [
"<string>"
],
"task_id": "<string>"
}
}上方请求和响应面板使用此 API 发布的 Schema。条件必填和参数组合限制属于请求契约;组合筛选条件或账号身份前,请查看完整 Schema。
仅表内参数值有价格;未列出的值不会回退到基础价格。
成功交付才收费;正常查空不收费。
发送相同请求并带上
计费
| 输入 | 计价单位 | 价格 (USD) |
|---|---|---|
| requested_review_pages = 0 | 每次成功请求 | 0 |
| requested_review_pages = 1 | 每次成功请求 | 0.044 |
| requested_review_pages = 2 | 每次成功请求 | 0.084 |
| requested_review_pages = 3 | 每次成功请求 | 0.128 |
| requested_review_pages = 4 | 每次成功请求 | 0.168 |
| requested_review_pages = 5 | 每次成功请求 | 0.212 |
| requested_review_pages = 6 | 每次成功请求 | 0.252 |
| requested_review_pages = 7 | 每次成功请求 | 0.296 |
| requested_review_pages = 8 | 每次成功请求 | 0.336 |
| requested_review_pages = 9 | 每次成功请求 | 0.38 |
| requested_review_pages = 10 | 每次成功请求 | 0.42 |
| requested_review_pages = 11 | 每次成功请求 | 0.464 |
| requested_review_pages = 12 | 每次成功请求 | 0.504 |
| requested_review_pages = 13 | 每次成功请求 | 0.548 |
| requested_review_pages = 14 | 每次成功请求 | 0.588 |
| requested_review_pages = 15 | 每次成功请求 | 0.632 |
| requested_review_pages = 16 | 每次成功请求 | 0.672 |
| requested_review_pages = 17 | 每次成功请求 | 0.716 |
| requested_review_pages = 18 | 每次成功请求 | 0.756 |
| requested_review_pages = 19 | 每次成功请求 | 0.8 |
| requested_review_pages = 20 | 每次成功请求 | 0.84 |
| requested_review_pages = 21 | 每次成功请求 | 0.884 |
| requested_review_pages = 22 | 每次成功请求 | 0.924 |
| requested_review_pages = 23 | 每次成功请求 | 0.968 |
| requested_review_pages = 24 | 每次成功请求 | 1.008 |
| requested_review_pages = 25 | 每次成功请求 | 1.052 |
| requested_review_pages = 26 | 每次成功请求 | 1.092 |
| requested_review_pages = 27 | 每次成功请求 | 1.136 |
| requested_review_pages = 28 | 每次成功请求 | 1.176 |
| requested_review_pages = 29 | 每次成功请求 | 1.22 |
| requested_review_pages = 30 | 每次成功请求 | 1.26 |
| requested_review_pages = 31 | 每次成功请求 | 1.304 |
| requested_review_pages = 32 | 每次成功请求 | 1.344 |
| requested_review_pages = 33 | 每次成功请求 | 1.388 |
| requested_review_pages = 34 | 每次成功请求 | 1.428 |
| requested_review_pages = 35 | 每次成功请求 | 1.472 |
| requested_review_pages = 36 | 每次成功请求 | 1.512 |
| requested_review_pages = 37 | 每次成功请求 | 1.556 |
| requested_review_pages = 38 | 每次成功请求 | 1.596 |
| requested_review_pages = 39 | 每次成功请求 | 1.64 |
| requested_review_pages = 40 | 每次成功请求 | 1.68 |
| requested_review_pages = 41 | 每次成功请求 | 1.724 |
| requested_review_pages = 42 | 每次成功请求 | 1.764 |
| requested_review_pages = 43 | 每次成功请求 | 1.808 |
| requested_review_pages = 44 | 每次成功请求 | 1.848 |
| requested_review_pages = 45 | 每次成功请求 | 1.892 |
| requested_review_pages = 46 | 每次成功请求 | 1.932 |
| requested_review_pages = 47 | 每次成功请求 | 1.976 |
| requested_review_pages = 48 | 每次成功请求 | 2.016 |
| requested_review_pages = 49 | 每次成功请求 | 2.06 |
| requested_review_pages = 50 | 每次成功请求 | 2.1 |
X-AISA-Cost-Mode: quote,获取与输入对应的报价;报价不执行任务,也不预扣资金。实际执行时预扣预计请求费用,按上述规则结算。用 X-AISA-Max-Price-USD 设置价格上限。
执行任务时使用 Idempotency-Key。错误时查看 error.code、error.request_id、error.retryable 和 error.retry_hint。提示先核对结算时,应先查询原请求再决定是否重试;不能把待结算当作已退款。