Skip to main content
Glama
tzangms

shopline-mcp

by tzangms

create_metafield

Create custom app metafields to store additional merchant settings or data for your application.

Instructions

[WRITE] 建立商家應用元欄位(App Metafield)。

【用途】 為商家建立自定義的元欄位,用於儲存應用程式所需的額外商家設定或資料。

【呼叫的 Shopline API】

  • POST /merchants/current/app-metafields

【回傳結構】 dict 含 success: bool, resource_id: str, message: str, metafield: dict。

【副作用】

  • 在商家的應用元欄位中新增一筆記錄

  • 相同 namespace + key 組合若已存在,可能會失敗或覆蓋(取決於 Shopline 實作)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
metafield_dataYes元欄位資料,例如:{"namespace": "my_app", "key": "custom_key", "value": "custom_value", "value_type": "string"}
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It discloses the side effect of creating a new record and explicitly warns that an existing namespace+key combination may cause failure or overwrite. It also includes the API endpoint and return structure, adding meaningful behavioral context beyond the bare create action.

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?

The description is well-structured with clear sections: [WRITE], purpose, API endpoint, return structure, and side effects. Every section provides necessary information without redundancy, and the write indicator is front-loaded.

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?

For a single-parameter create tool with no output schema, the description covers all essential aspects: purpose, API call, return format, and side effects/risks. It is fully self-contained and does not rely on annotations.

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?

The schema already provides 100% description coverage for the single parameter with an example. The description adds value by explaining the uniqueness constraint on namespace+key, which is crucial for understanding how metafield_data is used. This goes beyond the schema's example.

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?

Description begins with '[WRITE]' and clearly states '建立商家應用元欄位(App Metafield)' (create merchant app metafield), with a specific verb and resource. It also explains the purpose: storing app-specific merchant settings or data, which distinguishes it from sibling read-only tools.

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?

The 【用途】 section gives clear context for when to use the tool: to store additional merchant settings/data needed by the app. No explicit alternatives or when-not-to-use guidance, but no sibling tool shares the same write purpose, so the context is sufficient.

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