Skip to content

Commit 40c6145

Browse files
authored
[REST] Improved LM Studio REST Overview page (#143)
1 parent c851e77 commit 40c6145

File tree

2 files changed

+72
-9
lines changed

2 files changed

+72
-9
lines changed

1_developer/_2_rest/endpoints.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ description: "The REST API includes enhanced stats such as Token / Second and Ti
44
---
55

66
```lms_warning
7-
LM Studio now has a v1 REST API! Please migrate to the new API.
7+
LM Studio now has a [v1 REST API](/docs/developer/rest)! Please migrate to the new API.
88
```
99

10-
##### Requires [LM Studio 0.3.6](/download) or newer. Still WIP, endpoints may change.
10+
##### Requires [LM Studio 0.3.6](/download) or newer.
1111

1212
LM Studio now has its own REST API, in addition to OpenAI compatibility mode ([learn more](/docs/developer/openai-compat)).
1313

@@ -21,8 +21,6 @@ The REST API includes enhanced stats such as Token / Second and Time To First To
2121
- [`POST /api/v0/completions`](#post-apiv0completions) - Text Completions (prompt -> completion)
2222
- [`POST /api/v0/embeddings`](#post-apiv0embeddings) - Text Embeddings (text -> embedding)
2323

24-
###### 🚧 We are in the process of developing this interface. Let us know what's important to you on [Github](https://github.com/lmstudio-ai/lmstudio-js/issues) or by [email](mailto:[email protected]).
25-
2624
---
2725

2826
### Start the REST API server

1_developer/_2_rest/index.md

Lines changed: 70 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,24 @@
11
---
22
title: LM Studio API
33
sidebar_title: Overview
4-
description: Get started with LM Studio's REST API for local model management and inference.
5-
fullPage: true
4+
description: LM Studio's REST API for local inference and model management
5+
fullPage: false
66
index: 1
77
---
88

9-
LM Studio offers a powerful REST API with first-class support for local model management and inference. In addition to our native API, we provide full OpenAI compatibility mode ([learn more](/docs/developer/openai-compat)).
9+
LM Studio offers a powerful REST API with first-class support for local inference and model management. In addition to our native API, we provide full OpenAI compatibility mode ([learn more](/docs/developer/openai-compat)).
1010

11-
Our REST API handles local LLM workflows with model downloading, loading, configuration, and inference. Get performance stats like tokens per second, model status, context length, quantization info, and more. Configure loading parameters to customize how models initialize.
11+
## What's new
12+
Previously, there was a [v0 REST API](/docs/developer/rest/endpoints). That API has since been deprecated in favor of the v1 REST API.
1213

13-
### Supported endpoints
14+
The v1 REST API includes enhanced features such as:
15+
- [MCP via API](/docs/developer/core/mcp)
16+
- [Stateful chats](/docs/developer/rest/stateful-chats)
17+
- [Authentication](/docs/developer/core/authentication) configuration with API tokens
18+
- Model [download](/docs/developer/rest/download) and [load](/docs/developer/rest/load) endpoints
19+
20+
## Supported endpoints
21+
The following endpoints are available in LM Studio's v1 REST API.
1422
<table class="flexible-cols">
1523
<thead>
1624
<tr>
@@ -48,6 +56,63 @@ Our REST API handles local LLM workflows with model downloading, loading, config
4856
</tbody>
4957
</table>
5058

59+
## Inference endpoint comparison
60+
The table below compares the features of LM Studio's `api/v1/chat` endpoint with the OpenAI-compatible `v1/responses` and `v1/chat/completions` endpoints.
61+
<table class="flexible-cols">
62+
<thead>
63+
<tr>
64+
<th>Feature</th>
65+
<th><code>api/v1/chat</code></th>
66+
<th><code>v1/responses</code></th>
67+
<th><code>v1/chat/completions</code></th>
68+
</tr>
69+
</thead>
70+
<tbody>
71+
<tr>
72+
<td>Stateful chat</td>
73+
<td>✅</td>
74+
<td>✅</td>
75+
<td>❌</td>
76+
</tr>
77+
<tr>
78+
<td>Remote MCPs</td>
79+
<td>✅</td>
80+
<td>✅</td>
81+
<td>❌</td>
82+
</tr>
83+
<tr>
84+
<td>MCPs you have in LM Studio</td>
85+
<td>✅</td>
86+
<td>✅</td>
87+
<td>❌</td>
88+
</tr>
89+
<tr>
90+
<td>Custom tools</td>
91+
<td>❌</td>
92+
<td>✅</td>
93+
<td>✅</td>
94+
</tr>
95+
<tr>
96+
<td>Model load streaming events</td>
97+
<td>✅</td>
98+
<td>❌</td>
99+
<td>❌</td>
100+
</tr>
101+
<tr>
102+
<td>Prompt processing streaming events</td>
103+
<td>✅</td>
104+
<td>❌</td>
105+
<td>❌</td>
106+
</tr>
107+
<tr>
108+
<td>Specify context length in the request</td>
109+
<td>✅</td>
110+
<td>❌</td>
111+
<td>❌</td>
112+
</tr>
113+
</tbody>
114+
</table>
115+
51116
---
52117

53118
Please report bugs by opening an issue on [Github](https://github.com/lmstudio-ai/lmstudio-bug-tracker/issues).

0 commit comments

Comments
 (0)