mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-07-24 12:44:18 +08:00
feat(presets): add ClaudeCN provider presets
Add ClaudeCN as a new partner provider with support for: - Claude Code preset (Anthropic native protocol) - Codex preset (gpt-5.5 model) - Claude Desktop preset (direct mode with passthrough routes) - OpenCode preset (@ai-sdk/anthropic) - OpenClaw preset (anthropic-messages protocol) - Hermes preset (anthropic_messages mode) - Icon configuration (claudecn.png) - i18n support (zh/en/ja) with enterprise service promotion ClaudeCN is an enterprise-grade AI gateway operated by a registered company, supporting enterprise procurement processes with corporate payments, contracts, and compliance guarantees.
This commit is contained in:
@@ -529,6 +529,19 @@ export const claudeDesktopProviderPresets: ClaudeDesktopProviderPreset[] = [
|
||||
partnerPromotionKey: "claudeapi",
|
||||
icon: "claudeapi",
|
||||
},
|
||||
{
|
||||
name: "ClaudeCN",
|
||||
websiteUrl: "https://claudecn.top",
|
||||
apiKeyUrl: "https://claudecn.top/register?aff=ccswitch",
|
||||
category: "third_party",
|
||||
baseUrl: "https://claudecn.top",
|
||||
mode: "direct",
|
||||
apiFormat: "anthropic",
|
||||
modelRoutes: passthroughRoutes(),
|
||||
isPartner: true,
|
||||
partnerPromotionKey: "claudecn",
|
||||
icon: "claudecn",
|
||||
},
|
||||
{
|
||||
name: "Cubence",
|
||||
websiteUrl: "https://cubence.com",
|
||||
|
||||
@@ -570,6 +570,21 @@ export const providerPresets: ProviderPreset[] = [
|
||||
partnerPromotionKey: "claudeapi",
|
||||
icon: "claudeapi",
|
||||
},
|
||||
{
|
||||
name: "ClaudeCN",
|
||||
websiteUrl: "https://claudecn.top",
|
||||
apiKeyUrl: "https://claudecn.top/register?aff=ccswitch",
|
||||
settingsConfig: {
|
||||
env: {
|
||||
ANTHROPIC_BASE_URL: "https://claudecn.top",
|
||||
ANTHROPIC_AUTH_TOKEN: "",
|
||||
},
|
||||
},
|
||||
category: "third_party",
|
||||
isPartner: true,
|
||||
partnerPromotionKey: "claudecn",
|
||||
icon: "claudecn",
|
||||
},
|
||||
{
|
||||
name: "Cubence",
|
||||
websiteUrl: "https://cubence.com",
|
||||
|
||||
@@ -186,6 +186,21 @@ requires_openai_auth = true`,
|
||||
partnerPromotionKey: "patewayai",
|
||||
icon: "pateway",
|
||||
},
|
||||
{
|
||||
name: "ClaudeCN",
|
||||
websiteUrl: "https://claudecn.top",
|
||||
apiKeyUrl: "https://claudecn.top/register?aff=ccswitch",
|
||||
category: "third_party",
|
||||
auth: generateThirdPartyAuth(""),
|
||||
config: generateThirdPartyConfig(
|
||||
"claudecn",
|
||||
"https://claudecn.top/v1",
|
||||
"gpt-5.5",
|
||||
),
|
||||
isPartner: true,
|
||||
partnerPromotionKey: "claudecn",
|
||||
icon: "claudecn",
|
||||
},
|
||||
{
|
||||
name: "Cubence",
|
||||
websiteUrl: "https://cubence.com",
|
||||
|
||||
@@ -706,6 +706,36 @@ export const hermesProviderPresets: HermesProviderPreset[] = [
|
||||
model: { default: "claude-opus-4-7", provider: "cubence" },
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "ClaudeCN",
|
||||
websiteUrl: "https://claudecn.top",
|
||||
apiKeyUrl: "https://claudecn.top/register?aff=ccswitch",
|
||||
settingsConfig: {
|
||||
name: "claudecn",
|
||||
base_url: "https://claudecn.top",
|
||||
api_key: "",
|
||||
api_mode: "anthropic_messages",
|
||||
models: [
|
||||
{ id: "claude-opus-4-7", name: "Claude Opus 4.7" },
|
||||
{ id: "claude-sonnet-4-6", name: "Claude Sonnet 4.6" },
|
||||
{ id: "claude-haiku-4-5", name: "Claude Haiku 4.5" },
|
||||
],
|
||||
},
|
||||
category: "third_party",
|
||||
isPartner: true,
|
||||
partnerPromotionKey: "claudecn",
|
||||
icon: "claudecn",
|
||||
templateValues: {
|
||||
apiKey: {
|
||||
label: "API Key",
|
||||
placeholder: "",
|
||||
editorValue: "",
|
||||
},
|
||||
},
|
||||
suggestedDefaults: {
|
||||
model: { default: "claude-sonnet-4-6", provider: "claudecn" },
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "AIGoCode",
|
||||
websiteUrl: "https://aigocode.com",
|
||||
|
||||
@@ -774,6 +774,54 @@ export const openclawProviderPresets: OpenClawProviderPreset[] = [
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "ClaudeCN",
|
||||
websiteUrl: "https://claudecn.top",
|
||||
apiKeyUrl: "https://claudecn.top/register?aff=ccswitch",
|
||||
settingsConfig: {
|
||||
baseUrl: "https://claudecn.top",
|
||||
apiKey: "",
|
||||
api: "anthropic-messages",
|
||||
models: [
|
||||
{
|
||||
id: "claude-opus-4-7",
|
||||
name: "Claude Opus 4.7",
|
||||
contextWindow: 1000000,
|
||||
},
|
||||
{
|
||||
id: "claude-sonnet-4-6",
|
||||
name: "Claude Sonnet 4.6",
|
||||
contextWindow: 1000000,
|
||||
},
|
||||
{
|
||||
id: "claude-haiku-4-5",
|
||||
name: "Claude Haiku 4.5",
|
||||
contextWindow: 200000,
|
||||
},
|
||||
],
|
||||
},
|
||||
category: "third_party",
|
||||
isPartner: true,
|
||||
partnerPromotionKey: "claudecn",
|
||||
icon: "claudecn",
|
||||
templateValues: {
|
||||
apiKey: {
|
||||
label: "API Key",
|
||||
placeholder: "",
|
||||
editorValue: "",
|
||||
},
|
||||
},
|
||||
suggestedDefaults: {
|
||||
model: {
|
||||
primary: "claudecn/claude-sonnet-4-6",
|
||||
},
|
||||
modelCatalog: {
|
||||
"claudecn/claude-opus-4-7": { alias: "Opus" },
|
||||
"claudecn/claude-sonnet-4-6": { alias: "Sonnet" },
|
||||
"claudecn/claude-haiku-4-5": { alias: "Haiku" },
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "OpenRouter",
|
||||
websiteUrl: "https://openrouter.ai",
|
||||
|
||||
@@ -1210,6 +1210,36 @@ export const opencodeProviderPresets: OpenCodeProviderPreset[] = [
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "ClaudeCN",
|
||||
websiteUrl: "https://claudecn.top",
|
||||
apiKeyUrl: "https://claudecn.top/register?aff=ccswitch",
|
||||
settingsConfig: {
|
||||
npm: "@ai-sdk/anthropic",
|
||||
name: "ClaudeCN",
|
||||
options: {
|
||||
baseURL: "https://claudecn.top",
|
||||
apiKey: "",
|
||||
setCacheKey: true,
|
||||
},
|
||||
models: {
|
||||
"claude-sonnet-4-6": { name: "Claude Sonnet 4.6" },
|
||||
"claude-opus-4-7": { name: "Claude Opus 4.7" },
|
||||
"claude-haiku-4-5": { name: "Claude Haiku 4.5" },
|
||||
},
|
||||
},
|
||||
category: "third_party",
|
||||
isPartner: true,
|
||||
partnerPromotionKey: "claudecn",
|
||||
icon: "claudecn",
|
||||
templateValues: {
|
||||
apiKey: {
|
||||
label: "API Key",
|
||||
placeholder: "",
|
||||
editorValue: "",
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "AICoding",
|
||||
websiteUrl: "https://aicoding.sh",
|
||||
|
||||
@@ -837,6 +837,7 @@
|
||||
"packycode": "PackyCode is an official partner of CC Switch. Register using this link and enter \"cc-switch\" promo code during recharge to get 10% off",
|
||||
"patewayai": "PatewayAI offers special benefits for CC Switch users. Register via this link to receive $3 credit.",
|
||||
"claudeapi": "ClaudeAPI offers special benefits for CC Switch users. Register via this link to claim test credits.",
|
||||
"claudecn": "ClaudeCN is an enterprise-grade AI gateway operated by a registered company, supporting enterprise procurement processes with corporate payments, contracts, and compliance guarantees.",
|
||||
"minimax_cn": "MiniMax Coding Plan Special Offer, Starter from ¥9.9",
|
||||
"minimax_en": "MiniMax Coding Plan Black Friday, Starter is now $2/mo (80% OFF!)",
|
||||
"dmxapi": "Claude Code exclusive model 66% OFF now!",
|
||||
|
||||
@@ -837,6 +837,7 @@
|
||||
"packycode": "PackyCode は CC Switch の公式パートナーです。登録後チャージ時に \"cc-switch\" を入力すると 10% オフ",
|
||||
"patewayai": "PatewayAI は CC Switch ユーザーに特別な特典を提供しています。このリンクから登録すると $3 のクレジットがもらえます。",
|
||||
"claudeapi": "ClaudeAPI は CC Switch ユーザーに特別な特典を提供しています。このリンクから登録するとテストクレジットを受け取ることができます。",
|
||||
"claudecn": "ClaudeCN は登録企業が運営するエンタープライズグレードの AI ゲートウェイプラットフォームで、企業調達プロセスをサポートし、法人支払い、契約、コンプライアンス保証を提供します。",
|
||||
"minimax_cn": "MiniMax Coding Plan 特別価格、Starter ¥9.9 から",
|
||||
"minimax_en": "MiniMax Coding Plan Black Friday、Starter が月額 $2(80% OFF)",
|
||||
"dmxapi": "Claude Code 専用モデル 66% OFF 実施中!",
|
||||
|
||||
@@ -837,6 +837,7 @@
|
||||
"packycode": "PackyCode 是 CC Switch 的官方合作伙伴,使用此链接注册并在充值时填写 \"cc-switch\" 优惠码,可以享受9折优惠",
|
||||
"patewayai": "PatewayAI 为 CC Switch 的用户提供了特别福利,通过此链接注册可以获得3美元额度。",
|
||||
"claudeapi": "ClaudeAPI 为 CC Switch 的用户提供了特别福利,通过此链接注册可以领取测试额度。",
|
||||
"claudecn": "ClaudeCN 是一家实体企业运营的企业级AI中转平台,支持企业采购流程,可对公打款、签约,服务合规有保障。",
|
||||
"minimax_cn": "MiniMax Coding Plan 特惠,Starter 套餐 9.9 元起",
|
||||
"minimax_en": "MiniMax Coding Plan 黑五特惠,Starter 套餐现仅 $2/月(2折优惠!)",
|
||||
"dmxapi": "Claude Code 专属模型 3.4 折优惠进行中!",
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
// Do not edit manually
|
||||
|
||||
import _claudeapi from "./ClaudeApi.png";
|
||||
import _claudecn from "./claudecn.png";
|
||||
import _eflowcode from "./eflowcode.png";
|
||||
import _hermes from "./hermes.png";
|
||||
import _lemondata from "./lemondata.png";
|
||||
@@ -83,6 +84,7 @@ export const icons: Record<string, string> = {
|
||||
|
||||
export const iconUrls: Record<string, string> = {
|
||||
claudeapi: _claudeapi,
|
||||
claudecn: _claudecn,
|
||||
eflowcode: _eflowcode,
|
||||
hermes: _hermes,
|
||||
lemondata: _lemondata,
|
||||
|
||||
@@ -78,6 +78,12 @@ export const iconMetadata: Record<string, IconMetadata> = {
|
||||
category: "ai-provider",
|
||||
keywords: ["claudeapi", "claude", "anthropic", "bedrock"],
|
||||
},
|
||||
claudecn: {
|
||||
name: "claudecn",
|
||||
displayName: "ClaudeCN",
|
||||
category: "ai-provider",
|
||||
keywords: ["claudecn", "claude", "enterprise"],
|
||||
},
|
||||
cloudflare: {
|
||||
name: "cloudflare",
|
||||
displayName: "Cloudflare",
|
||||
|
||||
Reference in New Issue
Block a user