mirror of
https://github.com/ollama/ollama.git
synced 2026-05-13 14:27:00 +00:00
Merge d412266d73 into 3af1a008e2
This commit is contained in:
commit
eb8db608db
1 changed files with 12 additions and 0 deletions
12
docs/api.md
12
docs/api.md
|
|
@ -32,6 +32,18 @@ All durations are returned in nanoseconds.
|
|||
|
||||
Certain endpoints stream responses as JSON objects. Streaming can be disabled by providing `{"stream": false}` for these endpoints.
|
||||
|
||||
### Error responses
|
||||
|
||||
Error responses use HTTP status codes and, when returned as JSON, include an `error` field with a human-readable message:
|
||||
|
||||
```json
|
||||
{
|
||||
"error": "model 'llama3.2' not found"
|
||||
}
|
||||
```
|
||||
|
||||
Some endpoints may include additional fields, such as `signin_url` for authentication flows. Clients should use the HTTP status code together with the `error` message.
|
||||
|
||||
## Generate a completion
|
||||
|
||||
```
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue