48 lines
1.0 KiB
Markdown
48 lines
1.0 KiB
Markdown
---
|
|
name: 1688-product-master
|
|
description: "Scrape 1688 product pages and return structured product data."
|
|
---
|
|
|
|
# 1688 Product Master
|
|
|
|
Scrape 1688 product pages with image/title/variant optimization.
|
|
|
|
## Run
|
|
|
|
```bash
|
|
bun dist/run.js <command> [args] [--dry-run]
|
|
```
|
|
|
|
### Commands
|
|
|
|
| Command | Description |
|
|
|---------|-------------|
|
|
| `session` | Get session token |
|
|
| `scrape-url <url> [translate]` | Scrape a 1688 URL |
|
|
| `scrape-payload <json>` | Scrape with custom payload |
|
|
|
|
### Examples
|
|
|
|
```bash
|
|
# Scrape a product URL
|
|
bun dist/run.js scrape-url 'https://detail.1688.com/offer/852504650877.html'
|
|
|
|
# With translation
|
|
bun dist/run.js scrape-url 'https://detail.1688.com/offer/852504650877.html' true
|
|
|
|
# Dry run
|
|
bun dist/run.js scrape-url 'https://detail.1688.com/offer/852504650877.html' --dry-run
|
|
```
|
|
|
|
## Output
|
|
|
|
Returns structured JSON with product data:
|
|
- Product info (title, price, description)
|
|
- Images (optimized)
|
|
- Variants/SKUs
|
|
- Supplier info
|
|
|
|
## Reference
|
|
|
|
See [references/1688-product-master.md](references/1688-product-master.md).
|