---
name: recipe-manager
description: Add, search, update, and delete recipes in The Recipe Book. Use when the user asks to save a recipe, find recipes, or manage their recipe collection.
---

# Recipe Manager

You can manage recipes in The Recipe Book via the API at `https://recipes.jaystockwell.me/api`.

## Rules

- ALL measurements must be metric (g, ml, L, degrees C) -- this is an Australian kitchen
- ALL ingredients must be available in Australian supermarkets (Coles, Woolworths, Aldi, IGA)
- Quantities are specified separately for 2, 4, and 6 servings
- Quantities must make practical sense -- no "0.75 eggs" or "1.33 garlic cloves"
- Non-linear scaling examples:
  - Eggs: 1 for 2 serves, 2 for 4, 3 for 6
  - Oil for frying: 1 tbsp for all sizes (doesn't scale)
  - Salt/pepper: "to taste" -- use null for quantity, null for unit
  - Garlic: 1 clove for 2, 2 for 4, 3 for 6
- Use Australian English spelling: "favourite" not "favorite", "colour" not "color"
- ALWAYS include estimated nutrition per serve: calories_per_serve, protein_g, carbs_g, fat_g, fibre_g

## Categories

breakfast, lunch, dinner, sides, soups, baking, desserts, drinks, snacks, sauces, basics, slow-cooker

## API Endpoints

Base URL: `https://recipes.jaystockwell.me/api`

### Add Recipe
`POST /api/recipes`
Body: JSON with title, category (slug), description, prep_time_minutes, cook_time_minutes, difficulty, notes, calories_per_serve, protein_g, carbs_g, fat_g, fibre_g, tags[], ingredients[], steps[]

Each ingredient: { name, group?, quantity_2, unit_2, quantity_4, unit_4, quantity_6, unit_6, notes?, optional? }
Each step: { instruction, tip? }

### Search Recipes
`GET /api/search?q=chicken`

### Update Recipe
`PUT /api/recipes/{id}`
Body: partial JSON (only include fields to change)

### Delete Recipe
`DELETE /api/recipes/{id}`

### Toggle Favourite
`POST /api/recipes/{id}/favourite`

## Example: Adding a Recipe

```json
{
  "title": "Spaghetti Aglio e Olio",
  "category": "dinner",
  "description": "Classic Italian garlic and oil pasta.",
  "prep_time_minutes": 5,
  "cook_time_minutes": 12,
  "difficulty": "easy",
  "calories_per_serve": 450,
  "protein_g": 12,
  "carbs_g": 65,
  "fat_g": 16,
  "fibre_g": 3,
  "tags": ["pasta", "quick", "vegetarian"],
  "ingredients": [
    { "name": "spaghetti", "quantity_2": "200", "unit_2": "g", "quantity_4": "400", "unit_4": "g", "quantity_6": "600", "unit_6": "g" },
    { "name": "garlic cloves", "notes": "thinly sliced", "quantity_2": "3", "unit_2": "cloves", "quantity_4": "5", "unit_4": "cloves", "quantity_6": "8", "unit_6": "cloves" },
    { "name": "extra virgin olive oil", "quantity_2": "60", "unit_2": "ml", "quantity_4": "80", "unit_4": "ml", "quantity_6": "100", "unit_6": "ml" },
    { "name": "salt", "notes": "for pasta water" }
  ],
  "steps": [
    { "instruction": "Bring a large pot of salted water to the boil. Cook spaghetti until al dente. Reserve 250ml pasta water." },
    { "instruction": "Heat olive oil over medium-low. Add garlic, cook 2-3 min until golden.", "tip": "Keep heat low -- burnt garlic tastes bitter." },
    { "instruction": "Add drained pasta to garlic oil. Toss with splashes of pasta water to create a silky sauce." },
    { "instruction": "Toss through parsley, serve immediately." }
  ]
}
```
