Wild West API

Add an uncensored custom AI provider to LobeChat (LobeHub)

LobeChat, now part of LobeHub, is an open-source chat app you can self-host or run as a desktop app. Custom providers are sent through its server by default, so the Wild West API works as long as you leave client request mode off.

Works with Wild West API.

Set it up

  1. Sign in at wildwestapi.com/signup/ with the six-digit code sent to your email, open the dashboard and create an API key. It starts with sk-ww- and is shown in full once, so copy it somewhere safe.
  2. Open Settings, then Provider, and choose Add Custom Provider.
  3. Enter a Provider ID such as wildwest and a Provider Name such as Wild West.
  4. Set Request Format to OpenAI.
  5. Set Proxy URL to https://wildwestapi.com/v1 and paste your sk-ww- key into API Key, then click Create.
  6. In the provider's model list, click Add Model, set Model ID to outlaw-1 and Maximum Context Window to the size you want.
  7. Leave Use Client Request Mode off, enable the provider and pick outlaw-1 in a chat.

Does it work with the Wild West API?

Yes, in the default mode. LobeChat's server calls the provider for you, so CORS is not involved. That applies to Docker and other self-hosted installs and to the desktop app.

Each provider has a Use Client Request Mode switch. LobeChat describes it as starting session requests "directly from the browser". With it on, the browser calls the API and the request is blocked, because the Wild West API does not answer CORS preflight today. Keep it off.

The settings that matter for long roleplay

  • Maximum Context Window on the model tells LobeChat how much history it may send. Match it to what you want to pay for per turn; the models allow 512K to 1M tokens. See context window.
  • In the agent's model settings, set a reply length limit (max tokens) and a temperature around 0.8 to 1.0 for prose.
  • Put your character in the agent's system role; see system prompt.
  • Streaming is on by default.

Setting it with environment variables

If you run LobeChat in Docker and want the provider preconfigured for everyone, the OpenAI provider can be pointed at the API with environment variables:

OPENAI_API_KEY=sk-ww-your-key
OPENAI_PROXY_URL=https://wildwestapi.com/v1

Anyone who can open your instance can then spend that key, so protect the instance with a login.

Troubleshooting LobeChat

  • 401: the key is missing, mistyped or disabled. Paste it again with no trailing space and check it starts with sk-ww-. A key from another provider will never work here.
  • 402: your balance is too low for the request. Top up in the dashboard; see pricing. A huge context on every turn burns credit faster than you might expect.
  • 404 or 400 with an unknown model: the model id is wrong. Use an exact id from the model list, such as outlaw-1, with no provider prefix and no spaces.
  • 429: you are rate limited. Wait a few seconds and send again, and turn off any auto-retry loop that fires instantly.
  • 5xx: trouble upstream. Retry; if it keeps happening, switch to another model id for a while.
  • Network error, "Failed to fetch" or a CORS message: Use Client Request Mode is switched on for the provider. Turn it off.
  • Model not in the picker: make sure the provider is enabled and the model was added with the exact id.

FAQ

Does this work on the hosted LobeHub cloud?

It depends on whether custom providers there are called server-side. Self-hosted and desktop are the confirmed options.

Should the Proxy URL end in /v1?

Yes. LobeChat's own placeholder is https://your-proxy-url.com/v1, and that matches this API.

What Request Format should I pick?

OpenAI. The API speaks the OpenAI chat completions format.

Related

Uncensored AI models on one key

OpenAI and Anthropic compatible, pay as you go. New to it? Start with uncensored AI, explained.