# Alibaba Scraper (`scraper-engine/alibaba-scraper`) Actor

🛍️ Alibaba Scraper extracts product details, prices, MOQ, specs, images, reviews, shipping & supplier profiles from Alibaba listings at scale. ⚙️ Ideal for product research, supplier sourcing, price tracking & lead gen. 🚀 Fast, reliable, structured data.

- **URL**: https://apify.com/scraper-engine/alibaba-scraper.md
- **Developed by:** [Scraper Engine](https://apify.com/scraper-engine) (community)
- **Categories:** E-commerce, Lead generation, Automation
- **Stats:** 29 total users, 5 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $4.99 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### Alibaba Scraper — Prices, MOQ and Verified Supplier Data

Alibaba Scraper extracts public Alibaba trade search and category listing pages into structured product rows: title, price, minimum order quantity, supplier name, country, Gold Supplier years, review score and units sold. Every row is typed JSON with a stable schema — no HTML parsing, no selectors, no manual cleanup. Paste one or more Alibaba listing URLs, set how many products you want, and rows stream into the dataset live as each page finishes.

### What is Alibaba Scraper?

Alibaba Scraper is an Apify Actor that turns any Alibaba search or category browse page into a clean product dataset. It reads the listing data Alibaba embeds in its own page payload and returns 38 fields per product — commercial terms, supplier identity and trust signals included.

No Alibaba account, login or cookie is required. Every field it returns is already visible to any anonymous visitor on the listing page.

It is built for procurement teams, dropshippers and Amazon FBA sellers screening suppliers, pricing analysts tracking B2B market rates, and developers piping supplier data into an internal tool.

### What Alibaba product data is publicly available to scrape?

Alibaba shows the full commercial offer on its public search results — price, minimum order quantity, supplier identity and trust badges are all rendered before any login. What sits behind a gate is direct contact, not product data.

| Data Category | Publicly Available | Behind supplier inquiry / account |
| ----- | ----- | ----- |
| Product title, image gallery, product URL | ✓ Public | — |
| Price and price ladder | ✓ Public | — |
| Minimum order quantity (MOQ) | ✓ Public | — |
| Supplier company name, country, profile link | ✓ Public | — |
| Gold Supplier years, service and shipping scores | ✓ Public | — |
| Review score, review count, units sold | ✓ Public | — |
| Certification and badge labels | ✓ Public | — |
| Supplier email, phone, direct contact | ✗ | Inquiry / RFQ flow |
| Negotiated or tiered contract pricing | ✗ | Account + inquiry |
| Order and payment history | ✗ | Account |

Alibaba Scraper only returns publicly visible data — what any visitor sees on the search results page. Nothing behind a login wall or an inquiry form.

### What data can I extract with Alibaba Scraper?

Every product row carries four groups of data: what the product is, what it costs to buy, who sells it, and how Alibaba ranks and labels the listing.

| Field Name | Description |
| ----- | ----- |
| `title` | Product name, with Alibaba's keyword-highlight markup stripped |
| `productId` | Alibaba product identifier |
| `productUrl` | Absolute product page URL |
| `mainImage` | Primary product image URL |
| `multiImage` | Additional product image URLs |
| `price` | Listed price or price range as displayed |
| `moq` | Minimum order quantity as displayed |
| `moqV2` | Alibaba's alternate MOQ representation |
| `soldOrder` | Units sold / order volume signal |
| `reviewScore` | Product review score |
| `reviewCount` | Number of product reviews |
| `productScore` | Alibaba's internal product score |
| `companyName` | Supplier company name |
| `companyId` | Supplier company identifier |
| `companyLogo` | Supplier logo URL |
| `countryCode` | Supplier country code |
| `goldSupplierYears` | Consecutive years as a Gold Supplier |
| `supplierHref` | Absolute supplier page URL |
| `supplierHomeHref` | Absolute supplier storefront URL |
| `supplierService` | Supplier service label |
| `supplierServiceScore` | Supplier service score |
| `shippingScore` | Shipping performance score |
| `displayStarLevel` | Displayed star level |
| `certifications` | Certification labels attached to the listing |
| `badges` | Badge labels attached to the listing |
| `isShowAd` | Whether the row is a sponsored placement |
| `showCrown` | Crown / top-listing flag |
| `showAddToCart` | Add-to-cart availability flag |
| `lyb` | Alibaba listing flag |
| `customGroup` | Alibaba listing grouping value |
| `contactSupplier` | Contact-supplier link target as published |
| `chatToken` | Chat entry token as published |
| `eurl` | Alibaba tracking URL |
| `trackInfo` | Alibaba tracking payload |
| `loopSellingPoints` | Selling-point labels |
| `pcLoopSellingPoints` | Desktop selling-point labels |
| `id` | Offer identifier |
| `tmlid` | Alibaba template identifier |

#### Product and pricing fields

`title`, `productId`, `productUrl`, `mainImage` and `multiImage` identify and illustrate the item. `price`, `moq` and `moqV2` carry the commercial terms — these are the two fields that decide whether a product is viable for a given order size, and they are returned exactly as Alibaba displays them rather than parsed into a number, so a range like a price ladder survives intact.

#### Supplier trust and demand fields

`companyName`, `companyId`, `countryCode` and `goldSupplierYears` identify the seller. `supplierServiceScore`, `shippingScore`, `displayStarLevel`, `certifications` and `badges` are Alibaba's own trust signals. `reviewScore`, `reviewCount` and `soldOrder` show demand. Together these are the fields you sort and threshold on when shortlisting suppliers.

#### Listing-context fields

`isShowAd` flags sponsored placements — filter on it when you need organic ranking only. `showCrown`, `showAddToCart`, `lyb` and `customGroup` are Alibaba's own listing labels. `eurl`, `trackInfo` and `tmlid` are Alibaba's tracking values, returned unmodified for traceability.

#### 🤖 Add-on: Need additional Alibaba data?

Four companion Actors extend this one. **Alibaba Scraper With Supplier Contact Leads** adds outreach-ready supplier records. **Alibaba Scraper Supplier Profiles** goes one level deeper on each company. **Alibaba Scraper By Price MOQ Supplier Filter** applies commercial thresholds during the run. **Alibaba Scraper Supplier Trust Reorder Report** scores suppliers on repeat-order signals.

### Why not build this yourself?

Alibaba does not publish a general search API that returns arbitrary category or keyword result pages to anonymous callers, so a DIY scraper is the alternative — and the maintenance load is the real cost.

Alibaba embeds its listing data in an inline page payload (`window.__page__data_sse*._offer_list`), not in the rendered HTML. A CSS-selector scraper breaks on every layout change; a payload parser has to locate the blob, balance its braces through escaped strings, then walk an unstable nested structure to find the `offers` array. Alibaba Scraper does all three, and falls back to a deep key search per field when the shape shifts, so a moved key degrades one field instead of failing the row.

The second cost is access. Alibaba blocks datacenter IPs aggressively. Getting consistent results means residential egress, browser-accurate TLS and header fingerprinting, sticky sessions that are reused while they work and rotated when they stop, and a retry ladder underneath all of it. That is infrastructure to run and pay for before you have parsed a single product.

### How to use Alibaba Scraper

Alibaba Scraper runs on Apify. You can start it from the Apify Console or call it through the Apify API.

1. Open Alibaba Scraper on Apify and click **Try for free**
2. Paste one or more Alibaba listing URLs into **Page URLs (bulk)** — this is the only required input
3. Set **Max Items** to the total number of product rows you want across all URLs
4. Leave **Proxy configuration** on Apify Residential — Alibaba blocks datacenter IPs
5. Click **Start**, then download the dataset as JSON, CSV or Excel

To build a URL, open Alibaba in your browser, apply the keyword and category filters you want, then copy the address bar. The filters travel with the link.

#### How to scale to bulk product extraction

Paste as many URLs as you need into `urls` — the field is a list, and each entry is processed in turn. Both plain strings and `{ "url": "..." }` objects are accepted, so output from another tool can usually be fed in unchanged.

`maxItems` is a total across all URLs, not a per-URL figure. The Actor divides your target across the URLs you supplied, derives how many result pages that needs at roughly 48 products per page, and opens only those. Any overflow on the final page is trimmed, so you receive exactly the number of rows you asked for. Set `maxPages` above `0` only when you need to control page depth per URL directly — `maxItems` still caps the total saved either way.

### What can you do with Alibaba product data?

- A **sourcing manager** screening a new category pulls `moq`, `price` and `goldSupplierYears` across a keyword search, then shortlists only suppliers above a MOQ-to-price threshold before sending a single RFQ.
- A **dropshipper** validating a product idea filters on `soldOrder` and `reviewCount` to separate proven listings from untested ones, and checks `isShowAd` to exclude paid placements from the ranking.
- An **Amazon FBA seller** comparing landed cost tracks `price` and `moq` for the same product across suppliers, using `countryCode` and `shippingScore` to weigh lead time against unit cost.
- A **pricing analyst** monitoring a B2B category re-runs the same URLs weekly and diffs `price` and `soldOrder` per `productId` to detect movement before it shows up in retail pricing.
- An **AI engineer** building a sourcing assistant indexes `title`, `companyName`, `countryCode` and `certifications` into a vector store, so an agent can answer "which verified CN suppliers make this at MOQ under 100" against live catalogue data rather than a stale snapshot.

### How does Alibaba Scraper handle rate limits and blocking?

Alibaba blocks datacenter IPs aggressively, so the Actor is built around residential egress. Requests are sent with browser-accurate TLS impersonation and a full desktop header set rather than a default HTTP client signature.

Fetching escalates rather than failing on the first refusal. A caller-supplied proxy is tried first if `CUSTOM_PROXY_URL` is set, with up to four attempts. Otherwise the Actor uses the Apify proxy configuration you selected: when Residential is chosen it goes straight to residential, otherwise it tries direct, then datacenter, then residential. Residential attempts run up to six times, each with a fresh session ID. Once a session succeeds it is kept sticky and reused for subsequent pages, and only rotated after it stops working. Retries back off exponentially with jitter.

The Actor treats a response as blocked when the status is not 200, the body is under 800 bytes, or the listing payload markers are missing — so a soft block that returns a 200 with an empty shell is caught rather than parsed into zero rows. Pages are fetched at a concurrency of 3 with a randomised delay before each request. A page that cannot be recovered is skipped and logged; the run continues.

### ⬇️ Input

| Parameter | Required | Type | Description | Example Value |
| ----- | ----- | ----- | ----- | ----- |
| `urls` | ✅ Yes | array | Alibaba listing page URLs, one per line. Trade search and category browse pages both work. Plain strings and `{ "url": "..." }` objects are accepted. | `["https://www.alibaba.com/trade/search?..."]` |
| `maxItems` | No | integer | Total product rows to save across all URLs. Minimum 1, maximum 100000. Default `10`. | `50` |
| `maxPages` | No | integer | Advanced override for result pages opened per URL. `0` auto-derives from `maxItems`. Minimum 0, maximum 5000. Default `0`. | `0` |
| `proxyConfiguration` | No | object | Apify Proxy settings. Prefilled with Residential, which Alibaba effectively requires. | `{"useApifyProxy": true, "apifyProxyGroups": ["RESIDENTIAL"]}` |

#### Example input

```json
{
  "urls": [
    "https://www.alibaba.com/trade/search?fsb=y&IndexArea=product_en&keywords=Men%27s+Jackets&page=1",
    "https://www.alibaba.com/trade/search?fsb=y&IndexArea=product_en&keywords=waterproof+backpack&page=1"
  ],
  "maxItems": 100,
  "maxPages": 0,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": ["RESIDENTIAL"]
  }
}
```

### ⬆️ Output

Every product is one dataset row with the same 38 keys in the same order, run after run. Missing values come back as typed empty defaults — `""` for strings, `[]` for lists, `false` for booleans — never as a missing key, so downstream code never needs a presence check. Export as JSON, CSV or Excel, or read the dataset through the Apify API.

#### Example output

```json
{
  "title": "Men's Waterproof Softshell Jacket Custom Logo Windproof Outdoor Coat",
  "productUrl": "https://www.alibaba.com/product-detail/Men-s-Waterproof-Softshell-Jacket-Custom_1600981574830.html",
  "productId": "1600981574830",
  "id": "1600981574830",
  "price": "$12.50 - $18.90",
  "moq": "50 pieces",
  "moqV2": "50",
  "soldOrder": "1240",
  "reviewScore": "4.8",
  "reviewCount": "213",
  "productScore": "0.87",
  "companyName": "Quanzhou Hongfa Garment Co., Ltd.",
  "companyId": "234881907",
  "companyLogo": "https://s.alicdn.com/@sc04/kf/H9c2f1e8a.jpg",
  "countryCode": "CN",
  "goldSupplierYears": "7",
  "supplierHref": "https://hongfagarment.en.alibaba.com/company_profile.html",
  "supplierHomeHref": "https://hongfagarment.en.alibaba.com/",
  "supplierService": "Trade Assurance",
  "supplierServiceScore": "4.9",
  "shippingScore": "4.7",
  "displayStarLevel": "5",
  "certifications": ["BSCI", "OEKO-TEX"],
  "badges": ["Verified Supplier"],
  "mainImage": "https://s.alicdn.com/@sc04/kf/H0a1b2c3d.jpg",
  "multiImage": [
    "https://s.alicdn.com/@sc04/kf/H1a2b3c4d.jpg",
    "https://s.alicdn.com/@sc04/kf/H2b3c4d5e.jpg"
  ],
  "isShowAd": false,
  "showCrown": true,
  "showAddToCart": true,
  "lyb": false,
  "customGroup": "",
  "contactSupplier": "//message.alibaba.com/message/messenger.htm",
  "chatToken": "",
  "eurl": "https://www.alibaba.com/trade/search?...",
  "trackInfo": "",
  "loopSellingPoints": ["Custom logo", "Sample available"],
  "pcLoopSellingPoints": ["Custom logo"],
  "tmlid": ""
}
```

### How does it work?

Alibaba renders its search results from a JSON payload embedded directly in the page, not from the visible HTML. Alibaba Scraper requests the listing URL through a residential proxy with browser-accurate TLS and headers, locates that payload, and reads the product records straight out of it.

Because it parses structured data rather than scraping rendered markup, the output is not tied to Alibaba's visual layout — a redesign that would break a selector-based scraper leaves the payload intact. Each of the 38 fields is read by key, with a bounded deep search as a fallback when Alibaba nests a value differently than expected, so a structural change degrades one field rather than failing the whole row. Titles arrive wrapped in Alibaba's keyword-highlight markup and are stripped to clean product names; product and supplier links arrive protocol-relative and are returned as absolute HTTPS URLs.

Only publicly visible listing data is collected. No account, cookie or session is used.

### Integrations

Alibaba Scraper is an Apify Actor, so it works with anything that can call the Apify API or consume a dataset.

#### Calling Alibaba Scraper from Python

```python
from apify_client import ApifyClient

client = ApifyClient("<YOUR_APIFY_TOKEN>")

run = client.actor("<YOUR_USERNAME>/alibaba-scraper").call(run_input={
    "urls": ["https://www.alibaba.com/trade/search?fsb=y&keywords=waterproof+backpack&page=1"],
    "maxItems": 50,
    "proxyConfiguration": {"useApifyProxy": True, "apifyProxyGroups": ["RESIDENTIAL"]},
})

for product in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(product["title"], product["price"], product["moq"], product["companyName"])
```

Works in Go, Ruby, Node.js, cURL — any language that can make an HTTP request.

#### No-code tools (n8n, Make, Zapier)

In n8n, use the Apify node — or an HTTP Request node pointed at the Apify run endpoint with your token — and pass the same JSON input shown above. In Make, use the Apify module and map the dataset output straight into a Google Sheets or Airtable step. Both handle scheduling, so a weekly price sweep needs no code at all.

### Is it legal to scrape Alibaba products?

Scraping publicly listed product and supplier data is broadly treated as permissible where the data is accessible without authentication, and Alibaba Scraper collects only what an anonymous visitor already sees on the search results page.

Product listings, prices, MOQs and company trading names are commercial business records, not personal data — so the personal-data regimes that govern profile scraping do not attach to this output in the same way. The obligations that do apply are contractual and database-related: Alibaba's terms of service, and any local database or unfair-competition rules covering systematic reuse of a compiled catalogue.

Consult legal counsel before republishing extracted listings as a competing catalogue, or before reselling the data as a standalone product.

### ❓ Frequently asked questions

#### What Alibaba product fields does Alibaba Scraper return?

The five most used are `title`, `price`, `moq`, `companyName` and `goldSupplierYears`. Thirty-eight fields are returned in total — see the data fields table above.

#### Does Alibaba Scraper require an Alibaba account or login?

No. No account, no cookie, no session. The Actor sends anonymous requests and reads only the public listing payload. The one credential you need is your Apify token.

#### How many products can I extract in one run?

`maxItems` accepts up to 100,000 and is a total across all URLs, not a per-URL figure. Alibaba returns roughly 48 products per result page, and the Actor opens only enough pages to reach your target, trimming overflow on the last page so the row count matches exactly.

#### What happens if a listing page is blocked or returns no products?

The Actor treats a non-200 status, a body under 800 bytes, or a missing listing payload as a block, and retries through its proxy ladder. If the page still cannot be recovered, it is skipped with a log line and the run continues with the remaining pages. No partial or fabricated row is written, so a blocked page reduces your row count rather than corrupting the dataset.

#### Can I scrape multiple Alibaba searches at once?

Yes. `urls` is a list — paste as many listing URLs as you need. Each is processed in turn, and `maxItems` caps the combined total across all of them.

#### Does Alibaba Scraper work with Claude, ChatGPT and other AI agent tools?

Yes. It is callable as a standard HTTP endpoint through the Apify API, so any agent framework that can make a request — LangChain, CrewAI, n8n, a custom tool definition — can invoke it and receive typed JSON directly.

#### How does Alibaba Scraper compare to other Alibaba scrapers?

Checked on the Apify Store on 25 July 2026, the established Alibaba Actors take different angles. `devcake/alibaba-products-scraper` targets dropshippers and FBA sellers and leads on MOQ and supplier-verification fields. `lexis-solutions/alibaba-scraper` is a broader product-data scraper documented around market research and price monitoring. `piotrv1001/alibaba-listings-scraper` is the most compact listing extractor of the three. Alibaba Scraper's difference is field breadth from the search page alone — 38 fields per row, including Alibaba's own service, shipping and star-level scores and both selling-point arrays, without opening individual product pages.

#### Does Alibaba Scraper return data in a format LLMs can use directly?

Yes. Every response is typed, normalized JSON with the same field names on every run. No HTML parsing, no selectors. Pass a row straight into an LLM context window, index it into a vector store, or hand it to an agent tool — no transformation step required.

#### What happens when Alibaba changes its layout or anti-bot system?

The scraper is maintained, and because it reads Alibaba's embedded data payload rather than rendered markup, a visual redesign generally does not affect it at all. When Alibaba changes the payload structure itself, the per-field deep-search fallback keeps most fields populated while the Actor is updated. Your field names and types do not change on your end.

#### Can I use Alibaba Scraper without managing proxies?

Yes. Select Apify Residential in the proxy input and the Actor handles session creation, sticky-session reuse, rotation on failure and the retry ladder. You never create a proxy account or rotate an IP. If you already have residential egress, set `CUSTOM_PROXY_URL` and the Actor will use it first.

#### Which Alibaba fields work best for AI training data and RAG indexing?

For RAG indexing: `title`, `companyName`, `certifications` and `loopSellingPoints` carry the most descriptive text per product and chunk cleanly. For training data: `price`, `moq`, `reviewScore`, `reviewCount`, `soldOrder` and `goldSupplierYears` are the most structurally consistent fields across records. All values are returned as typed primitives or arrays with fixed defaults, so no normalization pass is needed before indexing.

### 🔗 Related scrapers

| Scraper Name | What it extracts |
| ----- | ----- |
| Alibaba Scraper With Supplier Contact Leads | Product rows plus outreach-ready supplier records |
| Alibaba Scraper Supplier Profiles | Full company profiles for suppliers behind the listings |
| Alibaba Scraper By Price MOQ Supplier Filter | Product rows filtered on commercial thresholds during the run |
| Alibaba Scraper Supplier Trust Reorder Report | Supplier trust and repeat-order scoring |

### 💬 Your feedback

Found a bug, or need a field that is in Alibaba's payload but not in the output? Open an issue on the Actor's Issues tab and it will be looked at. Field requests backed by a sample URL are the fastest to act on.

# Actor input Schema

## `urls` (type: `array`):

**Add every Alibaba listing page you want to collect from** — one URL per line. 📝

✅ **Works with:** trade/search results (`alibaba.com/trade/search?...`) and category browse pages.

🧭 **Tip:** Open the page in Chrome/Edge, apply your keyword/category filters, then copy the address bar — the filters travel with the link.

📦 **Bulk:** Paste many URLs at once; each is processed in order. Plain strings and `{ "url": "..." }` objects are both accepted.

## `maxItems` (type: `integer`):

**Total number of product rows** to save across all URLs (this is a product count, NOT a page count). 🎯

📊 **Dataset updates live** — rows appear as each page finishes, and the run stops as soon as the target is reached.

🧮 Alibaba returns ~48 products per result page, so the actor opens just enough pages to satisfy your target; any overflow on the last page is trimmed so you get **exactly** this many rows.

🎯 Example: `maxItems=50` collects 50 products. Try 10–50 first, then raise. Default is 10.

## `maxPages` (type: `integer`):

**Advanced override for the number of result pages opened per URL.** 📑

Leave at `0` (default) to let the actor auto-derive the page count from **Max Items** (~48 products/page). Set a positive value to force exactly that many pages per URL instead (capped at 5000).

⚠️ **Max Items still caps the total rows saved** — this only changes how many pages are fetched, not the final row count. Example: `maxPages=3` opens pages 1–3 of each URL. Default is 0 (auto).

## `proxyConfiguration` (type: `object`):

Enable Apify Proxy and pick a group. Residential is selected by default.

## Actor input object example

```json
{
  "urls": [
    "https://www.alibaba.com/trade/search?fsb=y&IndexArea=product_en&categoryId=127734135&has4Tab=true&keywords=Men%27s+Jackets&originKeywords=Men%27s+Jackets&productId=1600981574830&tab=all&&page=1&spm=undefined.pagination.0"
  ],
  "maxItems": 10,
  "maxPages": 0,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

## `results` (type: `string`):

Scraped Alibaba products, saved live to the default dataset as each result page is processed.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "urls": [
        "https://www.alibaba.com/trade/search?fsb=y&IndexArea=product_en&categoryId=127734135&has4Tab=true&keywords=Men%27s+Jackets&originKeywords=Men%27s+Jackets&productId=1600981574830&tab=all&&page=1&spm=undefined.pagination.0"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("scraper-engine/alibaba-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "urls": ["https://www.alibaba.com/trade/search?fsb=y&IndexArea=product_en&categoryId=127734135&has4Tab=true&keywords=Men%27s+Jackets&originKeywords=Men%27s+Jackets&productId=1600981574830&tab=all&&page=1&spm=undefined.pagination.0"],
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("scraper-engine/alibaba-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "urls": [
    "https://www.alibaba.com/trade/search?fsb=y&IndexArea=product_en&categoryId=127734135&has4Tab=true&keywords=Men%27s+Jackets&originKeywords=Men%27s+Jackets&productId=1600981574830&tab=all&&page=1&spm=undefined.pagination.0"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call scraper-engine/alibaba-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scraper-engine/alibaba-scraper"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/2fiIlxBB5U6TkYKaD/builds/WpQtdfrb0qWyPDjzf/openapi.json
