MCPcopy Create free account
hub / github.com/QodeXcli/QodeX / slugifyProviderName

Function slugifyProviderName

src/setup/gateways.ts:172–177  ·  view source on GitHub ↗
(raw: string)

Source from the content-addressed store, hash-verified

170 * gateway). If a model id is given we pin it (with the spec's defaults); otherwise we omit
171 * `models` so the provider auto-discovers from GET {baseUrl}/models.
172 */
173/**
174 * Turn a user-supplied provider identifier into a valid provider NAME.
175 *
176 * A provider name must not contain spaces, "/", or ":" (the config loader rejects
177 * such names — `providers.custom[].name must not contain spaces or "/"`). Users
178 * commonly run `qodex provider add https://api.example.com/v1`, which would
179 * otherwise store the whole URL as the name and get silently dropped at load.
180 * We reduce a URL to its host and slugify: `https://api.203668.xyz/v1` → `api-203668-xyz`.

Callers 3

interactiveAddProviderFunction · 0.85
buildCustomEntryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected