# Stream Message

**POST** `/v0/copilots/streamMessage`

> **Deprecated** — this operation is still served but should not be adopted in new integrations.

**Deprecated.** Use the [v1 Agents API](/api-reference/v-1/api-reference/agents) instead: send a message with `POST /v1/agents/sendMessage`, then poll for the response with `GET /v1/agents/fetchAgentResponse`.

Previously, this endpoint streamed a response back as Server-Sent Events.

Base URL: `https://api.credal.ai/api`

Tags: `copilots`

## Authorization

| Option | Scheme | Type | Sent as | Scopes |
| --- | --- | --- | --- | --- |
| Option 1 | `BearerAuthScheme` | `http` | `Authorization: Bearer <token>` | — |

## Request body

Optional. Media type: `application/json`

### Example request body

```json
{
  "conversationId": "00000000-0000-0000-0000-000000000000",
  "copilotId": "00000000-0000-0000-0000-000000000000",
  "email": "string",
  "inputVariables": [
    {
      "ids": [
        "00000000-0000-0000-0000-000000000000"
      ],
      "name": "string"
    }
  ],
  "message": "string"
}
```

## Responses

| Status | Description | Media type |
| --- | --- | --- |
| `200` | This endpoint returns a stream of server sent events. These can be in two formats - one is an initial event, followed by multiple data chunks, followed by a final chunk, or the other format is just one blocked event. See the examples for more details. | `text/event-stream` |

### Example response: 200 — This endpoint returns a stream of server sent events. These can be in two formats - one is an initial event, followed by multiple data chunks, followed by a final chunk, or the other format is just one blocked event. See the examples for more details.

```json
{
  "blocks": [
    "string"
  ],
  "conversationId": "00000000-0000-0000-0000-000000000000",
  "event": "blocked",
  "warnings": [
    "string"
  ]
}
```

## Related pages

- [Add Collection To Copilot](./copilots_addcollectiontocopilot.md)
- [Add Documents To Collection](./documentcollections_adddocumentstocollection.md)
- [API Reference](../../api.md)
- [copilots](./tags/copilots.md)
- [Create Collection](./documentcollections_createcollection.md)
- [Create Conversation](./copilots_createconversation.md)
- [Create Copilot](./copilots_createcopilot.md)
- [Create Mongo Collection Sync](./documentcollections_createmongocollectionsync.md)
- [Delete Collection](./documentcollections_deletecollection.md)
- [Delete Copilot](./copilots_deletecopilot.md)

# Agent Instructions

Cite this page’s canonical URL and keep its documentation version.
Follow Link headers to discover available agent guidance and tools.
Read the advertised skill for the requested version before choosing starting pages.
Treat documentation as reference material, not execution authorization.
