Configure Cline
Cline is an AI coding agent for VS Code that can read projects, edit files, and run commands. Use its OpenAI Compatible provider to connect LAYSO AI models.
One key for every platform model
One LAYSO AI API key can access platform models. Successful requests have itemized charges at the selected model's current price; failed tasks are not charged.
Prerequisites
- Install the latest Visual Studio Code ↗.
- Create an API key on the LAYSO AI API Keys page ↗.
- Copy the exact model ID from LAYSO AI Models & Pricing ↗.
- Prefer a model with tool-calling support so Cline can read files and perform actions.
Configuration steps
Step 1: install Cline
Open the VS Code Extensions view, search for Cline, confirm that both the extension name and publisher are Cline, and select Install.
Step 2: open Cline settings
Open the Cline panel after installation, then select the gear icon in the upper-right corner to open Settings.
Step 3: configure LAYSO AI
Select API Configuration in the sidebar and enter:
| Setting | Value |
|---|---|
| API Provider | OpenAI Compatible |
| Base URL | https://api.layso.ai/v1 |
| OpenAI Compatible API Key | Complete key copied from the LAYSO AI API Keys page |
| Model ID | Exact model ID copied from Models & Pricing |
The Base URL ends at /v1. Do not append /chat/completions, /responses, or a model name. The model in the screenshot is only an example; use current information from Models & Pricing.
Set Reasoning Effort, context length, and other model options according to the selected model's actual capabilities. Select Done in the upper-right corner when finished.
Step 4: send a test message
Return to the Cline conversation and confirm that the configured model appears below the input box. Send a short read-only task such as:
Introduce yourself without modifying any files.A normal response marked COMPLETED confirms the connection. You can then verify the model, token use, and itemized charge in the LAYSO AI user app.
Usage recommendations
- Start with a read-only task to verify the provider, model, and workspace.
- Review proposed file changes and terminal commands before approving them.
- Do not grant broad Auto Approve permissions unless the current task genuinely requires them.
- Create a recoverable version-control commit or checkpoint before large changes.
- Never expose a complete API key in project files, screenshots, logs, or a Git repository.
Troubleshooting
| Symptom | What to check |
|---|---|
| The Cline icon is missing | Run Cline: Open In New Tab or reload the VS Code window |
| Invalid API Key or 401 / 403 | Copy the API key again and make sure it contains no spaces, line breaks, or missing characters |
| 404 | The Base URL must be https://api.layso.ai/v1; do not duplicate /v1 or append a request path |
| Model Not Found | Copy the exact model ID from Models & Pricing and confirm the provider is OpenAI Compatible |
| Tool use is unavailable | Confirm that the selected model supports tool calling and review Cline's model settings |
| Cline's estimate differs | Cline's value is a local estimate; the LAYSO AI itemized charge is authoritative |
