Skip to main content
Glama
DanteMagg

DoorDash over text

by DanteMagg
README.md
# Poke × DoorDash CLI recipe

A [Poke](https://poke.com) recipe that lets Poke order DoorDash for you over text,
powered by DoorDash's official `dd-cli` (limited beta, announced 2026-07-15 by
[@andyfang](https://x.com/andyfang/status/2077516962515599799)).

Poke installs recipe integrations as **MCP servers**, so this repo is a thin MCP
bridge: Poke → tunnel → `server.mjs` → `dd-cli` → DoorDash.

## Prerequisites

1. **dd-cli** — official binary from [doordash-oss/doordash-cli](https://github.com/doordash-oss/doordash-cli)
   (macOS Apple Silicon only). v0.2.0 tarball is downloaded + SHA256-verified in
   `~/Downloads/dd-cli-v0.2.0-darwin-arm64/`; run `bash install.sh` there, then `dd-cli login`.
   Full functionality is waitlist-gated — join at https://forms.gle/gvCQZvu9C1EKA6aM6.
2. Node 18+, a Poke account with Kitchen access.
3. Log in once via `dd-cli login` (interactive; credentials go to the macOS keychain).

## Run + publish

```bash
npm install
npm start                # MCP server on http://localhost:3737/mcp
npm run tunnel           # in a second terminal: tunnels to Poke and creates the recipe
```

`npm run tunnel` runs `npx poke@latest tunnel http://localhost:3737/mcp -n "DoorDash CLI" --recipe`,
which prints a shareable recipe link + QR code. (Log in first with `npx poke@latest login`.
The tunnel only forwards the port — start `npm start` before it.)

Then polish in [Kitchen](https://poke.com/kitchen) → your recipe. Use
[RECIPE.md](RECIPE.md) as the recipe's instruction text — it's the agent-facing
operating manual (the pattern used by published CLI-backed recipes like poke-pc).
Kitchen field suggestions:

- **Name:** DoorDash over text
- **Description:** Text Poke to find food, compare deals, build a cart, and order
  DoorDash — with an explicit confirmation of the itemized total before anything is charged.
- **inputContext:** Ask the user for their delivery address (or confirm the account
  default), any dietary restrictions, favorite cuisines/restaurants, a typical budget
  per order, and default tip preference.
- **prefilledFirstText:** "Hey Poke — find me dinner on DoorDash. Show me a couple of
  good options with any deals, and always confirm the total with me before ordering."

Publishing in Kitchen makes it installable by others (and payout-eligible).

## Tools exposed

Full toolset built from the complete dd-cli v0.2.0 `--help` tree (readable after
`dd-cli login`). 27 tools covering the whole surface:

- **Discovery:** `search_restaurants`, `find_nearby_stores` (grocery/retail/alcohol/
  convenience/pets), `get_menu`, `find_items`, `restaurant_item_details`,
  `item_details`, `store_details`, `build_grocery_list`
- **Account:** `list_addresses`, `payment_methods`, `doordash_status`
- **Cart:** `cart_list` (pre-flight before creating carts), `cart_add_items`,
  `cart_show`, `cart_remove_item`, `cart_delete`
- **Promos:** `promo_list`, `promo_apply`, `promo_remove`
- **Orders:** `order_history`, `order_reorder`, `order_preview` (relays dd-cli's
  `--beautify` summary verbatim), `order_submit`, `order_status`, `order_receipt`,
  `checkout_url` (browser fallback for payment-method swaps)
- **Escape hatch:** `dd_cli` raw passthrough (`login` and raw `order submit` blocked)

Safety, per dd-cli's own agent guidance baked into descriptions + hard guards:

- `order_submit` **charges the default card immediately** and requires
  `user_confirmed=true` — legitimate only after the preview was shown, the total
  approved, the card NAMED (brand + last4 from `payment_methods`), and the Dasher
  tip explicitly confirmed (in cents).
- Duplicate submits of the same cart are blocked in-process (dd-cli has no
  upstream idempotency — a resubmit would double-order).
- Cart writes auto-spaced ~8s apart (DoorDash rate limiting).
- Errors map to `not_logged_in` / `waitlist_pending` / `dd_cli_not_found` with
  actionable messages the Poke agent can relay.

If the binary isn't named `dd-cli` on PATH, set `DD_CLI_BIN`.