@apimatic/cli 1.0.2-alpha.2 → 1.1.0-alpha.10
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 +220 -72
- package/bin/run.js +5 -0
- package/lib/actions/portal/generate.d.ts +7 -0
- package/lib/actions/portal/generate.js +54 -0
- package/lib/actions/portal/generate.js.map +1 -0
- package/lib/actions/portal/recipe/new-recipe.d.ts +24 -0
- package/lib/actions/portal/recipe/new-recipe.js +258 -0
- package/lib/actions/portal/recipe/new-recipe.js.map +1 -0
- package/lib/actions/portal/toc/new-toc.d.ts +17 -0
- package/lib/actions/portal/toc/new-toc.js +130 -0
- package/lib/actions/portal/toc/new-toc.js.map +1 -0
- package/lib/application/portal/recipe/portal-recipe.d.ts +8 -0
- package/lib/application/portal/recipe/portal-recipe.js +33 -0
- package/lib/application/portal/recipe/portal-recipe.js.map +1 -0
- package/lib/application/portal/recipe/recipe-generator.d.ts +16 -0
- package/lib/application/portal/recipe/recipe-generator.js +147 -0
- package/lib/application/portal/recipe/recipe-generator.js.map +1 -0
- package/lib/application/portal/toc/sdl-parser.d.ts +16 -0
- package/lib/application/portal/toc/sdl-parser.js +74 -0
- package/lib/application/portal/toc/sdl-parser.js.map +1 -0
- package/lib/application/portal/toc/toc-content-parser.d.ts +5 -0
- package/lib/application/portal/toc/toc-content-parser.js +44 -0
- package/lib/application/portal/toc/toc-content-parser.js.map +1 -0
- package/lib/application/portal/toc/toc-structure-generator.d.ts +6 -0
- package/lib/application/portal/toc/toc-structure-generator.js +84 -0
- package/lib/application/portal/toc/toc-structure-generator.js.map +1 -0
- package/lib/client-utils/auth-manager.d.ts +1 -1
- package/lib/client-utils/auth-manager.js +9 -13
- package/lib/client-utils/auth-manager.js.map +1 -0
- package/lib/client-utils/sdk-client.js +24 -23
- package/lib/client-utils/sdk-client.js.map +1 -0
- package/lib/commands/api/transform.d.ts +7 -7
- package/lib/commands/api/transform.js +44 -40
- package/lib/commands/api/transform.js.map +1 -0
- package/lib/commands/api/validate.d.ts +4 -4
- package/lib/commands/api/validate.js +33 -24
- package/lib/commands/api/validate.js.map +1 -0
- package/lib/commands/auth/login.d.ts +2 -2
- package/lib/commands/auth/login.js +33 -18
- package/lib/commands/auth/login.js.map +1 -0
- package/lib/commands/auth/logout.d.ts +1 -1
- package/lib/commands/auth/logout.js +6 -7
- package/lib/commands/auth/logout.js.map +1 -0
- package/lib/commands/auth/status.d.ts +1 -1
- package/lib/commands/auth/status.js +6 -7
- package/lib/commands/auth/status.js.map +1 -0
- package/lib/commands/portal/generate.d.ts +12 -7
- package/lib/commands/portal/generate.js +73 -79
- package/lib/commands/portal/generate.js.map +1 -0
- package/lib/commands/portal/quickstart.d.ts +10 -0
- package/lib/commands/portal/quickstart.js +77 -0
- package/lib/commands/portal/quickstart.js.map +1 -0
- package/lib/commands/portal/recipe/new.d.ts +12 -0
- package/lib/commands/portal/recipe/new.js +44 -0
- package/lib/commands/portal/recipe/new.js.map +1 -0
- package/lib/commands/portal/serve.d.ts +16 -0
- package/lib/commands/portal/serve.js +135 -0
- package/lib/commands/portal/serve.js.map +1 -0
- package/lib/commands/portal/toc/new.d.ts +15 -0
- package/lib/commands/portal/toc/new.js +63 -0
- package/lib/commands/portal/toc/new.js.map +1 -0
- package/lib/commands/sdk/generate.d.ts +8 -8
- package/lib/commands/sdk/generate.js +48 -41
- package/lib/commands/sdk/generate.js.map +1 -0
- package/lib/config/axios-config.d.ts +2 -0
- package/lib/config/axios-config.js +10 -0
- package/lib/config/axios-config.js.map +1 -0
- package/lib/config/env.d.ts +27 -1
- package/lib/config/env.js +28 -4
- package/lib/config/env.js.map +1 -0
- package/lib/controllers/api/transform.d.ts +1 -1
- package/lib/controllers/api/transform.js +23 -22
- package/lib/controllers/api/transform.js.map +1 -0
- package/lib/controllers/api/validate.d.ts +3 -3
- package/lib/controllers/api/validate.js +19 -12
- package/lib/controllers/api/validate.js.map +1 -0
- package/lib/controllers/portal/generate.d.ts +3 -2
- package/lib/controllers/portal/generate.js +105 -48
- package/lib/controllers/portal/generate.js.map +1 -0
- package/lib/controllers/portal/quickstart.d.ts +14 -0
- package/lib/controllers/portal/quickstart.js +253 -0
- package/lib/controllers/portal/quickstart.js.map +1 -0
- package/lib/controllers/portal/serve.d.ts +3 -0
- package/lib/controllers/portal/serve.js +133 -0
- package/lib/controllers/portal/serve.js.map +1 -0
- package/lib/controllers/sdk/generate.d.ts +4 -4
- package/lib/controllers/sdk/generate.js +23 -26
- package/lib/controllers/sdk/generate.js.map +1 -0
- package/lib/index.d.ts +1 -1
- package/lib/index.js +2 -4
- package/lib/index.js.map +1 -0
- package/lib/infrastructure/services/portal-service.d.ts +16 -0
- package/lib/infrastructure/services/portal-service.js +129 -0
- package/lib/infrastructure/services/portal-service.js.map +1 -0
- package/lib/prompts/portal/generate.d.ts +10 -0
- package/lib/prompts/portal/generate.js +57 -0
- package/lib/prompts/portal/generate.js.map +1 -0
- package/lib/prompts/portal/quickstart.d.ts +31 -0
- package/lib/prompts/portal/quickstart.js +212 -0
- package/lib/prompts/portal/quickstart.js.map +1 -0
- package/lib/prompts/portal/recipe/new-recipe.d.ts +23 -0
- package/lib/prompts/portal/recipe/new-recipe.js +193 -0
- package/lib/prompts/portal/recipe/new-recipe.js.map +1 -0
- package/lib/prompts/portal/serve.d.ts +7 -0
- package/lib/prompts/portal/serve.js +21 -0
- package/lib/prompts/portal/serve.js.map +1 -0
- package/lib/prompts/portal/toc/new-toc.d.ts +10 -0
- package/lib/prompts/portal/toc/new-toc.js +42 -0
- package/lib/prompts/portal/toc/new-toc.js.map +1 -0
- package/lib/services/portal/server.d.ts +14 -0
- package/lib/services/portal/server.js +97 -0
- package/lib/services/portal/server.js.map +1 -0
- package/lib/types/api/transform.d.ts +19 -8
- package/lib/types/api/transform.js +19 -4
- package/lib/types/api/transform.js.map +1 -0
- package/lib/types/api/validate.d.ts +3 -3
- package/lib/types/api/validate.js +2 -2
- package/lib/types/api/validate.js.map +1 -0
- package/lib/types/common/result.d.ts +17 -0
- package/lib/types/common/result.js +32 -0
- package/lib/types/common/result.js.map +1 -0
- package/lib/types/portal/generate.d.ts +26 -9
- package/lib/types/portal/generate.js +3 -2
- package/lib/types/portal/generate.js.map +1 -0
- package/lib/types/portal/quickstart.d.ts +17 -0
- package/lib/types/portal/quickstart.js +2 -0
- package/lib/types/portal/quickstart.js.map +1 -0
- package/lib/types/recipe/recipe.d.ts +37 -0
- package/lib/types/recipe/recipe.js +6 -0
- package/lib/types/recipe/recipe.js.map +1 -0
- package/lib/types/sdk/generate.d.ts +6 -5
- package/lib/types/sdk/generate.js +5 -6
- package/lib/types/sdk/generate.js.map +1 -0
- package/lib/types/sdl/sdl.d.ts +12 -0
- package/lib/types/sdl/sdl.js +2 -0
- package/lib/types/sdl/sdl.js.map +1 -0
- package/lib/types/toc/toc.d.ts +31 -0
- package/lib/types/toc/toc.js +9 -0
- package/lib/types/toc/toc.js.map +1 -0
- package/lib/types/utils.d.ts +6 -2
- package/lib/types/utils.js +2 -2
- package/lib/types/utils.js.map +1 -0
- package/lib/utils/utils.d.ts +31 -5
- package/lib/utils/utils.js +316 -74
- package/lib/utils/utils.js.map +1 -0
- package/lib/validators/common/directoryValidator.d.ts +9 -0
- package/lib/validators/common/directoryValidator.js +49 -0
- package/lib/validators/common/directoryValidator.js.map +1 -0
- package/lib/validators/common/portValidator.d.ts +5 -0
- package/lib/validators/common/portValidator.js +16 -0
- package/lib/validators/common/portValidator.js.map +1 -0
- package/lib/validators/portal/serveValidator.d.ts +6 -0
- package/lib/validators/portal/serveValidator.js +17 -0
- package/lib/validators/portal/serveValidator.js.map +1 -0
- package/package.json +86 -38
- package/bin/run +0 -5
package/package.json
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@apimatic/cli",
|
|
3
3
|
"description": "The official CLI for APIMatic.",
|
|
4
|
-
"version": "1.0
|
|
4
|
+
"version": "1.1.0-alpha.10",
|
|
5
5
|
"author": "APIMatic",
|
|
6
6
|
"bin": {
|
|
7
|
-
"apimatic": "./bin/run"
|
|
7
|
+
"apimatic": "./bin/run.js"
|
|
8
8
|
},
|
|
9
9
|
"bugs": "https://github.com/apimatic/apimatic-cli/issues",
|
|
10
10
|
"publishConfig": {
|
|
11
11
|
"access": "public"
|
|
12
12
|
},
|
|
13
13
|
"engines": {
|
|
14
|
-
"node": ">=
|
|
14
|
+
"node": ">=20.0.0"
|
|
15
15
|
},
|
|
16
16
|
"files": [
|
|
17
|
-
"
|
|
18
|
-
"
|
|
17
|
+
"./bin",
|
|
18
|
+
"./lib",
|
|
19
19
|
"/npm-shrinkwrap.json",
|
|
20
20
|
"/oclif.manifest.json"
|
|
21
21
|
],
|
|
@@ -30,76 +30,124 @@
|
|
|
30
30
|
"automation"
|
|
31
31
|
],
|
|
32
32
|
"license": "MIT",
|
|
33
|
+
"type": "module",
|
|
33
34
|
"main": "lib/index.js",
|
|
34
35
|
"types": "lib/index.d.ts",
|
|
35
36
|
"scripts": {
|
|
36
37
|
"build": "tsc -b",
|
|
37
38
|
"postpack": "rimraf oclif.manifest.json",
|
|
38
|
-
"posttest": "eslint . --ext .ts
|
|
39
|
-
"test": "nyc --extension .ts mocha --forbid-only \"test/**/*.test.ts\"",
|
|
39
|
+
"posttest": "eslint . --ext .ts",
|
|
40
40
|
"prettier": "prettier \"src/**/*.{js,ts}\"",
|
|
41
41
|
"format": "prettier --write \"src/**/*.{js,ts}\"",
|
|
42
42
|
"lint": "eslint \"src/**/*.{js,ts}\"",
|
|
43
|
-
"lint:fix": "eslint --fix \"src/**/*.{js,ts}\" --quiet"
|
|
43
|
+
"lint:fix": "eslint --fix \"src/**/*.{js,ts}\" --quiet",
|
|
44
|
+
"test": "tsx node_modules/mocha/bin/_mocha --forbid-only \"test/**/*.test.ts\" --timeout 99999"
|
|
44
45
|
},
|
|
45
46
|
"dependencies": {
|
|
46
|
-
"@apimatic/sdk": "^0.0
|
|
47
|
-
"@
|
|
48
|
-
"@oclif/
|
|
49
|
-
"@oclif/plugin-autocomplete": "^
|
|
50
|
-
"@oclif/plugin-help": "^
|
|
51
|
-
"@oclif/plugin-not-found": "^
|
|
52
|
-
"
|
|
53
|
-
"
|
|
47
|
+
"@apimatic/sdk": "^0.2.0-alpha.1",
|
|
48
|
+
"@clack/prompts": "1.0.0-alpha.1",
|
|
49
|
+
"@oclif/core": "^4.2.8",
|
|
50
|
+
"@oclif/plugin-autocomplete": "^3.2.24",
|
|
51
|
+
"@oclif/plugin-help": "^6.2.26",
|
|
52
|
+
"@oclif/plugin-not-found": "^3.2.44",
|
|
53
|
+
"adm-zip": "^0.5.14",
|
|
54
|
+
"archiver": "^7.0.1",
|
|
55
|
+
"axios": "^1.8.1",
|
|
54
56
|
"base-64": "^1.0.0",
|
|
55
|
-
"
|
|
56
|
-
"
|
|
57
|
+
"chokidar": "^3.6.0",
|
|
58
|
+
"connect-livereload": "^0.6.1",
|
|
59
|
+
"execa": "^9.6.0",
|
|
60
|
+
"express": "^4.17.1",
|
|
61
|
+
"file-type": "^15.0.0",
|
|
62
|
+
"form-data": "^4.0.2",
|
|
63
|
+
"fs-extra": "^11.3.0",
|
|
64
|
+
"livereload": "^0.9.3",
|
|
65
|
+
"open": "^8.4.0",
|
|
66
|
+
"prettier": "^2.8.8",
|
|
67
|
+
"simple-git": "^3.27.0",
|
|
57
68
|
"striptags": "^3.2.0",
|
|
58
|
-
"
|
|
59
|
-
"
|
|
69
|
+
"treeify": "^1.1.0",
|
|
70
|
+
"tslib": "^2.8.1",
|
|
71
|
+
"unzipper": "^0.12.3",
|
|
72
|
+
"yaml": "^2.8.0"
|
|
60
73
|
},
|
|
61
74
|
"devDependencies": {
|
|
62
75
|
"@commitlint/cli": "^15.0.0",
|
|
63
76
|
"@commitlint/config-conventional": "^15.0.0",
|
|
64
|
-
"@oclif/
|
|
65
|
-
"@
|
|
66
|
-
"@semantic-release/changelog": "^6.0.1",
|
|
77
|
+
"@oclif/test": "^4.1.13",
|
|
78
|
+
"@semantic-release/changelog": "^6.0.3",
|
|
67
79
|
"@semantic-release/git": "^10.0.1",
|
|
80
|
+
"@types/adm-zip": "^0.5.5",
|
|
68
81
|
"@types/archiver": "^5.1.1",
|
|
69
|
-
"@types/axios": "^0.14.0",
|
|
70
82
|
"@types/base-64": "^1.0.0",
|
|
71
|
-
"@types/chai": "^4.
|
|
83
|
+
"@types/chai": "^4.3.20",
|
|
84
|
+
"@types/connect-livereload": "^0.5.1",
|
|
85
|
+
"@types/express": "^4.17.13",
|
|
72
86
|
"@types/fs-extra": "^9.0.13",
|
|
87
|
+
"@types/livereload": "^0.9.2",
|
|
73
88
|
"@types/mocha": "^5.2.7",
|
|
74
|
-
"@types/
|
|
89
|
+
"@types/mock-fs": "^4.13.4",
|
|
90
|
+
"@types/node": "^20.17.50",
|
|
91
|
+
"@types/prettier": "^2.7.3",
|
|
92
|
+
"@types/sinon": "^17.0.4",
|
|
93
|
+
"@types/treeify": "^1.0.3",
|
|
75
94
|
"@types/unzipper": "^0.10.4",
|
|
76
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
77
|
-
"@typescript-eslint/parser": "^
|
|
78
|
-
"chai": "^4.
|
|
79
|
-
"eslint": "^
|
|
95
|
+
"@typescript-eslint/eslint-plugin": "^8.0.0",
|
|
96
|
+
"@typescript-eslint/parser": "^8.0.0",
|
|
97
|
+
"chai": "^4.5.0",
|
|
98
|
+
"eslint": "^9.21.0",
|
|
80
99
|
"eslint-config-prettier": "^8.3.0",
|
|
81
100
|
"eslint-plugin-import": "^2.25.2",
|
|
82
|
-
"globby": "^10.0.2",
|
|
83
101
|
"husky": "^7.0.4",
|
|
84
102
|
"lint-staged": "^11.2.6",
|
|
85
|
-
"mocha": "^
|
|
86
|
-
"
|
|
87
|
-
"
|
|
88
|
-
"
|
|
89
|
-
"
|
|
90
|
-
"
|
|
103
|
+
"mocha": "^11.7.1",
|
|
104
|
+
"mock-fs": "^5.5.0",
|
|
105
|
+
"nock": "^14.0.4",
|
|
106
|
+
"nyc": "^17.1.0",
|
|
107
|
+
"oclif": "^4.17.34",
|
|
108
|
+
"rimraf": "^6.0.1",
|
|
109
|
+
"sinon": "^21.0.0",
|
|
110
|
+
"tmp-promise": "^3.0.3",
|
|
111
|
+
"ts-node": "^10.9.2",
|
|
112
|
+
"tsx": "^4.20.3",
|
|
113
|
+
"typescript": "^5.2.2"
|
|
91
114
|
},
|
|
92
115
|
"oclif": {
|
|
93
116
|
"commands": "./lib/commands",
|
|
117
|
+
"dirname": "apimatic",
|
|
94
118
|
"bin": "apimatic",
|
|
119
|
+
"description": "The official CLI for APIMatic. \nTo get started with APIMatic's CLI using a step by step wizard, run 'apimatic portal:quickstart'.",
|
|
95
120
|
"plugins": [
|
|
96
121
|
"@oclif/plugin-autocomplete",
|
|
97
122
|
"@oclif/plugin-help",
|
|
98
123
|
"@oclif/plugin-not-found"
|
|
99
|
-
]
|
|
124
|
+
],
|
|
125
|
+
"topics": {
|
|
126
|
+
"api": {
|
|
127
|
+
"description": "Transform & Validate your API specifications."
|
|
128
|
+
},
|
|
129
|
+
"auth": {
|
|
130
|
+
"description": "Login using your APIMatic credentials, or view your authentication status."
|
|
131
|
+
},
|
|
132
|
+
"portal": {
|
|
133
|
+
"description": "Generate, download and serve an API Documentation portal for your APIs."
|
|
134
|
+
},
|
|
135
|
+
"sdk": {
|
|
136
|
+
"description": "Generate SDKs for your APIs in multiple languages."
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
"state": "Alpha"
|
|
100
140
|
},
|
|
101
141
|
"lint-staged": {
|
|
102
142
|
"*.js": "eslint --cache --fix",
|
|
103
143
|
"*.{js,ts}": "prettier --write"
|
|
144
|
+
},
|
|
145
|
+
"overrides": {
|
|
146
|
+
"inflight": "npm:lru-cache@^7.14.1",
|
|
147
|
+
"lodash.get": "npm:lodash@^4.17.21",
|
|
148
|
+
"@humanwhocodes/config-array": "npm:@eslint/config-array@latest",
|
|
149
|
+
"rimraf": "^6.0.1",
|
|
150
|
+
"glob": "^10.4.5",
|
|
151
|
+
"q": "npm:promise@^8.3.0"
|
|
104
152
|
}
|
|
105
153
|
}
|