Skip to main content
Glama
tzangms

shopline-mcp

by tzangms

get_product_list

Search and list products with SKU variants, prices, brands, stock quantities, and image URLs. Filter by SKU, barcode, keyword, category, status, or brand.

Instructions

搜尋 / 列出商品,含 SKU 變體、價格、品牌、庫存數量與商品圖 URL。

注意:使用 brand 篩選時結果可能不完整(見下方限制), 回傳的 scan_incomplete 為 true 時不可當成完整清單。

查詢一律交由 Shopline 後端比對(不做本地模糊比對),因此含 & 的名稱、 特殊排版的品名(如「8入-粗版」)都能正確命中,且結果不受筆數上限截斷。

【brand 參數的限制】 Shopline API 沒有品牌查詢參數,只能先取回商品再於本地比對, 最多掃描 10,000 筆(MAX_SCAN_PAGES)。商品數超過此值時無法保證找齊, 此時回傳的 scan_incomplete 會是 true —— 出現時請勿把結果當成完整清單, 改搭配 category_id / keyword 縮小範圍後再查。 其餘查詢條件(keyword / sku / barcode / category_id / status) 皆由 Shopline 後端處理,不受此限制。

【呼叫的 Shopline API】

  • GET /v1/products/search(有任何查詢條件時)

  • GET /v1/products(完全無條件的列全部)

【回傳結構】 dict 含 total_found, returned, truncated, scan_incomplete, query, products[]。

  • truncated: 符合條件者多於本次回傳筆數(可調大 max_results 取得更多)

  • scan_incomplete: 僅品牌篩選時可能為 true,代表未掃完全店,結果可能遺漏

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
skuNo以 SKU 精準查詢(完全相符)。查特定貨品時優先用這個,不會漏抓
brandNo品牌篩選。Shopline 無此查詢參數,需掃描商品後在本地比對,故最多只掃描前 10,000 筆商品;超過的部分請改用 category_id 或 keyword 縮小範圍
statusNo商品狀態篩選:active / draft / removed / hidden
barcodeNo以條碼(gtin)精準查詢
keywordNo關鍵字搜尋,由 Shopline 後端比對商品名稱 / SKU / 條碼
category_idNo依分類篩選,可用逗號分隔多個分類 ID
max_resultsNo最多回傳筆數。設大即可列出全部,不再有 500 筆上限
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden and delivers extensively: it explains the brand filter's 10,000-item scan limit, the scan_incomplete flag, the exact Shopline APIs used, backend matching behavior with no truncation, and return structure flags. This goes far beyond what the schema provides.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well-structured with clear sections, front-loaded with the main purpose, and every paragraph delivers essential caveats or behavioral details. The length is justified because of the non-obvious brand limitation and return flags; no filler content.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite having no output schema or annotations, the description fully explains return structure, the meaning of truncated and scan_incomplete, API selection logic, and parameter behavior. It is comprehensive enough for an agent to invoke the tool correctly in most scenarios.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema already describes all 7 parameters (100% coverage), giving a baseline of 3. The description adds extra meaning by explaining the brand scan limit in depth, clarifying that max_results has no 500 cap, and describing how the backend handles each filter, which elevates it above baseline.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it searches/lists products with specific attributes (SKU variants, price, brand, stock, image URL). It distinguishes itself from sibling read tools like get_product_by_sku and get_product_variants by being the general search/list entry point.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides clear usage context, including when to narrow using category_id or keyword when brand scan is incomplete, and notes that other filters are backend-handled. It does not explicitly name alternative tools, but the guidance on when to use and when not to trust results is strong.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/tzangms/shoplinemcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server