docs(amazon-shopping): add install and update instructions
This commit is contained in:
+42
-15
@@ -27,25 +27,59 @@ scripts/search-products 'USB-C charger under $30' --dry-run --json
|
|||||||
|
|
||||||
Use single quotes when a request contains dollar amounts so the shell does not expand `$4`. `--max N` is accepted as a compatibility alias for `--limit N`.
|
Use single quotes when a request contains dollar amounts so the shell does not expand `$4`. `--max N` is accepted as a compatibility alias for `--limit N`.
|
||||||
|
|
||||||
## Dependency
|
## Install Or Update
|
||||||
|
|
||||||
This skill depends on the workspace `web-automation` skill and its CloakBrowser runtime.
|
Run these commands from the `stef-openclaw-skills` repo checkout:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd ~/.openclaw/workspace/projects/stef-openclaw-skills
|
||||||
|
git pull --ff-only
|
||||||
|
rsync -a --delete \
|
||||||
|
--exclude node_modules \
|
||||||
|
--exclude dist \
|
||||||
|
--exclude coverage \
|
||||||
|
--exclude tmp \
|
||||||
|
--exclude out \
|
||||||
|
--exclude '*.log' \
|
||||||
|
--exclude '*.real.html' \
|
||||||
|
skills/amazon-shopping/ \
|
||||||
|
~/.openclaw/workspace/skills/amazon-shopping/
|
||||||
|
cd ~/.openclaw/workspace/skills/amazon-shopping
|
||||||
|
npm ci
|
||||||
|
```
|
||||||
|
|
||||||
|
Use the same sequence for a first install and for updates. `rsync --delete` keeps the active skill identical to the repo copy while preserving generated dependencies through the `node_modules` exclude. Always run `npm ci` after syncing because dependency changes are tracked through `package-lock.json`.
|
||||||
|
|
||||||
|
## Setup Verification
|
||||||
|
|
||||||
|
Verify the dependency skill, the active install, and OpenClaw discovery:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
openclaw skills info web-automation
|
openclaw skills info web-automation
|
||||||
node "$HOME/.openclaw/workspace/skills/web-automation/scripts/check-install.js"
|
node "$HOME/.openclaw/workspace/skills/web-automation/scripts/check-install.js"
|
||||||
```
|
|
||||||
|
|
||||||
Setup or update the active `amazon-shopping` helper:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
cd ~/.openclaw/workspace/skills/amazon-shopping
|
cd ~/.openclaw/workspace/skills/amazon-shopping
|
||||||
npm ci
|
|
||||||
npm run lint
|
npm run lint
|
||||||
npm run typecheck
|
npm run typecheck
|
||||||
npm test
|
npm test
|
||||||
|
openclaw skills info amazon-shopping
|
||||||
```
|
```
|
||||||
|
|
||||||
|
For a quick parser-only check that does not browse Amazon:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
scripts/search-products 'USB-C charger under $30' --dry-run --json
|
||||||
|
```
|
||||||
|
|
||||||
|
For a live smoke after install or update:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
scripts/search-products '100w led bulbs that cost less than $4 each and have over 200 reviews with a review score of more than 4.5 stars' --limit 5 --json
|
||||||
|
```
|
||||||
|
|
||||||
|
## Dependency
|
||||||
|
|
||||||
|
This skill depends on the workspace `web-automation` skill and its CloakBrowser runtime.
|
||||||
|
|
||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
Each result includes the product ASIN, title, source URL, price, unit price when visible, rating, review count, delivery summary, specs, feature bullets, seller, availability, sponsored marker, matched filters, missing fields, and extraction notes.
|
Each result includes the product ASIN, title, source URL, price, unit price when visible, rating, review count, delivery summary, specs, feature bullets, seller, availability, sponsored marker, matched filters, missing fields, and extraction notes.
|
||||||
@@ -73,10 +107,3 @@ This skill is for operator-directed product research, not purchasing automation.
|
|||||||
- It does not sign in, add to cart, purchase, access wishlists, submit reviews, crawl review pages, or bypass CAPTCHA/block pages.
|
- It does not sign in, add to cart, purchase, access wishlists, submit reviews, crawl review pages, or bypass CAPTCHA/block pages.
|
||||||
- It stops and reports a warning when Amazon returns a challenge, block, or disallowed robots path.
|
- It stops and reports a warning when Amazon returns a challenge, block, or disallowed robots path.
|
||||||
- It uses default bounded operation: 15 results, 2 search pages, detail pages one at a time.
|
- It uses default bounded operation: 15 results, 2 search pages, detail pages one at a time.
|
||||||
|
|
||||||
## Live Smoke
|
|
||||||
|
|
||||||
```bash
|
|
||||||
cd ~/.openclaw/workspace/skills/amazon-shopping
|
|
||||||
scripts/search-products '100w led bulbs that cost less than $4 each and have over 200 reviews with a review score of more than 4.5 stars' --limit 5 --json
|
|
||||||
```
|
|
||||||
|
|||||||
Reference in New Issue
Block a user