> For the complete documentation index, see [llms.txt](https://docs.sealsecurity.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sealsecurity.io/reference/public-api/patch-validation-prompt.md).

# Patch validation prompt

**Description:** Returns the [patch validation prompt](/trust/patch-validation-prompt.md) for one (package, vulnerable version, vulnerability) tuple as plain text. The prompt embeds the patch diff itself; the caller can paste the result directly into an LLM.

**Path:** `https://external.sealsecurity.io/authenticated/api/v1/patches/validation-prompt`

**Method:** GET

**Authentication:** Bearer token. See [Authentication](/reference/public-api.md#authentication).

#### Request parameters

All query parameters are required.

| Parameter                  | Type   | Required | Description                                                                                                        |
| -------------------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------ |
| `ecosystem`                | string | yes      | Package ecosystem (for example, `NPM`, `PyPI`, `Maven`, `RPM`, `DEB`, `APK`).                                      |
| `package_name`             | string | yes      | The package name.                                                                                                  |
| `vulnerable_version`       | string | yes      | The vulnerable origin version the prompt asks about.                                                               |
| `vulnerability_identifier` | string | yes      | The vulnerability identifier (CVE, GHSA, Snyk ID, or any other identifier Seal recognizes for this vulnerability). |

#### Response

`Content-Type: text/plain`. The body is the prompt text, ready to paste into your LLM. The prompt includes the patch diff inline, so no other artifacts need to be passed alongside it.

#### Errors

| HTTP status     | Meaning                                                                                                                                                 |
| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `404 Not Found` | The library version, the sealed version, or the matching vulnerability impact could not be located. The response body's `detail` field names which one. |

#### Example

**Request (cURL):**

```bash
curl -X GET \
  'https://external.sealsecurity.io/authenticated/api/v1/patches/validation-prompt?ecosystem=NPM&package_name=ejs&vulnerable_version=2.7.4&vulnerability_identifier=CVE-2024-33883' \
  -H 'Authorization: Bearer YOUR_ACCESS_TOKEN'
```

**Example Response (truncated):**

```
You are reviewing a security patch...
<the embedded diff>
...
```
