SALPX SUPPORT CENTER

Help Center
FAQ

Common questions about quota, tokens, channels, connectivity, and upgrades — all hosted on-site. When an error shows up, check by category first: it is usually quota, model pricing, channel routing, or upstream load.

Showing all questions
★

Connecting clients to SalpX (Codex / Claude Code / chat apps)

SalpX is an OpenAI / Anthropic compatible API gateway. Any client that supports a "custom API base URL + key" can connect — you only need two things:

  • OpenAI-compatible base URL (Codex, most chat clients): https://www.salpx.com/v1
  • Claude / Anthropic-compatible base URL (Claude Code): https://www.salpx.com (the client appends /v1/messages itself — do not add /v1)
  • API key: a token created under "Console → Token management"
Fastest path: use the one-line setup command from "Token management"

"Console → Token management" ships ready-made setup commands for Codex / Claude Code with the base URL, key, and required parameters pre-filled.

  1. Copy the command for your system.
  2. Windows: open PowerShell as administrator; Mac: open Terminal.
  3. Paste the entire block from the first line and press Enter — configuration runs automatically.
  4. After it finishes, reopen the terminal / app before using it (environment variables only apply to new processes).

⚠️ The command contains your API key — do not share it.

Codex: use the CLI, not the official desktop app

On some Windows machines the official Codex desktop app fails with "unable to set up non-admin sandbox" — that is an app-side issue, unrelated to SalpX, and not fixable via configuration. Use the CLI instead:

  1. Install Node.js (LTS installer from nodejs.org, or winget install OpenJS.NodeJS.LTS); open a new terminal and confirm node -v prints a version.
  2. Install Codex: npm install -g @openai/codex. (On Windows, if script execution is blocked: Set-ExecutionPolicy -Scope CurrentUser RemoteSigned)
  3. Let the one-line setup write ~/.codex/config.toml and auth.json; or configure manually: provider base URL https://www.salpx.com/v1, wire_api = "responses", plus sandbox_mode = "danger-full-access".
  4. Run: codex --sandbox danger-full-access.

Note: Codex now only supports wire_api = "responses" (chat is gone); sandbox_mode = "danger-full-access" skips the desktop/sandbox initialization error.

Claude Code setup
  1. Install: npm install -g @anthropic-ai/claude-code.
  2. Set three environment variables (or use the one-line setup): ANTHROPIC_BASE_URL=https://www.salpx.com (no /v1), ANTHROPIC_AUTH_TOKEN=your-token, ANTHROPIC_MODEL=claude-....
  3. Open a new terminal and run claude.

Keep /v1 off the base_url: the client appends /v1/messages itself; adding it produces /v1/v1/ and a 404.

Desktop chat: use ChatBox / Cherry Studio, not the official Claude / Codex desktop apps

The official Claude Desktop and Codex desktop apps are consumer products tied to official accounts — there is no way to enter a custom API base URL, so they cannot point at SalpX. For desktop chat, use a third-party client that supports custom endpoints:

  • ChatBox, Cherry Studio, LobeChat, etc.
  • Add a "custom / OpenAI-compatible" provider: set the base URL to https://www.salpx.com/v1, paste your token as the key, save, pick a model, and start chatting.
Quick list of common pitfalls
  • Official desktop apps won't work: Codex desktop sandbox errors / Claude desktop is locked to official endpoints → use the CLI or a third-party chat client.
  • Changed env vars have no effect: you must reopen the terminal / app (old processes keep the old values).
  • Windows blocks script execution: Set-ExecutionPolicy -Scope CurrentUser RemoteSigned.
  • Codex says wire_api is unsupported: switch the provider's wire_api to "responses".
  • Set the base URL but still hitting the official API: check the base_url (OpenAI-style takes /v1, Claude-style does not), and make sure the token is correct with no stray spaces.
01

Quota questions

What is quota and how is it computed?

Quota is the platform's internal unit for metering model usage. For pay-as-you-go models it typically factors in the user-group ratio, the model ratio, and input vs. output tokens.

