@apso/cli 0.25.0 → 0.26.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.
@@ -297,10 +297,30 @@ class Login extends base_command_1.default {
297
297
  this.log("");
298
298
  this.log(`Successfully logged in as ${tokenResponse.user.email}`);
299
299
  this.log("");
300
- this.log("Next steps:");
301
- this.log(" apso use - Select your workspace");
302
- this.log(" apso whoami - View your account + workspace");
303
- this.log(" apso projects - List services in a workspace");
300
+ // Brand-new users have no workspace yet. Workspaces are created in the web
301
+ // app (not the CLI), so guide them there explicitly and offer to open it —
302
+ // otherwise a first-timer hits a bare "No workspaces found" later with no
303
+ // idea what to do.
304
+ const workspaces = await services_1.workspacesApi.list().catch(() => []);
305
+ if (workspaces.length === 0) {
306
+ const onboardingUrl = `${config_1.globalConfig.read().webUrl}/onboarding/workspace`;
307
+ this.log("You don't have a workspace yet.");
308
+ this.log("Workspaces are created in the Apso web app:");
309
+ this.log(` ${onboardingUrl}`);
310
+ this.log("");
311
+ this.log("Opening it in your browser...");
312
+ await openBrowser(onboardingUrl).catch(() => {
313
+ this.log("(Could not open the browser — visit the URL above.)");
314
+ });
315
+ this.log("");
316
+ this.log("Once your workspace exists, run 'apso use' to select it.");
317
+ }
318
+ else {
319
+ this.log("Next steps:");
320
+ this.log(" apso use - Select your workspace");
321
+ this.log(" apso whoami - View your account + workspace");
322
+ this.log(" apso projects - List services in a workspace");
323
+ }
304
324
  }
305
325
  catch (error) {
306
326
  if (error instanceof Error) {
@@ -19,7 +19,8 @@ class Use extends base_command_1.default {
19
19
  }
20
20
  const workspaces = await services_1.workspacesApi.list();
21
21
  if (workspaces.length === 0) {
22
- this.error("No workspaces found. Create one at https://app.apso.cloud first.");
22
+ const onboardingUrl = `${config_1.globalConfig.read().webUrl}/onboarding/workspace`;
23
+ this.error(`You don't have a workspace yet. Workspaces are created in the Apso web app:\n ${onboardingUrl}\nThen run 'apso use' again to select it.`);
23
24
  }
24
25
  let ws;
25
26
  if (args.workspace) {
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@apso/cli",
3
- "version": "0.25.0",
3
+ "version": "0.26.0",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@apso/cli",
9
- "version": "0.25.0",
9
+ "version": "0.26.0",
10
10
  "license": "Apache-2.0",
11
11
  "dependencies": {
12
12
  "@biomejs/biome": "^1.9.4",
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.25.0",
2
+ "version": "0.26.0",
3
3
  "commands": {
4
4
  "config": {
5
5
  "id": "config",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@apso/cli",
3
- "version": "0.25.0",
3
+ "version": "0.26.0",
4
4
  "mcpName": "io.github.apsoai/apso",
5
5
  "description": "Apso CLI",
6
6
  "author": "Apso by Mavric - @mavric",