Use Your Own Provider and API Key for Custom Models

Add your own provider and API key, add or import its models, then pick the model in a Claude Code, Codex, OpenCode, pi or dsh session on your own computer, with a screenshot for each step.

Updated

Bring models from a third-party provider into PandaSI and use them in Claude Code, Codex, OpenCode, pi and dsh sessions on your own computer. This walkthrough shows every screen from adding the provider to chatting with the model. For what each field means and for troubleshooting, see API Key and Base URL.

Before you start

  • Custom models and your own key need no subscription. Only OpenCode, pi and dsh on your own computer require one; Claude Code and Codex do not.
  • Requests with your key are sent only from your own computers, through the desktop app or PandaPaw, and never from PandaSI servers.
  • Cloud Agents and sessions shared with other people cannot use your key.

Step 1: Open Model configuration

Open Model configuration at the bottom of the left bar. Providers are on the left, models on the right.

The Model configuration page with the sidebar entry and the Add button highlighted
Open Model configuration, then add a provider.
  1. Model configuration: The Model configuration icon at the bottom of the left bar.
  2. Click Add: Create your own provider from the top right of the Providers panel.

Step 2: Add a provider

Click Add and fill in the provider. The name and ID are yours to choose; the key and URL come from the provider console.

The Add Provider form with the name, ID, API Key and Base URL fields highlighted
Fill in the provider form.
  1. Display Name: A name for this provider, shown only to you.
  2. Provider ID: A unique ID in lowercase letters and hyphens.
  3. API Key: Copied from the provider console.
  4. Base URL: The provider API address, usually ending in /v1.

Step 3: Choose the protocol

The protocol decides which engines can use this provider. Pick the one your provider serves, then save.

The protocol options in the provider form and the Save button
Pick the protocol your provider serves and save.
  1. Match the provider API: Anthropic Messages, OpenAI Chat Completions or OpenAI Responses.
  2. Save: The provider then shows up under Custom providers.
Protocol Engines that can use it
Anthropic Messages Claude Code
OpenAI Responses Codex
OpenAI Chat Completions OpenCode, pi, dsh

After saving, switch to Custom providers to see it. The key is shown only as dots.

The Custom providers tab listing the saved provider
The saved provider under Custom providers.
  1. Custom providers: Shows only the providers you added.
  2. The provider you saved: Edit or delete it on the right. The key is never shown in plain text.

Step 4: Add a model

Back on the right, click Add Model and attach the model to the provider you just created.

The Add Model form with name, model value, type, provider and Save highlighted
Fill in the model form.
  1. Display Name: The name shown in the model picker.
  2. Model Value: The model ID from the provider docs, exactly as written.
  3. Model Type: Sets the card icon and default parameters.
  4. Pick your provider: The model uses the key and URL of this provider.
  5. Save: The model then shows up under Custom models.

After saving, switch to Custom models to see the new model card.

The Custom models tab showing the new model card
The saved model under Custom models.
  1. Custom models: Shows only the models you added.
  2. The model you saved: The card shows the name, model value and type; below are edit, copy, disable and delete.

Import the whole model list

You do not have to add models one by one. In the desktop app every custom provider has a Fetch models button that imports the model list of that provider in one go. The button appears only in the desktop app.

A custom provider row in the desktop app with the Fetch models button
Fetch models sits on each custom provider in the desktop app.
  1. Your provider: Find the provider you just saved under Custom providers.
  2. Fetch models: Click this button to load the model list of the provider.

The list is requested straight from the provider by this computer with your saved key. Chat models are ticked and typed automatically; image, speech and embedding models are left unticked.

The model import dialog with checkboxes, model types and the add button
Tick the models you want and add them together.
  1. Tick models: Tick the models to add. Select all and Select none are at the top right.
  2. Model type: Types are matched from the model name; choose one yourself when it is not recognised.
  3. Add in bulk: One click adds every ticked model.

When the import finishes, the models appear under Custom models and work just like models added by hand.

The Custom models tab filled with the imported models
Imported models under Custom models.
  1. Custom models: Switch here to see only your own models.
  2. Imported models: One card per model, with an icon for its type.

Step 5: Use it in Agent

Start a session on a connection to your own computer. First pick that connection at the top left. Models with your own key only send requests from your own computer.

The connection switcher in Agent with your own computer highlighted
Pick the connection to your own computer.
  1. Connection switcher: Click here to list all your connections.
  2. Your computer: Pick the paired computer that is online.

With the connection selected, click + and choose an engine: Claude Code, Codex, pi, opencode or dsh.

The new project button and the engine list with a Use button
Start a new project and choose the engine.
  1. New: Click + to start a new project.
  2. Choose engine: Click Use on the engine you want.

In the New project dialog open Default model. Your model is in the Custom models group.

The Default model list in the New project dialog with the Custom models group
Your models are listed under Custom models.
  1. Default model: Open the model list.
  2. Custom models: The models you added are listed in this group.

Pick the custom model and save. The session is created.

The New project dialog with a custom model selected and the Save button
Save the project with your model selected.
  1. Selected model: Your custom model is shown here.
  2. Save: Save to enter the new session.

The bar at the top shows the current model. Type a message and send it to start.

A new session with the current model in the top bar and the message box
Send the first message.
  1. Current model: The top bar shows the model this session uses.
  2. Type and send: Write a message, then click the arrow on the right.

Switch to another model

To change model, click the model name at the top and choose another one in Switch model.

The Switch model window listing custom models with the current one marked
Switch model from the top bar.
  1. Click the model name: Click the model name at the top to open the switcher.
  2. Custom models: Scroll down to your custom models.
  3. Current: The row marked Current is in use. Click another row to switch.

After switching, just keep sending messages. The new model answers from here on.

The session after switching models with a new message in the message box
Keep chatting after the switch.
  1. Keep chatting: Type and send as usual after switching.

Check that it works

Send a short message such as Reply with: connected. A normal reply, and a matching request in the usage records of your provider, confirm that the provider, the model and the engine fit together. Saving the forms alone does not test the connection.

If the model does not appear or the request fails

  • The model is missing from the picker. The picker lists only models the current engine can use. Check that the protocol of the provider matches the engine in the table above.
  • This computer has no saved key for the provider. The key is tied to the Base URL it was saved with. After changing the URL or moving to another computer, open the provider and enter the key again.
  • The session fails to start or never answers. Check the Base URL for a missing or doubled /v1, the model value against the provider docs, and the remaining balance of the key.
  • The model is missing in a cloud Agent. This is intended: models with your own key run only on your own computer.

Where your key is used

Requests with your key leave only from your own paired computers, which call the provider directly. The web page, phones and PandaSI servers never send requests with it. From the web or a phone you can still use these models by connecting to your own paired computer; the request is sent by that computer. See Your API key stays on your device.