> ## Documentation Index
> Fetch the complete documentation index at: https://botmesh.afaya.com.co/llms.txt
> Use this file to discover all available pages before exploring further.

# StreamTarget

> Interface exported by @botmesh/core.

Defined in: [streaming/types.ts:104](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L104)

The sink [streamText](https://botmesh.afaya.com.co/api/core/functions/streamText.md) renders into. `ctx.stream()` builds one from the
bot; tests and custom integrations can provide their own.

## Properties

### capabilities?

```ts theme={null}
capabilities?: Pick<ProviderCapabilities, "edit" | "streaming" | "maxTextLength" | "maxTextBytes">;
```

Defined in: [streaming/types.ts:105](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L105)

***

### isPrivate?

```ts theme={null}
isPrivate?: boolean;
```

Defined in: [streaming/types.ts:107](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L107)

`false` for groups/channels: native drafts are attempted only when not `false`.

***

### shutdown?

```ts theme={null}
shutdown?: AbortSignal;
```

Defined in: [streaming/types.ts:118](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L118)

Aborted when the transport shuts down (`bot.stop()`): the stream is cancelled and
touches the target no more — no flush, no discard, no rate-limit wait.

## Methods

### send()

```ts theme={null}
send(content, options?): Promise<SentMessage<unknown>>;
```

Defined in: [streaming/types.ts:108](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L108)

#### Parameters

| Parameter | Type |
| - | - |
| `content` | [`OutboundContent`](https://botmesh.afaya.com.co/api/core/type-aliases/OutboundContent) |
| `options?` | [`SendOptions`](https://botmesh.afaya.com.co/api/core/interfaces/SendOptions) |

#### Returns

`Promise`\<[`SentMessage`](https://botmesh.afaya.com.co/api/core/interfaces/SentMessage)\<`unknown`>>

***

### edit()?

```ts theme={null}
edit?(ref, content): Promise<unknown>;
```

Defined in: [streaming/types.ts:109](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L109)

#### Parameters

| Parameter | Type |
| - | - |
| `ref` | [`MessageRef`](https://botmesh.afaya.com.co/api/core/interfaces/MessageRef) |
| `content` | [`OutboundContent`](https://botmesh.afaya.com.co/api/core/type-aliases/OutboundContent) |

#### Returns

`Promise`\<`unknown`>

***

### delete()?

```ts theme={null}
delete?(ref): Promise<void>;
```

Defined in: [streaming/types.ts:111](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L111)

Deletes a message this stream sent (used by `onCancel: 'discard'`).

#### Parameters

| Parameter | Type |
| - | - |
| `ref` | [`MessageRef`](https://botmesh.afaya.com.co/api/core/interfaces/MessageRef) |

#### Returns

`Promise`\<`void`>

***

### draft()?

```ts theme={null}
draft?(
   draftId, 
   text, 
   opts?
): Promise<void>;
```

Defined in: [streaming/types.ts:112](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L112)

#### Parameters

| Parameter | Type |
| - | - |
| `draftId` | `number` |
| `text` | `string` |
| `opts?` | [`DraftOptions`](https://botmesh.afaya.com.co/api/core/interfaces/DraftOptions) |

#### Returns

`Promise`\<`void`>

***

### typing()?

```ts theme={null}
typing?(): Promise<void>;
```

Defined in: [streaming/types.ts:113](https://github.com/andresayac/botmesh/blob/main/packages/core/src/streaming/types.ts#L113)

#### Returns

`Promise`\<`void`>


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