# Too Good To Go API

> Too Good To Go surprise bag listings with price and quantity left

- Vendor: `toogoodtogoapi` · version 1.0 · category Food · tags too good to go api, toogoodtogo api, surprise bag api, food waste app api, tgtg api, restaurant surplus food api
- Datasource: custom HTTP routes
- Marketplace page: https://apiclay.com/api/toogoodtogoapi
- This document: https://apiclay.com/docs/toogoodtogoapi.md
- OpenAPI 3.1: https://apiclay.com/api/toogoodtogoapi/openapi.json
- MCP: connect https://api.apiclay.com/v1/mcp (see https://apiclay.com/llms.txt), then `apiclay_describe_api` with vendor `toogoodtogoapi`
- Updated: 2026-11-18

## About

## Too Good To Go API

Read a Too Good To Go listing: the surprise bag a store offers, its price, how many are left and the store details.

Data comes from **toogoodtogo.com** (https://www.toogoodtogo.com). Every route below calls the app's own endpoint directly and returns the upstream response unchanged.

### Routes

#### POST `/menus` - Menus (surprise bag item of a store)
Returns one Too Good To Go item (surprise bag) with its store.

| Param | In | Type | Required | Description |
|---|---|---|---|---|
| item_id | path | string | yes | Too Good To Go item id. |
| origin.latitude | body | number | yes | Customer latitude, e.g. `40.7128`. |
| origin.longitude | body | number | yes | Customer longitude, e.g. `-74.006`. |

Returns (fields read by the source code; not yet verified live):
- `item.item_id`: item id
- `item.price.minor_units`, `item.price_excluding_taxes.minor_units`: price in cents
- `items_available`: bags left
- `store.store_name`: store name

### Caveats

- Upstream calls change over time (embedded keys, field names). Verify responses before relying on them.
- The source site uses bot protection (DataDome); calls may be blocked until that is handled.
- The item endpoint expects an account bearer token, which this listing does not send. Calls are refused until that is handled.
- These routes were translated from working client code but have not yet been called through ApiClay. Expect adjustments once they are tested.
- Not affiliated with toogoodtogo.com.

## Pricing

- Pay as you go: 0.0012 credits/request
- Trial: 1 free requests per buyer
- Billing order: trial requests -> subscribed plan requests -> pay as you go. 1 credit's USD value is shown on the marketplace page.

## HTTP routes

Only the public, buyer-facing parts of each route are listed; vendor-side credentials stay on the gateway.

### POST /menus — Menus (surprise bag item of a store)
- Gateway: `POST https://api.apiclay.com/v1/api/toogoodtogoapi/menus`
- Public query params: `item_id` (string, required)
- Body sample (JSON):

```json
{"origin": {"latitude": 40.7128, "longitude": -74.006}}
```

- Upstream proxy: ApiClay proxy paid by the vendor (data cap 2 MB per call). Fetched through an ApiClay proxy paid by the vendor; a response larger than the route's data cap fails with 502 and is refunded in full.

## Call example

```bash
curl -X POST "https://api.apiclay.com/v1/api/toogoodtogoapi/menus?item_id=<item_id>" \
  -H "token: <YOUR_APICLAY_TOKEN>" \
  -H "Content-Type: application/json" \
  -d '{"origin": {"latitude": 40.7128, "longitude": -74.006}}'
```

Index of every published API: https://apiclay.com/llms.txt
