clear_cart

Clear (remove all items from) the Instamart cart. Authentication is handled automatically.

See clear_cart in actionComing soon

Example

const result = await client.callTool({
  name: "clear_cart",
  arguments: {},
});

Parameters

ParameterTypeRequiredDescription

Session credentials (user identity, access token) are supplied automatically by the authenticated MCP session - you do not pass them in the tool call. See Authenticate.

Response

All Swiggy MCP tools return:

{
  "success": true,
  "data": { /* tool-specific payload */ },
  "message": "optional human-readable message"
}

On failure:

{
  "success": false,
  "error": { "message": "description of what went wrong" }
}

See Error codes for the full catalogue.

Output schema

data: {
  verified: true;
} | {
  verified: null;
  acknowledged: true;
}

If the tool cannot verify the clear operation, it returns success: false with an error message.

Schema notes

  • Fields marked optional may be omitted depending on user state, cart/order state, and live Swiggy availability.
  • Use returned identifiers and enum values exactly as provided; do not invent fallback IDs, status values, payment methods, or timestamps.

Details

FieldValue
Nameclear_cart
MCP ServerInstamart
EndpointPOST mcp.swiggy.com/im
StageCart
Behaviourmutating

Next in this journey →

Continue with update_cart.