amazon-lyr
에이전트 세션, 처음부터 끝까지
다음은 amazon-lyr을 실행하는 에이전트와의 실제 대화 한 건입니다 — 숨겨진 단계 없음:
1. search_products("noise cancelling headphones", max_price=300, min_rating=4)
2. review_insights("B0X1234567") # star spread + keyword themes
3. search_in_reviews("B0X1234567", query="broke") # what actually breaks?
4. add_to_cart("B0X1234567", quantity=1)
5. checkout_preview() # totals + address + payment, nothing bought
6. place_order(confirm="PLACE_ORDER") # only after the user said "buy it"
✓ order placed · #111-2223334-5556667
7. track_shipment("111-2223334-5556667")
8. initiate_return("111-2223334-5556667", reason="defective", asin_hint="…")
9. list_returns() # refund status confirmed모든 단계는 타입이 지정된 MCP 도구 호출입니다. 구매 단계는 실수로 실행하기 어렵도록 의도적으로 설계되었습니다 — 안전 모델 참조.
Related MCP server: Amazon Cart MCP Server
차별점
API 키 불필요 | Chrome TLS 위장을 사용하는 |
전체 라이프사이클 | 단순 스크래핑이 아님: 장바구니 변경, 위시리스트 쓰기, 확인 파싱이 포함된 결제, 반품 마법사, 주문 취소 |
에이전트 친화적 오류 | CAPTCHA, 로그아웃 리디렉션, 소프트 스로틀이 복구 힌트( |
작동 방식
browser cookies ──▶ AmazonClient (curl_cffi, captcha-aware)
│
▼
bs4 parsers ──▶ normalized dicts ──▶ 21 FastMCP tools
(readOnly / destructive annotations)인증은 사용자 본인의 세션입니다: amazon-lyr login은 obscura-core를 통해 Chrome, Brave, Firefox, Edge 또는 Zen에서 쿠키를 가져오거나, 명시적 JSON 내보내기에서 가져옵니다. 읽기에는 로그인 토큰이 필요하며, 장바구니, 주문, 반품 및 결제에는 세션 컨텍스트 쿠키도 필요합니다.
설치
# Persistent install — uv tool (isolated; bootstraps uv on clean systems)
curl -sSL https://raw.githubusercontent.com/ishan-parihar/amazon-lyr/main/install.sh | bash
# Zero-install run without persistence:
uvx --from git+https://github.com/ishan-parihar/amazon-lyr amazon-lyr --version그런 다음 한 번 인증하고 서빙합니다:
amazon-lyr login --browser chrome # or: --cookies-file cookies.json
amazon-lyr search "mechanical keyboard" # shell works immediately
amazon-lyr serve # MCP server (stdio){
"mcpServers": {
"amazon": {
"command": "amazon-lyr",
"args": ["serve"]
}
}
}도구 (21개)
카테고리 | 도구 |
검색 |
|
제품 |
|
리뷰 |
|
장바구니 |
|
위시리스트 |
|
주문 |
|
반품 |
|
구매 |
|
위험 구역 |
|
세션 |
|
안전 모델
돈이 움직이는 경로는 정확히 두 개의 관문을 통과합니다:
세션 관문 — 모든 변경 작업에는 전체 로그인 쿠키(
at-main+session-id/ubid-main)가 필요합니다. 읽기 전용 세션은 요청이 이루어지기 전에 거부됩니다.동의 관문 —
place_order는 정확한 리터럴confirm="PLACE_ORDER"가 전달되지 않으면 실행을 거부합니다. 의도된 흐름은 다음과 같습니다: 사용자에게 미리보기 표시 → 사용자 승인 → 그런 다음 리터럴 전달.cancel_order및initiate_return도 파괴적/비멱등적 작업으로 주석 처리되어 에이전트 프레임워크가 그에 따라 처리합니다.
카드 검증(OTP / 3-D Secure)은 결제 중간에 감지되어 브라우저 지침과 함께 needs_verification으로 보고됩니다 — 절대 추측으로 통과하지 않습니다.
제한 사항
정직한 한계점이며, 모두 잘못된 데이터 대신 타입이 지정된 오류로 표시됩니다:
CAPTCHA 벽 — 계정 영역 페이지는 카탈로그보다 더 엄격합니다; 새 쿠키를 다시 가져오거나 기다리세요(
CaptchaError에 힌트 포함)소프트 스로틀 — 3초 미만의 요청 간격은 조용한 빈 그리드를 유발합니다; 의심될 때 응답에
possibly_throttled: true가 포함됩니다지역별 가격 변형 — 일부 변형은 가격을 클라이언트 측에서 렌더링합니다; 검색은 텍스트 스캔으로 대체되고,
get_product는 권위 있는 소스로 유지됩니다동의 없는 자동 구매 없음 — 설계상 의도된 사항입니다; 결제는 명시적 확인 리터럴과 사용자 승인을 요구합니다
개발
git clone https://github.com/ishan-parihar/amazon-lyr && cd amazon-lyr
uv sync --extra dev
uv run ruff check . && uv run pytest -q아키텍처 노트, 불변 조건 및 릴리스 프로세스는 AGENTS.md에 있습니다.
라이선스
MIT © Ishan Parihar
This server cannot be deployed
Maintenance
Related MCP Connectors
Real-time Amazon product, seller, and search data for AI agents across 21 marketplaces.
Product search for AI agents: Amazon + Shopify, cart-to-checkout buy path. Pay-per-call, no API key.
Let your AI agent operate any website through a real, logged-in browser session.
Live product search for AI agents across Shopify merchants and major retailers.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to search products, manage shopping carts, place orders, and retrieve order history from Amazon and Target accounts.2MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with your personal Amazon cart through browser automation, allowing search, add to cart, and view cart functionalities.6 npm22MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to search products, manage cart, place orders, and track shipments on Amazon via browser automation.10 npm1MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to search products across Amazon and live Shopify storefronts, vet merchants, build carts, and obtain checkout URLs via a pay-per-call API with no API key or signup.MIT