@epilot/cli 0.1.45 → 0.1.47

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.
@@ -0,0 +1,56 @@
1
+ #!/usr/bin/env node
2
+ import {
3
+ callApi
4
+ } from "./chunk-5ZFPCFKV.js";
5
+ import "./chunk-IOLKUHUB.js";
6
+ import "./chunk-M3M3C5WH.js";
7
+ import "./chunk-YHQA2AVG.js";
8
+ import "./chunk-7ZQ666ZQ.js";
9
+
10
+ // src/commands/apis/snapshot.ts
11
+ import { defineCommand } from "citty";
12
+ var snapshot_default = defineCommand({
13
+ meta: { name: "snapshot", description: "Snapshot API" },
14
+ args: {
15
+ operation: { type: "positional", description: "operationId to call", required: false },
16
+ param: { type: "string", alias: "p", description: "Parameter key=value" },
17
+ data: { type: "string", alias: "d", description: "Request body JSON" },
18
+ header: { type: "string", alias: "H", description: "Custom header" },
19
+ include: { type: "boolean", alias: "i", description: "Include response headers" },
20
+ definition: { type: "string", description: "Override OpenAPI spec file/URL" },
21
+ server: { type: "string", alias: "s", description: "Override server base URL" },
22
+ "use-dev": { type: "boolean", description: "Target dev environment" },
23
+ "use-staging": { type: "boolean", description: "Target staging environment" },
24
+ profile: { type: "string", description: "Use a named profile" },
25
+ token: { type: "string", alias: "t", description: "Bearer token" },
26
+ json: { type: "boolean", description: "Output raw JSON" },
27
+ verbose: { type: "boolean", alias: "v", description: "Verbose output" },
28
+ guided: { type: "boolean", description: "Prompt for all parameters interactively" },
29
+ interactive: { type: "boolean", description: "Interactive mode" },
30
+ jsonata: { type: "string", description: "JSONata expression to transform response" },
31
+ _ophelp: { type: "boolean", description: "Show operation help", required: false },
32
+ _apihelp: { type: "boolean", description: "Show API help", required: false }
33
+ },
34
+ run: ({ args, rawArgs }) => {
35
+ const positionalArgs = [];
36
+ if (args.operation && rawArgs) {
37
+ const opIdx = rawArgs.indexOf(args.operation);
38
+ if (opIdx >= 0) {
39
+ for (let i = opIdx + 1; i < rawArgs.length; i++) {
40
+ const arg = rawArgs[i];
41
+ if (arg.startsWith("-")) break;
42
+ positionalArgs.push(arg);
43
+ }
44
+ }
45
+ }
46
+ return callApi("snapshot", {
47
+ ...args,
48
+ help: !!args._ophelp,
49
+ _apihelp: !!args._apihelp,
50
+ _args: positionalArgs
51
+ });
52
+ }
53
+ });
54
+ export {
55
+ snapshot_default as default
56
+ };
@@ -72,7 +72,7 @@ ${GREEN}${BOLD}Upgraded to @epilot/cli@${latest}${RESET}
72
72
  }
73
73
  });
74
74
  var getCurrentVersion = () => {
75
- if (true) return "0.1.45";
75
+ if (true) return "0.1.47";
76
76
  try {
77
77
  const output = execSync("npm ls -g @epilot/cli --depth=0 --json 2>/dev/null", {
78
78
  encoding: "utf-8",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epilot/cli",
3
- "version": "0.1.45",
3
+ "version": "0.1.47",
4
4
  "description": "CLI for epilot APIs",
5
5
  "type": "module",
6
6
  "bin": {