quota = group ratio × model ratio × (prompt tokens + completion tokens × completion ratio)
  • Completion ratios differ per model — output is usually more expensive than input.
  • In non-streaming calls the upstream may only report total tokens, even though input and output ratios differ.
  • Per-call models (video, images, etc.) are not token-based; they charge the fixed price configured in the backend.
My account has balance — why "insufficient quota"?

The usual cause: "account balance" and "token quota limit" are two separate layers. A funded account does not mean a given API key's limit is unlimited.

  • Check that key's quota cap under Console → Token management.
  • Confirm the key is not expired, disabled, or restricted by IP or model.
  • Video and high-price models pre-deduct a larger amount; requests can be rejected when the balance is near the threshold.
02

Channel configuration

What do "priority" and "weight" mean on a channel?

Priority decides which batch of channels is used first; weight decides how requests spread within the same priority.

  • Priority: higher number wins. Priority 2 is picked before priority 1.
  • Weight: channels at the same priority split traffic proportionally — with weights 2:1, requests split roughly 2:1.
  • Best practice: give stable, cheap channels high priority; keep backup channels enabled at lower priority.
"No available channel" — how to troubleshoot
  1. Confirm your user group is allowed to use the model.
  2. Confirm the channel's group list includes your user group.
  3. Confirm the channel's model list contains the exact model name from the request — case and aliases matter.
  4. Confirm the channel is enabled and not suspended due to balance, failed tests, or auto-disable.
Channel test error: invalid character '<' looking for beginning of value

This means the system expected JSON but received an HTML page. Typically the upstream gateway, Cloudflare, a security policy, or an error page intercepted the request.

  • Check the channel Base URL for typos — an extra /v1 or a missing path segment.
  • Confirm the API key is valid and has access to the target model.
  • Check whether the server IP or proxy node is blocked by an upstream security policy.
  • If needed, curl the upstream directly from the server and see whether the response is HTML.
Channel test error: ratio or price not configured

Usually the model has no usable pay-as-you-go ratio or per-call price. In the admin backend check:

  • Whether System settings → Operations settings → Model ratio settings defines a model ratio, completion ratio, or fixed price for it.
  • Per-call models belong in fixed pricing — do not also bill them by token or by second.
  • For internal testing, check whether self-use mode is enabled.
03

Deployment & connectivity

Client error: Failed to fetch

This typically happens when a browser or desktop client cannot reach the API address.

  1. Confirm the API address is https://www.salpx.com/v1.
  2. Confirm the API key is in the Authorization header, with no stray spaces.
  3. An HTTPS page must not call HTTP endpoints — the browser blocks them.
  4. If you use a proxy client, check whether its rules intercept the SalpX domain.
Error: current group is saturated, please retry later

Usually the upstream channel returned 429, or every channel in the group is busy.

  • Retry later, or switch to another available model.
  • Admins can add backup channels to the group, top up channel balance, or adjust weights and priorities.
  • Video, image, and reasoning models are the likeliest to queue or rate-limit at peak hours.
04

Database & upgrades

Will an upgrade lose my data?

Not in a normal deployment — what matters is whether the database and data directories are persisted.

  • PostgreSQL / MySQL: as long as the database service and data volume are not deleted, an app upgrade cannot lose data.
  • SQLite: the directory holding the database file must be mounted correctly, otherwise a container rebuild can wipe it.
  • Back up the database and config files before upgrading — especially in production.
Do I need to touch the database before upgrading?

Generally no. The system applies the necessary schema changes automatically at startup. Only run extra scripts when the release notes explicitly require it.

"Database consistency broken" after manual DB edits — what now?

This usually means invalid references between channels and the model ability tables — e.g. a channel row was deleted while its ID remained in the abilities table.

  • Avoid deleting channel rows directly in the database.
  • Prefer the admin console's channel management, model deployment, and bulk-repair features.
  • If you already edited manually, verify that channels and abilities rows still match.
05

Can't find your question?

First grab the request ID, model name, channel ID, and the full error message from the usage log, then continue with the paths below. To keep everything on-site, this Help Center does not link out to external docs.

Compliance note: SalpX serves users outside mainland China only. Please follow the laws of your region, the upstream model terms of service, and platform content-safety requirements.