Skip to content
Try chatGet API key

Cline

Cline is an open-source coding agent that runs inside VS Code. Bayle is set up as an OpenAI Compatible provider.

Copies this page's setup instructions, to paste into your coding agent.
Show the prompt
Help me set this up to use Bayle AI, an OpenAI-compatible API. Full guide: https://docs.bayle.ai/guides/coding-tools/cline/

Goal: set up the Cline coding agent in VS Code (https://cline.bot) to use a Bayle model. This is a settings panel inside the editor, so walk me through it step by step and wait for me at each one.

1. Make sure the Cline extension is installed in VS Code. If not:
   code --install-extension saoudrizwan.claude-dev
   (listing: https://marketplace.visualstudio.com/items?itemName=saoudrizwan.claude-dev)
2. Pick a model. Cline relies on tool calls, so use one that supports them, and read its context length:
   curl -s "https://api.bayle.ai/models?type=text" \
     | jq -r '.data[] | select(.model_spec.capabilities.supportsFunctionCalling)
              | "\(.id)  \(.model_spec.availableContextTokens)"'
   Show me the list and let me choose.
3. Tell me to open the Cline panel, click the settings gear, set "API Provider" to "OpenAI Compatible", and fill in:
   Base URL: https://api.bayle.ai
   API Key: my Bayle key. Tell me to paste it into the field myself; do not ask me to type it into this chat. Cline stores it in the editor's secret storage.
   Model ID: the chosen id
4. Optionally have me set the context window to the model's real size, so Cline knows when to condense the conversation.
5. Verify: run one curl to POST https://api.bayle.ai/chat/completions with the chosen model and show me the result, then ask me to send Cline a short message and confirm it answers.

Rules:
1. The base URL is https://api.bayle.ai exactly as written. Append no path to it.
2. Read the key from the BAYLE_API_KEY environment variable. Never write the key itself into a file you create, a command, a commit or the chat. Where the tool keeps the key in its own settings screen, tell me where to paste it. If BAYLE_API_KEY is not set, stop and ask me to create a key at https://chat.bayle.ai/developers and export it.
3. Take model ids only from GET https://api.bayle.ai/models (no key needed). Never guess one.
4. Finish with one real test request, show me the result and list the files you changed.

Install the extension from the Visual Studio Marketplace, or from a terminal:

Terminal window
code --install-extension saoudrizwan.claude-dev

The official install guide covers other editors.

Don't have a Bayle key yet?Get API key
  1. Open the Cline panel and click the settings gear.

  2. Set API Provider to OpenAI Compatible.

  3. Fill in:

    Field Value
    Base URL https://api.bayle.ai
    API Key Your Bayle key
    Model ID MODEL_ID
  4. Optionally set the context window to the model’s real size, so Cline knows when to condense the conversation.

Cline adds /chat/completions to the base URL.

Cline takes the key in its settings rather than from an environment variable, and stores it in the editor’s secret storage.

Cline relies on tool calls, so use a model that supports them, and read its context length while you’re there:

Terminal window
curl -s "https://api.bayle.ai/models?type=text" \
| jq -r '.data[] | select(.model_spec.capabilities.supportsFunctionCalling)
| "\(.id) \(.model_spec.availableContextTokens)"'