Skip to main content
Glama
bunkerapps

Superprecio MCP Server

by bunkerapps

remove_shopping_list

Delete a shopping list and all its items from active lists, with soft-delete functionality allowing recovery if needed.

Instructions

Delete a shopping list.

This removes the list and all its items from the active lists. The list is soft-deleted (marked as inactive) so it can be recovered if needed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
listIdYesID of the shopping list to delete

Implementation Reference

  • Executes the removal of a shopping list by calling the API client's deleteShoppingList method and returns a formatted success or error response.
    export async function executeRemoveShoppingList(
      client: SuperPrecioApiClient,
      args: { listId: number }
    ) {
      const response = await client.deleteShoppingList(args.listId);
    
      if (!response.success) {
        return {
          content: [
            {
              type: 'text',
              text: `Failed to delete shopping list: ${response.message || 'Unknown error'}`,
            },
          ],
          isError: true,
        };
      }
    
      return {
        content: [
          {
            type: 'text',
            text: `
    ✅ Shopping list deleted successfully!
    
    List ID ${args.listId} has been removed.
    
    You can:
    - View remaining lists with get_shopping_lists
    - Create a new list with create_shopping_list
    `,
          },
        ],
      };
    }
  • Defines the tool's metadata: name, description, and input schema requiring a numeric listId.
    export const removeShoppingListTool = {
      name: 'remove_shopping_list',
      description: `Delete a shopping list.
    
    This removes the list and all its items from the active lists.
    The list is soft-deleted (marked as inactive) so it can be recovered if needed.`,
      inputSchema: {
        type: 'object',
        properties: {
          listId: {
            type: 'number',
            description: 'ID of the shopping list to delete',
          },
        },
        required: ['listId'],
      },
    };
  • src/index.ts:105-105 (registration)
    Registers the removeShoppingListTool in the array returned by ListToolsRequestSchema, making it discoverable by MCP clients.
    removeShoppingListTool,
  • src/index.ts:156-157 (registration)
    Registers the dispatch logic in the CallToolRequestSchema handler's switch statement to invoke the tool's execute function.
    case 'remove_shopping_list':
      return await executeRemoveShoppingList(apiClient, args as any);
  • src/index.ts:41-41 (registration)
    Imports the tool definition and execution handler from the dedicated tool module.
    import { removeShoppingListTool, executeRemoveShoppingList } from './tools/removeShoppingList.js';
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively explains that this is a destructive operation ('removes the list and all its items'), clarifies the deletion type ('soft-deleted'), and notes recoverability ('can be recovered if needed'). However, it lacks details on permissions, error conditions, or confirmation prompts.

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 front-loaded with the core purpose in the first sentence, followed by two concise sentences that add critical behavioral context. Every sentence earns its place by clarifying scope and deletion behavior without redundancy.

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

Completeness3/5

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

For a destructive tool with no annotations and no output schema, the description provides adequate basics (purpose and soft-delete behavior) but lacks completeness. It doesn't cover error handling, return values, or integration with sibling tools, leaving gaps for an agent to infer operational details.

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

Parameters3/5

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

The input schema has 100% description coverage, with the single parameter 'listId' clearly documented. The description adds no additional parameter semantics beyond what the schema provides, such as format examples or constraints, but this is acceptable given the high schema coverage.

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 the specific action ('Delete a shopping list') and resource ('shopping list'), distinguishing it from siblings like 'create_shopping_list' or 'get_shopping_lists'. It goes beyond the tool name by specifying what gets removed ('the list and all its items from the active lists').

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

Usage Guidelines2/5

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

No explicit guidance on when to use this tool versus alternatives is provided. While it's clear this is for deletion, there's no mention of prerequisites (e.g., list must exist), recovery options, or when to choose this over other list-management tools like 'optimize_shopping_list'.

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/bunkerapps/superprecio_mcp'

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