swaggerhub-cli 0.6.4 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/README.md +535 -291
  2. package/bin/run +3 -3
  3. package/oclif.manifest.json +1165 -1
  4. package/package.json +19 -26
  5. package/src/commands/api/create.js +12 -11
  6. package/src/commands/api/delete.js +9 -8
  7. package/src/commands/api/get.js +10 -9
  8. package/src/commands/api/publish.js +12 -9
  9. package/src/commands/api/setdefault.js +8 -6
  10. package/src/commands/api/unpublish.js +8 -6
  11. package/src/commands/api/update.js +12 -11
  12. package/src/commands/api/validate.js +41 -12
  13. package/src/commands/domain/create.js +12 -11
  14. package/src/commands/domain/delete.js +9 -8
  15. package/src/commands/domain/get.js +9 -8
  16. package/src/commands/domain/publish.js +8 -6
  17. package/src/commands/domain/setdefault.js +8 -6
  18. package/src/commands/domain/unpublish.js +8 -6
  19. package/src/commands/domain/update.js +12 -11
  20. package/src/commands/integration/create.js +10 -9
  21. package/src/commands/integration/delete.js +8 -6
  22. package/src/commands/integration/execute.js +8 -6
  23. package/src/commands/integration/get.js +8 -6
  24. package/src/commands/integration/list.js +11 -10
  25. package/src/commands/integration/update.js +9 -8
  26. package/src/commands/project/api/add.js +10 -12
  27. package/src/commands/project/api/remove.js +10 -11
  28. package/src/commands/project/create.js +11 -10
  29. package/src/commands/project/delete.js +8 -6
  30. package/src/commands/project/domain/add.js +10 -12
  31. package/src/commands/project/domain/remove.js +10 -11
  32. package/src/commands/project/get.js +8 -6
  33. package/src/commands/project/list.js +10 -9
  34. package/src/commands/project/member/list.js +10 -9
  35. package/src/config/index.js +1 -2
  36. package/src/help.js +1 -1
  37. package/src/index.js +2 -1
  38. package/src/support/command/base-command.js +2 -2
  39. package/src/support/command/handle-response.js +1 -1
  40. package/src/support/command/parse-input.js +1 -1
  41. package/src/support/command/update-command.js +1 -1
  42. package/src/support/http/index.js +1 -3
  43. package/src/support/isOnPrem.js +10 -0
  44. package/src/utils/definitions.js +4 -2
  45. package/src/utils/general.js +29 -1
