perstack 0.0.102 → 0.0.103

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/bin/cli.js CHANGED
@@ -21133,6 +21133,25 @@ function createStudioClient(options) {
21133
21133
  });
21134
21134
  }
21135
21135
 
21136
+ //#endregion
21137
+ //#region ../../packages/studio/src/application-handlers.ts
21138
+ async function applicationsListHandler(options) {
21139
+ const result = await createStudioClient({
21140
+ apiKey: resolveApiKey(options.apiKey),
21141
+ baseUrl: options.baseUrl
21142
+ }).applications.list();
21143
+ if (!result.ok) throw new PerstackError(`Failed to list applications: ${result.error.message}`);
21144
+ const { applications } = result.data.data;
21145
+ if (applications.length === 0) {
21146
+ console.log("No applications found.");
21147
+ return;
21148
+ }
21149
+ for (const app of applications) {
21150
+ console.log(` ${app.name}`);
21151
+ console.log(` ID: ${app.id}`);
21152
+ }
21153
+ }
21154
+
21136
21155
  //#endregion
21137
21156
  //#region ../../packages/studio/src/draft-handlers.ts
21138
21157
  async function expertListHandler(options) {
@@ -119756,7 +119775,7 @@ async function startHandler(expertKey, query, options, handlerOptions) {
119756
119775
  //#endregion
119757
119776
  //#region package.json
119758
119777
  var name = "perstack";
119759
- var version = "0.0.102";
119778
+ var version = "0.0.103";
119760
119779
  var description = "PerStack CLI";
119761
119780
 
119762
119781
  //#endregion
@@ -119853,6 +119872,9 @@ expertCmd.command("unpublish").description("Make an expert scope private").argum
119853
119872
  expertCmd.command("yank").description("Deprecate a specific expert version").argument("<key>", "Expert key with version (e.g., my-expert@1.0.0)").action(async function(key) {
119854
119873
  await expertYankHandler(key, getParentOptions(this));
119855
119874
  });
119875
+ program.command("application").description("Manage applications on Perstack API").option("--api-key <key>", "Perstack API key (default: PERSTACK_API_KEY env)").option("--base-url <url>", "Custom API base URL").command("list").description("List applications").action(async function() {
119876
+ await applicationsListHandler(getParentOptions(this));
119877
+ });
119856
119878
  program.parseAsync().catch((error) => {
119857
119879
  if (error instanceof PerstackError) {
119858
119880
  console.error(error.message);