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

# Cursor 配置指南

> 在 Cursor 中配置 OpenAI 兼容接口，接入 YeLin AI。

<Info>
  Cursor 支持配置 OpenAI 兼容提供商。
  你可以把 base URL 指向 `https://api.yelinai.com/v1`。
</Info>

## 你先准备什么

1. 你在 **Console** 创建 **API key**。
2. 你已安装 Cursor。

## 配置步骤

1. 打开 Cursor 的 **Settings**。
2. 找到 **Models** 或 **OpenAI** 配置。
3. 填入以下参数。

| 字段       | 你要填什么                        |
| -------- | ---------------------------- |
| Base URL | `https://api.yelinai.com/v1` |
| API key  | 你在 **Console** 复制的 key       |
| Model    | 例如 `gpt-4o-mini`             |

## 验证

你让 Cursor 生成一段简单代码。
你能收到回复就说明成功。

<Tip>
  你先用 `gpt-4o-mini`。
  你确认流程没问题后再换更强模型。
</Tip>

<CardGroup cols={2}>
  <Card title="API key 管理" icon="key" href="/faq/token-management">
    创建并保存 key。
  </Card>

  <Card title="模型列表" icon="list" href="/api-reference/models">
    找到可用模型 id。
  </Card>
</CardGroup>
