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

# Prompt Enhancement - Overview

> AI-powered prompt optimization tools for better generation results.

<Info>
  In v2 all prompt boosters use a **single unified endpoint** — `POST /api/v2/prompts/enhancements`. You select the booster with the **`type`** field (v2 dot notation) and the target model via **`model_slug`**.
</Info>

## Endpoints

| Purpose        | Endpoint                                  |
| -------------- | ----------------------------------------- |
| Prompt Booster | `POST /api/v2/prompts/enhancements`       |
| Booster Price  | `POST /api/v2/prompts/enhancements/price` |

## Request fields (`/api/v2/prompts/enhancements`)

| Field             | Required                                                        | Notes                                                               |
| ----------------- | --------------------------------------------------------------- | ------------------------------------------------------------------- |
| `prompt`          | **Yes**                                                         | Raw user prompt (min 3 chars).                                      |
| `type`            | **Yes**                                                         | Inference type in dot notation (see table below).                   |
| `model_slug`      | **Yes**                                                         | Target deAPI model, e.g. `Flux_2_Klein_4B_BF16`. Selects the guide. |
| `image`           | Conditional — required for `images.edits` / `videos.animations` | Reference image: URL, data-URI, base64, or file.                    |
| `negative_prompt` | No                                                              | Optional (min 3 chars).                                             |

### `type` values

| `type`                       | Use case                                 |
| ---------------------------- | ---------------------------------------- |
| `images.generations`         | Text-to-image                            |
| `images.edits`               | Image-to-image / edit (requires `image`) |
| `images.upscales`            | Image upscaling                          |
| `images.background-removals` | Image background removal                 |
| `images.ocr`                 | Image OCR                                |
| `videos.generations`         | Text/image-to-video                      |
| `videos.animations`          | Character animation (requires `image`)   |
| `videos.upscales`            | Video upscaling                          |
| `videos.background-removals` | Video background removal                 |
| `videos.transcriptions`      | Video transcription                      |
| `audio.speech`               | Text-to-speech                           |
| `audio.music`                | Text-to-music                            |
| `audio.transcriptions`       | Audio transcription                      |
| `embeddings`                 | Embeddings                               |

## Workflow

<Steps>
  <Step title="Enhance your prompt">
    Call `POST /api/v2/prompts/enhancements` with `prompt`, `type`, and `model_slug` (plus `image` for `images.edits` / `videos.animations`).
  </Step>

  <Step title="Use the enhanced prompt">
    Plug the returned `prompt` into the matching v2 generation endpoint — `/api/v2/images/generations`, `/api/v2/images/edits`, `/api/v2/videos/generations`, `/api/v2/audio/speech`, etc.
  </Step>
</Steps>

See the [Prompt Booster](/api/v2/prompt-enhancement/prompt-booster) page for the full request/response schema.
