swaggerhub-cli 0.6.4 → 0.6.5
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 +31 -31
- package/oclif.manifest.json +1 -1
- package/package.json +1 -1
- package/src/commands/api/validate.js +11 -0
package/README.md
CHANGED
|
@@ -172,7 +172,7 @@ EXAMPLES
|
|
|
172
172
|
swaggerhub api:create organization/api/1.0.0 --published=publish --setdefault --file api.json
|
|
173
173
|
```
|
|
174
174
|
|
|
175
|
-
_See code: [src/commands/api/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
175
|
+
_See code: [src/commands/api/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/api/create.js)_
|
|
176
176
|
|
|
177
177
|
## `swaggerhub api:delete`
|
|
178
178
|
|
|
@@ -195,7 +195,7 @@ EXAMPLES
|
|
|
195
195
|
swaggerhub api:delete organization/api --force
|
|
196
196
|
```
|
|
197
197
|
|
|
198
|
-
_See code: [src/commands/api/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
198
|
+
_See code: [src/commands/api/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/api/delete.js)_
|
|
199
199
|
|
|
200
200
|
## `swaggerhub api:get`
|
|
201
201
|
|
|
@@ -222,7 +222,7 @@ EXAMPLES
|
|
|
222
222
|
swaggerhub api:get organization/api/1.0.0 --json
|
|
223
223
|
```
|
|
224
224
|
|
|
225
|
-
_See code: [src/commands/api/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
225
|
+
_See code: [src/commands/api/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/api/get.js)_
|
|
226
226
|
|
|
227
227
|
## `swaggerhub api:publish`
|
|
228
228
|
|
|
@@ -244,7 +244,7 @@ EXAMPLES
|
|
|
244
244
|
swaggerhub api:publish organization/api/1.0.0 --force
|
|
245
245
|
```
|
|
246
246
|
|
|
247
|
-
_See code: [src/commands/api/publish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
247
|
+
_See code: [src/commands/api/publish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/api/publish.js)_
|
|
248
248
|
|
|
249
249
|
## `swaggerhub api:setdefault`
|
|
250
250
|
|
|
@@ -264,7 +264,7 @@ EXAMPLE
|
|
|
264
264
|
swaggerhub api:setdefault organization/api/2.0.0
|
|
265
265
|
```
|
|
266
266
|
|
|
267
|
-
_See code: [src/commands/api/setdefault.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
267
|
+
_See code: [src/commands/api/setdefault.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/api/setdefault.js)_
|
|
268
268
|
|
|
269
269
|
## `swaggerhub api:unpublish`
|
|
270
270
|
|
|
@@ -284,7 +284,7 @@ EXAMPLE
|
|
|
284
284
|
swaggerhub api:unpublish organization/api/1.0.0
|
|
285
285
|
```
|
|
286
286
|
|
|
287
|
-
_See code: [src/commands/api/unpublish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
287
|
+
_See code: [src/commands/api/unpublish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/api/unpublish.js)_
|
|
288
288
|
|
|
289
289
|
## `swaggerhub api:update`
|
|
290
290
|
|
|
@@ -318,7 +318,7 @@ EXAMPLES
|
|
|
318
318
|
swaggerhub api:update organization/api/1.0.0 --visibility=private
|
|
319
319
|
```
|
|
320
320
|
|
|
321
|
-
_See code: [src/commands/api/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
321
|
+
_See code: [src/commands/api/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/api/update.js)_
|
|
322
322
|
|
|
323
323
|
## `swaggerhub api:validate`
|
|
324
324
|
|
|
@@ -343,7 +343,7 @@ EXAMPLES
|
|
|
343
343
|
swaggerhub api:validate organization/api
|
|
344
344
|
```
|
|
345
345
|
|
|
346
|
-
_See code: [src/commands/api/validate.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
346
|
+
_See code: [src/commands/api/validate.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/api/validate.js)_
|
|
347
347
|
|
|
348
348
|
## `swaggerhub configure`
|
|
349
349
|
|
|
@@ -365,7 +365,7 @@ DESCRIPTION
|
|
|
365
365
|
settings.
|
|
366
366
|
```
|
|
367
367
|
|
|
368
|
-
_See code: [src/commands/configure.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
368
|
+
_See code: [src/commands/configure.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/configure.js)_
|
|
369
369
|
|
|
370
370
|
## `swaggerhub domain:create`
|
|
371
371
|
|
|
@@ -397,7 +397,7 @@ EXAMPLES
|
|
|
397
397
|
swaggerhub domain:create organization/domain/1.0.0 --publish --setdefault --file domain.json
|
|
398
398
|
```
|
|
399
399
|
|
|
400
|
-
_See code: [src/commands/domain/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
400
|
+
_See code: [src/commands/domain/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/domain/create.js)_
|
|
401
401
|
|
|
402
402
|
## `swaggerhub domain:delete`
|
|
403
403
|
|
|
@@ -420,7 +420,7 @@ EXAMPLES
|
|
|
420
420
|
swaggerhub domain:delete organization/domain --force
|
|
421
421
|
```
|
|
422
422
|
|
|
423
|
-
_See code: [src/commands/domain/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
423
|
+
_See code: [src/commands/domain/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/domain/delete.js)_
|
|
424
424
|
|
|
425
425
|
## `swaggerhub domain:get`
|
|
426
426
|
|
|
@@ -446,7 +446,7 @@ EXAMPLES
|
|
|
446
446
|
swaggerhub domain:get organization/domain/1.0.0 --json
|
|
447
447
|
```
|
|
448
448
|
|
|
449
|
-
_See code: [src/commands/domain/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
449
|
+
_See code: [src/commands/domain/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/domain/get.js)_
|
|
450
450
|
|
|
451
451
|
## `swaggerhub domain:publish`
|
|
452
452
|
|
|
@@ -466,7 +466,7 @@ EXAMPLE
|
|
|
466
466
|
swaggerhub domain:publish organization/domain/1.0.0
|
|
467
467
|
```
|
|
468
468
|
|
|
469
|
-
_See code: [src/commands/domain/publish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
469
|
+
_See code: [src/commands/domain/publish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/domain/publish.js)_
|
|
470
470
|
|
|
471
471
|
## `swaggerhub domain:setdefault`
|
|
472
472
|
|
|
@@ -486,7 +486,7 @@ EXAMPLE
|
|
|
486
486
|
swaggerhub domain:setdefault organization/domain/2.0.0
|
|
487
487
|
```
|
|
488
488
|
|
|
489
|
-
_See code: [src/commands/domain/setdefault.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
489
|
+
_See code: [src/commands/domain/setdefault.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/domain/setdefault.js)_
|
|
490
490
|
|
|
491
491
|
## `swaggerhub domain:unpublish`
|
|
492
492
|
|
|
@@ -506,7 +506,7 @@ EXAMPLE
|
|
|
506
506
|
swaggerhub domain:unpublish organization/domain/1.0.0
|
|
507
507
|
```
|
|
508
508
|
|
|
509
|
-
_See code: [src/commands/domain/unpublish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
509
|
+
_See code: [src/commands/domain/unpublish.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/domain/unpublish.js)_
|
|
510
510
|
|
|
511
511
|
## `swaggerhub domain:update`
|
|
512
512
|
|
|
@@ -540,7 +540,7 @@ EXAMPLES
|
|
|
540
540
|
swaggerhub domain:update organization/domain/1.0.0 --visibility=private
|
|
541
541
|
```
|
|
542
542
|
|
|
543
|
-
_See code: [src/commands/domain/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
543
|
+
_See code: [src/commands/domain/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/domain/update.js)_
|
|
544
544
|
|
|
545
545
|
## `swaggerhub help`
|
|
546
546
|
|
|
@@ -583,7 +583,7 @@ EXAMPLE
|
|
|
583
583
|
swaggerhub integration:create organization/api/1.0.0 --file config.json
|
|
584
584
|
```
|
|
585
585
|
|
|
586
|
-
_See code: [src/commands/integration/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
586
|
+
_See code: [src/commands/integration/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/integration/create.js)_
|
|
587
587
|
|
|
588
588
|
## `swaggerhub integration:delete`
|
|
589
589
|
|
|
@@ -603,7 +603,7 @@ EXAMPLE
|
|
|
603
603
|
swaggerhub integration:delete organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704
|
|
604
604
|
```
|
|
605
605
|
|
|
606
|
-
_See code: [src/commands/integration/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
606
|
+
_See code: [src/commands/integration/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/integration/delete.js)_
|
|
607
607
|
|
|
608
608
|
## `swaggerhub integration:execute`
|
|
609
609
|
|
|
@@ -623,7 +623,7 @@ EXAMPLE
|
|
|
623
623
|
swaggerhub integration:execute organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704
|
|
624
624
|
```
|
|
625
625
|
|
|
626
|
-
_See code: [src/commands/integration/execute.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
626
|
+
_See code: [src/commands/integration/execute.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/integration/execute.js)_
|
|
627
627
|
|
|
628
628
|
## `swaggerhub integration:get`
|
|
629
629
|
|
|
@@ -643,7 +643,7 @@ EXAMPLE
|
|
|
643
643
|
swaggerhub integration:get organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704
|
|
644
644
|
```
|
|
645
645
|
|
|
646
|
-
_See code: [src/commands/integration/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
646
|
+
_See code: [src/commands/integration/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/integration/get.js)_
|
|
647
647
|
|
|
648
648
|
## `swaggerhub integration:list`
|
|
649
649
|
|
|
@@ -663,7 +663,7 @@ EXAMPLE
|
|
|
663
663
|
swaggerhub integration:list organization/api/1.0.0
|
|
664
664
|
```
|
|
665
665
|
|
|
666
|
-
_See code: [src/commands/integration/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
666
|
+
_See code: [src/commands/integration/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/integration/list.js)_
|
|
667
667
|
|
|
668
668
|
## `swaggerhub integration:update`
|
|
669
669
|
|
|
@@ -684,7 +684,7 @@ EXAMPLE
|
|
|
684
684
|
swaggerhub integration:update organization/api/1.0.0/503c2db6-448a-4678-abcd-0123456789abc --file config.json
|
|
685
685
|
```
|
|
686
686
|
|
|
687
|
-
_See code: [src/commands/integration/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
687
|
+
_See code: [src/commands/integration/update.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/integration/update.js)_
|
|
688
688
|
|
|
689
689
|
## `swaggerhub plugins`
|
|
690
690
|
|
|
@@ -843,7 +843,7 @@ EXAMPLE
|
|
|
843
843
|
swaggerhub project:api:add organization/project_name my_api
|
|
844
844
|
```
|
|
845
845
|
|
|
846
|
-
_See code: [src/commands/project/api/add.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
846
|
+
_See code: [src/commands/project/api/add.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/api/add.js)_
|
|
847
847
|
|
|
848
848
|
## `swaggerhub project:api:remove`
|
|
849
849
|
|
|
@@ -864,7 +864,7 @@ EXAMPLE
|
|
|
864
864
|
swaggerhub project:api:remove organization/project_name my_api
|
|
865
865
|
```
|
|
866
866
|
|
|
867
|
-
_See code: [src/commands/project/api/remove.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
867
|
+
_See code: [src/commands/project/api/remove.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/api/remove.js)_
|
|
868
868
|
|
|
869
869
|
## `swaggerhub project:create`
|
|
870
870
|
|
|
@@ -892,7 +892,7 @@ EXAMPLES
|
|
|
892
892
|
swaggerhub project:create organization/new_project_name -a "testapi1" -d "testdomain3" --description "description"
|
|
893
893
|
```
|
|
894
894
|
|
|
895
|
-
_See code: [src/commands/project/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
895
|
+
_See code: [src/commands/project/create.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/create.js)_
|
|
896
896
|
|
|
897
897
|
## `swaggerhub project:delete`
|
|
898
898
|
|
|
@@ -912,7 +912,7 @@ EXAMPLE
|
|
|
912
912
|
swaggerhub project:delete organization/project_name
|
|
913
913
|
```
|
|
914
914
|
|
|
915
|
-
_See code: [src/commands/project/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
915
|
+
_See code: [src/commands/project/delete.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/delete.js)_
|
|
916
916
|
|
|
917
917
|
## `swaggerhub project:domain:add`
|
|
918
918
|
|
|
@@ -933,7 +933,7 @@ EXAMPLE
|
|
|
933
933
|
swaggerhub project:domain:add organization/project_name my_domain
|
|
934
934
|
```
|
|
935
935
|
|
|
936
|
-
_See code: [src/commands/project/domain/add.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
936
|
+
_See code: [src/commands/project/domain/add.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/domain/add.js)_
|
|
937
937
|
|
|
938
938
|
## `swaggerhub project:domain:remove`
|
|
939
939
|
|
|
@@ -954,7 +954,7 @@ EXAMPLE
|
|
|
954
954
|
swaggerhub project:domain:remove organization/project_name my_domain
|
|
955
955
|
```
|
|
956
956
|
|
|
957
|
-
_See code: [src/commands/project/domain/remove.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
957
|
+
_See code: [src/commands/project/domain/remove.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/domain/remove.js)_
|
|
958
958
|
|
|
959
959
|
## `swaggerhub project:get`
|
|
960
960
|
|
|
@@ -974,7 +974,7 @@ EXAMPLE
|
|
|
974
974
|
swaggerhub project:get organization/project_name
|
|
975
975
|
```
|
|
976
976
|
|
|
977
|
-
_See code: [src/commands/project/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
977
|
+
_See code: [src/commands/project/get.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/get.js)_
|
|
978
978
|
|
|
979
979
|
## `swaggerhub project:list`
|
|
980
980
|
|
|
@@ -995,7 +995,7 @@ EXAMPLES
|
|
|
995
995
|
swaggerhub project:list organization
|
|
996
996
|
```
|
|
997
997
|
|
|
998
|
-
_See code: [src/commands/project/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
998
|
+
_See code: [src/commands/project/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/list.js)_
|
|
999
999
|
|
|
1000
1000
|
## `swaggerhub project:member:list`
|
|
1001
1001
|
|
|
@@ -1015,7 +1015,7 @@ EXAMPLE
|
|
|
1015
1015
|
swaggerhub project:member:list organisation/project_name
|
|
1016
1016
|
```
|
|
1017
1017
|
|
|
1018
|
-
_See code: [src/commands/project/member/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.
|
|
1018
|
+
_See code: [src/commands/project/member/list.js](https://github.com/SmartBear/swaggerhub-cli/blob/v0.6.5/src/commands/project/member/list.js)_
|
|
1019
1019
|
<!-- commandsstop -->
|
|
1020
1020
|
|
|
1021
1021
|
# Plugins
|
package/oclif.manifest.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"0.6.4","commands":{"configure":{"id":"configure","description":"configure application settings\nEnter the SwaggerHub URL - default is https://api.swaggerhub.com\nCustomers with on-premise installations need to point this to their on-premise API, which is http(s)://{swaggerhub-host}/v1\nEnter the API Key - this can be retrieved from https://app.swaggerhub.com/settings/apiKey\nYou can set these as environment variables: SWAGGERHUB_URL, SWAGGERHUB_API_KEY. These take priority over config settings.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[]},"api:create":{"id":"api:create","description":"creates a new API / API version from a YAML/JSON file\nThe API version from the file will be used unless the version is specified in the command argument.\nAn error will occur if the API version already exists.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:create organization/api/1.0.0 --file api.yaml --visibility public","swaggerhub api:create organization/api --file api.yaml","swaggerhub api:create organization/api/1.0.0 --published=publish --file api.json","swaggerhub api:create organization/api/1.0.0 --setdefault --file api.json","swaggerhub api:create organization/api/1.0.0 --published=publish --setdefault --file api.json"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"file location of API to create","required":true},"visibility":{"name":"visibility","type":"option","description":"visibility of API in SwaggerHub","options":["public","private"],"default":"private"},"published":{"name":"published","type":"option","description":"sets the lifecycle setting of the API version","required":false,"options":["publish","unpublish"],"default":"unpublish"},"setdefault":{"name":"setdefault","type":"boolean","description":"sets API version to be the default","required":false,"allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API to create in SwaggerHub","required":true}]},"api:delete":{"id":"api:delete","description":"delete an API or API version\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:delete organization/api/1.0.0","swaggerhub api:delete organization/api","swaggerhub api:delete organization/api --force"],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"delete API without prompting for confirmation","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API to delete in SwaggerHub","required":true}]},"api:get":{"id":"api:get","description":"fetches an API definition\nWhen VERSION is not included in the argument, the default version will be returned.\nReturns the API in YAML format by default.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:get organization/api","swaggerhub api:get organization/api/1.0.0 --json"],"flags":{"json":{"name":"json","type":"boolean","char":"j","description":"returns the API in JSON format.","allowNo":false},"resolved":{"name":"resolved","type":"boolean","char":"r","description":"gets the resolved API definition (supported in v1.25+). ","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"SwaggerHub API to fetch","required":true}]},"api:publish":{"id":"api:publish","description":"publish an API version","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:publish organization/api/1.0.0","swaggerhub api:publish organization/api/1.0.0 --force"],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"publish API without prompting for confirmation","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION","description":"API identifier","required":true}]},"api:setdefault":{"id":"api:setdefault","description":"set the default version of an API","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:setdefault organization/api/2.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION","description":"API identifier","required":true}]},"api:unpublish":{"id":"api:unpublish","description":"unpublish an API version","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:unpublish organization/api/1.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION","description":"API identifier","required":true}]},"api:update":{"id":"api:update","description":"update an API\nThe API version from the file will be used unless the version is specified in the command argument.\nWhen no file is specified then the default API version will be updated.\nThe API visibility can be changed by using visibility flag.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:update organization/api --file api.yaml","swaggerhub api:update organization/api/1.0.0 --file api.json","swaggerhub api:update organization/api/1.0.0 --published=publish --file api.json","swaggerhub api:update organization/api/1.0.0 --setdefault --file api.json","swaggerhub api:update organization/api/1.0.0 --published=unpublish --setdefault --file api.json","swaggerhub api:update organization/api/1.0.0 --visibility=private"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"file location of API to update","required":false},"visibility":{"name":"visibility","type":"option","description":"visibility of API in SwaggerHub","options":["public","private"]},"published":{"name":"published","type":"option","description":"sets the lifecycle setting of the API version","required":false,"options":["publish","unpublish"]},"setdefault":{"name":"setdefault","type":"boolean","description":"sets API version to be the default","required":false,"allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API to update in SwaggerHub","required":true}]},"api:validate":{"id":"api:validate","description":"get validation result for an API version\nWhen VERSION is not included in the argument, the default version will be validated.\nAn error will occur if the API version does not exist.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:validate organization/api/1.0.0","swaggerhub api:validate organization/api"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API Identifier","required":true}]},"domain:create":{"id":"domain:create","description":"creates a new domain / domain version from a YAML/JSON file\nThe domain version from the file will be used unless the version is specified in the command argument.\nAn error will occur if the domain version already exists.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:create organization/domain/1.0.0 --file domain.yaml --visibility public","swaggerhub domain:create organization/domain --file domain.yaml","swaggerhub domain:create organization/domain/1.0.0 --publish --file domain.json","swaggerhub domain:create organization/domain/1.0.0 --setdefault --file domain.json","swaggerhub domain:create organization/domain/1.0.0 --publish --setdefault --file domain.json"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"file location of domain to create","required":true},"visibility":{"name":"visibility","type":"option","description":"visibility of domain in SwaggerHub","options":["public","private"],"default":"private"},"published":{"name":"published","type":"option","description":"sets the lifecycle setting of the domain version","required":false,"options":["publish","unpublish"],"default":"unpublish"},"setdefault":{"name":"setdefault","type":"boolean","description":"sets domain version to be the default","required":false,"allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/[VERSION]","description":"Domain to create in SwaggerHub","required":true}]},"domain:delete":{"id":"domain:delete","description":"delete a domain or domain version\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:delete organization/domain/1.0.0","swaggerhub domain:delete organization/domain","swaggerhub domain:delete organization/domain --force"],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"delete domain without prompting for confirmation","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/[VERSION]","description":"Domain to delete in SwaggerHub","required":true}]},"domain:get":{"id":"domain:get","description":"fetches a domain definition\nWhen VERSION is not included in the argument, the default version will be returned.\nReturns the domain in YAML format by default.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:get organization/domain","swaggerhub domain:get organization/domain/1.0.0 --json"],"flags":{"json":{"name":"json","type":"boolean","char":"j","description":"returns the domain in JSON format.","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/[VERSION]","description":"SwaggerHub domain to fetch","required":true}]},"domain:publish":{"id":"domain:publish","description":"publish a domain version","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:publish organization/domain/1.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/VERSION","description":"Domain identifier","required":true}]},"domain:setdefault":{"id":"domain:setdefault","description":"set the default version of a domain","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:setdefault organization/domain/2.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/VERSION","description":"domain identifier","required":true}]},"domain:unpublish":{"id":"domain:unpublish","description":"unpublish a domain version","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:unpublish organization/domain/1.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/VERSION","description":"Domain identifier","required":true}]},"domain:update":{"id":"domain:update","description":"update a domain\nThe domain version from the file will be used unless the version is specified in the command argument.\nWhen no file is specified then the default domain version will be updated.\nThe domain visibility can be changed by using visibility flag.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:update organization/domain --file domain.yaml","swaggerhub domain:update organization/domain/1.0.0 --file domain.json","swaggerhub domain:update organization/domain/1.0.0 --published=publish --file domain.json","swaggerhub domain:update organization/domain/1.0.0 --setdefault --file domain.json","swaggerhub domain:update organization/domain/1.0.0 --published=unpublish --setdefault --file domain.json","swaggerhub domain:update organization/domain/1.0.0 --visibility=private"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"file location of domain to update","required":false},"visibility":{"name":"visibility","type":"option","description":"visibility of domain in SwaggerHub","options":["public","private"]},"published":{"name":"published","type":"option","description":"sets the lifecycle setting of the domain version","required":false,"options":["publish","unpublish"]},"setdefault":{"name":"setdefault","type":"boolean","description":"sets domain version to be the default","required":false,"allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/[VERSION]","description":"domain to update in SwaggerHub","required":true}]},"integration:create":{"id":"integration:create","description":"creates a new API integration from a JSON configuration file.\nSee the documentation for configuration files: https://github.com/SmartBear/swaggerhub-cli/tree/master/examples/integrations\nWhen VERSION is not included in the argument, the integration will be added to be default API version.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:create organization/api/1.0.0 --file config.json"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"location of integration configuration file","required":true},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API where integration will be added","required":true}]},"integration:delete":{"id":"integration:delete","description":"deletes the integration from the given API.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:delete organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION/INTEGRATION_ID","description":"Integration to delete","required":true}]},"integration:execute":{"id":"integration:execute","description":"executes an integration for the given API.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:execute organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION/INTEGRATION_ID","description":"Integration to execute for given API","required":true}]},"integration:get":{"id":"integration:get","description":"retieves an integration for the given API.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:get organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION/INTEGRATION_ID","description":"Integration to fetch for given API","required":true}]},"integration:list":{"id":"integration:list","description":"list integrations on an API.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:list organization/api/1.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API to list integrations on","required":true}]},"integration:update":{"id":"integration:update","description":"update the configuration of an API integration.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:update organization/api/1.0.0/503c2db6-448a-4678-abcd-0123456789abc --file config.json"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"location of integration configuration file","required":true},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION/INTEGRATION_ID","description":"Integration to update on the given API","required":true}]},"project:create":{"id":"project:create","description":"Creates a new project in SwaggerHub.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:create organization/new_project_name --description \"project description\"","swaggerhub project:create organization/new_project_name -a \"testapi1,testapi2\"","swaggerhub project:create organization/new_project_name --apis \"testapi1,testapi2\"","swaggerhub project:create organization/new_project_name -d \"testdomain3,testdomain4\"","swaggerhub project:create organization/new_project_name --domains \"testdomain3,testdomain4\"","swaggerhub project:create organization/new_project_name -a \"testapi1\" -d \"testdomain3\" --description \"description\""],"flags":{"description":{"name":"description","type":"option","description":"Description of project","required":false},"apis":{"name":"apis","type":"option","char":"a","description":"Comma separated list of api names to include in project","required":false},"domains":{"name":"domains","type":"option","char":"d","description":"Comma separated list of domain names to include in project","required":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The new project to create","required":true}]},"project:delete":{"id":"project:delete","description":"Deletes a project from SwaggerHub.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:delete organization/project_name"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"Project to delete","required":true}]},"project:get":{"id":"project:get","description":"Retrieves the details for a project.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:get organization/project_name"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"Project to retrieve the details for","required":true}]},"project:list":{"id":"project:list","description":"list projects","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:list","swaggerhub project:list organization"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER","description":"Organization to list projects for","required":false}]},"project:api:add":{"id":"project:api:add","description":"Adds an API to an existing project.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:api:add organization/project_name my_api"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The project to add the API to","required":true},{"name":"API","description":"The name of the API to add","required":true}]},"project:api:remove":{"id":"project:api:remove","description":"Removes an API from a project in SwaggerHub.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:api:remove organization/project_name my_api"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The project remove the API from","required":true},{"name":"API","description":"The API to remove","required":true}]},"project:domain:add":{"id":"project:domain:add","description":"Adds a domain to an existing project.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:domain:add organization/project_name my_domain"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The project to add the domain to","required":true},{"name":"DOMAIN","description":"The name of the domain to add","required":true}]},"project:domain:remove":{"id":"project:domain:remove","description":"Removes a domain from a project in SwaggerHub.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:domain:remove organization/project_name my_domain"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The project remove the domain from","required":true},{"name":"DOMAIN","description":"The domain to remove","required":true}]},"project:member:list":{"id":"project:member:list","description":"list members of a project","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:member:list organisation/project_name"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"Project to list members of","required":true}]}}}
|
|
1
|
+
{"version":"0.6.5","commands":{"configure":{"id":"configure","description":"configure application settings\nEnter the SwaggerHub URL - default is https://api.swaggerhub.com\nCustomers with on-premise installations need to point this to their on-premise API, which is http(s)://{swaggerhub-host}/v1\nEnter the API Key - this can be retrieved from https://app.swaggerhub.com/settings/apiKey\nYou can set these as environment variables: SWAGGERHUB_URL, SWAGGERHUB_API_KEY. These take priority over config settings.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[]},"api:create":{"id":"api:create","description":"creates a new API / API version from a YAML/JSON file\nThe API version from the file will be used unless the version is specified in the command argument.\nAn error will occur if the API version already exists.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:create organization/api/1.0.0 --file api.yaml --visibility public","swaggerhub api:create organization/api --file api.yaml","swaggerhub api:create organization/api/1.0.0 --published=publish --file api.json","swaggerhub api:create organization/api/1.0.0 --setdefault --file api.json","swaggerhub api:create organization/api/1.0.0 --published=publish --setdefault --file api.json"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"file location of API to create","required":true},"visibility":{"name":"visibility","type":"option","description":"visibility of API in SwaggerHub","options":["public","private"],"default":"private"},"published":{"name":"published","type":"option","description":"sets the lifecycle setting of the API version","required":false,"options":["publish","unpublish"],"default":"unpublish"},"setdefault":{"name":"setdefault","type":"boolean","description":"sets API version to be the default","required":false,"allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API to create in SwaggerHub","required":true}]},"api:delete":{"id":"api:delete","description":"delete an API or API version\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:delete organization/api/1.0.0","swaggerhub api:delete organization/api","swaggerhub api:delete organization/api --force"],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"delete API without prompting for confirmation","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API to delete in SwaggerHub","required":true}]},"api:get":{"id":"api:get","description":"fetches an API definition\nWhen VERSION is not included in the argument, the default version will be returned.\nReturns the API in YAML format by default.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:get organization/api","swaggerhub api:get organization/api/1.0.0 --json"],"flags":{"json":{"name":"json","type":"boolean","char":"j","description":"returns the API in JSON format.","allowNo":false},"resolved":{"name":"resolved","type":"boolean","char":"r","description":"gets the resolved API definition (supported in v1.25+). ","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"SwaggerHub API to fetch","required":true}]},"api:publish":{"id":"api:publish","description":"publish an API version","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:publish organization/api/1.0.0","swaggerhub api:publish organization/api/1.0.0 --force"],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"publish API without prompting for confirmation","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION","description":"API identifier","required":true}]},"api:setdefault":{"id":"api:setdefault","description":"set the default version of an API","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:setdefault organization/api/2.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION","description":"API identifier","required":true}]},"api:unpublish":{"id":"api:unpublish","description":"unpublish an API version","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:unpublish organization/api/1.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION","description":"API identifier","required":true}]},"api:update":{"id":"api:update","description":"update an API\nThe API version from the file will be used unless the version is specified in the command argument.\nWhen no file is specified then the default API version will be updated.\nThe API visibility can be changed by using visibility flag.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:update organization/api --file api.yaml","swaggerhub api:update organization/api/1.0.0 --file api.json","swaggerhub api:update organization/api/1.0.0 --published=publish --file api.json","swaggerhub api:update organization/api/1.0.0 --setdefault --file api.json","swaggerhub api:update organization/api/1.0.0 --published=unpublish --setdefault --file api.json","swaggerhub api:update organization/api/1.0.0 --visibility=private"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"file location of API to update","required":false},"visibility":{"name":"visibility","type":"option","description":"visibility of API in SwaggerHub","options":["public","private"]},"published":{"name":"published","type":"option","description":"sets the lifecycle setting of the API version","required":false,"options":["publish","unpublish"]},"setdefault":{"name":"setdefault","type":"boolean","description":"sets API version to be the default","required":false,"allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API to update in SwaggerHub","required":true}]},"api:validate":{"id":"api:validate","description":"get validation result for an API version\nWhen VERSION is not included in the argument, the default version will be validated.\nAn error will occur if the API version does not exist.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub api:validate organization/api/1.0.0","swaggerhub api:validate organization/api"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API Identifier","required":true}]},"domain:create":{"id":"domain:create","description":"creates a new domain / domain version from a YAML/JSON file\nThe domain version from the file will be used unless the version is specified in the command argument.\nAn error will occur if the domain version already exists.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:create organization/domain/1.0.0 --file domain.yaml --visibility public","swaggerhub domain:create organization/domain --file domain.yaml","swaggerhub domain:create organization/domain/1.0.0 --publish --file domain.json","swaggerhub domain:create organization/domain/1.0.0 --setdefault --file domain.json","swaggerhub domain:create organization/domain/1.0.0 --publish --setdefault --file domain.json"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"file location of domain to create","required":true},"visibility":{"name":"visibility","type":"option","description":"visibility of domain in SwaggerHub","options":["public","private"],"default":"private"},"published":{"name":"published","type":"option","description":"sets the lifecycle setting of the domain version","required":false,"options":["publish","unpublish"],"default":"unpublish"},"setdefault":{"name":"setdefault","type":"boolean","description":"sets domain version to be the default","required":false,"allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/[VERSION]","description":"Domain to create in SwaggerHub","required":true}]},"domain:delete":{"id":"domain:delete","description":"delete a domain or domain version\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:delete organization/domain/1.0.0","swaggerhub domain:delete organization/domain","swaggerhub domain:delete organization/domain --force"],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"delete domain without prompting for confirmation","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/[VERSION]","description":"Domain to delete in SwaggerHub","required":true}]},"domain:get":{"id":"domain:get","description":"fetches a domain definition\nWhen VERSION is not included in the argument, the default version will be returned.\nReturns the domain in YAML format by default.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:get organization/domain","swaggerhub domain:get organization/domain/1.0.0 --json"],"flags":{"json":{"name":"json","type":"boolean","char":"j","description":"returns the domain in JSON format.","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/[VERSION]","description":"SwaggerHub domain to fetch","required":true}]},"domain:publish":{"id":"domain:publish","description":"publish a domain version","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:publish organization/domain/1.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/VERSION","description":"Domain identifier","required":true}]},"domain:setdefault":{"id":"domain:setdefault","description":"set the default version of a domain","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:setdefault organization/domain/2.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/VERSION","description":"domain identifier","required":true}]},"domain:unpublish":{"id":"domain:unpublish","description":"unpublish a domain version","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:unpublish organization/domain/1.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/VERSION","description":"Domain identifier","required":true}]},"domain:update":{"id":"domain:update","description":"update a domain\nThe domain version from the file will be used unless the version is specified in the command argument.\nWhen no file is specified then the default domain version will be updated.\nThe domain visibility can be changed by using visibility flag.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub domain:update organization/domain --file domain.yaml","swaggerhub domain:update organization/domain/1.0.0 --file domain.json","swaggerhub domain:update organization/domain/1.0.0 --published=publish --file domain.json","swaggerhub domain:update organization/domain/1.0.0 --setdefault --file domain.json","swaggerhub domain:update organization/domain/1.0.0 --published=unpublish --setdefault --file domain.json","swaggerhub domain:update organization/domain/1.0.0 --visibility=private"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"file location of domain to update","required":false},"visibility":{"name":"visibility","type":"option","description":"visibility of domain in SwaggerHub","options":["public","private"]},"published":{"name":"published","type":"option","description":"sets the lifecycle setting of the domain version","required":false,"options":["publish","unpublish"]},"setdefault":{"name":"setdefault","type":"boolean","description":"sets domain version to be the default","required":false,"allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/DOMAIN_NAME/[VERSION]","description":"domain to update in SwaggerHub","required":true}]},"integration:create":{"id":"integration:create","description":"creates a new API integration from a JSON configuration file.\nSee the documentation for configuration files: https://github.com/SmartBear/swaggerhub-cli/tree/master/examples/integrations\nWhen VERSION is not included in the argument, the integration will be added to be default API version.\n","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:create organization/api/1.0.0 --file config.json"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"location of integration configuration file","required":true},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API where integration will be added","required":true}]},"integration:delete":{"id":"integration:delete","description":"deletes the integration from the given API.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:delete organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION/INTEGRATION_ID","description":"Integration to delete","required":true}]},"integration:execute":{"id":"integration:execute","description":"executes an integration for the given API.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:execute organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION/INTEGRATION_ID","description":"Integration to execute for given API","required":true}]},"integration:get":{"id":"integration:get","description":"retieves an integration for the given API.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:get organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION/INTEGRATION_ID","description":"Integration to fetch for given API","required":true}]},"integration:list":{"id":"integration:list","description":"list integrations on an API.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:list organization/api/1.0.0"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/[VERSION]","description":"API to list integrations on","required":true}]},"integration:update":{"id":"integration:update","description":"update the configuration of an API integration.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub integration:update organization/api/1.0.0/503c2db6-448a-4678-abcd-0123456789abc --file config.json"],"flags":{"file":{"name":"file","type":"option","char":"f","description":"location of integration configuration file","required":true},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/API_NAME/VERSION/INTEGRATION_ID","description":"Integration to update on the given API","required":true}]},"project:create":{"id":"project:create","description":"Creates a new project in SwaggerHub.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:create organization/new_project_name --description \"project description\"","swaggerhub project:create organization/new_project_name -a \"testapi1,testapi2\"","swaggerhub project:create organization/new_project_name --apis \"testapi1,testapi2\"","swaggerhub project:create organization/new_project_name -d \"testdomain3,testdomain4\"","swaggerhub project:create organization/new_project_name --domains \"testdomain3,testdomain4\"","swaggerhub project:create organization/new_project_name -a \"testapi1\" -d \"testdomain3\" --description \"description\""],"flags":{"description":{"name":"description","type":"option","description":"Description of project","required":false},"apis":{"name":"apis","type":"option","char":"a","description":"Comma separated list of api names to include in project","required":false},"domains":{"name":"domains","type":"option","char":"d","description":"Comma separated list of domain names to include in project","required":false},"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The new project to create","required":true}]},"project:delete":{"id":"project:delete","description":"Deletes a project from SwaggerHub.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:delete organization/project_name"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"Project to delete","required":true}]},"project:get":{"id":"project:get","description":"Retrieves the details for a project.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:get organization/project_name"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"Project to retrieve the details for","required":true}]},"project:list":{"id":"project:list","description":"list projects","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:list","swaggerhub project:list organization"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER","description":"Organization to list projects for","required":false}]},"project:api:add":{"id":"project:api:add","description":"Adds an API to an existing project.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:api:add organization/project_name my_api"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The project to add the API to","required":true},{"name":"API","description":"The name of the API to add","required":true}]},"project:api:remove":{"id":"project:api:remove","description":"Removes an API from a project in SwaggerHub.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:api:remove organization/project_name my_api"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The project remove the API from","required":true},{"name":"API","description":"The API to remove","required":true}]},"project:domain:add":{"id":"project:domain:add","description":"Adds a domain to an existing project.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:domain:add organization/project_name my_domain"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The project to add the domain to","required":true},{"name":"DOMAIN","description":"The name of the domain to add","required":true}]},"project:domain:remove":{"id":"project:domain:remove","description":"Removes a domain from a project in SwaggerHub.","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:domain:remove organization/project_name my_domain"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"The project remove the domain from","required":true},{"name":"DOMAIN","description":"The domain to remove","required":true}]},"project:member:list":{"id":"project:member:list","description":"list members of a project","pluginName":"swaggerhub-cli","pluginType":"core","aliases":[],"examples":["swaggerhub project:member:list organisation/project_name"],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"show CLI help","allowNo":false}},"args":[{"name":"OWNER/PROJECT_NAME","description":"Project to list members of","required":true}]}}}
|
package/package.json
CHANGED
|
@@ -28,12 +28,23 @@ class ValidateCommand extends BaseCommand {
|
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
getValidationResult(apiPath) {
|
|
31
|
+
return this.executeHttp({
|
|
32
|
+
execute: () => getApi([apiPath, 'standardization']),
|
|
33
|
+
onResolve: pipeAsync(getResponseContent, JSON.parse),
|
|
34
|
+
onReject: () => this.getFallbackValidationResult(apiPath),
|
|
35
|
+
options: {}
|
|
36
|
+
})
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/* Required to support older on-prem installations */
|
|
40
|
+
getFallbackValidationResult(apiPath) {
|
|
31
41
|
return this.executeHttp({
|
|
32
42
|
execute: () => getApi([apiPath, 'validation']),
|
|
33
43
|
onResolve: pipeAsync(getResponseContent, JSON.parse),
|
|
34
44
|
options: {}
|
|
35
45
|
})
|
|
36
46
|
}
|
|
47
|
+
|
|
37
48
|
}
|
|
38
49
|
|
|
39
50
|
ValidateCommand.description = `get validation result for an API version
|