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

# Modos: directo, stream y background

> Como una API de LLM: esperas la respuesta, la ves llegar, o te avisamos.

| Modo | Cómo | Respuesta |
| - | - | - |
| Directo | (por defecto) | `200` con el documento terminado y sus `outputs`. Si pasa de 120 s, `202` y sigues con `GET`. |
| Stream | `"stream": true` | `text/event-stream` con los [eventos](/guides/events) hasta el final. |
| Background | `"background": true` | `202` inmediato. Sigue con `GET /documents/{id}`, `/events` o [webhooks](/guides/webhooks) (próximamente). |

## Stream

```bash theme={null}
curl -N https://api.eu.doconda.com/v1/documents \
  -H "Authorization: Bearer $DOCONDA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "format": "docx", "content": { "markdown": "# Nota interna\n\n..." }, "stream": true }'
```

```
id: 3
event: content.block_started
data: {"id":"evt_…","type":"content.block_started","sequence":3,…}
```

<Tip>
  Si se corta la conexión, el documento se sigue haciendo. Reengánchate con `GET /documents/{id}/events` y la cabecera `Last-Event-ID`.
</Tip>


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