登录
使用 JS token

AliExpress scrapers 配合您的 JavaScript token 效果最佳。

API 使用

Crawling API 请求中添加 &scraper=aliexpress-product。在 url 参数中对目标 URL 进行 URL 编码。

curl 'https://api.crawlbase.com/?token=YOUR_TOKEN' \
  --data-urlencode 'url=https://www.aliexpress.com/item/1005008227636051.html' \
  --data-urlencode 'scraper=aliexpress-product' -G
from crawlbase import CrawlingAPI

api = CrawlingAPI({'token': 'YOUR_TOKEN'})
res = api.get(
    'https://www.aliexpress.com/item/1005008227636051.html',
    {'scraper': 'aliexpress-product'}
)

import json
data = json.loads(res['body'])
const { CrawlingAPI } = require('crawlbase');
const api = new CrawlingAPI({ token: 'YOUR_TOKEN' });

const res = await api.get(
  'https://www.aliexpress.com/item/1005008227636051.html',
  { scraper: 'aliexpress-product' }
);
const data = JSON.parse(res.body);
require 'crawlbase'
api = Crawlbase::API.new(token: 'YOUR_TOKEN')

res = api.get('https://www.aliexpress.com/item/1005008227636051.html', scraper: 'aliexpress-product')
data = JSON.parse(res.body)

示例输入 URL

传入 url 参数的 URL(为便于阅读已 URL 解码):

https://www.aliexpress.com/item/1005008227636051.html

响应结构

JSON 响应体。当源页面缺失该值时,字段类型可能为 null

product_id
string
产品 ID。
title
string
标题。
price
string
价格。
original_price
string | null
折扣前价格。
discount_percentage
string | null
折扣。
rating
number
评分。
reviews_count
integer
评论数。
orders_count
integer
总订单数。
images
array
图片 URL。
variants
array
变体选项。
shipping
object
运输方式、费用、配送。
store
object
店铺元数据。

示例响应

{
  "product_id": "1005008227636051",
  "title": "Wireless Bluetooth Headphones",
  "price": "$18.99",
  "original_price": "$45.00",
  "rating": 4.8,
  "orders_count": 5240
}