Skip to main content
Glama

delete_product

DestructiveIdempotent

Permanently delete a product listing and all its images. Destructive.

Authenticated. OAuth (scope `products:write`) preferred; `api_key` fallback.

Use only when the user explicitly asks to remove a listing they own.
Cannot be undone — there is no soft-delete or trash bin. Idempotent:
deleting a product that no longer exists returns an error, not duplicate
side effects.

Caller must own the product.

Args:
    product_id: ID of the product to delete. Get from `get_my_products`.
    api_key: Optional API key (`pk_*`, generate at /account).
        Used when there is no OAuth token, and also when the OAuth
        token lacks the required scope — an explicitly passed key
        overrides an ambient token that is scoped too narrowly.
        An invalid or revoked token still fails regardless. Omit when using OAuth.

Returns:
    ``{"deleted": True, "product_id": int}`` on success, or
    ``{"error": ...}`` on auth/ownership failure.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
api_keyNo
product_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • addedInput schema / properties / api_key / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / api_key / default
      Added value: +null
    • removedInput schema / properties / api_key / type
      Removed value: -"string"
    • changedInput schema / required
      Previous value: -[
      -  "api_key",
      -  "product_id"
      -]New value: +[
      +  "product_id"
      +]
  2. Added

TDQS

A4.9/5.0
Behavior5/5

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

Beyond annotations, the description discloses that the action cannot be undone, there is no soft-delete/trash bin, idempotency semantics, ownership requirements, and detailed auth fallback behavior. This adds significant context beyond the structured fields.

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

Conciseness4/5

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

The description is well-structured and front-loaded, but the api_key explanation is lengthy. However, all details are relevant and serve to prevent misuse, so it remains appropriately sized.

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 no output schema, the description explicitly states success and error return formats. It covers auth, ownership, idempotency, parameters, and return values, making it complete for a destructive tool.

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

Parameters5/5

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

Even though schema coverage is 0%, the description fully explains both parameters. product_id is tied to get_my_products, and api_key has a detailed explanation of when to use it, how it overrides narrow-scoped tokens, and when to omit it.

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 opens with 'Permanently delete a product listing and all its images,' using a specific verb and resource. It clearly distinguishes itself from sibling tools like delete_product_image and delete_inventory_item by emphasizing the entire listing and its images.

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

Usage Guidelines5/5

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

Provides explicit when-to-use guidance: 'Use only when the user explicitly asks to remove a listing they own.' It also states ownership and auth requirements, making it clear when not to use this tool.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources