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

# Delete a recipe

> **Beta.** The request and response shapes may still change.

Delete a recipe no flow still references. A recipe referenced by a flow answers `409`, with the flows holding it listed in `details`: detach it there first.

Deleting a recipe that is already gone succeeds.

A recipe still referenced by a flow cannot be deleted. The refusal lists the flows holding it:

```json theme={null}
{
  "code": "recipe_in_use",
  "message": "The recipe is still referenced and cannot be deleted. See `details` field for what refers to it.",
  "details": [{ "path": "id", "message": "flo_01jc0t6fwwfgfsq1md24mhyztj" }]
}
```

Remove it from those flows first. If you only want it to stop deciding, [replace it](/watch/v2/api-reference/management/recipes/replace-recipe) with `status: "INACTIVE"` instead - the flow keeps working and the recipe stops evaluating.

Deleting a recipe leaves the rules it scored over in place; they become deletable once nothing else references them.

Deleting a recipe that is already gone returns `204`. A `404` here means the identifier is malformed, not that the recipe was missing.


## OpenAPI

````yaml delete /v2/watch/management/recipes/{recipe_id}
openapi: 3.1.0
info:
  title: Prelude API
  version: 2.0.0
  description: The Prelude API allows you to send messages to your users.
  contact:
    email: support@prelude.so
servers:
  - url: https://api.prelude.dev
    description: Production server
security:
  - apiToken: []
tags:
  - name: Notify
    description: Send transactional and marketing messages with compliance enforcement.
  - name: Transactional
    description: Send transactional messages (deprecated - use Notify API instead).
  - name: Verify
    description: Verify phone numbers.
  - name: Watch
    description: Evaluate email addresses and phone numbers for trustworthiness.
  - name: Lookup
    description: >-
      Retrieve detailed information about a phone number including carrier data,
      line type, and portability status.
paths:
  /v2/watch/management/recipes/{recipe_id}:
    delete:
      tags:
        - Watch
      summary: Delete a recipe
      description: >-
        **Beta.** The request and response shapes may still change.


        Delete a recipe no flow still references. A recipe referenced by a flow
        answers `409`, with the flows holding it listed in `details`: detach it
        there first.


        Deleting a recipe that is already gone succeeds.
      operationId: deleteWatchRecipe
      parameters:
        - name: recipe_id
          in: path
          required: true
          schema:
            type: string
            examples:
              - rcp_01jc0t6fwwfgfsq1md24mhyztj
          description: The recipe identifier.
      responses:
        '204':
          description: No Content
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: Conflict
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Error'
                example:
                  code: recipe_in_use
                  message: >-
                    The recipe is still referenced and cannot be deleted. See
                    `details` field for what refers to it.
                  type: conflict
                  details:
                    - path: id
                      message: flo_01jc0t6fwwfgfsq1md24mhyztj
                  request_id: 3d19215e-2991-4a05-a41a-527314e6ff6a
components:
  schemas:
    Error:
      type: object
      properties:
        code:
          type: string
          description: The error code.
          examples:
            - invalid_phone_number
        message:
          type: string
          examples:
            - >-
              The provided phone number is invalid. Provide a valid E.164 phone
              number.
          description: A human-readable message describing the error.
        type:
          type: string
          examples:
            - bad_request
          description: The error type.
        request_id:
          type: string
          examples:
            - 3d19215e-2991-4a05-a41a-527314e6ff6a
          description: >-
            A string that identifies this specific request. Report it back to us
            to help us diagnose your issues.
        param:
          type: string
          examples:
            - phone_number
          description: The parameter the error refers to, when it applies to a single one.
      required:
        - code
        - message
        - type
  securitySchemes:
    apiToken:
      type: http
      scheme: bearer

````