Skip to main content
Glama

doordash_cart

View current DoorDash cart contents and totals to manage food delivery orders programmatically.

Instructions

View your current DoorDash cart contents and totals

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The doordash_cart tool is registered and implemented in src/tools/index.ts, where it calls the api.cart.listCarts() method to retrieve and format cart information.
    server.registerTool(
      "doordash_cart",
      { description: "View your current DoorDash cart contents and totals" },
      () =>
        wrap(async () => {
          const carts = await api.cart.listCarts();
          if (carts.length === 0) return err("Cart is empty.");
    
          const lines = ["# Your Carts\n"];
          for (const cart of carts) {
            const group = cart.isGroupOrder ? " (GROUP ORDER)" : "";
            lines.push(`**${cart.storeName}**${group}`);
            lines.push(`Cart ID: ${cart.id}`);
            for (const item of cart.items) {
              const price = item.price ? `$${(item.price / 100).toFixed(2)}` : "";
              lines.push(
                `- ${item.quantity}x **${item.name}** ${price} (item ID: ${item.id})`,
              );
            }
            if (cart.subtotal)
              lines.push(`\nSubtotal: $${(cart.subtotal / 100).toFixed(2)}`);
            lines.push("");
          }
          return ok(lines.join("\n"));
        }),
Behavior3/5

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

With no annotations provided, the description carries the full burden. 'View' implies read-only safety and 'contents and totals' hints at return data, but it omits authentication requirements, empty cart behavior, and return format details.

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?

Single sentence of 7 words with zero redundancy. Purpose is front-loaded immediately with no filler content.

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 simple read operation, it adequately describes the functional scope, but given the lack of output schema, it should specify the return format (e.g., item list, pricing breakdown) or error conditions.

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?

Input schema contains 0 parameters, establishing baseline 4. The description appropriately does not fabricate parameter details, though it could explicitly confirm no filters are available.

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 uses specific verb 'View' with clear resource 'DoorDash cart contents and totals', effectively distinguishing this read operation from sibling write operations like doordash_add_to_cart, doordash_modify_cart, and doordash_delete_cart.

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

Usage Guidelines3/5

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

While the read-only nature is implied by 'View', the description lacks explicit guidance on when to use this tool (e.g., 'check before checkout') or when to prefer doordash_modify_cart instead.

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/ashah360/doordash-mcp'

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