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

# Prompt draft

# PromptDraftClient

`adaline.prompts.draft` reads the current working draft of a prompt — the unsaved version shown in the editor before a save is applied.

Today the only operation is `get`; the sub-namespace exists to leave room for future draft mutations without reshuffling call sites.

## Access

```typescript theme={null}
import { Adaline } from '@adaline/client';

const adaline = new Adaline();
const draft = adaline.prompts.draft; // PromptDraftClient
```

The class is also exported directly:

```typescript theme={null}
import { PromptDraftClient } from '@adaline/client';
```

Types from `@adaline/api`:

```typescript theme={null}
import type { PromptDraft } from '@adaline/api';
```

***

## get()

Get the current draft for a prompt — the unsaved working version shown in the editor before a save.

```typescript theme={null}
get(options: { promptId: string }): Promise<PromptDraft>
```

### Parameters

| Name       | Type     | Required | Description        |
| ---------- | -------- | -------- | ------------------ |
| `promptId` | `string` | Yes      | Prompt identifier. |

### Returns

`Promise<PromptDraft>` with config, messages, tools, and variables mirroring the [PromptSnapshot](/docs/reference/sdk/v2/typescript/types/PromptSnapshot) shape.

### Example

```typescript theme={null}
const draft = await adaline.prompts.draft.get({ promptId: 'prompt_abc123' });

console.log(draft.config.model);
console.log(draft.messages);
```

***

## See Also

* [PromptsClient](/docs/reference/sdk/v2/typescript/classes/prompts) — parent client
* [PromptSnapshot](/docs/reference/sdk/v2/typescript/types/PromptSnapshot)
* API reference: [Get prompt draft](/docs/reference/api/v2/openapi/get-prompt-draft)
