@omnicross/contracts 0.3.1 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -42,19 +42,56 @@ var ANTHROPIC_MODELS = {
42
42
  "claude-opus-4-6[1m]": { category: "reasoning", contextLength: 1e6, maxTokens: 128e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high", "xhigh", "max"], thinkingTokenLimit: { min: 1024, max: 128e3 } },
43
43
  "claude-sonnet-4-6": { category: "chat", contextLength: 2e5, maxTokens: 64e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high", "xhigh", "max"], thinkingTokenLimit: { min: 1024, max: 64e3 } },
44
44
  "claude-sonnet-4-6[1m]": { category: "chat", contextLength: 1e6, maxTokens: 64e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high", "xhigh", "max"], thinkingTokenLimit: { min: 1024, max: 64e3 } },
45
- "claude-haiku-4-5": { category: "chat", contextLength: 2e5, maxTokens: 64e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high", "xhigh", "max"], thinkingTokenLimit: { min: 1024, max: 64e3 } }
45
+ "claude-haiku-4-5": { category: "chat", contextLength: 2e5, maxTokens: 64e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high", "xhigh", "max"], thinkingTokenLimit: { min: 1024, max: 64e3 } },
46
+ // Copilot-served variants (same model family on the Copilot API; context
47
+ // windows per the Copilot catalog where it diverges from the family default).
48
+ "claude-opus-4-5": { category: "reasoning", contextLength: 2e5, maxTokens: 128e3, vision: true, functionCall: true, reasoning: true },
49
+ "claude-sonnet-4-5": { category: "chat", contextLength: 2e5, maxTokens: 64e3, vision: true, functionCall: true, reasoning: true },
50
+ "claude-sonnet-4": { category: "chat", contextLength: 216e3, maxTokens: 64e3, vision: true, functionCall: true, reasoning: true }
46
51
  };
47
52
  var GEMINI_MODELS = {
48
53
  "gemini-3.5-flash": { category: "chat", contextLength: 1e6, maxTokens: 65536, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 24576 } },
49
54
  "gemini-3-flash": { category: "chat", contextLength: 1e6, maxTokens: 65536, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 24576 } },
50
- "gemini-3.1-pro": { category: "chat", contextLength: 1e6, maxTokens: 65536, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["low", "medium", "high"], thinkingTokenLimit: { min: 128, max: 32768 } }
55
+ "gemini-3.1-pro": { category: "chat", contextLength: 1e6, maxTokens: 65536, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["low", "medium", "high"], thinkingTokenLimit: { min: 128, max: 32768 } },
56
+ // Copilot-served variants (chat-completions wire on the Copilot API).
57
+ "gemini-3.1-pro-preview": { category: "chat", contextLength: 1e6, maxTokens: 65536, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["low", "medium", "high"] },
58
+ "gemini-3.6-flash": { category: "chat", contextLength: 1e6, maxTokens: 65536, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"] },
59
+ "gemini-3.7-flash": { category: "chat", contextLength: 1e6, maxTokens: 65536, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"] },
60
+ "gemini-3-pro-preview": { category: "chat", contextLength: 128e3, maxTokens: 65536, vision: true, functionCall: true, reasoning: true },
61
+ "gemini-3-flash-preview": { category: "chat", contextLength: 128e3, maxTokens: 65536, vision: true, functionCall: true, reasoning: true },
62
+ "gemini-2.5-pro": { category: "chat", contextLength: 128e3, maxTokens: 65536, vision: true, functionCall: true, reasoning: true }
51
63
  };
52
64
  var GROK_MODELS = {
53
65
  "grok-4.5": { category: "chat", contextLength: 5e5, maxTokens: 32768, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 32768 } },
54
66
  "grok-4.3": { category: "chat", contextLength: 1e6, maxTokens: 32768, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 32768 } },
55
67
  "grok-4.20": { category: "chat", contextLength: 131072, maxTokens: 32768, vision: true, functionCall: true },
56
68
  "grok-4.20-reasoning": { category: "reasoning", contextLength: 131072, maxTokens: 32768, reasoning: true, vision: true, functionCall: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 32768 } },
57
- "grok-4.20-multi-agent": { category: "reasoning", contextLength: 131072, maxTokens: 32768, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 32768 } }
69
+ "grok-4.20-multi-agent": { category: "reasoning", contextLength: 131072, maxTokens: 32768, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 32768 } },
70
+ // SuperGrok subscription ids (Responses wire). Upstream context/output caps
71
+ // per the audit source; the effort-taking models accept low/medium/high only
72
+ // (minimal→low, xhigh/max→high), and the omit-effort models carry
73
+ // `thinkingLevels: ['none']` so the effort negotiation drops the
74
+ // `reasoning.effort` field entirely (sending it upstream is a 400).
75
+ "grok-4.6": { category: "chat", contextLength: 5e5, maxTokens: 5e5, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 32768 } },
76
+ "grok-4.20-0309-non-reasoning": { category: "chat", contextLength: 2e6, maxTokens: 2e6, vision: true, functionCall: true, thinkingLevels: ["none"] },
77
+ "grok-4.20-0309-reasoning": { category: "reasoning", contextLength: 2e6, maxTokens: 2e6, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none"] },
78
+ "grok-4.20-multi-agent-0309": { category: "reasoning", contextLength: 2e6, maxTokens: 2e6, functionCall: true, reasoning: true, thinkingLevels: ["low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 32768 } },
79
+ "grok-build": { category: "reasoning", contextLength: 512e3, maxTokens: 512e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none"] },
80
+ "grok-build-0.1": { category: "reasoning", contextLength: 256e3, maxTokens: 256e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none"] },
81
+ "grok-composer-2.5-fast": { category: "chat", contextLength: 2e5, maxTokens: 2e5, functionCall: true, thinkingLevels: ["none"] }
82
+ };
83
+ var COPILOT_MODELS = {
84
+ "gpt-5.1-codex-max": { category: "code", contextLength: 272e3, maxTokens: 128e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 128e3 } },
85
+ "gpt-5.1-codex-mini": { category: "code", contextLength: 272e3, maxTokens: 128e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["medium", "high"], thinkingTokenLimit: { min: 0, max: 128e3 } },
86
+ "gpt-5.2-codex": { category: "code", contextLength: 272e3, maxTokens: 128e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 128e3 } },
87
+ "gpt-5.1-codex": { category: "code", contextLength: 272e3, maxTokens: 128e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 128e3 } },
88
+ "gpt-5.1": { category: "reasoning", contextLength: 264e3, maxTokens: 128e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 128e3 } },
89
+ "gpt-5-mini": { category: "reasoning", contextLength: 264e3, maxTokens: 128e3, vision: true, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 128e3 } },
90
+ "gpt-5.4-nano": { category: "reasoning", contextLength: 4e5, maxTokens: 128e3, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"], thinkingTokenLimit: { min: 0, max: 128e3 } },
91
+ "grok-code-fast-1": { category: "code", contextLength: 192e3, maxTokens: 32768, functionCall: true, reasoning: true },
92
+ "raptor-mini": { category: "reasoning", contextLength: 4e5, maxTokens: 65536, functionCall: true, reasoning: true, vision: true },
93
+ "mai-code-1-flash-picker": { category: "code", contextLength: 256e3, maxTokens: 65536, functionCall: true, reasoning: true, thinkingLevels: ["none", "low", "medium", "high"] },
94
+ "mai-code-1.1-flash": { category: "code", contextLength: 256e3, maxTokens: 65536, functionCall: true, reasoning: true, vision: true, thinkingLevels: ["none", "low", "medium", "high"] }
58
95
  };
