@kaitranntt/ccs 7.54.0-dev.1 → 7.54.0-dev.11
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/README.md +26 -4
- package/dist/ccs.js +70 -370
- package/dist/ccs.js.map +1 -1
- package/dist/commands/api-command/copy-command.d.ts +2 -0
- package/dist/commands/api-command/copy-command.d.ts.map +1 -0
- package/dist/commands/api-command/copy-command.js +41 -0
- package/dist/commands/api-command/copy-command.js.map +1 -0
- package/dist/commands/api-command/create-command.d.ts +2 -0
- package/dist/commands/api-command/create-command.d.ts.map +1 -0
- package/dist/commands/api-command/create-command.js +249 -0
- package/dist/commands/api-command/create-command.js.map +1 -0
- package/dist/commands/api-command/discover-command.d.ts +2 -0
- package/dist/commands/api-command/discover-command.d.ts.map +1 -0
- package/dist/commands/api-command/discover-command.js +69 -0
- package/dist/commands/api-command/discover-command.js.map +1 -0
- package/dist/commands/api-command/export-command.d.ts +2 -0
- package/dist/commands/api-command/export-command.d.ts.map +1 -0
- package/dist/commands/api-command/export-command.js +73 -0
- package/dist/commands/api-command/export-command.js.map +1 -0
- package/dist/commands/api-command/help.d.ts +3 -0
- package/dist/commands/api-command/help.d.ts.map +1 -0
- package/dist/commands/api-command/help.js +100 -0
- package/dist/commands/api-command/help.js.map +1 -0
- package/dist/commands/api-command/import-command.d.ts +2 -0
- package/dist/commands/api-command/import-command.d.ts.map +1 -0
- package/dist/commands/api-command/import-command.js +111 -0
- package/dist/commands/api-command/import-command.js.map +1 -0
- package/dist/commands/api-command/index.d.ts +3 -0
- package/dist/commands/api-command/index.d.ts.map +1 -0
- package/dist/commands/api-command/index.js +34 -0
- package/dist/commands/api-command/index.js.map +1 -0
- package/dist/commands/api-command/list-command.d.ts +2 -0
- package/dist/commands/api-command/list-command.d.ts.map +1 -0
- package/dist/commands/api-command/list-command.js +53 -0
- package/dist/commands/api-command/list-command.js.map +1 -0
- package/dist/commands/api-command/remove-command.d.ts +2 -0
- package/dist/commands/api-command/remove-command.d.ts.map +1 -0
- package/dist/commands/api-command/remove-command.js +63 -0
- package/dist/commands/api-command/remove-command.js.map +1 -0
- package/dist/commands/api-command/shared.d.ts +36 -0
- package/dist/commands/api-command/shared.d.ts.map +1 -0
- package/dist/commands/api-command/shared.js +164 -0
- package/dist/commands/api-command/shared.js.map +1 -0
- package/dist/commands/api-command.d.ts +1 -26
- package/dist/commands/api-command.d.ts.map +1 -1
- package/dist/commands/api-command.js +3 -807
- package/dist/commands/api-command.js.map +1 -1
- package/dist/commands/arg-extractor.d.ts +15 -0
- package/dist/commands/arg-extractor.d.ts.map +1 -1
- package/dist/commands/arg-extractor.js +48 -2
- package/dist/commands/arg-extractor.js.map +1 -1
- package/dist/commands/config-auth/index.d.ts.map +1 -1
- package/dist/commands/config-auth/index.js +35 -19
- package/dist/commands/config-auth/index.js.map +1 -1
- package/dist/commands/config-command-options.d.ts +14 -0
- package/dist/commands/config-command-options.d.ts.map +1 -0
- package/dist/commands/config-command-options.js +108 -0
- package/dist/commands/config-command-options.js.map +1 -0
- package/dist/commands/config-command.d.ts +1 -1
- package/dist/commands/config-command.d.ts.map +1 -1
- package/dist/commands/config-command.js +91 -104
- package/dist/commands/config-command.js.map +1 -1
- package/dist/commands/config-dashboard-host.d.ts +17 -0
- package/dist/commands/config-dashboard-host.d.ts.map +1 -0
- package/dist/commands/config-dashboard-host.js +99 -0
- package/dist/commands/config-dashboard-host.js.map +1 -0
- package/dist/commands/env-command.d.ts.map +1 -1
- package/dist/commands/env-command.js +5 -0
- package/dist/commands/env-command.js.map +1 -1
- package/dist/commands/help-command.js +1 -1
- package/dist/commands/help-command.js.map +1 -1
- package/dist/commands/named-command-router.d.ts +17 -0
- package/dist/commands/named-command-router.d.ts.map +1 -0
- package/dist/commands/named-command-router.js +39 -0
- package/dist/commands/named-command-router.js.map +1 -0
- package/dist/commands/persist-command.js +1 -1
- package/dist/commands/persist-command.js.map +1 -1
- package/dist/commands/root-command-router.d.ts +2 -0
- package/dist/commands/root-command-router.d.ts.map +1 -0
- package/dist/commands/root-command-router.js +209 -0
- package/dist/commands/root-command-router.js.map +1 -0
- package/dist/config/unified-config-loader.js +1 -1
- package/dist/config/unified-config-loader.js.map +1 -1
- package/dist/cursor/cursor-anthropic-response.d.ts +6 -0
- package/dist/cursor/cursor-anthropic-response.d.ts.map +1 -0
- package/dist/cursor/cursor-anthropic-response.js +190 -0
- package/dist/cursor/cursor-anthropic-response.js.map +1 -0
- package/dist/cursor/cursor-anthropic-translator.d.ts +11 -0
- package/dist/cursor/cursor-anthropic-translator.d.ts.map +1 -0
- package/dist/cursor/cursor-anthropic-translator.js +167 -0
- package/dist/cursor/cursor-anthropic-translator.js.map +1 -0
- package/dist/cursor/cursor-anthropic-types.d.ts +46 -0
- package/dist/cursor/cursor-anthropic-types.d.ts.map +1 -0
- package/dist/cursor/cursor-anthropic-types.js +3 -0
- package/dist/cursor/cursor-anthropic-types.js.map +1 -0
- package/dist/cursor/cursor-daemon-entry.d.ts.map +1 -1
- package/dist/cursor/cursor-daemon-entry.js +53 -24
- package/dist/cursor/cursor-daemon-entry.js.map +1 -1
- package/dist/cursor/cursor-models.d.ts.map +1 -1
- package/dist/cursor/cursor-models.js +36 -2
- package/dist/cursor/cursor-models.js.map +1 -1
- package/dist/glmt/glmt-proxy.d.ts +4 -3
- package/dist/glmt/glmt-proxy.d.ts.map +1 -1
- package/dist/glmt/glmt-proxy.js +4 -3
- package/dist/glmt/glmt-proxy.js.map +1 -1
- package/dist/glmt/sse-parser.d.ts +2 -0
- package/dist/glmt/sse-parser.d.ts.map +1 -1
- package/dist/glmt/sse-parser.js +4 -0
- package/dist/glmt/sse-parser.js.map +1 -1
- package/dist/management/instance-manager.d.ts.map +1 -1
- package/dist/management/instance-manager.js +1 -0
- package/dist/management/instance-manager.js.map +1 -1
- package/dist/management/recovery-manager.d.ts +2 -2
- package/dist/management/recovery-manager.js +2 -2
- package/dist/management/shared-manager.d.ts +18 -1
- package/dist/management/shared-manager.d.ts.map +1 -1
- package/dist/management/shared-manager.js +82 -14
- package/dist/management/shared-manager.js.map +1 -1
- package/dist/shared/claude-extension-setup.d.ts.map +1 -1
- package/dist/shared/claude-extension-setup.js +16 -2
- package/dist/shared/claude-extension-setup.js.map +1 -1
- package/dist/shared/provider-preset-catalog.d.ts +1 -1
- package/dist/shared/provider-preset-catalog.d.ts.map +1 -1
- package/dist/shared/provider-preset-catalog.js +34 -40
- package/dist/shared/provider-preset-catalog.js.map +1 -1
- package/dist/ui/assets/{accounts-CZEg1_PX.js → accounts-CjGyCl_8.js} +1 -1
- package/dist/ui/assets/{alert-dialog-DhwS38kc.js → alert-dialog-cy99V8EM.js} +1 -1
- package/dist/ui/assets/{api-sWNND4wP.js → api-DKrhDjiy.js} +1 -1
- package/dist/ui/assets/{auth-section-nJIpOcnm.js → auth-section-DsDyGmzl.js} +1 -1
- package/dist/ui/assets/{backups-section-D3A6hmrU.js → backups-section-B63xrUmB.js} +1 -1
- package/dist/ui/assets/checkbox-AxZFvatO.js +1 -0
- package/dist/ui/assets/{claude-extension-BjInaILv.js → claude-extension-N0lxo7BY.js} +1 -1
- package/dist/ui/assets/cliproxy-D2ozaUJ3.js +3 -0
- package/dist/ui/assets/{cliproxy-control-panel-CKO2Sn9B.js → cliproxy-control-panel-5fYLcZKs.js} +1 -1
- package/dist/ui/assets/{confirm-dialog-DTKxwrat.js → confirm-dialog-D2bDFGvT.js} +1 -1
- package/dist/ui/assets/copilot-INm6uOZF.js +3 -0
- package/dist/ui/assets/cursor-C8rDHKEp.js +1 -0
- package/dist/ui/assets/{droid-Cl8QsJJL.js → droid-OZDvbiwC.js} +2 -2
- package/dist/ui/assets/{globalenv-section-C3dxxoD9.js → globalenv-section-ClTBgKg5.js} +1 -1
- package/dist/ui/assets/{health-BUifaDU7.js → health-CGaRANip.js} +1 -1
- package/dist/ui/assets/icons-DtwH984l.js +1 -0
- package/dist/ui/assets/{index-CPdceT1C.js → index-CCSdUs7x.js} +1 -1
- package/dist/ui/assets/{index-BOsbrhaa.js → index-CGOZU3jq.js} +1 -1
- package/dist/ui/assets/index-ClEn7Y7g.css +1 -0
- package/dist/ui/assets/{index-xayyyR26.js → index-DQ4jn6yA.js} +1 -1
- package/dist/ui/assets/{index-CYo-E5rU.js → index-DS1QEaxk.js} +1 -1
- package/dist/ui/assets/index-tMnuUCFi.js +47 -0
- package/dist/ui/assets/providers/llama-cpp.svg +5 -0
- package/dist/ui/assets/{proxy-status-widget-D94htBPb.js → proxy-status-widget-PESjh9-t.js} +1 -1
- package/dist/ui/assets/{radix-ui-BR1vy4kf.js → radix-ui-Dt3edmE5.js} +8 -8
- package/dist/ui/assets/searchable-select-D6dcPTiL.js +1 -0
- package/dist/ui/assets/{separator-3fBbTn-V.js → separator-Czy9IRpl.js} +1 -1
- package/dist/ui/assets/{shared-q_FNNbjD.js → shared-BUJNJgAr.js} +1 -1
- package/dist/ui/assets/{switch-5N8qBdBr.js → switch-Bog43RUy.js} +1 -1
- package/dist/ui/assets/{tanstack-e99Cjjy2.js → tanstack-B8i0evp-.js} +1 -1
- package/dist/ui/assets/{updates-CubQ54J0.js → updates-jcWPnn9L.js} +1 -1
- package/dist/ui/icons/novita.svg +9 -0
- package/dist/ui/index.html +5 -5
- package/dist/utils/config-manager.d.ts +1 -1
- package/dist/utils/config-manager.js +1 -1
- package/dist/utils/fetch-proxy-setup.d.ts.map +1 -1
- package/dist/utils/fetch-proxy-setup.js.map +1 -1
- package/dist/utils/glmt-deprecation.d.ts +11 -0
- package/dist/utils/glmt-deprecation.d.ts.map +1 -0
- package/dist/utils/glmt-deprecation.js +64 -0
- package/dist/utils/glmt-deprecation.js.map +1 -0
- package/dist/utils/shell-executor.d.ts.map +1 -1
- package/dist/utils/shell-executor.js +12 -0
- package/dist/utils/shell-executor.js.map +1 -1
- package/dist/web-server/index.d.ts +1 -0
- package/dist/web-server/index.d.ts.map +1 -1
- package/dist/web-server/index.js +39 -3
- package/dist/web-server/index.js.map +1 -1
- package/dist/web-server/routes/profile-routes.d.ts +1 -0
- package/dist/web-server/routes/profile-routes.d.ts.map +1 -1
- package/dist/web-server/routes/profile-routes.js +3 -0
- package/dist/web-server/routes/profile-routes.js.map +1 -1
- package/dist/web-server/routes/variant-routes.d.ts +1 -0
- package/dist/web-server/routes/variant-routes.d.ts.map +1 -1
- package/dist/web-server/routes/variant-routes.js +3 -0
- package/dist/web-server/routes/variant-routes.js.map +1 -1
- package/package.json +3 -2
- package/scripts/completion/README.md +1 -1
- package/scripts/completion/ccs.fish +1 -2
- package/scripts/completion/ccs.zsh +1 -2
- package/scripts/postinstall.js +3 -3
- package/dist/ui/assets/checkbox-CZrxD1iS.js +0 -1
- package/dist/ui/assets/cliproxy-BGiSCGkl.js +0 -3
- package/dist/ui/assets/copilot-CuRngdBg.js +0 -3
- package/dist/ui/assets/cursor-Dxo0uIiU.js +0 -1
- package/dist/ui/assets/icons-DrEfTmfX.js +0 -1
- package/dist/ui/assets/index-Btf_ow2V.css +0 -1
- package/dist/ui/assets/index-Cw9Urr0S.js +0 -47
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.exitOnApiCommandErrors = exports.parseApiCommandArgs = exports.collectUnexpectedApiArgs = exports.parseOptionalTargetFlag = exports.extractPositionalArgs = exports.sanitizeHelpText = exports.API_KNOWN_FLAGS = exports.API_VALUE_FLAGS = exports.API_BOOLEAN_FLAGS = void 0;
|
|
4
|
+
const ui_1 = require("../../utils/ui");
|
|
5
|
+
const arg_extractor_1 = require("../arg-extractor");
|
|
6
|
+
exports.API_BOOLEAN_FLAGS = ['--force', '--yes', '-y'];
|
|
7
|
+
exports.API_VALUE_FLAGS = [
|
|
8
|
+
'--base-url',
|
|
9
|
+
'--api-key',
|
|
10
|
+
'--model',
|
|
11
|
+
'--preset',
|
|
12
|
+
'--target',
|
|
13
|
+
];
|
|
14
|
+
exports.API_KNOWN_FLAGS = [...exports.API_BOOLEAN_FLAGS, ...exports.API_VALUE_FLAGS];
|
|
15
|
+
const API_VALUE_FLAG_SET = new Set(exports.API_VALUE_FLAGS);
|
|
16
|
+
function sanitizeHelpText(value) {
|
|
17
|
+
return value
|
|
18
|
+
.replace(/[\r\n\t]+/g, ' ')
|
|
19
|
+
.replace(/[\x00-\x1f\x7f]/g, ' ')
|
|
20
|
+
.replace(/\s+/g, ' ')
|
|
21
|
+
.trim();
|
|
22
|
+
}
|
|
23
|
+
exports.sanitizeHelpText = sanitizeHelpText;
|
|
24
|
+
function applyRepeatedOption(args, flags, onValue, onMissing, allowDashValue = false) {
|
|
25
|
+
let remaining = [...args];
|
|
26
|
+
while (true) {
|
|
27
|
+
const extracted = (0, arg_extractor_1.extractOption)(remaining, flags, {
|
|
28
|
+
allowDashValue,
|
|
29
|
+
knownFlags: exports.API_KNOWN_FLAGS,
|
|
30
|
+
});
|
|
31
|
+
if (!extracted.found) {
|
|
32
|
+
return remaining;
|
|
33
|
+
}
|
|
34
|
+
if (extracted.missingValue || !extracted.value) {
|
|
35
|
+
onMissing();
|
|
36
|
+
}
|
|
37
|
+
else {
|
|
38
|
+
onValue(extracted.value);
|
|
39
|
+
}
|
|
40
|
+
remaining = extracted.remainingArgs;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
function extractPositionalArgs(args) {
|
|
44
|
+
const positionals = [];
|
|
45
|
+
for (let i = 0; i < args.length; i++) {
|
|
46
|
+
const token = args[i];
|
|
47
|
+
if (token === '--') {
|
|
48
|
+
positionals.push(...args.slice(i + 1));
|
|
49
|
+
break;
|
|
50
|
+
}
|
|
51
|
+
if (token.startsWith('-')) {
|
|
52
|
+
if (!token.includes('=') && API_VALUE_FLAG_SET.has(token)) {
|
|
53
|
+
const next = args[i + 1];
|
|
54
|
+
if (next && !next.startsWith('-')) {
|
|
55
|
+
i++;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
continue;
|
|
59
|
+
}
|
|
60
|
+
positionals.push(token);
|
|
61
|
+
}
|
|
62
|
+
return positionals;
|
|
63
|
+
}
|
|
64
|
+
exports.extractPositionalArgs = extractPositionalArgs;
|
|
65
|
+
function parseTargetValue(value) {
|
|
66
|
+
const normalized = value.trim().toLowerCase();
|
|
67
|
+
if (normalized === 'claude' || normalized === 'droid') {
|
|
68
|
+
return normalized;
|
|
69
|
+
}
|
|
70
|
+
return null;
|
|
71
|
+
}
|
|
72
|
+
function parseOptionalTargetFlag(args, knownFlags) {
|
|
73
|
+
const extracted = (0, arg_extractor_1.extractOption)(args, ['--target'], {
|
|
74
|
+
knownFlags,
|
|
75
|
+
});
|
|
76
|
+
if (!extracted.found) {
|
|
77
|
+
return { remainingArgs: args, errors: [] };
|
|
78
|
+
}
|
|
79
|
+
if (extracted.missingValue || !extracted.value) {
|
|
80
|
+
return { remainingArgs: extracted.remainingArgs, errors: ['Missing value for --target'] };
|
|
81
|
+
}
|
|
82
|
+
const target = parseTargetValue(extracted.value);
|
|
83
|
+
if (!target) {
|
|
84
|
+
return {
|
|
85
|
+
remainingArgs: extracted.remainingArgs,
|
|
86
|
+
errors: [`Invalid --target value "${extracted.value}". Use: claude or droid`],
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
return { target, remainingArgs: extracted.remainingArgs, errors: [] };
|
|
90
|
+
}
|
|
91
|
+
exports.parseOptionalTargetFlag = parseOptionalTargetFlag;
|
|
92
|
+
function collectUnexpectedApiArgs(args, options) {
|
|
93
|
+
const scanned = (0, arg_extractor_1.scanCommandArgs)(args, {
|
|
94
|
+
knownFlags: options.knownFlags ?? [],
|
|
95
|
+
});
|
|
96
|
+
const errors = scanned.unknownFlags.map((flag) => `Unknown option: ${flag}`);
|
|
97
|
+
if (scanned.positionals.length > options.maxPositionals) {
|
|
98
|
+
errors.push(`Unexpected arguments: ${scanned.positionals.slice(options.maxPositionals).join(' ')}`);
|
|
99
|
+
}
|
|
100
|
+
return {
|
|
101
|
+
positionals: scanned.positionals,
|
|
102
|
+
errors,
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
exports.collectUnexpectedApiArgs = collectUnexpectedApiArgs;
|
|
106
|
+
function parseApiCommandArgs(args, options = {}) {
|
|
107
|
+
const result = {
|
|
108
|
+
positionals: [],
|
|
109
|
+
force: (0, arg_extractor_1.hasAnyFlag)(args, ['--force']),
|
|
110
|
+
yes: (0, arg_extractor_1.hasAnyFlag)(args, ['--yes', '-y']),
|
|
111
|
+
errors: [],
|
|
112
|
+
};
|
|
113
|
+
let remaining = [...args];
|
|
114
|
+
remaining = applyRepeatedOption(remaining, ['--base-url'], (value) => {
|
|
115
|
+
result.baseUrl = value;
|
|
116
|
+
}, () => {
|
|
117
|
+
result.errors.push('Missing value for --base-url');
|
|
118
|
+
}, false);
|
|
119
|
+
remaining = applyRepeatedOption(remaining, ['--api-key'], (value) => {
|
|
120
|
+
result.apiKey = value;
|
|
121
|
+
}, () => {
|
|
122
|
+
result.errors.push('Missing value for --api-key');
|
|
123
|
+
}, false);
|
|
124
|
+
remaining = applyRepeatedOption(remaining, ['--model'], (value) => {
|
|
125
|
+
result.model = value;
|
|
126
|
+
}, () => {
|
|
127
|
+
result.errors.push('Missing value for --model');
|
|
128
|
+
}, true);
|
|
129
|
+
remaining = applyRepeatedOption(remaining, ['--preset'], (value) => {
|
|
130
|
+
result.preset = value;
|
|
131
|
+
}, () => {
|
|
132
|
+
result.errors.push('Missing value for --preset');
|
|
133
|
+
}, false);
|
|
134
|
+
remaining = applyRepeatedOption(remaining, ['--target'], (value) => {
|
|
135
|
+
const target = parseTargetValue(value);
|
|
136
|
+
if (!target) {
|
|
137
|
+
result.errors.push(`Invalid --target value "${value}". Use: claude or droid`);
|
|
138
|
+
return;
|
|
139
|
+
}
|
|
140
|
+
result.target = target;
|
|
141
|
+
}, () => {
|
|
142
|
+
result.errors.push('Missing value for --target');
|
|
143
|
+
}, false);
|
|
144
|
+
const unexpected = collectUnexpectedApiArgs(remaining, {
|
|
145
|
+
knownFlags: exports.API_BOOLEAN_FLAGS,
|
|
146
|
+
maxPositionals: options.maxPositionals ?? 1,
|
|
147
|
+
});
|
|
148
|
+
result.positionals = unexpected.positionals;
|
|
149
|
+
result.name = unexpected.positionals[0];
|
|
150
|
+
result.errors.push(...unexpected.errors);
|
|
151
|
+
return result;
|
|
152
|
+
}
|
|
153
|
+
exports.parseApiCommandArgs = parseApiCommandArgs;
|
|
154
|
+
function exitOnApiCommandErrors(errors) {
|
|
155
|
+
if (errors.length === 0) {
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
158
|
+
errors.forEach((errorMessage) => {
|
|
159
|
+
console.log((0, ui_1.fail)(errorMessage));
|
|
160
|
+
});
|
|
161
|
+
process.exit(1);
|
|
162
|
+
}
|
|
163
|
+
exports.exitOnApiCommandErrors = exitOnApiCommandErrors;
|
|
164
|
+
//# sourceMappingURL=shared.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shared.js","sourceRoot":"","sources":["../../../src/commands/api-command/shared.ts"],"names":[],"mappings":";;;AACA,uCAAsC;AACtC,oDAA8E;AAejE,QAAA,iBAAiB,GAAG,CAAC,SAAS,EAAE,OAAO,EAAE,IAAI,CAAU,CAAC;AACxD,QAAA,eAAe,GAAG;IAC7B,YAAY;IACZ,WAAW;IACX,SAAS;IACT,UAAU;IACV,UAAU;CACF,CAAC;AACE,QAAA,eAAe,GAAsB,CAAC,GAAG,yBAAiB,EAAE,GAAG,uBAAe,CAAC,CAAC;AAE7F,MAAM,kBAAkB,GAAG,IAAI,GAAG,CAAS,uBAAe,CAAC,CAAC;AAM5D,SAAgB,gBAAgB,CAAC,KAAa;IAC5C,OAAO,KAAK;SACT,OAAO,CAAC,YAAY,EAAE,GAAG,CAAC;SAC1B,OAAO,CAAC,kBAAkB,EAAE,GAAG,CAAC;SAChC,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC;SACpB,IAAI,EAAE,CAAC;AACZ,CAAC;AAND,4CAMC;AAED,SAAS,mBAAmB,CAC1B,IAAc,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AM,CAAC,IAAI,CAAC,4BAA4B,CAAC,CAAC;IACnD,CAAC,EACD,KAAK,CACN,CAAC;IAEF,MAAM,UAAU,GAAG,wBAAwB,CAAC,SAAS,EAAE;QACrD,UAAU,EAAE,yBAAiB;QAC7B,cAAc,EAAE,OAAO,CAAC,cAAc,IAAI,CAAC;KAC5C,CAAC,CAAC;IACH,MAAM,CAAC,WAAW,GAAG,UAAU,CAAC,WAAW,CAAC;IAC5C,MAAM,CAAC,IAAI,GAAG,UAAU,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC;IACxC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,UAAU,CAAC,MAAM,CAAC,CAAC;IACzC,OAAO,MAAM,CAAC;AAChB,CAAC;AAtFD,kDAsFC;AAED,SAAgB,sBAAsB,CAAC,MAAgB;IACrD,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACxB,OAAO;IACT,CAAC;IAED,MAAM,CAAC,OAAO,CAAC,CAAC,YAAY,EAAE,EAAE;QAC9B,OAAO,CAAC,GAAG,CAAC,IAAA,SAAI,EAAC,YAAY,CAAC,CAAC,CAAC;IAClC,CAAC,CAAC,CAAC;IACH,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC;AATD,wDASC"}
|
|
@@ -1,27 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
* API Command Handler
|
|
3
|
-
*
|
|
4
|
-
* Manages CCS API profiles for custom API providers.
|
|
5
|
-
* Commands: create, list, remove
|
|
6
|
-
*
|
|
7
|
-
* CLI parsing and output formatting only.
|
|
8
|
-
* Business logic delegated to src/api/services/.
|
|
9
|
-
*/
|
|
10
|
-
import type { TargetType } from '../targets/target-adapter';
|
|
11
|
-
interface ApiCommandArgs {
|
|
12
|
-
name?: string;
|
|
13
|
-
baseUrl?: string;
|
|
14
|
-
apiKey?: string;
|
|
15
|
-
model?: string;
|
|
16
|
-
preset?: string;
|
|
17
|
-
target?: TargetType;
|
|
18
|
-
force?: boolean;
|
|
19
|
-
yes?: boolean;
|
|
20
|
-
errors: string[];
|
|
21
|
-
}
|
|
22
|
-
/** Parse command line arguments for api commands */
|
|
23
|
-
export declare function parseApiCommandArgs(args: string[]): ApiCommandArgs;
|
|
24
|
-
/** Main api command router */
|
|
25
|
-
export declare function handleApiCommand(args: string[]): Promise<void>;
|
|
26
|
-
export {};
|
|
1
|
+
export * from './api-command/index';
|
|
27
2
|
//# sourceMappingURL=api-command.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api-command.d.ts","sourceRoot":"","sources":["../../src/commands/api-command.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"api-command.d.ts","sourceRoot":"","sources":["../../src/commands/api-command.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC"}
|