# exchange.recipe.recipe

> Published by [recipe.exchange](https://lexicon.garden/identity/did:plc:4cx7ts7lqgjtsfquo53qo3sz)

✓ This is the authoritative definition for this NSID.

## Description

A recipe shared on recipe.exchange

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:4cx7ts7lqgjtsfquo53qo3sz/exchange.recipe.recipe)
- [Documentation](https://lexicon.garden/lexicon/did:plc:4cx7ts7lqgjtsfquo53qo3sz/exchange.recipe.recipe/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:4cx7ts7lqgjtsfquo53qo3sz/exchange.recipe.recipe/examples)

## Definitions

### `exchange.recipe.recipe`

**Type**: `record`

A complete recipe with all its components.

**Key**: `tid`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `name` | `string` | Yes | The name of the recipe |
| `text` | `string` | Yes | A description of the recipe |
| `embed` | `ref` → `#imagesEmbed` | No |  |
| `cookTime` | `string` (duration) | No | Time required for cooking |
| `keywords` | `array` | No | Tags describing the recipe |
| `prepTime` | `string` (duration) | No | Time required for preparation |
| `createdAt` | `string` (datetime) | Yes | Timestamp when this recipe was created |
| `nutrition` | `object` | No | Nutritional information |
| `totalTime` | `string` (duration) | No | Total time required |
| `updatedAt` | `string` (datetime) | Yes | Timestamp when this recipe was last updated |
| `attribution` | `union` | No |  |
| `ingredients` | `array` | Yes | List of ingredients and their measurements |
| `recipeYield` | `string` | No | Number of servings or yield |
| `instructions` | `array` | Yes | Step by step cooking instructions |
| `cookingMethod` | `string` | No | Method of cooking (e.g., baking, grilling) |
| `recipeCuisine` | `string` | No | Cuisine type (e.g., Italian, Mexican) |
| `recipeCategory` | `string` | No | Category of recipe (e.g., appetizer, main course) |
| `suitableForDiet` | `array` | No | Dietary restrictions this recipe is suitable for |

### `exchange.recipe.recipe#view`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `images` | `array` | Yes |  |

### `exchange.recipe.recipe#image`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `alt` | `string` | Yes | Alt text description of the image, for accessibility. |
| `image` | `blob` | Yes |  |
| `aspectRatio` | `ref` → `app.bsky.embed.defs#aspectRatio` | No |  |

### `exchange.recipe.recipe#viewImage`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `alt` | `string` | Yes | Alt text description of the image, for accessibility. |
| `thumb` | `string` (uri) | Yes | URL for thumbnail version of the image. CDN location provided by recipe.exchange. |
| `fullsize` | `string` (uri) | Yes | URL for full size version of the image. CDN location provided by recipe.exchange. |
| `aspectRatio` | `ref` → `app.bsky.embed.defs#aspectRatio` | No |  |

### `exchange.recipe.recipe#imagesEmbed`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `images` | `array` | Yes |  |

## Raw Schema

```json
{
  "id": "exchange.recipe.recipe",
  "defs": {
    "main": {
      "key": "tid",
      "type": "record",
      "record": {
        "type": "object",
        "required": [
          "name",
          "text",
          "ingredients",
          "instructions",
          "createdAt",
          "updatedAt"
        ],
        "properties": {
          "name": {
            "type": "string",
            "maxLength": 255,
            "description": "The name of the recipe"
          },
          "text": {
            "type": "string",
            "maxLength": 3000,
            "description": "A description of the recipe"
          },
          "embed": {
            "ref": "#imagesEmbed",
            "type": "ref"
          },
          "cookTime": {
            "type": "string",
            "format": "duration",
            "description": "Time required for cooking"
          },
          "keywords": {
            "type": "array",
            "items": {
              "type": "string",
              "maxLength": 64
            },
            "description": "Tags describing the recipe"
          },
          "prepTime": {
            "type": "string",
            "format": "duration",
            "description": "Time required for preparation"
          },
          "createdAt": {
            "type": "string",
            "format": "datetime",
            "description": "Timestamp when this recipe was created"
          },
          "nutrition": {
            "type": "object",
            "properties": {
              "calories": {
                "type": "integer"
              },
              "fatContent": {
                "type": "number"
              },
              "proteinContent": {
                "type": "number"
              },
              "carbohydrateContent": {
                "type": "number"
              }
            },
            "description": "Nutritional information"
          },
          "totalTime": {
            "type": "string",
            "format": "duration",
            "description": "Total time required"
          },
          "updatedAt": {
            "type": "string",
            "format": "datetime",
            "description": "Timestamp when this recipe was last updated"
          },
          "attribution": {
            "refs": [
              "exchange.recipe.defs#attributionOriginal",
              "exchange.recipe.defs#attributionPerson",
              "exchange.recipe.defs#attributionPublication",
              "exchange.recipe.defs#attributionWebsite",
              "exchange.recipe.defs#attributionShow",
              "exchange.recipe.defs#attributionProduct"
            ],
            "type": "union"
          },
          "ingredients": {
            "type": "array",
            "items": {
              "type": "string",
              "maxLength": 500
            },
            "description": "List of ingredients and their measurements"
          },
          "recipeYield": {
            "type": "string",
            "description": "Number of servings or yield"
          },
          "instructions": {
            "type": "array",
            "items": {
              "type": "string",
              "maxLength": 1000
            },
            "description": "Step by step cooking instructions"
          },
          "cookingMethod": {
            "type": "string",
            "description": "Method of cooking (e.g., baking, grilling)",
            "knownValues": [
              "exchange.recipe.defs#cookingMethod"
            ]
          },
          "recipeCuisine": {
            "type": "string",
            "description": "Cuisine type (e.g., Italian, Mexican)",
            "knownValues": [
              "exchange.recipe.defs#recipeCuisine"
            ]
          },
          "recipeCategory": {
            "type": "string",
            "description": "Category of recipe (e.g., appetizer, main course)",
            "knownValues": [
              "exchange.recipe.defs#recipeCategory"
            ]
          },
          "suitableForDiet": {
            "type": "array",
            "items": {
              "type": "string",
              "knownValues": [
                "exchange.recipe.defs#diet"
              ]
            },
            "description": "Dietary restrictions this recipe is suitable for"
          }
        }
      },
      "description": "A complete recipe with all its components."
    },
    "view": {
      "type": "object",
      "required": [
        "images"
      ],
      "properties": {
        "images": {
          "type": "array",
          "items": {
            "ref": "#viewImage",
            "type": "ref"
          },
          "maxLength": 4
        }
      }
    },
    "image": {
      "type": "object",
      "required": [
        "image",
        "alt"
      ],
      "properties": {
        "alt": {
          "type": "string",
          "description": "Alt text description of the image, for accessibility."
        },
        "image": {
          "type": "blob",
          "accept": [
            "image/*"
          ],
          "maxSize": 1000000
        },
        "aspectRatio": {
          "ref": "app.bsky.embed.defs#aspectRatio",
          "type": "ref"
        }
      }
    },
    "viewImage": {
      "type": "object",
      "required": [
        "thumb",
        "fullsize",
        "alt"
      ],
      "properties": {
        "alt": {
          "type": "string",
          "description": "Alt text description of the image, for accessibility."
        },
        "thumb": {
          "type": "string",
          "format": "uri",
          "description": "URL for thumbnail version of the image. CDN location provided by recipe.exchange."
        },
        "fullsize": {
          "type": "string",
          "format": "uri",
          "description": "URL for full size version of the image. CDN location provided by recipe.exchange."
        },
        "aspectRatio": {
          "ref": "app.bsky.embed.defs#aspectRatio",
          "type": "ref"
        }
      }
    },
    "imagesEmbed": {
      "type": "object",
      "required": [
        "images"
      ],
      "properties": {
        "images": {
          "type": "array",
          "items": {
            "ref": "#image",
            "type": "ref"
          },
          "maxLength": 4
        }
      }
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1,
  "description": "A recipe shared on recipe.exchange"
}
```
