@dishantlangayan/solace-cloud-cli 0.1.0 → 0.1.1

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 CHANGED
@@ -22,7 +22,7 @@ $ npm install -g @dishantlangayan/solace-cloud-cli
22
22
  $ sc COMMAND
23
23
  running command...
24
24
  $ sc (--version)
25
- @dishantlangayan/solace-cloud-cli/0.1.0 darwin-arm64 node-v24.1.0
25
+ @dishantlangayan/solace-cloud-cli/0.1.1 darwin-arm64 node-v24.1.0
26
26
  $ sc --help [COMMAND]
27
27
  USAGE
28
28
  $ sc COMMAND
@@ -51,6 +51,7 @@ The following Environment variables are optional:
51
51
  * [`sc missionctrl broker display`](#sc-missionctrl-broker-display)
52
52
  * [`sc missionctrl broker list`](#sc-missionctrl-broker-list)
53
53
  * [`sc missionctrl broker opstatus`](#sc-missionctrl-broker-opstatus)
54
+ * [`sc missionctrl broker state`](#sc-missionctrl-broker-state)
54
55
  * [`sc missionctrl broker update`](#sc-missionctrl-broker-update)
55
56
  * [`sc platform env create`](#sc-platform-env-create)
56
57
  * [`sc platform env delete`](#sc-platform-env-delete)
@@ -145,7 +146,7 @@ EXAMPLES
145
146
  $ sc missionctrl broker create --name=MyBrokerName --datacenter-id=eks-ca-central-1a --service-class-id=DEVELOPER
146
147
  ```
147
148
 
148
- _See code: [src/commands/missionctrl/broker/create.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/missionctrl/broker/create.ts)_
149
+ _See code: [src/commands/missionctrl/broker/create.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/missionctrl/broker/create.ts)_
149
150
 
150
151
  ## `sc missionctrl broker delete`
151
152
 
@@ -177,7 +178,7 @@ EXAMPLES
177
178
  $ sc missionctrl broker delete --name=MyBrokerName
178
179
  ```
179
180
 
180
- _See code: [src/commands/missionctrl/broker/delete.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/missionctrl/broker/delete.ts)_
181
+ _See code: [src/commands/missionctrl/broker/delete.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/missionctrl/broker/delete.ts)_
181
182
 
182
183
  ## `sc missionctrl broker display`
183
184
 
@@ -208,7 +209,7 @@ EXAMPLES
208
209
  $ sc missionctrl broker display
209
210
  ```
210
211
 
211
- _See code: [src/commands/missionctrl/broker/display.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/missionctrl/broker/display.ts)_
212
+ _See code: [src/commands/missionctrl/broker/display.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/missionctrl/broker/display.ts)_
212
213
 
213
214
  ## `sc missionctrl broker list`
214
215
 
@@ -227,7 +228,7 @@ FLAGS
227
228
  The page number to get. Defaults to 1
228
229
 
229
230
  --pageSize=<value>
230
- The number of event broker services to return per page. Defaults to 100
231
+ The number of event broker services to return per page. Defaults to 10
231
232
 
232
233
  --sort=<value>
233
234
  Sort the returned event broker services by attribute.
@@ -251,10 +252,12 @@ DESCRIPTION
251
252
  **or** `services:view:self` ]
252
253
 
253
254
  EXAMPLES
255
+ $ sc missionctrl broker list
256
+
254
257
  $ sc missionctrl broker list --name=MyBrokerName --pageNumber=1 --pageSize=10 --sort=name:asc
255
258
  ```
256
259
 
257
- _See code: [src/commands/missionctrl/broker/list.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/missionctrl/broker/list.ts)_
260
+ _See code: [src/commands/missionctrl/broker/list.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/missionctrl/broker/list.ts)_
258
261
 
259
262
  ## `sc missionctrl broker opstatus`
260
263
 
@@ -291,7 +294,41 @@ EXAMPLES
291
294
  $ sc missionctrl broker opstatus -n <broker-name>
292
295
  ```
293
296
 
294
- _See code: [src/commands/missionctrl/broker/opstatus.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/missionctrl/broker/opstatus.ts)_
297
+ _See code: [src/commands/missionctrl/broker/opstatus.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/missionctrl/broker/opstatus.ts)_
298
+
299
+ ## `sc missionctrl broker state`
300
+
301
+ Get the availability state of an event broker service and the name of the active messaging node using the service's unique identifier.
302
+
303
+ ```
304
+ USAGE
305
+ $ sc missionctrl broker state [--json] [--log-level debug|warn|error|info|trace] [-b <value>] [-n <value>]
306
+
307
+ FLAGS
308
+ -b, --broker-id=<value> Id of the event broker service.
309
+ -n, --name=<value> Name of the event broker service.
310
+
311
+ GLOBAL FLAGS
312
+ --json Format output as json.
313
+ --log-level=<option> [default: info] Specify level for logging.
314
+ <options: debug|warn|error|info|trace>
315
+
316
+ DESCRIPTION
317
+ Get the availability state of an event broker service and the name of the active messaging node using the service's
318
+ unique identifier.
319
+
320
+ Your token must have one of the permissions listed in the Token Permissions.
321
+
322
+ Token Permissions: [ mission_control:access or services:get or services:get:self or services:view or
323
+ services:view:self ]
324
+
325
+ EXAMPLES
326
+ $ sc missionctrl broker state --broker-id=MyBrokerServiceId
327
+
328
+ $ sc missionctrl broker state --name=MyBrokerName
329
+ ```
330
+
331
+ _See code: [src/commands/missionctrl/broker/state.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/missionctrl/broker/state.ts)_
295
332
 
296
333
  ## `sc missionctrl broker update`
297
334
 
@@ -325,9 +362,13 @@ DESCRIPTION
325
362
 
326
363
  EXAMPLES
327
364
  $ sc missionctrl broker update
365
+
366
+ $ sc missionctrl broker update --broker-id <broker-id> --new-name <new-name>
367
+
368
+ $ sc missionctrl broker update --name <name> --new-name <new-name>
328
369
  ```
329
370
 
330
- _See code: [src/commands/missionctrl/broker/update.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/missionctrl/broker/update.ts)_
371
+ _See code: [src/commands/missionctrl/broker/update.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/missionctrl/broker/update.ts)_
331
372
 
332
373
  ## `sc platform env create`
333
374
 
@@ -341,8 +382,8 @@ USAGE
341
382
  FLAGS
342
383
  -d, --description=<value> Description of the environment to create.
343
384
  -n, --name=<value> (required) Name of the environment to create.
344
- --isDefault Indicates this is the organization’s default environment.
345
- --isProduction Indicates this is an organization’s production environment.
385
+ --isDefault Indicates this is the organization's default environment.
386
+ --isProduction Indicates this is an organization's production environment.
346
387
  This is an immutable field. If an environment needs to be migrated,
347
388
  architecture can be migrated to a new environment with the desired
348
389
  environment type instead.
@@ -361,7 +402,7 @@ EXAMPLES
361
402
  $ sc platform env create --name=MyEnvironment --desc="My environment description" --isDefault --isProduction
362
403
  ```
363
404
 
364
- _See code: [src/commands/platform/env/create.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/platform/env/create.ts)_
405
+ _See code: [src/commands/platform/env/create.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/platform/env/create.ts)_
365
406
 
366
407
  ## `sc platform env delete`
367
408
 
@@ -391,7 +432,7 @@ EXAMPLES
391
432
  $ sc platform env delete --env-id=MyEnvId
392
433
  ```
393
434
 
394
- _See code: [src/commands/platform/env/delete.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/platform/env/delete.ts)_
435
+ _See code: [src/commands/platform/env/delete.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/platform/env/delete.ts)_
395
436
 
396
437
  ## `sc platform env display`
397
438
 
@@ -423,7 +464,7 @@ EXAMPLES
423
464
  $ sc platform env display --env-id=MyEnvId
424
465
  ```
425
466
 
426
- _See code: [src/commands/platform/env/display.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/platform/env/display.ts)_
467
+ _See code: [src/commands/platform/env/display.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/platform/env/display.ts)_
427
468
 
428
469
  ## `sc platform env list`
429
470
 
@@ -456,7 +497,7 @@ EXAMPLES
456
497
  $ sc platform env list --name=Default --pageNumber=1 --pageSize=10 --sort=name:ASC
457
498
  ```
458
499
 
459
- _See code: [src/commands/platform/env/list.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/platform/env/list.ts)_
500
+ _See code: [src/commands/platform/env/list.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/platform/env/list.ts)_
460
501
 
461
502
  ## `sc platform env update`
462
503
 
@@ -493,7 +534,7 @@ EXAMPLES
493
534
  $ sc platform env update --env-id=MyEnvId --new-name=MyNewEnvName --desc="My description to update" --isDefault
494
535
  ```
495
536
 
496
- _See code: [src/commands/platform/env/update.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.0/src/commands/platform/env/update.ts)_
537
+ _See code: [src/commands/platform/env/update.ts](https://github.com/dishantlangayan/solace-cloud-cli/blob/v0.1.1/src/commands/platform/env/update.ts)_
497
538
 
498
539
  ## `sc plugins`
499
540
 
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { EventBrokerOperationDetail } from '../../../types/broker.js';
2
+ import { EventBrokerOperationApiResponse } from '../../../types/broker.js';
3
3
  export default class MissionctrlBrokerCreate extends ScCommand<typeof MissionctrlBrokerCreate> {
4
4
  static args: {};
5
5
  static description: string;
@@ -15,6 +15,5 @@ export default class MissionctrlBrokerCreate extends ScCommand<typeof Missionctr
15
15
  'service-class-id': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
16
16
  version: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
17
17
  };
18
- run(): Promise<EventBrokerOperationDetail>;
19
- private print;
18
+ run(): Promise<EventBrokerOperationApiResponse>;
20
19
  }
@@ -1,6 +1,6 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import { ScCommand } from '../../../sc-command.js';
3
- import { camelCaseToTitleCase, renderKeyValueTable } from '../../../util/internal.js';
3
+ import { printObjectAsKeyValueTable } from '../../../util/internal.js';
4
4
  import { ScConnection } from '../../../util/sc-connection.js';
5
5
  export default class MissionctrlBrokerCreate extends ScCommand {
6
6
  static args = {};
@@ -99,16 +99,7 @@ Token Permissions: [ \`services:post\` ]`;
99
99
  // API call
100
100
  const resp = await conn.post(apiUrl, body);
101
101
  // Display results
102
- this.log('Event broker service created successfully.');
103
- this.print(resp.data);
104
- return resp.data;
105
- }
106
- print(broker) {
107
- const tableRows = [
108
- ['Key', 'Value'],
109
- ...Object.entries(broker).map(([key, value]) => [camelCaseToTitleCase(key), value]),
110
- ];
111
- this.log();
112
- this.log(renderKeyValueTable(tableRows));
102
+ this.log(printObjectAsKeyValueTable(resp.data));
103
+ return resp;
113
104
  }
114
105
  }
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { EventBrokerOperationDetail } from '../../../types/broker.js';
2
+ import { EventBrokerOperationApiResponse } from '../../../types/broker.js';
3
3
  export default class MissionctrlBrokerDelete extends ScCommand<typeof MissionctrlBrokerDelete> {
4
4
  static args: {};
5
5
  static description: string;
@@ -8,6 +8,5 @@ export default class MissionctrlBrokerDelete extends ScCommand<typeof Missionctr
8
8
  'broker-id': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
9
9
  name: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
10
10
  };
11
- run(): Promise<EventBrokerOperationDetail>;
12
- private print;
11
+ run(): Promise<EventBrokerOperationApiResponse>;
13
12
  }
@@ -1,6 +1,6 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import { ScCommand } from '../../../sc-command.js';
3
- import { camelCaseToTitleCase, renderKeyValueTable } from '../../../util/internal.js';
3
+ import { printObjectAsKeyValueTable } from '../../../util/internal.js';
4
4
  import { ScConnection } from '../../../util/sc-connection.js';
5
5
  export default class MissionctrlBrokerDelete extends ScCommand {
6
6
  static args = {};
@@ -50,15 +50,7 @@ Token Permissions: [ \`services:delete\` **or** \`services:delete:self\` **or**
50
50
  apiUrl += `/${brokerIdToDelete}`;
51
51
  const resp = await conn.delete(apiUrl);
52
52
  // Display results
53
- this.print(resp.data);
54
- return resp.data;
55
- }
56
- print(broker) {
57
- const tableRows = [
58
- ['Key', 'Value'],
59
- ...Object.entries(broker).map(([key, value]) => [camelCaseToTitleCase(key), value]),
60
- ];
61
- this.log();
62
- this.log(renderKeyValueTable(tableRows));
53
+ this.log(printObjectAsKeyValueTable(resp.data));
54
+ return resp;
63
55
  }
64
56
  }
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { EventBrokerServiceDetail } from '../../../types/broker.js';
2
+ import { EventBrokerApiResponse, EventBrokerListApiResponse } from '../../../types/broker.js';
3
3
  export default class MissionctrlBrokerDisplay extends ScCommand<typeof MissionctrlBrokerDisplay> {
4
4
  static args: {};
5
5
  static description: string;
@@ -8,6 +8,5 @@ export default class MissionctrlBrokerDisplay extends ScCommand<typeof Missionct
8
8
  'broker-id': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
9
9
  name: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
10
10
  };
11
- run(): Promise<EventBrokerServiceDetail[]>;
12
- private print;
11
+ run(): Promise<EventBrokerApiResponse | EventBrokerListApiResponse>;
13
12
  }
@@ -1,6 +1,6 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import { ScCommand } from '../../../sc-command.js';
3
- import { camelCaseToTitleCase, renderKeyValueTable } from '../../../util/internal.js';
3
+ import { printObjectAsKeyValueTable } from '../../../util/internal.js';
4
4
  import { ScConnection } from '../../../util/sc-connection.js';
5
5
  export default class MissionctrlBrokerDisplay extends ScCommand {
6
6
  static args = {};
@@ -36,17 +36,18 @@ export default class MissionctrlBrokerDisplay extends ScCommand {
36
36
  // API call to get broker by id
37
37
  apiUrl += `/${brokerId}`;
38
38
  const resp = await conn.get(apiUrl);
39
- this.print(resp.data);
40
- rawResp = [resp.data];
39
+ this.log(printObjectAsKeyValueTable(resp.data));
40
+ rawResp = resp;
41
41
  }
42
42
  else if (name) {
43
43
  // API call to get broker by name
44
44
  apiUrl += `?customAttributes=name=="${name}"`;
45
45
  const resp = await conn.get(apiUrl);
46
+ // Display all brokers found
46
47
  for (const broker of resp.data) {
47
- this.print(broker);
48
+ this.log(printObjectAsKeyValueTable(broker));
48
49
  }
49
- rawResp = resp.data;
50
+ rawResp = resp;
50
51
  }
51
52
  else {
52
53
  this.error('Either --broker-id or --name must be provided.');
@@ -54,12 +55,4 @@ export default class MissionctrlBrokerDisplay extends ScCommand {
54
55
  // Return raw json if --json flag is set
55
56
  return rawResp;
56
57
  }
57
- print(broker) {
58
- const tableRows = [
59
- ['Key', 'Value'],
60
- ...Object.entries(broker).map(([key, value]) => [camelCaseToTitleCase(key), value]),
61
- ];
62
- this.log();
63
- this.log(renderKeyValueTable(tableRows));
64
- }
65
58
  }
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { EventBrokerServiceDetail } from '../../../types/broker.js';
2
+ import { EventBrokerListApiResponse } from '../../../types/broker.js';
3
3
  export default class MissionctrlBrokerList extends ScCommand<typeof MissionctrlBrokerList> {
4
4
  static args: {};
5
5
  static description: string;
@@ -10,5 +10,5 @@ export default class MissionctrlBrokerList extends ScCommand<typeof MissionctrlB
10
10
  pageSize: import("@oclif/core/interfaces").OptionFlag<number | undefined, import("@oclif/core/interfaces").CustomOptions>;
11
11
  sort: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
12
12
  };
13
- run(): Promise<EventBrokerServiceDetail[]>;
13
+ run(): Promise<EventBrokerListApiResponse>;
14
14
  }
@@ -9,17 +9,20 @@ export default class MissionctrlBrokerList extends ScCommand {
9
9
  Your token must have one of the permissions listed in the Token Permissions.
10
10
 
11
11
  Token Permissions: [ \`mission_control:access\` **or** \`services:get\` **or** \`services:get:self\` **or** \`services:view\` **or** \`services:view:self\` ]`;
12
- static examples = ['<%= config.bin %> <%= command.id %> --name=MyBrokerName --pageNumber=1 --pageSize=10 --sort=name:asc'];
12
+ static examples = [
13
+ '<%= config.bin %> <%= command.id %>',
14
+ '<%= config.bin %> <%= command.id %> --name=MyBrokerName --pageNumber=1 --pageSize=10 --sort=name:asc',
15
+ ];
13
16
  static flags = {
14
17
  name: Flags.string({
15
18
  char: 'n',
16
- description: 'Name of the event broker service to match on.'
19
+ description: 'Name of the event broker service to match on.',
17
20
  }),
18
21
  pageNumber: Flags.integer({
19
- description: 'The page number to get. Defaults to 1'
22
+ description: 'The page number to get. Defaults to 1',
20
23
  }),
21
24
  pageSize: Flags.integer({
22
- description: 'The number of event broker services to return per page. Defaults to 100',
25
+ description: 'The number of event broker services to return per page. Defaults to 10',
23
26
  max: 100,
24
27
  min: 1,
25
28
  }),
@@ -61,9 +64,8 @@ Token Permissions: [ \`mission_control:access\` **or** \`services:get\` **or** \
61
64
  ]),
62
65
  ];
63
66
  // Display results as a table
64
- this.log();
65
67
  this.log(renderTable(brokerArray));
66
68
  // Return raw json if --json flag is set
67
- return resp.data;
69
+ return resp;
68
70
  }
69
71
  }
@@ -0,0 +1,12 @@
1
+ import { ScCommand } from '../../../sc-command.js';
2
+ import { EventBrokerRedundancyApiResponse } from '../../../types/broker.js';
3
+ export default class MissionctrlBrokerState extends ScCommand<typeof MissionctrlBrokerState> {
4
+ static args: {};
5
+ static description: string;
6
+ static examples: string[];
7
+ static flags: {
8
+ 'broker-id': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
9
+ name: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
10
+ };
11
+ run(): Promise<EventBrokerRedundancyApiResponse>;
12
+ }
@@ -0,0 +1,54 @@
1
+ import { Flags } from '@oclif/core';
2
+ import { ScCommand } from '../../../sc-command.js';
3
+ import { printObjectAsKeyValueTable } from '../../../util/internal.js';
4
+ import { ScConnection } from '../../../util/sc-connection.js';
5
+ export default class MissionctrlBrokerState extends ScCommand {
6
+ static args = {};
7
+ static description = `Get the availability state of an event broker service and the name of the active messaging node using the service's unique identifier.
8
+
9
+ Your token must have one of the permissions listed in the Token Permissions.
10
+
11
+ Token Permissions: [ mission_control:access or services:get or services:get:self or services:view or services:view:self ]`;
12
+ static examples = [
13
+ '<%= config.bin %> <%= command.id %> --broker-id=MyBrokerServiceId',
14
+ '<%= config.bin %> <%= command.id %> --name=MyBrokerName',
15
+ ];
16
+ static flags = {
17
+ 'broker-id': Flags.string({
18
+ char: 'b',
19
+ description: 'Id of the event broker service.',
20
+ exactlyOne: ['broker-id', 'name'],
21
+ }),
22
+ name: Flags.string({
23
+ char: 'n',
24
+ description: 'Name of the event broker service.',
25
+ exactlyOne: ['broker-id', 'name'],
26
+ }),
27
+ };
28
+ async run() {
29
+ const { flags } = await this.parse(MissionctrlBrokerState);
30
+ const name = flags.name ?? '';
31
+ let brokerId = flags['broker-id'] ?? '';
32
+ const conn = new ScConnection();
33
+ // API url
34
+ let apiUrl = `/missionControl/eventBrokerServices`;
35
+ if (name) {
36
+ // If broker name provided, get the broker matching provided name. If more than one broker matches, an error will be thrown.
37
+ const resp = await conn.get(`${apiUrl}?customAttributes=name=="${name}"`);
38
+ if (resp.data.length === 0) {
39
+ this.error(`No brokers found with name: ${name}.`);
40
+ }
41
+ else if (resp.data.length > 1) {
42
+ this.error(`Multiple brokers found with name: ${name}. Exactly one event broker service must match the provided name.`);
43
+ }
44
+ else {
45
+ brokerId = resp.data[0]?.id;
46
+ }
47
+ }
48
+ // API call to update broker by id
49
+ apiUrl += `/${brokerId}/brokerState`;
50
+ const resp = await conn.get(apiUrl);
51
+ this.log(printObjectAsKeyValueTable(resp.data));
52
+ return resp;
53
+ }
54
+ }
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { EventBrokerOperationDetail } from '../../../types/broker.js';
2
+ import { EventBrokerOperationApiResponse } from '../../../types/broker.js';
3
3
  export default class MissionctrlBrokerUpdate extends ScCommand<typeof MissionctrlBrokerUpdate> {
4
4
  static args: {};
5
5
  static description: string;
@@ -10,6 +10,5 @@ export default class MissionctrlBrokerUpdate extends ScCommand<typeof Missionctr
10
10
  name: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
11
11
  'new-name': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
12
12
  };
13
- run(): Promise<EventBrokerOperationDetail>;
14
- private print;
13
+ run(): Promise<EventBrokerOperationApiResponse>;
15
14
  }
@@ -1,6 +1,6 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import { ScCommand } from '../../../sc-command.js';
3
- import { camelCaseToTitleCase, renderKeyValueTable } from '../../../util/internal.js';
3
+ import { printObjectAsKeyValueTable } from '../../../util/internal.js';
4
4
  import { ScConnection } from '../../../util/sc-connection.js';
5
5
  export default class MissionctrlBrokerUpdate extends ScCommand {
6
6
  static args = {};
@@ -10,7 +10,11 @@ export default class MissionctrlBrokerUpdate extends ScCommand {
10
10
  Your token must have one of the permissions listed in the Token Permissions.
11
11
 
12
12
  Token Permissions: [ mission_control:access or services:put ]`;
13
- static examples = ['<%= config.bin %> <%= command.id %>'];
13
+ static examples = [
14
+ '<%= config.bin %> <%= command.id %>',
15
+ '<%= config.bin %> <%= command.id %> --broker-id <broker-id> --new-name <new-name>',
16
+ '<%= config.bin %> <%= command.id %> --name <name> --new-name <new-name>',
17
+ ];
14
18
  static flags = {
15
19
  'broker-id': Flags.string({
16
20
  char: 'b',
@@ -63,15 +67,7 @@ export default class MissionctrlBrokerUpdate extends ScCommand {
63
67
  apiUrl += `/${brokerIdToUpdate}`;
64
68
  const resp = await conn.patch(apiUrl, body);
65
69
  this.log(`Broker with id '${brokerIdToUpdate}' has been updated successfully.`);
66
- this.print(resp.data);
67
- return resp.data;
68
- }
69
- print(broker) {
70
- const tableRows = [
71
- ['Key', 'Value'],
72
- ...Object.entries(broker).map(([key, value]) => [camelCaseToTitleCase(key), value]),
73
- ];
74
- this.log();
75
- this.log(renderKeyValueTable(tableRows));
70
+ this.log(printObjectAsKeyValueTable(resp.data));
71
+ return resp;
76
72
  }
77
73
  }
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { Environment } from '../../../types/environment.js';
2
+ import { EnvironmentApiResponse } from '../../../types/environment.js';
3
3
  export default class PlatformEnvCreate extends ScCommand<typeof PlatformEnvCreate> {
4
4
  static args: {};
5
5
  static description: string;
@@ -10,6 +10,5 @@ export default class PlatformEnvCreate extends ScCommand<typeof PlatformEnvCreat
10
10
  isProduction: import("@oclif/core/interfaces").BooleanFlag<boolean>;
11
11
  name: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
12
12
  };
13
- run(): Promise<Environment>;
14
- private print;
13
+ run(): Promise<EnvironmentApiResponse>;
15
14
  }
@@ -1,23 +1,25 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import { ScCommand } from '../../../sc-command.js';
3
- import { camelCaseToTitleCase, renderKeyValueTable } from '../../../util/internal.js';
3
+ import { printObjectAsKeyValueTable } from '../../../util/internal.js';
4
4
  import { ScConnection } from '../../../util/sc-connection.js';
5
5
  export default class PlatformEnvCreate extends ScCommand {
6
6
  static args = {};
7
7
  static description = `Create a new environment.
8
8
 
9
9
  Token Permissions: [ environments:edit ]`;
10
- static examples = ['<%= config.bin %> <%= command.id %> --name=MyEnvironment --desc="My environment description" --isDefault --isProduction'];
10
+ static examples = [
11
+ '<%= config.bin %> <%= command.id %> --name=MyEnvironment --desc="My environment description" --isDefault --isProduction',
12
+ ];
11
13
  static flags = {
12
14
  description: Flags.string({
13
15
  char: 'd',
14
- description: 'Description of the environment to create.'
16
+ description: 'Description of the environment to create.',
15
17
  }),
16
18
  isDefault: Flags.boolean({
17
- description: 'Indicates this is the organization’s default environment.'
19
+ description: `Indicates this is the organization's default environment.`,
18
20
  }),
19
21
  isProduction: Flags.boolean({
20
- description: `Indicates this is an organization’s production environment.
22
+ description: `Indicates this is an organization's production environment.
21
23
  This is an immutable field. If an environment needs to be migrated,
22
24
  architecture can be migrated to a new environment with the desired
23
25
  environment type instead.`,
@@ -25,7 +27,7 @@ export default class PlatformEnvCreate extends ScCommand {
25
27
  name: Flags.string({
26
28
  char: 'n',
27
29
  description: 'Name of the environment to create.',
28
- required: true
30
+ required: true,
29
31
  }),
30
32
  };
31
33
  async run() {
@@ -47,17 +49,8 @@ export default class PlatformEnvCreate extends ScCommand {
47
49
  // API call
48
50
  const resp = await conn.post(apiUrl, body);
49
51
  // Display results
50
- this.log('Environment created successfully.');
51
- this.print(resp.data);
52
+ this.log(printObjectAsKeyValueTable(resp.data));
52
53
  // Return raw json if --json flag is set
53
- return resp.data;
54
- }
55
- print(environment) {
56
- const tableRows = [
57
- ['Key', 'Value'],
58
- ...Object.entries(environment).map(([key, value]) => [camelCaseToTitleCase(key), value]),
59
- ];
60
- this.log();
61
- this.log(renderKeyValueTable(tableRows));
54
+ return resp;
62
55
  }
63
56
  }
@@ -6,17 +6,20 @@ export default class PlatformEnvDelete extends ScCommand {
6
6
  static description = `Delete an environment using either its name or unique identifier. The default environment cannot be deleted.
7
7
 
8
8
  Token Permissions: [ environments:edit ]`;
9
- static examples = ['<%= config.bin %> <%= command.id %> --name=MyEnvName', '<%= config.bin %> <%= command.id %> --env-id=MyEnvId'];
9
+ static examples = [
10
+ '<%= config.bin %> <%= command.id %> --name=MyEnvName',
11
+ '<%= config.bin %> <%= command.id %> --env-id=MyEnvId',
12
+ ];
10
13
  static flags = {
11
14
  'env-id': Flags.string({
12
15
  char: 'e',
13
16
  description: 'Id of the environment.',
14
- exactlyOne: ['env-id', 'name']
17
+ exactlyOne: ['env-id', 'name'],
15
18
  }),
16
19
  name: Flags.string({
17
20
  char: 'n',
18
21
  description: 'Name of the environment.',
19
- exactlyOne: ['env-id', 'name']
22
+ exactlyOne: ['env-id', 'name'],
20
23
  }),
21
24
  };
22
25
  async run() {
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { Environment } from '../../../types/environment.js';
2
+ import { EnvironmentApiResponse, EnvironmentListApiResponse } from '../../../types/environment.js';
3
3
  export default class PlatformEnvDisplay extends ScCommand<typeof PlatformEnvDisplay> {
4
4
  static args: {};
5
5
  static description: string;
@@ -8,6 +8,5 @@ export default class PlatformEnvDisplay extends ScCommand<typeof PlatformEnvDisp
8
8
  'env-id': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
9
9
  name: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
10
10
  };
11
- run(): Promise<Environment[]>;
12
- private print;
11
+ run(): Promise<EnvironmentApiResponse | EnvironmentListApiResponse>;
13
12
  }
@@ -1,6 +1,6 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import { ScCommand } from '../../../sc-command.js';
3
- import { camelCaseToTitleCase, renderKeyValueTable } from '../../../util/internal.js';
3
+ import { printObjectAsKeyValueTable } from '../../../util/internal.js';
4
4
  import { ScConnection } from '../../../util/sc-connection.js';
5
5
  export default class PlatformEnvDisplay extends ScCommand {
6
6
  static args = {};
@@ -9,17 +9,20 @@ export default class PlatformEnvDisplay extends ScCommand {
9
9
  Use either the Environment's ID (--env-id) or name of the Environment (--name).
10
10
 
11
11
  Required token permissions: [ environments:view ]`;
12
- static examples = ['<%= config.bin %> <%= command.id %> --name=MyEnvName', '<%= config.bin %> <%= command.id %> --env-id=MyEnvId'];
12
+ static examples = [
13
+ '<%= config.bin %> <%= command.id %> --name=MyEnvName',
14
+ '<%= config.bin %> <%= command.id %> --env-id=MyEnvId',
15
+ ];
13
16
  static flags = {
14
17
  'env-id': Flags.string({
15
18
  char: 'e',
16
19
  description: 'Id of the environment.',
17
- exactlyOne: ['env-id', 'name']
20
+ exactlyOne: ['env-id', 'name'],
18
21
  }),
19
22
  name: Flags.string({
20
23
  char: 'n',
21
24
  description: 'Name of the environment.',
22
- exactlyOne: ['env-id', 'name']
25
+ exactlyOne: ['env-id', 'name'],
23
26
  }),
24
27
  };
25
28
  async run() {
@@ -31,35 +34,22 @@ export default class PlatformEnvDisplay extends ScCommand {
31
34
  // If env name provided, get all environments matching provided name
32
35
  // If env id provided, get environment with that id
33
36
  let apiUrl = `/platform/environments`;
34
- let rawResp;
37
+ let resp;
35
38
  if (envId) {
36
39
  // API call to get environment by id
37
40
  apiUrl += `/${envId}`;
38
- const resp = await conn.get(apiUrl);
39
- this.print(resp.data);
40
- rawResp = [resp.data];
41
+ resp = await conn.get(apiUrl);
42
+ this.log(printObjectAsKeyValueTable(resp.data));
41
43
  }
42
- else if (name) {
44
+ else {
43
45
  // API call to get environment by name
44
46
  apiUrl += `?name=${name}`;
45
- const resp = await conn.get(apiUrl);
47
+ resp = await conn.get(apiUrl);
46
48
  for (const env of resp.data) {
47
- this.print(env);
49
+ this.log(printObjectAsKeyValueTable(env));
48
50
  }
49
- rawResp = resp.data;
50
- }
51
- else {
52
- this.error('Either --env-id or --name must be provided.');
53
51
  }
54
52
  // Return raw json if --json flag is set
55
- return rawResp;
56
- }
57
- print(environment) {
58
- const tableRows = [
59
- ['Key', 'Value'],
60
- ...Object.entries(environment).map(([key, value]) => [camelCaseToTitleCase(key), value]),
61
- ];
62
- this.log();
63
- this.log(renderKeyValueTable(tableRows));
53
+ return resp;
64
54
  }
65
55
  }
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { Environment } from '../../../types/environment.js';
2
+ import { EnvironmentListApiResponse } from '../../../types/environment.js';
3
3
  export default class PlatformEnvList extends ScCommand<typeof PlatformEnvList> {
4
4
  static args: {};
5
5
  static description: string;
@@ -10,5 +10,5 @@ export default class PlatformEnvList extends ScCommand<typeof PlatformEnvList> {
10
10
  pageSize: import("@oclif/core/interfaces").OptionFlag<number | undefined, import("@oclif/core/interfaces").CustomOptions>;
11
11
  sort: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
12
12
  };
13
- run(): Promise<Environment[]>;
13
+ run(): Promise<EnvironmentListApiResponse>;
14
14
  }
@@ -7,15 +7,18 @@ export default class PlatformEnvList extends ScCommand {
7
7
  static description = `Get a list of all Environments.
8
8
 
9
9
  Required token permissions: [ environments:view ]`;
10
- static examples = ['<%= config.bin %> <%= command.id %>', '<%= config.bin %> <%= command.id %> --name=Default --pageNumber=1 --pageSize=10 --sort=name:ASC'];
10
+ static examples = [
11
+ '<%= config.bin %> <%= command.id %>',
12
+ '<%= config.bin %> <%= command.id %> --name=Default --pageNumber=1 --pageSize=10 --sort=name:ASC',
13
+ ];
11
14
  static flags = {
12
15
  name: Flags.string({
13
16
  char: 'n',
14
- description: 'Name of the environment to match on.'
17
+ description: 'Name of the environment to match on.',
15
18
  }),
16
19
  pageNumber: Flags.integer({
17
20
  char: 'p',
18
- description: 'The page number to get. Defaults to 10'
21
+ description: 'The page number to get. Defaults to 10',
19
22
  }),
20
23
  pageSize: Flags.integer({
21
24
  char: 's',
@@ -48,12 +51,11 @@ export default class PlatformEnvList extends ScCommand {
48
51
  item.isDefault,
49
52
  item.isProduction,
50
53
  item.description,
51
- ])
54
+ ]),
52
55
  ];
53
56
  // Display results as a table
54
- this.log();
55
57
  this.log(renderTable(envArray, { 4: { width: 50, wrapWord: true } }));
56
58
  // Return raw json if --json flag is set
57
- return resp.data;
59
+ return resp;
58
60
  }
59
61
  }
@@ -1,5 +1,5 @@
1
1
  import { ScCommand } from '../../../sc-command.js';
2
- import { Environment } from '../../../types/environment.js';
2
+ import { EnvironmentApiResponse } from '../../../types/environment.js';
3
3
  export default class PlatformEnvUpdate extends ScCommand<typeof PlatformEnvUpdate> {
4
4
  static args: {};
5
5
  static description: string;
@@ -11,6 +11,5 @@ export default class PlatformEnvUpdate extends ScCommand<typeof PlatformEnvUpdat
11
11
  name: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
12
12
  'new-name': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
13
13
  };
14
- run(): Promise<Environment>;
15
- private print;
14
+ run(): Promise<EnvironmentApiResponse>;
16
15
  }
@@ -1,6 +1,6 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import { ScCommand } from '../../../sc-command.js';
3
- import { camelCaseToTitleCase, renderKeyValueTable } from '../../../util/internal.js';
3
+ import { printObjectAsKeyValueTable } from '../../../util/internal.js';
4
4
  import { ScConnection } from '../../../util/sc-connection.js';
5
5
  export default class PlatformEnvUpdate extends ScCommand {
6
6
  static args = {};
@@ -12,27 +12,28 @@ export default class PlatformEnvUpdate extends ScCommand {
12
12
  `;
13
13
  static examples = [
14
14
  '<%= config.bin %> <%= command.id %> --name=MyEnvName --new-name=MyNewEnvName --desc="My description to update" --isDefault',
15
- '<%= config.bin %> <%= command.id %> --env-id=MyEnvId --new-name=MyNewEnvName --desc="My description to update" --isDefault'
15
+ '<%= config.bin %> <%= command.id %> --env-id=MyEnvId --new-name=MyNewEnvName --desc="My description to update" --isDefault',
16
16
  ];
17
17
  static flags = {
18
18
  description: Flags.string({
19
19
  char: 'd',
20
- description: 'Description of the environment to update.'
20
+ description: 'Description of the environment to update.',
21
21
  }),
22
22
  'env-id': Flags.string({
23
23
  char: 'e',
24
24
  description: 'Id of the environment.',
25
- exactlyOne: ['env-id', 'name']
25
+ exactlyOne: ['env-id', 'name'],
26
26
  }),
27
27
  isDefault: Flags.boolean({
28
- description: `Indicates this is the organization's default environment. The default value is false.`
28
+ description: `Indicates this is the organization's default environment. The default value is false.`,
29
29
  }),
30
30
  name: Flags.string({
31
- char: 'n', description: 'Current name of the environment.',
32
- exactlyOne: ['env-id', 'name']
31
+ char: 'n',
32
+ description: 'Current name of the environment.',
33
+ exactlyOne: ['env-id', 'name'],
33
34
  }),
34
35
  'new-name': Flags.string({
35
- description: 'New name of the environment.'
36
+ description: 'New name of the environment.',
36
37
  }),
37
38
  };
38
39
  async run() {
@@ -67,16 +68,7 @@ export default class PlatformEnvUpdate extends ScCommand {
67
68
  // API call to update environment by id
68
69
  apiUrl += `/${envIdToUpdate}`;
69
70
  const resp = await conn.put(apiUrl, body);
70
- this.log(`Environment with id '${envIdToUpdate}' has been updated successfully.`);
71
- this.print(resp.data);
72
- return resp.data;
73
- }
74
- print(environment) {
75
- const tableRows = [
76
- ['Key', 'Value'],
77
- ...Object.entries(environment).map(([key, value]) => [camelCaseToTitleCase(key), value]),
78
- ];
79
- this.log();
80
- this.log(renderKeyValueTable(tableRows));
71
+ this.log(printObjectAsKeyValueTable(resp.data));
72
+ return resp;
81
73
  }
82
74
  }
@@ -57,6 +57,21 @@ export interface EventBrokerApiResponse {
57
57
  };
58
58
  };
59
59
  }
60
+ export interface EventBrokerRedundancyApiResponse {
61
+ data: {
62
+ id: string;
63
+ isHighAvailability: boolean;
64
+ redundancy: {
65
+ activeNode: string;
66
+ configSync: string;
67
+ redundancy: string;
68
+ };
69
+ type: string;
70
+ };
71
+ meta?: {
72
+ additionalProp?: Record<string, unknown>;
73
+ };
74
+ }
60
75
  export interface EventBrokerServiceDetail {
61
76
  adminState?: string;
62
77
  allowedActions?: string[];
@@ -19,7 +19,7 @@ export interface Environment {
19
19
  updatedBy?: string;
20
20
  updatedTime?: string;
21
21
  }
22
- export interface EnvironmentApiResponse {
22
+ export interface EnvironmentListApiResponse {
23
23
  data: Environment[];
24
24
  meta: {
25
25
  pagination: {
@@ -31,6 +31,6 @@ export interface EnvironmentApiResponse {
31
31
  };
32
32
  };
33
33
  }
34
- export interface EnvironmentDetail {
34
+ export interface EnvironmentApiResponse {
35
35
  data: Environment;
36
36
  }
@@ -8,6 +8,12 @@ export interface ColumnConfig {
8
8
  width?: number;
9
9
  wrapWord?: boolean;
10
10
  }
11
+ /**
12
+ * Prints object data in a formatted key-value table.
13
+ * @param data The object data to print
14
+ * @returns Formatted table string
15
+ */
16
+ export declare function printObjectAsKeyValueTable<T extends Record<string, unknown>>(data: T): string;
11
17
  export declare function renderTable<T>(data: T[][], columnConfig?: Record<number, ColumnConfig>): string;
12
18
  export declare function renderKeyValueTable<T>(data: T[][], columnConfig?: Record<number, ColumnConfig>): string;
13
19
  /**
@@ -11,10 +11,22 @@ export function camelCaseToTitleCase(text) {
11
11
  .replaceAll(/\s{2,}/g, ' ')
12
12
  .trim();
13
13
  }
14
+ /**
15
+ * Prints object data in a formatted key-value table.
16
+ * @param data The object data to print
17
+ * @returns Formatted table string
18
+ */
19
+ export function printObjectAsKeyValueTable(data) {
20
+ const tableRows = [
21
+ ['Key', 'Value'],
22
+ ...Object.entries(data).map(([key, value]) => [camelCaseToTitleCase(key), value]),
23
+ ];
24
+ return renderKeyValueTable(tableRows);
25
+ }
14
26
  export function renderTable(data, columnConfig) {
15
27
  // Table config
16
28
  const tableConfig = {
17
- columns: columnConfig
29
+ columns: columnConfig,
18
30
  };
19
31
  const tableStr = table(data, tableConfig);
20
32
  return tableStr;
@@ -258,6 +258,7 @@
258
258
  "args": {},
259
259
  "description": "Get a listing of event broker services.\n\nYour token must have one of the permissions listed in the Token Permissions.\n\nToken Permissions: [ `mission_control:access` **or** `services:get` **or** `services:get:self` **or** `services:view` **or** `services:view:self` ]",
260
260
  "examples": [
261
+ "<%= config.bin %> <%= command.id %>",
261
262
  "<%= config.bin %> <%= command.id %> --name=MyBrokerName --pageNumber=1 --pageSize=10 --sort=name:asc"
262
263
  ],
263
264
  "flags": {
@@ -300,7 +301,7 @@
300
301
  "type": "option"
301
302
  },
302
303
  "pageSize": {
303
- "description": "The number of event broker services to return per page. Defaults to 100",
304
+ "description": "The number of event broker services to return per page. Defaults to 10",
304
305
  "name": "pageSize",
305
306
  "hasDynamicHelp": false,
306
307
  "multiple": false,
@@ -412,12 +413,80 @@
412
413
  "opstatus.js"
413
414
  ]
414
415
  },
416
+ "missionctrl:broker:state": {
417
+ "aliases": [],
418
+ "args": {},
419
+ "description": "Get the availability state of an event broker service and the name of the active messaging node using the service's unique identifier.\n\n Your token must have one of the permissions listed in the Token Permissions.\n \n Token Permissions: [ mission_control:access or services:get or services:get:self or services:view or services:view:self ]",
420
+ "examples": [
421
+ "<%= config.bin %> <%= command.id %> --broker-id=MyBrokerServiceId",
422
+ "<%= config.bin %> <%= command.id %> --name=MyBrokerName"
423
+ ],
424
+ "flags": {
425
+ "json": {
426
+ "description": "Format output as json.",
427
+ "helpGroup": "GLOBAL",
428
+ "name": "json",
429
+ "allowNo": false,
430
+ "type": "boolean"
431
+ },
432
+ "log-level": {
433
+ "helpGroup": "GLOBAL",
434
+ "name": "log-level",
435
+ "summary": "Specify level for logging.",
436
+ "default": "info",
437
+ "hasDynamicHelp": false,
438
+ "multiple": false,
439
+ "options": [
440
+ "debug",
441
+ "warn",
442
+ "error",
443
+ "info",
444
+ "trace"
445
+ ],
446
+ "type": "option"
447
+ },
448
+ "broker-id": {
449
+ "char": "b",
450
+ "description": "Id of the event broker service.",
451
+ "name": "broker-id",
452
+ "hasDynamicHelp": false,
453
+ "multiple": false,
454
+ "type": "option"
455
+ },
456
+ "name": {
457
+ "char": "n",
458
+ "description": "Name of the event broker service.",
459
+ "name": "name",
460
+ "hasDynamicHelp": false,
461
+ "multiple": false,
462
+ "type": "option"
463
+ }
464
+ },
465
+ "hasDynamicHelp": false,
466
+ "hiddenAliases": [],
467
+ "id": "missionctrl:broker:state",
468
+ "pluginAlias": "@dishantlangayan/solace-cloud-cli",
469
+ "pluginName": "@dishantlangayan/solace-cloud-cli",
470
+ "pluginType": "core",
471
+ "strict": true,
472
+ "enableJsonFlag": true,
473
+ "isESM": true,
474
+ "relativePath": [
475
+ "dist",
476
+ "commands",
477
+ "missionctrl",
478
+ "broker",
479
+ "state.js"
480
+ ]
481
+ },
415
482
  "missionctrl:broker:update": {
416
483
  "aliases": [],
417
484
  "args": {},
418
485
  "description": "Update the configuration of an existing event broker service. \n You can provide any combination of supported flags. If a flag is not provided, then it will not be updated.\n \n Your token must have one of the permissions listed in the Token Permissions.\n\n Token Permissions: [ mission_control:access or services:put ]",
419
486
  "examples": [
420
- "<%= config.bin %> <%= command.id %>"
487
+ "<%= config.bin %> <%= command.id %>",
488
+ "<%= config.bin %> <%= command.id %> --broker-id <broker-id> --new-name <new-name>",
489
+ "<%= config.bin %> <%= command.id %> --name <name> --new-name <new-name>"
421
490
  ],
422
491
  "flags": {
423
492
  "json": {
@@ -532,13 +601,13 @@
532
601
  "type": "option"
533
602
  },
534
603
  "isDefault": {
535
- "description": "Indicates this is the organization’s default environment.",
604
+ "description": "Indicates this is the organization's default environment.",
536
605
  "name": "isDefault",
537
606
  "allowNo": false,
538
607
  "type": "boolean"
539
608
  },
540
609
  "isProduction": {
541
- "description": "Indicates this is an organization’s production environment. \n This is an immutable field. If an environment needs to be migrated, \n architecture can be migrated to a new environment with the desired \n environment type instead.",
610
+ "description": "Indicates this is an organization's production environment. \n This is an immutable field. If an environment needs to be migrated, \n architecture can be migrated to a new environment with the desired \n environment type instead.",
542
611
  "name": "isProduction",
543
612
  "allowNo": false,
544
613
  "type": "boolean"
@@ -871,5 +940,5 @@
871
940
  ]
872
941
  }
873
942
  },
874
- "version": "0.1.0"
943
+ "version": "0.1.1"
875
944
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@dishantlangayan/solace-cloud-cli",
3
3
  "description": "The Solace Cloud CLI",
4
- "version": "0.1.0",
4
+ "version": "0.1.1",
5
5
  "author": "Dishant Langayan",
6
6
  "bin": {
7
7
  "sc": "./bin/run.js"