> ## 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.

# TextContent

> Plain text content type for prompt messages.

# TextContent

Plain text content for messages in LLM conversations.

## Import

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

## Type Definition

```typescript theme={null}
interface TextContent {
  modality: 'text';
  value: string;
}
```

## Fields

**modality** `string` *required*

Must be `"text"`.

**value** `string` *required*

The text content string.

***

## Example

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

const text: TextContent = {
  modality: 'text',
  value: 'Hello, how are you?'
};

const message: PromptMessage = {
  role: 'user',
  content: [text]
};
```

**JSON**:

```json theme={null}
{
  "modality": "text",
  "value": "Hello, how are you?"
}
```

***

## Related

* [MessageContent](https://www.adaline.ai/docs/reference/sdk/v2/typescript/types/MessageContent.md) — union type that includes `TextContent`
* [PromptMessage](https://www.adaline.ai/docs/reference/sdk/v2/typescript/types/PromptMessage.md) — uses `MessageContent[]` as its `content` field


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.