@@ -1 +1,1165 @@
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
+ {
2
+ "version": "0.7.0",
3
+ "commands": {
4
+ "configure": {
5
+ "id": "configure",
6
+ "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",
7
+ "strict": true,
8
+ "pluginName": "swaggerhub-cli",
9
+ "pluginAlias": "swaggerhub-cli",
10
+ "pluginType": "core",
11
+ "aliases": [],
12
+ "flags": {
13
+ "help": {
14
+ "name": "help",
15
+ "type": "boolean",
16
+ "char": "h",
17
+ "description": "Show CLI help.",
18
+ "allowNo": false
19
+ }
20
+ },
21
+ "args": {}
22
+ },
23
+ "api:create": {
24
+ "id": "api:create",
25
+ "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",
26
+ "strict": true,
27
+ "pluginName": "swaggerhub-cli",
28
+ "pluginAlias": "swaggerhub-cli",
29
+ "pluginType": "core",
30
+ "aliases": [],
31
+ "examples": [
32
+ "swaggerhub api:create organization/api/1.0.0 --file api.yaml --visibility public",
33
+ "swaggerhub api:create organization/api --file api.yaml",
34
+ "swaggerhub api:create organization/api/1.0.0 --published=publish --file api.json",
35
+ "swaggerhub api:create organization/api/1.0.0 --setdefault --file api.json",
36
+ "swaggerhub api:create organization/api/1.0.0 --published=publish --setdefault --file api.json"
37
+ ],
38
+ "flags": {
39
+ "help": {
40
+ "name": "help",
41
+ "type": "boolean",
42
+ "char": "h",
43
+ "description": "Show CLI help.",
44
+ "allowNo": false
45
+ },
46
+ "file": {
47
+ "name": "file",
48
+ "type": "option",
49
+ "char": "f",
50
+ "description": "file location of API to create",
51
+ "required": true,
52
+ "multiple": false
53
+ },
54
+ "visibility": {
55
+ "name": "visibility",
56
+ "type": "option",
57
+ "description": "visibility of API in SwaggerHub",
58
+ "multiple": false,
59
+ "options": [
60
+ "public",
61
+ "private"
62
+ ],
63
+ "default": "private"
64
+ },
65
+ "published": {
66
+ "name": "published",
67
+ "type": "option",
68
+ "description": "sets the lifecycle setting of the API version",
69
+ "required": false,
70
+ "multiple": false,
71
+ "options": [
72
+ "publish",
73
+ "unpublish"
74
+ ],
75
+ "dependsOn": [
76
+ "file"
77
+ ],
78
+ "default": "unpublish"
79
+ },
80
+ "setdefault": {
81
+ "name": "setdefault",
82
+ "type": "boolean",
83
+ "description": "sets API version to be the default",
84
+ "required": false,
85
+ "allowNo": false,
86
+ "dependsOn": [
87
+ "file"
88
+ ]
89
+ }
90
+ },
91
+ "args": {
92
+ "OWNER/API_NAME/[VERSION]": {
93
+ "name": "OWNER/API_NAME/[VERSION]",
94
+ "description": "API to create on SwaggerHub",
95
+ "required": true
96
+ }
97
+ }
98
+ },
99
+ "api:delete": {
100
+ "id": "api:delete",
101
+ "description": "delete an API or API version\n",
102
+ "strict": true,
103
+ "pluginName": "swaggerhub-cli",
104
+ "pluginAlias": "swaggerhub-cli",
105
+ "pluginType": "core",
106
+ "aliases": [],
107
+ "examples": [
108
+ "swaggerhub api:delete organization/api/1.0.0",
109
+ "swaggerhub api:delete organization/api",
110
+ "swaggerhub api:delete organization/api --force"
111
+ ],
112
+ "flags": {
113
+ "help": {
114
+ "name": "help",
115
+ "type": "boolean",
116
+ "char": "h",
117
+ "description": "Show CLI help.",
118
+ "allowNo": false
119
+ },
120
+ "force": {
121
+ "name": "force",
122
+ "type": "boolean",
123
+ "char": "f",
124
+ "description": "delete API without prompting for confirmation",
125
+ "allowNo": false
126
+ }
127
+ },
128
+ "args": {
129
+ "OWNER/API_NAME/[VERSION]": {
130
+ "name": "OWNER/API_NAME/[VERSION]",
131
+ "description": "API to delete on SwaggerHub",
132
+ "required": true
133
+ }
134
+ }
135
+ },
136
+ "api:get": {
137
+ "id": "api:get",
138
+ "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",
139
+ "strict": true,
140
+ "pluginName": "swaggerhub-cli",
141
+ "pluginAlias": "swaggerhub-cli",
142
+ "pluginType": "core",
143
+ "aliases": [],
144
+ "examples": [
145
+ "swaggerhub api:get organization/api",
146
+ "swaggerhub api:get organization/api/1.0.0 --json"
147
+ ],
148
+ "flags": {
149
+ "help": {
150
+ "name": "help",
151
+ "type": "boolean",
152
+ "char": "h",
153
+ "description": "Show CLI help.",
154
+ "allowNo": false
155
+ },
156
+ "json": {
157
+ "name": "json",
158
+ "type": "boolean",
159
+ "char": "j",
160
+ "description": "returns the API in JSON format.",
161
+ "allowNo": false
162
+ },
163
+ "resolved": {
164
+ "name": "resolved",
165
+ "type": "boolean",
166
+ "char": "r",
167
+ "description": "gets the resolved API definition (supported in v1.25+). ",
168
+ "allowNo": false
169
+ }
170
+ },
171
+ "args": {
172
+ "OWNER/API_NAME/[VERSION]": {
173
+ "name": "OWNER/API_NAME/[VERSION]",
174
+ "description": "API to fetch from Swaggerhub",
175
+ "required": true
176
+ }
177
+ }
178
+ },
179
+ "api:publish": {
180
+ "id": "api:publish",
181
+ "description": "publish an API version",
182
+ "strict": true,
183
+ "pluginName": "swaggerhub-cli",
184
+ "pluginAlias": "swaggerhub-cli",
185
+ "pluginType": "core",
186
+ "aliases": [],
187
+ "examples": [
188
+ "swaggerhub api:publish organization/api/1.0.0",
189
+ "swaggerhub api:publish organization/api/1.0.0 --force"
190
+ ],
191
+ "flags": {
192
+ "help": {
193
+ "name": "help",
194
+ "type": "boolean",
195
+ "char": "h",
196
+ "description": "Show CLI help.",
197
+ "allowNo": false
198
+ },
199
+ "force": {
200
+ "name": "force",
201
+ "type": "boolean",
202
+ "char": "f",
203
+ "description": "publish API without prompting for confirmation",
204
+ "allowNo": false
205
+ }
206
+ },
207
+ "args": {
208
+ "OWNER/API_NAME/VERSION": {
209
+ "name": "OWNER/API_NAME/VERSION",
210
+ "description": "API to publish on Swaggerhub",
211
+ "required": true
212
+ }
213
+ }
214
+ },
215
+ "api:setdefault": {
216
+ "id": "api:setdefault",
217
+ "description": "set the default version of an API",
218
+ "strict": true,
219
+ "pluginName": "swaggerhub-cli",
220
+ "pluginAlias": "swaggerhub-cli",
221
+ "pluginType": "core",
222
+ "aliases": [],
223
+ "examples": [
224
+ "swaggerhub api:setdefault organization/api/2.0.0"
225
+ ],
226
+ "flags": {
227
+ "help": {
228
+ "name": "help",
229
+ "type": "boolean",
230
+ "char": "h",
231
+ "description": "Show CLI help.",
232
+ "allowNo": false
233
+ }
234
+ },
235
+ "args": {
236
+ "OWNER/API_NAME/VERSION": {
237
+ "name": "OWNER/API_NAME/VERSION",
238
+ "description": "API to set as default on Swaggerhub",
239
+ "required": true
240
+ }
241
+ }
242
+ },
243
+ "api:unpublish": {
244
+ "id": "api:unpublish",
245
+ "description": "unpublish an API version",
246
+ "strict": true,
247
+ "pluginName": "swaggerhub-cli",
248
+ "pluginAlias": "swaggerhub-cli",
249
+ "pluginType": "core",
250
+ "aliases": [],
251
+ "examples": [
252
+ "swaggerhub api:unpublish organization/api/1.0.0"
253
+ ],
254
+ "flags": {
255
+ "help": {
256
+ "name": "help",
257
+ "type": "boolean",
258
+ "char": "h",
259
+ "description": "Show CLI help.",
260
+ "allowNo": false
261
+ }
262
+ },
263
+ "args": {
264
+ "OWNER/API_NAME/VERSION": {
265
+ "name": "OWNER/API_NAME/VERSION",
266
+ "description": "API identifier",
267
+ "required": true
268
+ }
269
+ }
270
+ },
271
+ "api:update": {
272
+ "id": "api:update",
273
+ "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",
274
+ "strict": true,
275
+ "pluginName": "swaggerhub-cli",
276
+ "pluginAlias": "swaggerhub-cli",
277
+ "pluginType": "core",
278
+ "aliases": [],
279
+ "examples": [
280
+ "swaggerhub api:update organization/api --file api.yaml",
281
+ "swaggerhub api:update organization/api/1.0.0 --file api.json",
282
+ "swaggerhub api:update organization/api/1.0.0 --published=publish --file api.json",
283
+ "swaggerhub api:update organization/api/1.0.0 --setdefault --file api.json",
284
+ "swaggerhub api:update organization/api/1.0.0 --published=unpublish --setdefault --file api.json",
285
+ "swaggerhub api:update organization/api/1.0.0 --visibility=private"
286
+ ],
287
+ "flags": {
288
+ "help": {
289
+ "name": "help",
290
+ "type": "boolean",
291
+ "char": "h",
292
+ "description": "Show CLI help.",
293
+ "allowNo": false
294
+ },
295
+ "file": {
296
+ "name": "file",
297
+ "type": "option",
298
+ "char": "f",
299
+ "description": "file location of API to update",
300
+ "required": false,
301
+ "multiple": false
302
+ },
303
+ "visibility": {
304
+ "name": "visibility",
305
+ "type": "option",
306
+ "description": "visibility of API in SwaggerHub",
307
+ "multiple": false,
308
+ "options": [
309
+ "public",
310
+ "private"
311
+ ]
312
+ },
313
+ "published": {
314
+ "name": "published",
315
+ "type": "option",
316
+ "description": "sets the lifecycle setting of the API version",
317
+ "required": false,
318
+ "multiple": false,
319
+ "options": [
320
+ "publish",
321
+ "unpublish"
322
+ ]
323
+ },
324
+ "setdefault": {
325
+ "name": "setdefault",
326
+ "type": "boolean",
327
+ "description": "sets API version to be the default",
328
+ "required": false,
329
+ "allowNo": false
330
+ }
331
+ },
332
+ "args": {
333
+ "OWNER/API_NAME/[VERSION]": {
334
+ "name": "OWNER/API_NAME/[VERSION]",
335
+ "description": "API to update on SwaggerHub",
336
+ "required": true
337
+ }
338
+ }
339
+ },
340
+ "api:validate": {
341
+ "id": "api:validate",
342
+ "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.\nIf the flag `-c` or `--failOnCritical` is used and there are standardization\nerrors with `Critical` severity present, the command will exit with error code `1`.\n",
343
+ "strict": true,
344
+ "pluginName": "swaggerhub-cli",
345
+ "pluginAlias": "swaggerhub-cli",
346
+ "pluginType": "core",
347
+ "aliases": [],
348
+ "examples": [
349
+ "swaggerhub api:validate organization/api/1.0.0",
350
+ "swaggerhub api:validate -c organization/api/1.0.0",
351
+ "swaggerhub api:validate --fail-on-critical organization/api"
352
+ ],
353
+ "flags": {
354
+ "help": {
355
+ "name": "help",
356
+ "type": "boolean",
357
+ "char": "h",
358
+ "description": "Show CLI help.",
359
+ "allowNo": false
360
+ },
361
+ "fail-on-critical": {
362
+ "name": "fail-on-critical",
363
+ "type": "boolean",
364
+ "char": "c",
365
+ "description": "Exit with error code 1 if there are critical standardization errors present",
366
+ "allowNo": false
367
+ }
368
+ },
369
+ "args": {
370
+ "OWNER/API_NAME/[VERSION]": {
371
+ "name": "OWNER/API_NAME/[VERSION]",
372
+ "description": "API to fetch validation errors for from Swaggerhub",
373
+ "required": true
374
+ }
375
+ }
376
+ },
377
+ "domain:create": {
378
+ "id": "domain:create",
379
+ "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",
380
+ "strict": true,
381
+ "pluginName": "swaggerhub-cli",
382
+ "pluginAlias": "swaggerhub-cli",
383
+ "pluginType": "core",
384
+ "aliases": [],
385
+ "examples": [
386
+ "swaggerhub domain:create organization/domain/1.0.0 --file domain.yaml --visibility public",
387
+ "swaggerhub domain:create organization/domain --file domain.yaml",
388
+ "swaggerhub domain:create organization/domain/1.0.0 --publish --file domain.json",
389
+ "swaggerhub domain:create organization/domain/1.0.0 --setdefault --file domain.json",
390
+ "swaggerhub domain:create organization/domain/1.0.0 --publish --setdefault --file domain.json"
391
+ ],
392
+ "flags": {
393
+ "help": {
394
+ "name": "help",
395
+ "type": "boolean",
396
+ "char": "h",
397
+ "description": "Show CLI help.",
398
+ "allowNo": false
399
+ },
400
+ "file": {
401
+ "name": "file",
402
+ "type": "option",
403
+ "char": "f",
404
+ "description": "file location of domain to create",
405
+ "required": true,
406
+ "multiple": false
407
+ },
408
+ "visibility": {
409
+ "name": "visibility",
410
+ "type": "option",
411
+ "description": "visibility of domain in SwaggerHub",
412
+ "multiple": false,
413
+ "options": [
414
+ "public",
415
+ "private"
416
+ ],
417
+ "default": "private"
418
+ },
419
+ "published": {
420
+ "name": "published",
421
+ "type": "option",
422
+ "description": "sets the lifecycle setting of the domain version",
423
+ "required": false,
424
+ "multiple": false,
425
+ "options": [
426
+ "publish",
427
+ "unpublish"
428
+ ],
429
+ "dependsOn": [
430
+ "file"
431
+ ],
432
+ "default": "unpublish"
433
+ },
434
+ "setdefault": {
435
+ "name": "setdefault",
436
+ "type": "boolean",
437
+ "description": "sets domain version to be the default",
438
+ "required": false,
439
+ "allowNo": false,
440
+ "dependsOn": [
441
+ "file"
442
+ ]
443
+ }
444
+ },
445
+ "args": {
446
+ "OWNER/DOMAIN_NAME/[VERSION]": {
447
+ "name": "OWNER/DOMAIN_NAME/[VERSION]",
448
+ "description": "Domain to create on SwaggerHub",
449
+ "required": true
450
+ }
451
+ }
452
+ },
453
+ "domain:delete": {
454
+ "id": "domain:delete",
455
+ "description": "delete a domain or domain version\n",
456
+ "strict": true,
457
+ "pluginName": "swaggerhub-cli",
458
+ "pluginAlias": "swaggerhub-cli",
459
+ "pluginType": "core",
460
+ "aliases": [],
461
+ "examples": [
462
+ "swaggerhub domain:delete organization/domain/1.0.0",
463
+ "swaggerhub domain:delete organization/domain",
464
+ "swaggerhub domain:delete organization/domain --force"
465
+ ],
466
+ "flags": {
467
+ "help": {
468
+ "name": "help",
469
+ "type": "boolean",
470
+ "char": "h",
471
+ "description": "Show CLI help.",
472
+ "allowNo": false
473
+ },
474
+ "force": {
475
+ "name": "force",
476
+ "type": "boolean",
477
+ "char": "f",
478
+ "description": "delete domain without prompting for confirmation",
479
+ "allowNo": false
480
+ }
481
+ },
482
+ "args": {
483
+ "OWNER/DOMAIN_NAME/[VERSION]": {
484
+ "name": "OWNER/DOMAIN_NAME/[VERSION]",
485
+ "description": "Domain to delete on SwaggerHub",
486
+ "required": true
487
+ }
488
+ }
489
+ },
490
+ "domain:get": {
491
+ "id": "domain:get",
492
+ "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",
493
+ "strict": true,
494
+ "pluginName": "swaggerhub-cli",
495
+ "pluginAlias": "swaggerhub-cli",
496
+ "pluginType": "core",
497
+ "aliases": [],
498
+ "examples": [
499
+ "swaggerhub domain:get organization/domain",
500
+ "swaggerhub domain:get organization/domain/1.0.0 --json"
501
+ ],
502
+ "flags": {
503
+ "help": {
504
+ "name": "help",
505
+ "type": "boolean",
506
+ "char": "h",
507
+ "description": "Show CLI help.",
508
+ "allowNo": false
509
+ },
510
+ "json": {
511
+ "name": "json",
512
+ "type": "boolean",
513
+ "char": "j",
514
+ "description": "returns the domain in JSON format.",
515
+ "allowNo": false
516
+ }
517
+ },
518
+ "args": {
519
+ "OWNER/DOMAIN_NAME/[VERSION]": {
520
+ "name": "OWNER/DOMAIN_NAME/[VERSION]",
521
+ "description": "Domain to fetch from SwaggerHub",
522
+ "required": true
523
+ }
524
+ }
525
+ },
526
+ "domain:publish": {
527
+ "id": "domain:publish",
528
+ "description": "publish a domain version",
529
+ "strict": true,
530
+ "pluginName": "swaggerhub-cli",
531
+ "pluginAlias": "swaggerhub-cli",
532
+ "pluginType": "core",
533
+ "aliases": [],
534
+ "examples": [
535
+ "swaggerhub domain:publish organization/domain/1.0.0"
536
+ ],
537
+ "flags": {
538
+ "help": {
539
+ "name": "help",
540
+ "type": "boolean",
541
+ "char": "h",
542
+ "description": "Show CLI help.",
543
+ "allowNo": false
544
+ }
545
+ },
546
+ "args": {
547
+ "OWNER/DOMAIN_NAME/VERSION": {
548
+ "name": "OWNER/DOMAIN_NAME/VERSION",
549
+ "description": "Domain to publish on SwaggerHub",
550
+ "required": true
551
+ }
552
+ }
553
+ },
554
+ "domain:setdefault": {
555
+ "id": "domain:setdefault",
556
+ "description": "set the default version of a domain",
557
+ "strict": true,
558
+ "pluginName": "swaggerhub-cli",
559
+ "pluginAlias": "swaggerhub-cli",
560
+ "pluginType": "core",
561
+ "aliases": [],
562
+ "examples": [
563
+ "swaggerhub domain:setdefault organization/domain/2.0.0"
564
+ ],
565
+ "flags": {
566
+ "help": {
567
+ "name": "help",
568
+ "type": "boolean",
569
+ "char": "h",
570
+ "description": "Show CLI help.",
571
+ "allowNo": false
572
+ }
573
+ },
574
+ "args": {
575
+ "OWNER/DOMAIN_NAME/VERSION": {
576
+ "name": "OWNER/DOMAIN_NAME/VERSION",
577
+ "description": "Domain to set as default on SwaggerHub",
578
+ "required": true
579
+ }
580
+ }
581
+ },
582
+ "domain:unpublish": {
583
+ "id": "domain:unpublish",
584
+ "description": "unpublish a domain version",
585
+ "strict": true,
586
+ "pluginName": "swaggerhub-cli",
587
+ "pluginAlias": "swaggerhub-cli",
588
+ "pluginType": "core",
589
+ "aliases": [],
590
+ "examples": [
591
+ "swaggerhub domain:unpublish organization/domain/1.0.0"
592
+ ],
593
+ "flags": {
594
+ "help": {
595
+ "name": "help",
596
+ "type": "boolean",
597
+ "char": "h",
598
+ "description": "Show CLI help.",
599
+ "allowNo": false
600
+ }
601
+ },
602
+ "args": {
603
+ "OWNER/DOMAIN_NAME/VERSION": {
604
+ "name": "OWNER/DOMAIN_NAME/VERSION",
605
+ "description": "Domain to unpublish on SwaggerHub",
606
+ "required": true
607
+ }
608
+ }
609
+ },
610
+ "domain:update": {
611
+ "id": "domain:update",
612
+ "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",
613
+ "strict": true,
614
+ "pluginName": "swaggerhub-cli",
615
+ "pluginAlias": "swaggerhub-cli",
616
+ "pluginType": "core",
617
+ "aliases": [],
618
+ "examples": [
619
+ "swaggerhub domain:update organization/domain --file domain.yaml",
620
+ "swaggerhub domain:update organization/domain/1.0.0 --file domain.json",
621
+ "swaggerhub domain:update organization/domain/1.0.0 --published=publish --file domain.json",
622
+ "swaggerhub domain:update organization/domain/1.0.0 --setdefault --file domain.json",
623
+ "swaggerhub domain:update organization/domain/1.0.0 --published=unpublish --setdefault --file domain.json",
624
+ "swaggerhub domain:update organization/domain/1.0.0 --visibility=private"
625
+ ],
626
+ "flags": {
627
+ "help": {
628
+ "name": "help",
629
+ "type": "boolean",
630
+ "char": "h",
631
+ "description": "Show CLI help.",
632
+ "allowNo": false
633
+ },
634
+ "file": {
635
+ "name": "file",
636
+ "type": "option",
637
+ "char": "f",
638
+ "description": "file location of domain to update",
639
+ "required": false,
640
+ "multiple": false
641
+ },
642
+ "visibility": {
643
+ "name": "visibility",
644
+ "type": "option",
645
+ "description": "visibility of domain in SwaggerHub",
646
+ "multiple": false,
647
+ "options": [
648
+ "public",
649
+ "private"
650
+ ]
651
+ },
652
+ "published": {
653
+ "name": "published",
654
+ "type": "option",
655
+ "description": "sets the lifecycle setting of the domain version",
656
+ "required": false,
657
+ "multiple": false,
658
+ "options": [
659
+ "publish",
660
+ "unpublish"
661
+ ]
662
+ },
663
+ "setdefault": {
664
+ "name": "setdefault",
665
+ "type": "boolean",
666
+ "description": "sets domain version to be the default",
667
+ "required": false,
668
+ "allowNo": false
669
+ }
670
+ },
671
+ "args": {
672
+ "OWNER/DOMAIN_NAME/[VERSION]": {
673
+ "name": "OWNER/DOMAIN_NAME/[VERSION]",
674
+ "description": "Domain to update on SwaggerHub",
675
+ "required": true
676
+ }
677
+ }
678
+ },
679
+ "integration:create": {
680
+ "id": "integration:create",
681
+ "description": "creates a new API integration from a JSON configuration file.\nSee the documentation for configuration files: https://github.com/SmartBear/swaggerhub-cli/tree/main/examples/integrations\nWhen VERSION is not included in the argument, the integration will be added to be default API version.\n",
682
+ "strict": true,
683
+ "pluginName": "swaggerhub-cli",
684
+ "pluginAlias": "swaggerhub-cli",
685
+ "pluginType": "core",
686
+ "aliases": [],
687
+ "examples": [
688
+ "swaggerhub integration:create organization/api/1.0.0 --file config.json"
689
+ ],
690
+ "flags": {
691
+ "help": {
692
+ "name": "help",
693
+ "type": "boolean",
694
+ "char": "h",
695
+ "description": "Show CLI help.",
696
+ "allowNo": false
697
+ },
698
+ "file": {
699
+ "name": "file",
700
+ "type": "option",
701
+ "char": "f",
702
+ "description": "location of integration configuration file",
703
+ "required": true,
704
+ "multiple": false
705
+ }
706
+ },
707
+ "args": {
708
+ "OWNER/API_NAME/[VERSION]": {
709
+ "name": "OWNER/API_NAME/[VERSION]",
710
+ "description": "API to add integration to on SwaggerHub",
711
+ "required": true
712
+ }
713
+ }
714
+ },
715
+ "integration:delete": {
716
+ "id": "integration:delete",
717
+ "description": "deletes the integration from the given API.",
718
+ "strict": true,
719
+ "pluginName": "swaggerhub-cli",
720
+ "pluginAlias": "swaggerhub-cli",
721
+ "pluginType": "core",
722
+ "aliases": [],
723
+ "examples": [
724
+ "swaggerhub integration:delete organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"
725
+ ],
726
+ "flags": {
727
+ "help": {
728
+ "name": "help",
729
+ "type": "boolean",
730
+ "char": "h",
731
+ "description": "Show CLI help.",
732
+ "allowNo": false
733
+ }
734
+ },
735
+ "args": {
736
+ "OWNER/API_NAME/VERSION/INTEGRATION_ID": {
737
+ "name": "OWNER/API_NAME/VERSION/INTEGRATION_ID",
738
+ "description": "Integration to delete for given API on Swaggerhub",
739
+ "required": true
740
+ }
741
+ }
742
+ },
743
+ "integration:execute": {
744
+ "id": "integration:execute",
745
+ "description": "executes an integration for the given API.",
746
+ "strict": true,
747
+ "pluginName": "swaggerhub-cli",
748
+ "pluginAlias": "swaggerhub-cli",
749
+ "pluginType": "core",
750
+ "aliases": [],
751
+ "examples": [
752
+ "swaggerhub integration:execute organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"
753
+ ],
754
+ "flags": {
755
+ "help": {
756
+ "name": "help",
757
+ "type": "boolean",
758
+ "char": "h",
759
+ "description": "Show CLI help.",
760
+ "allowNo": false
761
+ }
762
+ },
763
+ "args": {
764
+ "OWNER/API_NAME/VERSION/INTEGRATION_ID": {
765
+ "name": "OWNER/API_NAME/VERSION/INTEGRATION_ID",
766
+ "description": "Integration to execute for given API on Swaggerhub",
767
+ "required": true
768
+ }
769
+ }
770
+ },
771
+ "integration:get": {
772
+ "id": "integration:get",
773
+ "description": "retieves an integration for the given API.",
774
+ "strict": true,
775
+ "pluginName": "swaggerhub-cli",
776
+ "pluginAlias": "swaggerhub-cli",
777
+ "pluginType": "core",
778
+ "aliases": [],
779
+ "examples": [
780
+ "swaggerhub integration:get organization/api/1.0.0/503c2db6-448a-4678-a310-f465429e9704"
781
+ ],
782
+ "flags": {
783
+ "help": {
784
+ "name": "help",
785
+ "type": "boolean",
786
+ "char": "h",
787
+ "description": "Show CLI help.",
788
+ "allowNo": false
789
+ }
790
+ },
791
+ "args": {
792
+ "OWNER/API_NAME/VERSION/INTEGRATION_ID": {
793
+ "name": "OWNER/API_NAME/VERSION/INTEGRATION_ID",
794
+ "description": "Integration to fetch for given API on Swaggerhub",
795
+ "required": true
796
+ }
797
+ }
798
+ },
799
+ "integration:list": {
800
+ "id": "integration:list",
801
+ "description": "list integrations on an API.",
802
+ "strict": true,
803
+ "pluginName": "swaggerhub-cli",
804
+ "pluginAlias": "swaggerhub-cli",
805
+ "pluginType": "core",
806
+ "aliases": [],
807
+ "examples": [
808
+ "swaggerhub integration:list organization/api/1.0.0"
809
+ ],
810
+ "flags": {
811
+ "help": {
812
+ "name": "help",
813
+ "type": "boolean",
814
+ "char": "h",
815
+ "description": "Show CLI help.",
816
+ "allowNo": false
817
+ }
818
+ },
819
+ "args": {
820
+ "OWNER/API_NAME/[VERSION]": {
821
+ "name": "OWNER/API_NAME/[VERSION]",
822
+ "description": "API to list integrations for on Swaggerhub",
823
+ "required": true
824
+ }
825
+ }
826
+ },
827
+ "integration:update": {
828
+ "id": "integration:update",
829
+ "description": "update the configuration of an API integration.",
830
+ "strict": true,
831
+ "pluginName": "swaggerhub-cli",
832
+ "pluginAlias": "swaggerhub-cli",
833
+ "pluginType": "core",
834
+ "aliases": [],
835
+ "examples": [
836
+ "swaggerhub integration:update organization/api/1.0.0/503c2db6-448a-4678-abcd-0123456789abc --file config.json"
837
+ ],
838
+ "flags": {
839
+ "help": {
840
+ "name": "help",
841
+ "type": "boolean",
842
+ "char": "h",
843
+ "description": "Show CLI help.",
844
+ "allowNo": false
845
+ },
846
+ "file": {
847
+ "name": "file",
848
+ "type": "option",
849
+ "char": "f",
850
+ "description": "location of integration configuration file",
851
+ "required": true,
852
+ "multiple": false
853
+ }
854
+ },
855
+ "args": {
856
+ "OWNER/API_NAME/VERSION/INTEGRATION_ID": {
857
+ "name": "OWNER/API_NAME/VERSION/INTEGRATION_ID",
858
+ "description": "Integration to update for given API on Swaggerhub",
859
+ "required": true
860
+ }
861
+ }
862
+ },
863
+ "project:create": {
864
+ "id": "project:create",
865
+ "description": "Creates a new project in SwaggerHub.",
866
+ "strict": true,
867
+ "pluginName": "swaggerhub-cli",
868
+ "pluginAlias": "swaggerhub-cli",
869
+ "pluginType": "core",
870
+ "aliases": [],
871
+ "examples": [
872
+ "swaggerhub project:create organization/new_project_name --description \"project description\"",
873
+ "swaggerhub project:create organization/new_project_name -a \"testapi1,testapi2\"",
874
+ "swaggerhub project:create organization/new_project_name --apis \"testapi1,testapi2\"",
875
+ "swaggerhub project:create organization/new_project_name -d \"testdomain3,testdomain4\"",
876
+ "swaggerhub project:create organization/new_project_name --domains \"testdomain3,testdomain4\"",
877
+ "swaggerhub project:create organization/new_project_name -a \"testapi1\" -d \"testdomain3\" --description \"description\""
878
+ ],
879
+ "flags": {
880
+ "help": {
881
+ "name": "help",
882
+ "type": "boolean",
883
+ "char": "h",
884
+ "description": "Show CLI help.",
885
+ "allowNo": false
886
+ },
887
+ "description": {
888
+ "name": "description",
889
+ "type": "option",
890
+ "description": "Description of project",
891
+ "required": false,
892
+ "multiple": false
893
+ },
894
+ "apis": {
895
+ "name": "apis",
896
+ "type": "option",
897
+ "char": "a",
898
+ "description": "Comma separated list of api names to include in project",
899
+ "required": false,
900
+ "multiple": false
901
+ },
902
+ "domains": {
903
+ "name": "domains",
904
+ "type": "option",
905
+ "char": "d",
906
+ "description": "Comma separated list of domain names to include in project",
907
+ "required": false,
908
+ "multiple": false
909
+ }
910
+ },
911
+ "args": {
912
+ "OWNER/PROJECT_NAME": {
913
+ "name": "OWNER/PROJECT_NAME",
914
+ "description": "The new project to create on Swaggerhub",
915
+ "required": true
916
+ }
917
+ }
918
+ },
919
+ "project:delete": {
920
+ "id": "project:delete",
921
+ "description": "Deletes a project from SwaggerHub.",
922
+ "strict": true,
923
+ "pluginName": "swaggerhub-cli",
924
+ "pluginAlias": "swaggerhub-cli",
925
+ "pluginType": "core",
926
+ "aliases": [],
927
+ "examples": [
928
+ "swaggerhub project:delete organization/project_name"
929
+ ],
930
+ "flags": {
931
+ "help": {
932
+ "name": "help",
933
+ "type": "boolean",
934
+ "char": "h",
935
+ "description": "Show CLI help.",
936
+ "allowNo": false
937
+ }
938
+ },
939
+ "args": {
940
+ "OWNER/PROJECT_NAME": {
941
+ "name": "OWNER/PROJECT_NAME",
942
+ "description": "The project to delete on Swaggerhub",
943
+ "required": true
944
+ }
945
+ }
946
+ },
947
+ "project:get": {
948
+ "id": "project:get",
949
+ "description": "Retrieves the details for a project.",
950
+ "strict": true,
951
+ "pluginName": "swaggerhub-cli",
952
+ "pluginAlias": "swaggerhub-cli",
953
+ "pluginType": "core",
954
+ "aliases": [],
955
+ "examples": [
956
+ "swaggerhub project:get organization/project_name"
957
+ ],
958
+ "flags": {
959
+ "help": {
960
+ "name": "help",
961
+ "type": "boolean",
962
+ "char": "h",
963
+ "description": "Show CLI help.",
964
+ "allowNo": false
965
+ }
966
+ },
967
+ "args": {
968
+ "OWNER/PROJECT_NAME": {
969
+ "name": "OWNER/PROJECT_NAME",
970
+ "description": "The project to get details for on Swaggerhub",
971
+ "required": true
972
+ }
973
+ }
974
+ },
975
+ "project:list": {
976
+ "id": "project:list",
977
+ "description": "list projects",
978
+ "strict": true,
979
+ "pluginName": "swaggerhub-cli",
980
+ "pluginAlias": "swaggerhub-cli",
981
+ "pluginType": "core",
982
+ "aliases": [],
983
+ "examples": [
984
+ "swaggerhub project:list",
985
+ "swaggerhub project:list organization"
986
+ ],
987
+ "flags": {
988
+ "help": {
989
+ "name": "help",
990
+ "type": "boolean",
991
+ "char": "h",
992
+ "description": "Show CLI help.",
993
+ "allowNo": false
994
+ }
995
+ },
996
+ "args": {
997
+ "OWNER": {
998
+ "name": "OWNER",
999
+ "description": "The organization to list projects for on Swaggerhub",
1000
+ "required": false
1001
+ }
1002
+ }
1003
+ },
1004
+ "project:api:add": {
1005
+ "id": "project:api:add",
1006
+ "description": "Adds an API to an existing project.",
1007
+ "strict": true,
1008
+ "pluginName": "swaggerhub-cli",
1009
+ "pluginAlias": "swaggerhub-cli",
1010
+ "pluginType": "core",
1011
+ "aliases": [],
1012
+ "examples": [
1013
+ "swaggerhub project:api:add organization/project_name my_api"
1014
+ ],
1015
+ "flags": {
1016
+ "help": {
1017
+ "name": "help",
1018
+ "type": "boolean",
1019
+ "char": "h",
1020
+ "description": "Show CLI help.",
1021
+ "allowNo": false
1022
+ }
1023
+ },
1024
+ "args": {
1025
+ "OWNER/PROJECT_NAME": {
1026
+ "name": "OWNER/PROJECT_NAME",
1027
+ "description": "The project to add the API to on Swaggerhub",
1028
+ "required": true
1029
+ },
1030
+ "API": {
1031
+ "name": "API",
1032
+ "description": "The name of the API on Swaggerhub to add",
1033
+ "required": true
1034
+ }
1035
+ }
1036
+ },
1037
+ "project:api:remove": {
1038
+ "id": "project:api:remove",
1039
+ "description": "Removes an API from a project in SwaggerHub.",
1040
+ "strict": true,
1041
+ "pluginName": "swaggerhub-cli",
1042
+ "pluginAlias": "swaggerhub-cli",
1043
+ "pluginType": "core",
1044
+ "aliases": [],
1045
+ "examples": [
1046
+ "swaggerhub project:api:remove organization/project_name my_api"
1047
+ ],
1048
+ "flags": {
1049
+ "help": {
1050
+ "name": "help",
1051
+ "type": "boolean",
1052
+ "char": "h",
1053
+ "description": "Show CLI help.",
1054
+ "allowNo": false
1055
+ }
1056
+ },
1057
+ "args": {
1058
+ "OWNER/PROJECT_NAME": {
1059
+ "name": "OWNER/PROJECT_NAME",
1060
+ "description": "The project to remove the API from on Swaggerhub",
1061
+ "required": true
1062
+ },
1063
+ "API": {
1064
+ "name": "API",
1065
+ "description": "The name of the API on Swaggerhub to remove",
1066
+ "required": true
1067
+ }
1068
+ }
1069
+ },
1070
+ "project:domain:add": {
1071
+ "id": "project:domain:add",
1072
+ "description": "Adds a domain to an existing project.",
1073
+ "strict": true,
1074
+ "pluginName": "swaggerhub-cli",
1075
+ "pluginAlias": "swaggerhub-cli",
1076
+ "pluginType": "core",
1077
+ "aliases": [],
1078
+ "examples": [
1079
+ "swaggerhub project:domain:add organization/project_name my_domain"
1080
+ ],
1081
+ "flags": {
1082
+ "help": {
1083
+ "name": "help",
1084
+ "type": "boolean",
1085
+ "char": "h",
1086
+ "description": "Show CLI help.",
1087
+ "allowNo": false
1088
+ }
1089
+ },
1090
+ "args": {
1091
+ "OWNER/PROJECT_NAME": {
1092
+ "name": "OWNER/PROJECT_NAME",
1093
+ "description": "The project to add the domain to on Swaggerhub",
1094
+ "required": true
1095
+ },
1096
+ "DOMAIN": {
1097
+ "name": "DOMAIN",
1098
+ "description": "The name of the domain on Swaggerhub to add",
1099
+ "required": true
1100
+ }
1101
+ }
1102
+ },
1103
+ "project:domain:remove": {
1104
+ "id": "project:domain:remove",
1105
+ "description": "Removes a domain from a project in SwaggerHub.",
1106
+ "strict": true,
1107
+ "pluginName": "swaggerhub-cli",
1108
+ "pluginAlias": "swaggerhub-cli",
1109
+ "pluginType": "core",
1110
+ "aliases": [],
1111
+ "examples": [
1112
+ "swaggerhub project:domain:remove organization/project_name my_domain"
1113
+ ],
1114
+ "flags": {
1115
+ "help": {
1116
+ "name": "help",
1117
+ "type": "boolean",
1118
+ "char": "h",
1119
+ "description": "Show CLI help.",
1120
+ "allowNo": false
1121
+ }
1122
+ },
1123
+ "args": {
1124
+ "OWNER/PROJECT_NAME": {
1125
+ "name": "OWNER/PROJECT_NAME",
1126
+ "description": "The project to remove the domain from on Swaggerhub",
1127
+ "required": true
1128
+ },
1129
+ "DOMAIN": {
1130
+ "name": "DOMAIN",
1131
+ "description": "The name of the domain on Swaggerhub to remove",
1132
+ "required": true
1133
+ }
1134
+ }
1135
+ },
1136
+ "project:member:list": {
1137
+ "id": "project:member:list",
1138
+ "description": "list members of a project",
1139
+ "strict": true,
1140
+ "pluginName": "swaggerhub-cli",
1141
+ "pluginAlias": "swaggerhub-cli",
1142
+ "pluginType": "core",
1143
+ "aliases": [],
1144
+ "examples": [
1145
+ "swaggerhub project:member:list organisation/project_name"
1146
+ ],
1147
+ "flags": {
1148
+ "help": {
1149
+ "name": "help",
1150
+ "type": "boolean",
1151
+ "char": "h",
1152
+ "description": "Show CLI help.",
1153
+ "allowNo": false
1154
+ }
1155
+ },
1156
+ "args": {
1157
+ "OWNER/PROJECT_NAME": {
1158
+ "name": "OWNER/PROJECT_NAME",
1159
+ "description": "Project to list members of on Swaggerhub",
1160
+ "required": true
1161
+ }
1162
+ }
1163
+ }
1164
+ }
1165
+ }