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

# cURL

LLMGrid exposes OpenAI-compatible routes such as `/chat/completions` and `/embeddings` under the `/v1` base URL.

Streaming (SSE)

```text theme={null}
curl -N https://api.llmgrid.ai/v1/chat/completions \
  -H "Authorization: Bearer $LLMGRID_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-4.1",
    "messages": [{"role": "user", "content": "Stream a 2-sentence summary of caching."}],
    "stream": true
  }'
```

Embedding

```text theme={null}
curl -sS https://api.llmgrid.ai/v1/embeddings \
  -H "Authorization: Bearer $LLMGRID_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "text-embedding-3-large",
    "input": ["LLMGrid embeddings example"]
  }'
``
```
