# Catering & Party API
> Catering and party-planning maths as an API, computed locally and deterministically — the how-much-do-I-buy numbers a host or caterer plans a headcount with. The food endpoint scales a menu to the guest count and appetite: the main protein at about half a pound of cooked meat per person (light 0.33, hearty 0.75), each side dish at roughly four ounces a head, six appetizer pieces each and one-and-a-half dinner rolls — so 50 guests at a standard dinner with three sides need 25 lb of meat, 300 appetizers and 75 rolls. The drinks endpoint sizes the bar: about one drink per guest per hour plus an extra in the first hour, split across beer, wine and cocktails, and converted into the real units you buy — beer by the case (24) and the half-keg (~165 servings), wine by the bottle (~5 glasses), spirits by the 750 ml bottle (~16 shots) — plus the ice (about 1.5 lb per guest) and water; a 50-guest, four-hour party comes to 250 drinks, 125 beers (0.76 of a keg), 15 bottles of wine and 75 lb of ice. Everything is computed locally and deterministically, so it is instant and private. Ideal for event-planning, catering, hospitality and party app developers, shopping-list and headcount tools, and host calculators. Pure local computation — no key, no third-party service, instant. US units; rules of thumb — round up. Live, nothing stored. 2 compute endpoints. Adjust for the crowd and the season.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/catering-api/..."
```

## Pricing
- **Free** (Free) — 6,850 calls/Mo, 2 req/s
- **Starter** ($4/Mo) — 60,500 calls/Mo, 6 req/s
- **Pro** ($11/Mo) — 247,500 calls/Mo, 15 req/s
- **Mega** ($35/Mo) — 1,385,000 calls/Mo, 40 req/s

## Endpoints

### Catering

#### `GET /v1/drinks` — Drink quantities

**Parameters:**
- `guests` (query, required, string) — Number of guests Example: `50`
- `hours` (query, required, string) — Event length (hours) Example: `4`
- `alcohol` (query, optional, string) — Serve alcohol (default true) Example: `true`
- `beer_percent` (query, optional, string) — Beer share % (default 50) Example: `50`
- `wine_percent` (query, optional, string) — Wine share % (default 30) Example: `30`
- `cocktail_percent` (query, optional, string) — Cocktail share % (default 20) Example: `20`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/catering-api/v1/drinks?guests=50&hours=4&alcohol=true&beer_percent=50&wine_percent=30&cocktail_percent=20"
```

**Response:**
```json
{
    "data": {
        "note": "About 1 drink per guest per hour, plus one extra in the first hour. Beer: 24 per case, ~165 per half-keg. Wine: ~5 glasses per bottle. Spirits: ~16 shots per 750 ml. Ice ≈ 1.5 lb per guest.",
        "ice_lb": 75,
        "inputs": {
            "hours": 4,
            "guests": 50,
            "alcohol": true
        },
        "total_drinks": 250,
        "wine_bottles": 15,
        "beer_cases_24": 5.21,
        "beer_servings": 125,
        "water_bottles": 100,
        "wine_servings": 75,
        "beer_half_kegs": 0.76,
        "cocktail_servings": 50,
        "liquor_bottles_750": 4
    },
    "meta": {
        "timestamp": "2026-06-06T07:14:07.313Z",
        "request_id": "244e3e75-7cfc-49ff-b4b0-d3d29c97d0de"
    },
    "status": "ok",
    "message": "Drink quantities",
    "success": true
}
```

#### `GET /v1/food` — Food quantities

**Parameters:**
- `guests` (query, required, string) — Number of guests Example: `50`
- `appetite` (query, optional, string) — light, standard or hearty Example: `standard`
- `sides` (query, optional, string) — Number of side dishes (default 3) Example: `3`
- `appetizers_per_person` (query, optional, string) — Appetizer pieces each (default 6)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/catering-api/v1/food?guests=50&appetite=standard&sides=3"
```

**Response:**
```json
{
    "data": {
        "note": "Main protein ≈ 0.5 lb cooked per person (light 0.33, hearty 0.75). Each side ≈ 4 oz per person; appetizers ≈ 6 pieces per person; ~1.5 rolls each. Scale up 10–15% for big eaters or no other food.",
        "inputs": {
            "sides": 3,
            "guests": 50,
            "appetite": "standard",
            "appetizers_per_person": 6
        },
        "side_dishes": 3,
        "dinner_rolls": 75,
        "each_side_lb": 12.5,
        "total_sides_lb": 37.5,
        "main_protein_lb": 25,
        "appetizer_pieces": 300
    },
    "meta": {
        "timestamp": "2026-06-06T07:14:07.406Z",
        "request_id": "9659078b-8cb9-4b03-b6f1-4e052b23c859"
    },
    "status": "ok",
    "message": "Food quantities",
    "success": true
}
```

### Meta

#### `GET /v1/meta` — Spec

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/catering-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "notes": "US units (pounds, 12-oz beers, 750 ml bottles). Rules of thumb — adjust for the crowd, the season and whether it's a full meal. Round up; running out is worse than leftovers.",
        "service": "catering-api",
        "endpoints": {
            "GET /v1/food": "Main protein, sides, appetizers and rolls for a guest count and appetite.",
            "GET /v1/meta": "This document.",
            "GET /v1/drinks": "Total drinks, beer (cases/kegs), wine bottles, cocktails, ice and water."
        },
        "description": "Catering & party-planning maths: food and drink quantities for a headcount, with kegs, wine bottles and ice."
    },
    "meta": {
        "timestamp": "2026-06-06T07:14:07.495Z",
        "request_id": "a70ca9f3-2c75-45bb-8037-d261cd61365b"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/catering-api
OpenAPI spec: https://www.oanor.com/api/catering-api/openapi.json