59
96
  var DEEPSEEK_MODELS = {
60
97
  "deepseek-v4-flash": { category: "chat", contextLength: 1e6, maxTokens: 384e3, functionCall: true, reasoning: true, thinkingLevels: ["none", "high", "max"], thinkingTokenLimit: { min: 0, max: 32768 } },
@@ -150,6 +187,7 @@ var VENDOR_GROUPS = [
150
187
  { name: "ANTHROPIC_MODELS", entries: ANTHROPIC_MODELS },
151
188
  { name: "GEMINI_MODELS", entries: GEMINI_MODELS },
152
189
  { name: "GROK_MODELS", entries: GROK_MODELS },
190
+ { name: "COPILOT_MODELS", entries: COPILOT_MODELS },
153
191
  { name: "DEEPSEEK_MODELS", entries: DEEPSEEK_MODELS },
154
192
  { name: "ZHIPU_MODELS", entries: ZHIPU_MODELS },
155
193
  { name: "KIMI_MODELS", entries: KIMI_MODELS },
@@ -819,6 +857,72 @@ var cerebras_default = {
819
857
  features: []
820
858
  };
821
859
 
860
+ // src/provider-presets/presets/cline-pass.json
861
+ var cline_pass_default = {
862
+ id: "cline-pass",
863
+ presetId: "cline-pass",
864
+ name: "Cline",
865
+ apiFormat: "openai",
866
+ api_base_url: "https://api.cline.bot/api/v1",
867
+ extraHeaders: {
868
+ "HTTP-Referer": "https://cline.bot",
869
+ "X-Title": "Cline",
870
+ "X-IS-MULTIROOT": "false",
871
+ "X-CLIENT-TYPE": "cline-sdk",
872
+ "User-Agent": "Cline/3.0.58",
873
+ "X-CLIENT-VERSION": "3.0.58",
874
+ "X-PLATFORM": "{{platform}}",
875
+ "X-PLATFORM-VERSION": "3.0.54",
876
+ "X-CORE-VERSION": "0.0.79"
877
+ },
878
+ models: [
879
+ "cline-pass/kimi-k3",
880
+ "cline-pass/glm-5.3",
881
+ "cline-pass/glm-5.3-flash",
882
+ "cline-pass/glm-5.2",
883
+ "cline-pass/deepseek-v4-pro",
884
+ "cline-pass/deepseek-v4-flash",
885
+ "cline-pass/qwen3.8-max",
886
+ "cline-pass/qwen3.7-max",
887
+ "cline-pass/qwen3.7-plus",
888
+ "cline-pass/kimi-k2.7-code",
889
+ "cline-pass/kimi-k2.6",
890
+ "cline-pass/minimax-m3",
891
+ "cline-pass/mimo-v2.5-pro",
892
+ "cline-pass/mimo-v2.5",
893
+ "cline-free/longcat-2.0",
894
+ "deepseek/deepseek-v4-flash",
895
+ "z-ai/glm-5.3-flash",
896
+ "poolside/laguna-s-2.1:free"
897
+ ],
898
+ modelConfigs: [
899
+ { id: "cline-pass/kimi-k3", name: "Kimi K3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true, vision: true },
900
+ { id: "cline-pass/glm-5.3", name: "GLM-5.3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
901
+ { id: "cline-pass/glm-5.3-flash", name: "GLM-5.3 Flash", enabled: true, category: "code", contextLength: 1310720, functionCall: true, reasoning: true, vision: true },
902
+ { id: "cline-pass/glm-5.2", name: "GLM-5.2", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
903
+ { id: "cline-pass/deepseek-v4-pro", name: "DeepSeek V4 Pro", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
904
+ { id: "cline-pass/deepseek-v4-flash", name: "DeepSeek V4 Flash", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
905
+ { id: "cline-pass/qwen3.8-max", name: "Qwen3.8 Max", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true, vision: true },
906
+ { id: "cline-pass/qwen3.7-max", name: "Qwen3.7 Max", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true },
907
+ { id: "cline-pass/qwen3.7-plus", name: "Qwen3.7 Plus", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true, vision: true },
908
+ { id: "cline-pass/kimi-k2.7-code", name: "Kimi K2.7 Code", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true, vision: true },
909
+ { id: "cline-pass/kimi-k2.6", name: "Kimi K2.6", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true, vision: true },
910
+ { id: "cline-pass/minimax-m3", name: "MiniMax M3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true, vision: true },
911
+ { id: "cline-pass/mimo-v2.5-pro", name: "MiMo V2.5 Pro", enabled: true, category: "code", contextLength: 105e4, functionCall: true, reasoning: true },
912
+ { id: "cline-pass/mimo-v2.5", name: "MiMo V2.5", enabled: true, category: "code", contextLength: 105e4, functionCall: true, reasoning: true, vision: true },
913
+ { id: "cline-free/longcat-2.0", name: "LongCat 2.0 (free)", enabled: true, category: "code", contextLength: 1048756, functionCall: true, reasoning: true },
914
+ { id: "deepseek/deepseek-v4-flash", name: "DeepSeek V4 Flash (free)", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
915
+ { id: "z-ai/glm-5.3-flash", name: "GLM-5.3 Flash (free)", enabled: true, category: "code", contextLength: 1310720, functionCall: true, reasoning: true, vision: true },
916
+ { id: "poolside/laguna-s-2.1:free", name: "Laguna S 2.1 (free)", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true }
917
+ ],
918
+ description: "Cline \u8BA2\u9605\u901A\u884C\u8BC1\uFF08OpenAI \u517C\u5BB9\u7AEF\u70B9\uFF0C\u542B\u514D\u8D39\u6863\u6A21\u578B\uFF1B\u5728 Cline \u63A7\u5236\u53F0 Settings \u2192 API Keys \u521B\u5EFA\u5BC6\u94A5\uFF09\u3002\u8BF7\u6C42\u81EA\u52A8\u643A\u5E26 Cline \u5BA2\u6237\u7AEF\u8EAB\u4EFD\u5934\uFF08\u786C\u6027\u5951\u7EA6\uFF0C\u7F3A\u5931\u4F1A\u88AB 403\uFF09\uFF1B\u5BC6\u94A5\u7684 5 \u5C0F\u65F6/\u6BCF\u5468/\u6BCF\u6708\u7528\u91CF\u4F1A\u81EA\u52A8\u663E\u793A\u5728\u5BC6\u94A5\u5217\u8868\u3002",
919
+ icon: "cline",
920
+ website: "https://cline.bot",
921
+ docsUrl: "https://app.cline.bot/dashboard/account",
922
+ isSystem: true,
923
+ features: ["coding-plan"]
924
+ };
925
+
822
926
  // src/provider-presets/presets/dashscope.json
823
927
  var dashscope_default = {
824
928
  id: "dashscope",
@@ -2503,6 +2607,7 @@ var RAW_PRESETS_IN_ORDER = [
2503
2607
  perplexity_default,
2504
2608
  synthetic_default,
2505
2609
  umans_default,
2610
+ cline_pass_default,
2506
2611
  // Chinese cloud
2507
2612
  zhipu_default,
2508
2613
  zhipu_bigmodel_default,
@@ -2594,6 +2699,7 @@ var presetSchema = z.object({
2594
2699
  maxConcurrency: z.number().optional(),
2595
2700
  codingPlanBaseUrl: z.string().optional(),
2596
2701
  codingPlanSeparateKey: z.boolean().optional(),
2702
+ extraHeaders: z.record(z.string(), z.string()).optional(),
2597
2703
  features: z.array(z.string()).optional(),
2598
2704
  searchConfig: providerSearchConfigSchema.optional(),
2599
2705
  apiModes: z.array(apiModeSchema).optional(),
@@ -2819,7 +2925,72 @@ var SUBSCRIPTION_MODEL_CATALOG = {
2819
2925
  opencodego: [],
2820
2926
  // Kimi Code's subscription catalog (the official CLI's built-ins + the
2821
2927
  // k2.6/k2.7-code coding models, small → large).
2822
- kimi: ["kimi-k2.5", "kimi-k2.6", "kimi-k2.7-code", "kimi-k3", "kimi-for-coding", "kimi-for-coding-highspeed"]
2928
+ kimi: ["kimi-k2.5", "kimi-k2.6", "kimi-k2.7-code", "kimi-k3", "kimi-for-coding", "kimi-for-coding-highspeed"],
2929
+ // SuperGrok's Responses-wire catalog (verified ids from the audit source,
2930
+ // small → large; the grok-build / composer models are plan-gated products).
2931
+ grok: [
2932
+ "grok-composer-2.5-fast",
2933
+ "grok-build-0.1",
2934
+ "grok-build",
2935
+ "grok-4.5",
2936
+ "grok-4.6",
2937
+ "grok-4.3",
2938
+ "grok-4.20-0309-non-reasoning",
2939
+ "grok-4.20-0309-reasoning",
2940
+ "grok-4.20-multi-agent-0309"
2941
+ ],
2942
+ // GitHub Copilot's mixed-wire catalog (verified ids from the audit source,
2943
+ // grouped by wire then small → large). The per-model wire each id rides is
2944
+ // mapped in `@omnicross/subscriptions`' copilot module (this list only feeds
2945
+ // the picker).
2946
+ copilot: [
2947
+ // anthropic-messages face (Claude family)
2948
+ "claude-haiku-4.5",
2949
+ "claude-sonnet-4.5",
2950
+ "claude-sonnet-4.6",
2951
+ "claude-opus-4.5",
2952
+ "claude-opus-4.6",
2953
+ "claude-opus-4.7",
2954
+ "claude-opus-4.8",
2955
+ "claude-sonnet-5",
2956
+ "claude-opus-5",
2957
+ "claude-fable-5",
2958
+ // openai-chat face
2959
+ "gpt-4o",
2960
+ "gpt-4.1",
2961
+ "grok-code-fast-1",
2962
+ "gemini-2.5-pro",
2963
+ "gemini-3.5-flash",
2964
+ "gemini-3-flash-preview",
2965
+ "gemini-3-pro-preview",
2966
+ "gemini-3.6-flash",
2967
+ "gemini-3.7-flash",
2968
+ "gemini-3.1-pro-preview",
2969
+ "raptor-mini",
2970
+ "kimi-k2.7-code",
2971
+ "kimi-k3",
2972
+ // openai-responses face
2973
+ "mai-code-1-flash-picker",
2974
+ "mai-code-1.1-flash",
2975
+ "gpt-5-mini",
2976
+ "gpt-5.1",
2977
+ "gpt-5.1-codex-mini",
2978
+ "gpt-5.1-codex",
2979
+ "gpt-5.1-codex-max",
2980
+ "gpt-5",
2981
+ "gpt-5.2",
2982
+ "gpt-5.2-codex",
2983
+ "gpt-5.3-codex",
2984
+ "gpt-5.4-mini",
2985
+ "gpt-5.4-nano",
2986
+ "gpt-5.4",
2987
+ "gpt-5.5",
2988
+ "gpt-5.6-luna",
2989
+ "gpt-5.6-terra",
2990
+ "gpt-5.6-sol",
2991
+ "grok-4.5",
2992
+ "grok-4.6"
2993
+ ]
2823
2994
  };
2824
2995
  function subscriptionProviderHasCatalog(providerId) {
2825
2996
  return SUBSCRIPTION_MODEL_CATALOG[providerId].length > 0;
@@ -123,6 +123,14 @@ interface PresetProviderTemplate extends ProviderTemplate {
123
123
  codingPlanBaseUrl?: string;
124
124
  /** Whether Coding Plan requires a separate API Key */
125
125
  codingPlanSeparateKey?: boolean;
126
+ /**
127
+ * Static extra request headers seeded onto every provider row created from
128
+ * this preset and merged into every BYO request (identity/attribution
129
+ * contracts some gateways gate on). Values may carry `{{platform}}`,
130
+ * resolved to `process.platform` at request time. Auth headers are rejected
131
+ * by the config-layer guard (credentials come only from the key fields).
132
+ */
133
+ extraHeaders?: Record<string, string>;
126
134
  /** Feature tags for display */
127
135
  features?: string[];
128
136
  /** Search capability configuration for this provider */
@@ -294,6 +302,16 @@ interface LLMProvider {
294
302
  * `UseBearer` transformer option independently).
295
303
  */
296
304
  useBearer?: boolean;
305
+ /**
306
+ * Static extra request headers merged into EVERY request for this provider
307
+ * (identity/attribution contracts some gateways gate on — e.g. the Cline
308
+ * client-identity set). Values may carry the `{{platform}}` placeholder,
309
+ * resolved to `process.platform` at request time. Auth headers
310
+ * (`Authorization` / `x-api-key` / `x-goog-api-key` / `api-key` / `cookie`)
311
+ * and `Content-Type`/`Content-Length` are rejected at the config layer —
312
+ * credentials come only from the key fields.
313
+ */
314
+ extraHeaders?: Record<string, string>;
297
315
  transformer?: TransformerConfig;
298
316
  rerouterEnabled?: boolean;
299
317
  icon?: string;
@@ -123,6 +123,14 @@ interface PresetProviderTemplate extends ProviderTemplate {
123
123
  codingPlanBaseUrl?: string;
124
124
  /** Whether Coding Plan requires a separate API Key */
125
125
  codingPlanSeparateKey?: boolean;
126
+ /**
127
+ * Static extra request headers seeded onto every provider row created from
128
+ * this preset and merged into every BYO request (identity/attribution
129
+ * contracts some gateways gate on). Values may carry `{{platform}}`,
130
+ * resolved to `process.platform` at request time. Auth headers are rejected
131
+ * by the config-layer guard (credentials come only from the key fields).
132
+ */
133
+ extraHeaders?: Record<string, string>;
126
134
  /** Feature tags for display */
127
135
  features?: string[];
128
136
  /** Search capability configuration for this provider */
@@ -294,6 +302,16 @@ interface LLMProvider {
294
302
  * `UseBearer` transformer option independently).
295
303
  */
296
304
  useBearer?: boolean;
305
+ /**
306
+ * Static extra request headers merged into EVERY request for this provider
307
+ * (identity/attribution contracts some gateways gate on — e.g. the Cline
308
+ * client-identity set). Values may carry the `{{platform}}` placeholder,
309
+ * resolved to `process.platform` at request time. Auth headers
310
+ * (`Authorization` / `x-api-key` / `x-goog-api-key` / `api-key` / `cookie`)
311
+ * and `Content-Type`/`Content-Length` are rejected at the config layer —
312
+ * credentials come only from the key fields.
313
+ */
314
+ extraHeaders?: Record<string, string>;
297
315
  transformer?: TransformerConfig;
298
316
  rerouterEnabled?: boolean;
299
317
  icon?: string;
@@ -1,2 +1,2 @@
1
1
  import './thinking-CBWSLel8.cjs';
2
- export { a as AgentDefaultModels, b as ApiFormat, c as ApiKeyEntry, C as ChatApiFormat, g as CompletionSettings, G as GlobalModelParameters, L as LLMProvider, M as ModelConfig, h as ModelGroup, i as ModelParameter, j as ModelRef, O as OpenRouterDataCollection, k as OpenRouterMaxPrice, l as OpenRouterProviderRouting, m as OpenRouterProviderSort, n as OpenRouterQuantization, o as ProviderApiType, r as ProviderTemplate, T as TransformerConfig, s as TransformerEntry } from './llm-config-DeWNx1ig.cjs';
2
+ export { a as AgentDefaultModels, b as ApiFormat, c as ApiKeyEntry, C as ChatApiFormat, g as CompletionSettings, G as GlobalModelParameters, L as LLMProvider, M as ModelConfig, h as ModelGroup, i as ModelParameter, j as ModelRef, O as OpenRouterDataCollection, k as OpenRouterMaxPrice, l as OpenRouterProviderRouting, m as OpenRouterProviderSort, n as OpenRouterQuantization, o as ProviderApiType, r as ProviderTemplate, T as TransformerConfig, s as TransformerEntry } from './llm-config-CEZvId7g.cjs';
@@ -1,2 +1,2 @@
1
1
  import './thinking-CBWSLel8.js';
2
- export { a as AgentDefaultModels, b as ApiFormat, c as ApiKeyEntry, C as ChatApiFormat, g as CompletionSettings, G as GlobalModelParameters, L as LLMProvider, M as ModelConfig, h as ModelGroup, i as ModelParameter, j as ModelRef, O as OpenRouterDataCollection, k as OpenRouterMaxPrice, l as OpenRouterProviderRouting, m as OpenRouterProviderSort, n as OpenRouterQuantization, o as ProviderApiType, r as ProviderTemplate, T as TransformerConfig, s as TransformerEntry } from './llm-config-CKOaFFdy.js';
2
+ export { a as AgentDefaultModels, b as ApiFormat, c as ApiKeyEntry, C as ChatApiFormat, g as CompletionSettings, G as GlobalModelParameters, L as LLMProvider, M as ModelConfig, h as ModelGroup, i as ModelParameter, j as ModelRef, O as OpenRouterDataCollection, k as OpenRouterMaxPrice, l as OpenRouterProviderRouting, m as OpenRouterProviderSort, n as OpenRouterQuantization, o as ProviderApiType, r as ProviderTemplate, T as TransformerConfig, s as TransformerEntry } from './llm-config-Dxw7F1_U.js';
@@ -512,6 +512,72 @@ var cerebras_default = {
512
512
  features: []
513
513
  };
514
514
 
515
+ // src/provider-presets/presets/cline-pass.json
516
+ var cline_pass_default = {
517
+ id: "cline-pass",
518
+ presetId: "cline-pass",
519
+ name: "Cline",
520
+ apiFormat: "openai",
521
+ api_base_url: "https://api.cline.bot/api/v1",
522
+ extraHeaders: {
523
+ "HTTP-Referer": "https://cline.bot",
524
+ "X-Title": "Cline",
525
+ "X-IS-MULTIROOT": "false",
526
+ "X-CLIENT-TYPE": "cline-sdk",
527
+ "User-Agent": "Cline/3.0.58",
528
+ "X-CLIENT-VERSION": "3.0.58",
529
+ "X-PLATFORM": "{{platform}}",
530
+ "X-PLATFORM-VERSION": "3.0.54",
531
+ "X-CORE-VERSION": "0.0.79"
532
+ },
533
+ models: [
534
+ "cline-pass/kimi-k3",
535
+ "cline-pass/glm-5.3",
536
+ "cline-pass/glm-5.3-flash",
537
+ "cline-pass/glm-5.2",
538
+ "cline-pass/deepseek-v4-pro",
539
+ "cline-pass/deepseek-v4-flash",
540
+ "cline-pass/qwen3.8-max",
541
+ "cline-pass/qwen3.7-max",
542
+ "cline-pass/qwen3.7-plus",
543
+ "cline-pass/kimi-k2.7-code",
544
+ "cline-pass/kimi-k2.6",
545
+ "cline-pass/minimax-m3",
546
+ "cline-pass/mimo-v2.5-pro",
547
+ "cline-pass/mimo-v2.5",
548
+ "cline-free/longcat-2.0",
549
+ "deepseek/deepseek-v4-flash",
550
+ "z-ai/glm-5.3-flash",
551
+ "poolside/laguna-s-2.1:free"
552
+ ],
553
+ modelConfigs: [
554
+ { id: "cline-pass/kimi-k3", name: "Kimi K3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true, vision: true },
555
+ { id: "cline-pass/glm-5.3", name: "GLM-5.3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
556
+ { id: "cline-pass/glm-5.3-flash", name: "GLM-5.3 Flash", enabled: true, category: "code", contextLength: 1310720, functionCall: true, reasoning: true, vision: true },
557
+ { id: "cline-pass/glm-5.2", name: "GLM-5.2", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
558
+ { id: "cline-pass/deepseek-v4-pro", name: "DeepSeek V4 Pro", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
559
+ { id: "cline-pass/deepseek-v4-flash", name: "DeepSeek V4 Flash", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
560
+ { id: "cline-pass/qwen3.8-max", name: "Qwen3.8 Max", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true, vision: true },
561
+ { id: "cline-pass/qwen3.7-max", name: "Qwen3.7 Max", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true },
562
+ { id: "cline-pass/qwen3.7-plus", name: "Qwen3.7 Plus", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true, vision: true },
563
+ { id: "cline-pass/kimi-k2.7-code", name: "Kimi K2.7 Code", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true, vision: true },
564
+ { id: "cline-pass/kimi-k2.6", name: "Kimi K2.6", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true, vision: true },
565
+ { id: "cline-pass/minimax-m3", name: "MiniMax M3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true, vision: true },
566
+ { id: "cline-pass/mimo-v2.5-pro", name: "MiMo V2.5 Pro", enabled: true, category: "code", contextLength: 105e4, functionCall: true, reasoning: true },
567
+ { id: "cline-pass/mimo-v2.5", name: "MiMo V2.5", enabled: true, category: "code", contextLength: 105e4, functionCall: true, reasoning: true, vision: true },
568
+ { id: "cline-free/longcat-2.0", name: "LongCat 2.0 (free)", enabled: true, category: "code", contextLength: 1048756, functionCall: true, reasoning: true },
569
+ { id: "deepseek/deepseek-v4-flash", name: "DeepSeek V4 Flash (free)", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
570
+ { id: "z-ai/glm-5.3-flash", name: "GLM-5.3 Flash (free)", enabled: true, category: "code", contextLength: 1310720, functionCall: true, reasoning: true, vision: true },
571
+ { id: "poolside/laguna-s-2.1:free", name: "Laguna S 2.1 (free)", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true }
572
+ ],
573
+ description: "Cline \u8BA2\u9605\u901A\u884C\u8BC1\uFF08OpenAI \u517C\u5BB9\u7AEF\u70B9\uFF0C\u542B\u514D\u8D39\u6863\u6A21\u578B\uFF1B\u5728 Cline \u63A7\u5236\u53F0 Settings \u2192 API Keys \u521B\u5EFA\u5BC6\u94A5\uFF09\u3002\u8BF7\u6C42\u81EA\u52A8\u643A\u5E26 Cline \u5BA2\u6237\u7AEF\u8EAB\u4EFD\u5934\uFF08\u786C\u6027\u5951\u7EA6\uFF0C\u7F3A\u5931\u4F1A\u88AB 403\uFF09\uFF1B\u5BC6\u94A5\u7684 5 \u5C0F\u65F6/\u6BCF\u5468/\u6BCF\u6708\u7528\u91CF\u4F1A\u81EA\u52A8\u663E\u793A\u5728\u5BC6\u94A5\u5217\u8868\u3002",
574
+ icon: "cline",
575
+ website: "https://cline.bot",
576
+ docsUrl: "https://app.cline.bot/dashboard/account",
577
+ isSystem: true,
578
+ features: ["coding-plan"]
579
+ };
580
+
515
581
  // src/provider-presets/presets/dashscope.json
516
582
  var dashscope_default = {
517
583
  id: "dashscope",
@@ -2196,6 +2262,7 @@ var RAW_PRESETS_IN_ORDER = [
2196
2262
  perplexity_default,
2197
2263
  synthetic_default,
2198
2264
  umans_default,
2265
+ cline_pass_default,
2199
2266
  // Chinese cloud
2200
2267
  zhipu_default,
2201
2268
  zhipu_bigmodel_default,
@@ -2287,6 +2354,7 @@ var presetSchema = import_zod.z.object({
2287
2354
  maxConcurrency: import_zod.z.number().optional(),
2288
2355
  codingPlanBaseUrl: import_zod.z.string().optional(),
2289
2356
  codingPlanSeparateKey: import_zod.z.boolean().optional(),
2357
+ extraHeaders: import_zod.z.record(import_zod.z.string(), import_zod.z.string()).optional(),
2290
2358
  features: import_zod.z.array(import_zod.z.string()).optional(),
2291
2359
  searchConfig: providerSearchConfigSchema.optional(),
2292
2360
  apiModes: import_zod.z.array(apiModeSchema).optional(),
@@ -1,5 +1,5 @@
1
- import { p as ProviderModelMapping, q as ProviderSearchConfig, P as PresetProviderTemplate } from '../llm-config-DeWNx1ig.cjs';
2
- export { A as API_MODE_IDS, d as ApiMode, e as ApiModeId, f as CodingPlanConfig, S as SearchCapability } from '../llm-config-DeWNx1ig.cjs';
1
+ import { p as ProviderModelMapping, q as ProviderSearchConfig, P as PresetProviderTemplate } from '../llm-config-CEZvId7g.cjs';
2
+ export { A as API_MODE_IDS, d as ApiMode, e as ApiModeId, f as CodingPlanConfig, S as SearchCapability } from '../llm-config-CEZvId7g.cjs';
3
3
  import '../thinking-CBWSLel8.cjs';
4
4
 
5
5
  /**
@@ -1,5 +1,5 @@
1
- import { p as ProviderModelMapping, q as ProviderSearchConfig, P as PresetProviderTemplate } from '../llm-config-CKOaFFdy.js';
2
- export { A as API_MODE_IDS, d as ApiMode, e as ApiModeId, f as CodingPlanConfig, S as SearchCapability } from '../llm-config-CKOaFFdy.js';
1
+ import { p as ProviderModelMapping, q as ProviderSearchConfig, P as PresetProviderTemplate } from '../llm-config-Dxw7F1_U.js';
2
+ export { A as API_MODE_IDS, d as ApiMode, e as ApiModeId, f as CodingPlanConfig, S as SearchCapability } from '../llm-config-Dxw7F1_U.js';
3
3
  import '../thinking-CBWSLel8.js';
4
4
 
5
5
  /**
@@ -473,6 +473,72 @@ var cerebras_default = {
473
473
  features: []
474
474
  };
475
475
 
476
+ // src/provider-presets/presets/cline-pass.json
477
+ var cline_pass_default = {
478
+ id: "cline-pass",
479
+ presetId: "cline-pass",
480
+ name: "Cline",
481
+ apiFormat: "openai",
482
+ api_base_url: "https://api.cline.bot/api/v1",
483
+ extraHeaders: {
484
+ "HTTP-Referer": "https://cline.bot",
485
+ "X-Title": "Cline",
486
+ "X-IS-MULTIROOT": "false",
487
+ "X-CLIENT-TYPE": "cline-sdk",
488
+ "User-Agent": "Cline/3.0.58",
489
+ "X-CLIENT-VERSION": "3.0.58",
490
+ "X-PLATFORM": "{{platform}}",
491
+ "X-PLATFORM-VERSION": "3.0.54",
492
+ "X-CORE-VERSION": "0.0.79"
493
+ },
494
+ models: [
495
+ "cline-pass/kimi-k3",
496
+ "cline-pass/glm-5.3",
497
+ "cline-pass/glm-5.3-flash",
498
+ "cline-pass/glm-5.2",
499
+ "cline-pass/deepseek-v4-pro",
500
+ "cline-pass/deepseek-v4-flash",
501
+ "cline-pass/qwen3.8-max",
502
+ "cline-pass/qwen3.7-max",
503
+ "cline-pass/qwen3.7-plus",
504
+ "cline-pass/kimi-k2.7-code",
505
+ "cline-pass/kimi-k2.6",
506
+ "cline-pass/minimax-m3",
507
+ "cline-pass/mimo-v2.5-pro",
508
+ "cline-pass/mimo-v2.5",
509
+ "cline-free/longcat-2.0",
510
+ "deepseek/deepseek-v4-flash",
511
+ "z-ai/glm-5.3-flash",
512
+ "poolside/laguna-s-2.1:free"
513
+ ],
514
+ modelConfigs: [
515
+ { id: "cline-pass/kimi-k3", name: "Kimi K3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true, vision: true },
516
+ { id: "cline-pass/glm-5.3", name: "GLM-5.3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
517
+ { id: "cline-pass/glm-5.3-flash", name: "GLM-5.3 Flash", enabled: true, category: "code", contextLength: 1310720, functionCall: true, reasoning: true, vision: true },
518
+ { id: "cline-pass/glm-5.2", name: "GLM-5.2", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
519
+ { id: "cline-pass/deepseek-v4-pro", name: "DeepSeek V4 Pro", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
520
+ { id: "cline-pass/deepseek-v4-flash", name: "DeepSeek V4 Flash", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
521
+ { id: "cline-pass/qwen3.8-max", name: "Qwen3.8 Max", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true, vision: true },
522
+ { id: "cline-pass/qwen3.7-max", name: "Qwen3.7 Max", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true },
523
+ { id: "cline-pass/qwen3.7-plus", name: "Qwen3.7 Plus", enabled: true, category: "code", contextLength: 1e6, functionCall: true, reasoning: true, vision: true },
524
+ { id: "cline-pass/kimi-k2.7-code", name: "Kimi K2.7 Code", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true, vision: true },
525
+ { id: "cline-pass/kimi-k2.6", name: "Kimi K2.6", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true, vision: true },
526
+ { id: "cline-pass/minimax-m3", name: "MiniMax M3", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true, vision: true },
527
+ { id: "cline-pass/mimo-v2.5-pro", name: "MiMo V2.5 Pro", enabled: true, category: "code", contextLength: 105e4, functionCall: true, reasoning: true },
528
+ { id: "cline-pass/mimo-v2.5", name: "MiMo V2.5", enabled: true, category: "code", contextLength: 105e4, functionCall: true, reasoning: true, vision: true },
529
+ { id: "cline-free/longcat-2.0", name: "LongCat 2.0 (free)", enabled: true, category: "code", contextLength: 1048756, functionCall: true, reasoning: true },
530
+ { id: "deepseek/deepseek-v4-flash", name: "DeepSeek V4 Flash (free)", enabled: true, category: "code", contextLength: 1048576, functionCall: true, reasoning: true },
531
+ { id: "z-ai/glm-5.3-flash", name: "GLM-5.3 Flash (free)", enabled: true, category: "code", contextLength: 1310720, functionCall: true, reasoning: true, vision: true },
532
+ { id: "poolside/laguna-s-2.1:free", name: "Laguna S 2.1 (free)", enabled: true, category: "code", contextLength: 262144, functionCall: true, reasoning: true }
533
+ ],
534
+ description: "Cline \u8BA2\u9605\u901A\u884C\u8BC1\uFF08OpenAI \u517C\u5BB9\u7AEF\u70B9\uFF0C\u542B\u514D\u8D39\u6863\u6A21\u578B\uFF1B\u5728 Cline \u63A7\u5236\u53F0 Settings \u2192 API Keys \u521B\u5EFA\u5BC6\u94A5\uFF09\u3002\u8BF7\u6C42\u81EA\u52A8\u643A\u5E26 Cline \u5BA2\u6237\u7AEF\u8EAB\u4EFD\u5934\uFF08\u786C\u6027\u5951\u7EA6\uFF0C\u7F3A\u5931\u4F1A\u88AB 403\uFF09\uFF1B\u5BC6\u94A5\u7684 5 \u5C0F\u65F6/\u6BCF\u5468/\u6BCF\u6708\u7528\u91CF\u4F1A\u81EA\u52A8\u663E\u793A\u5728\u5BC6\u94A5\u5217\u8868\u3002",
535
+ icon: "cline",
536
+ website: "https://cline.bot",
537
+ docsUrl: "https://app.cline.bot/dashboard/account",
538
+ isSystem: true,
539
+ features: ["coding-plan"]
540
+ };
541
+
476
542
  // src/provider-presets/presets/dashscope.json
477
543
  var dashscope_default = {
478
544
  id: "dashscope",
@@ -2157,6 +2223,7 @@ var RAW_PRESETS_IN_ORDER = [
2157
2223
  perplexity_default,
2158
2224
  synthetic_default,
2159
2225
  umans_default,
2226
+ cline_pass_default,
2160
2227
  // Chinese cloud
2161
2228
  zhipu_default,
2162
2229
  zhipu_bigmodel_default,
@@ -2248,6 +2315,7 @@ var presetSchema = z.object({
2248
2315
  maxConcurrency: z.number().optional(),
2249
2316
  codingPlanBaseUrl: z.string().optional(),
2250
2317
  codingPlanSeparateKey: z.boolean().optional(),
2318
+ extraHeaders: z.record(z.string(), z.string()).optional(),
2251
2319
  features: z.array(z.string()).optional(),
2252
2320
  searchConfig: providerSearchConfigSchema.optional(),
2253
2321
  apiModes: z.array(apiModeSchema).optional(),
@@ -31,7 +31,72 @@ var SUBSCRIPTION_MODEL_CATALOG = {
31
31
  opencodego: [],
32
32
  // Kimi Code's subscription catalog (the official CLI's built-ins + the
33
33
  // k2.6/k2.7-code coding models, small → large).
34
- kimi: ["kimi-k2.5", "kimi-k2.6", "kimi-k2.7-code", "kimi-k3", "kimi-for-coding", "kimi-for-coding-highspeed"]
34
+ kimi: ["kimi-k2.5", "kimi-k2.6", "kimi-k2.7-code", "kimi-k3", "kimi-for-coding", "kimi-for-coding-highspeed"],
35
+ // SuperGrok's Responses-wire catalog (verified ids from the audit source,
36
+ // small → large; the grok-build / composer models are plan-gated products).
37
+ grok: [
38
+ "grok-composer-2.5-fast",
39
+ "grok-build-0.1",
40
+ "grok-build",
41
+ "grok-4.5",
42
+ "grok-4.6",
43
+ "grok-4.3",
44
+ "grok-4.20-0309-non-reasoning",
45
+ "grok-4.20-0309-reasoning",
46
+ "grok-4.20-multi-agent-0309"
47
+ ],
48
+ // GitHub Copilot's mixed-wire catalog (verified ids from the audit source,
49
+ // grouped by wire then small → large). The per-model wire each id rides is
50
+ // mapped in `@omnicross/subscriptions`' copilot module (this list only feeds
51
+ // the picker).
52
+ copilot: [
53
+ // anthropic-messages face (Claude family)
54
+ "claude-haiku-4.5",
55
+ "claude-sonnet-4.5",
56
+ "claude-sonnet-4.6",
57
+ "claude-opus-4.5",
58
+ "claude-opus-4.6",
59
+ "claude-opus-4.7",
60
+ "claude-opus-4.8",
61
+ "claude-sonnet-5",
62
+ "claude-opus-5",
63
+ "claude-fable-5",
64
+ // openai-chat face
65
+ "gpt-4o",
66
+ "gpt-4.1",
67
+ "grok-code-fast-1",
68
+ "gemini-2.5-pro",
69
+ "gemini-3.5-flash",
70
+ "gemini-3-flash-preview",
71
+ "gemini-3-pro-preview",
72
+ "gemini-3.6-flash",
73
+ "gemini-3.7-flash",
74
+ "gemini-3.1-pro-preview",
75
+ "raptor-mini",
76
+ "kimi-k2.7-code",
77
+ "kimi-k3",
78
+ // openai-responses face
79
+ "mai-code-1-flash-picker",
80
+ "mai-code-1.1-flash",
81
+ "gpt-5-mini",
82
+ "gpt-5.1",
83
+ "gpt-5.1-codex-mini",
84
+ "gpt-5.1-codex",
85
+ "gpt-5.1-codex-max",
86
+ "gpt-5",
87
+ "gpt-5.2",
88
+ "gpt-5.2-codex",
89
+ "gpt-5.3-codex",
90
+ "gpt-5.4-mini",
91
+ "gpt-5.4-nano",
92
+ "gpt-5.4",
93
+ "gpt-5.5",
94
+ "gpt-5.6-luna",
95
+ "gpt-5.6-terra",
96
+ "gpt-5.6-sol",
97
+ "grok-4.5",
98
+ "grok-4.6"
99
+ ]
35
100
  };
36
101
  function subscriptionProviderHasCatalog(providerId) {
37
102
  return SUBSCRIPTION_MODEL_CATALOG[providerId].length > 0;