> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fire.rest/llms.txt
> Use this file to discover all available pages before exploring further.

# Create recipe

> Creates a new recipe in DRAFT status. Recipes start as DRAFT, require at least one line, and must be published before BOH uses them for consumption.

<ParamField header="x-api-key" type="string" required>
  BOH API key with `recipes:write` scope.
</ParamField>

<ParamField path="vendorId" type="string" required>
  Vendor UUID.
</ParamField>

<ParamField body="recipe_type" type="string" required>
  `SALES_RECIPE`, `PRODUCTION_RECIPE`, or `SUBRECIPE`.
</ParamField>

<ParamField body="recipe_name" type="string" required>
  Display name for the recipe.
</ParamField>

<ParamField body="store_id" type="string">
  UUID of a BOH store. Leave `null` for a recipe that applies to all stores.
</ParamField>

<ParamField body="external_product_id" type="string">
  Your POS product ID. Required for `SALES_RECIPE` if you want automatic linking to orders.
</ParamField>

<ParamField body="external_variant_id" type="string">
  Your POS variant ID, when the recipe applies to a specific variant.
</ParamField>

<ParamField body="output_item_id" type="string">
  UUID of the BOH item produced. Required for `PRODUCTION_RECIPE` and `SUBRECIPE`.
</ParamField>

<ParamField body="recipe_code" type="string">
  Short code used to reference this recipe as a subrecipe from other recipes.
</ParamField>

<ParamField body="recipe" type="object" required>
  Recipe content:

  <Expandable title="recipe fields">
    <ParamField body="output" type="object">
      For `PRODUCTION_RECIPE`: the planned output quantity.

      <Expandable title="output fields">
        <ParamField body="qty_base" type="number" required>Quantity in the base unit.</ParamField>
        <ParamField body="base_unit_id" type="string" required>UUID of the base unit.</ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="lines" type="object[]" required>
      Ingredient lines. Each line must have `consume_by` set to `ITEM`, `ITEM_TAG`, or `SUBRECIPE`.

      <Expandable title="line fields">
        <ParamField body="consume_by" type="string" required>`ITEM`, `ITEM_TAG`, or `SUBRECIPE`.</ParamField>
        <ParamField body="item_id" type="string">UUID of the item. Required when `consume_by=ITEM`.</ParamField>
        <ParamField body="item_tag_id" type="string">UUID of the item tag. Required when `consume_by=ITEM_TAG`.</ParamField>
        <ParamField body="subrecipe_code" type="string">Code of the subrecipe. Required when `consume_by=SUBRECIPE`.</ParamField>
        <ParamField body="qty_base" type="number" required>Quantity consumed per unit in the base unit of the item.</ParamField>
        <ParamField body="base_unit_id" type="string" required>UUID of the base unit for this line.</ParamField>

        <ParamField body="service_codes" type="string[]">
          Channel scoping (`SALES_RECIPE` root lines only). Empty or absent = applies to all channels.
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

<ParamField body="external_user_id" type="string">
  Actor for audit trail.
</ParamField>

<RequestExample>
  ```json Sales recipe with channel-scoped lines theme={null}
  {
    "recipe_type": "SALES_RECIPE",
    "recipe_name": "Classic Burger",
    "external_product_id": "prod-burger-001",
    "store_id": null,
    "recipe": {
      "lines": [
        {
          "consume_by": "ITEM",
          "item_id": "itm_beef_01...",
          "qty_base": 180,
          "base_unit_id": "unit_g_01..."
        },
        {
          "consume_by": "ITEM",
          "item_id": "itm_box_delivery_01...",
          "qty_base": 1,
          "base_unit_id": "unit_ea_01...",
          "service_codes": ["DELIVERY"]
        }
      ]
    },
    "external_user_id": "user_chef_99"
  }
  ```

  ```json Production recipe theme={null}
  {
    "recipe_type": "PRODUCTION_RECIPE",
    "recipe_name": "Burger patties batch",
    "output_item_id": "itm_patty_01...",
    "recipe": {
      "output": {
        "qty_base": 10,
        "base_unit_id": "unit_ea_01..."
      },
      "lines": [
        {
          "consume_by": "ITEM",
          "item_id": "itm_beef_01...",
          "qty_base": 1800,
          "base_unit_id": "unit_g_01..."
        }
      ]
    },
    "external_user_id": "user_chef_99"
  }
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  {
    "id": "rec_01j5k...",
    "account_id": "acc_01j...",
    "store_id": null,
    "recipe_type": "SALES_RECIPE",
    "recipe_role": "BASE",
    "status": "DRAFT",
    "version": 1,
    "recipe_name": "Classic Burger",
    "recipe_code": null,
    "external_product_id": "prod-burger-001",
    "external_variant_id": null,
    "output_item_id": null,
    "recipe": {
      "lines": [
        {
          "consume_by": "ITEM",
          "item_id": "itm_beef_01...",
          "qty_base": 180,
          "base_unit_id": "unit_g_01..."
        }
      ]
    },
    "created_by_external_user_id": "user_chef_99",
    "published_by_external_user_id": null,
    "created_at": "2026-08-07T14:30:00.000Z",
    "published_at": null,
    "archived_at": null
  }
  ```
</ResponseExample>
