@apimatic/cli 1.1.0-beta.14 → 1.1.0-beta.16
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/lib/actions/portal/toc/new-toc.js +7 -18
- package/lib/actions/portal/toc/new-toc.js.map +1 -1
- package/lib/actions/sdk/publish.js +3 -5
- package/lib/actions/sdk/publish.js.map +1 -1
- package/lib/application/portal/toc/toc-structure-generator.d.ts +3 -19
- package/lib/application/portal/toc/toc-structure-generator.js +43 -33
- package/lib/application/portal/toc/toc-structure-generator.js.map +1 -1
- package/lib/infrastructure/services/portal-service.d.ts +2 -0
- package/lib/infrastructure/services/portal-service.js +20 -1
- package/lib/infrastructure/services/portal-service.js.map +1 -1
- package/lib/prompts/portal/toc/new-toc.d.ts +2 -2
- package/lib/prompts/portal/toc/new-toc.js +3 -3
- package/lib/prompts/portal/toc/new-toc.js.map +1 -1
- package/lib/types/publish/package-settings-configuration.d.ts +18 -14
- package/lib/types/publish/package-settings-configuration.js +1 -45
- package/lib/types/publish/package-settings-configuration.js.map +1 -1
- package/lib/types/publish/publishing-profile.d.ts +13 -5
- package/lib/types/publish/publishing-profile.js +119 -70
- package/lib/types/publish/publishing-profile.js.map +1 -1
- package/lib/types/publish-api/publishing-profile-item.d.ts +22 -15
- package/lib/types/sdl/sdl.d.ts +0 -28
- package/lib/types/sdl/sdl.js +1 -128
- package/lib/types/sdl/sdl.js.map +1 -1
- package/lib/types/toc/toc-components.d.ts +37 -0
- package/lib/types/toc/toc-components.js +97 -0
- package/lib/types/toc/toc-components.js.map +1 -0
- package/lib/types/toc/toc.d.ts +11 -0
- package/lib/utils/string-utils.d.ts +0 -1
- package/lib/utils/string-utils.js +0 -42
- package/lib/utils/string-utils.js.map +1 -1
- package/package.json +8 -12
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import { Language } from '../sdk/generate.js';
|
|
2
|
-
import {
|
|
2
|
+
import { PublishingProfileItem, PublishingProfileSummaryGroup, PublishingProfileWithLanguagesGroup, PublishType } from '../publish-api/publishing-profile-item.js';
|
|
3
|
+
import { PackageConfigurationData } from './package-settings-configuration.js';
|
|
3
4
|
export declare class PublishingProfile {
|
|
4
|
-
private readonly
|
|
5
|
+
private readonly profile;
|
|
6
|
+
private readonly languageConfigs;
|
|
7
|
+
private readonly gitConfigs;
|
|
5
8
|
private constructor();
|
|
6
9
|
static create(item: PublishingProfileItem): PublishingProfile;
|
|
7
10
|
toString(): string;
|
|
@@ -12,7 +15,12 @@ export declare class PublishingProfile {
|
|
|
12
15
|
getUnallowedPublishTypes(language: Language, requestedTypes: PublishType[]): PublishType[];
|
|
13
16
|
toPublishingProfileSummaryGroup(): PublishingProfileSummaryGroup;
|
|
14
17
|
toPublishingProfileWithLanguagesGroup(): PublishingProfileWithLanguagesGroup;
|
|
15
|
-
|
|
16
|
-
private
|
|
17
|
-
private
|
|
18
|
+
getPackageConfigurationDataForLanguage(language: Language): PackageConfigurationData | undefined;
|
|
19
|
+
private static createCSharpConfiguration;
|
|
20
|
+
private static createJavaConfiguration;
|
|
21
|
+
private static createPhpConfiguration;
|
|
22
|
+
private static createPythonConfiguration;
|
|
23
|
+
private static createRubyConfiguration;
|
|
24
|
+
private static createTypeScriptConfiguration;
|
|
25
|
+
private static createGoConfiguration;
|
|
18
26
|
}
|
|
@@ -1,35 +1,48 @@
|
|
|
1
1
|
import { Language } from '../sdk/generate.js';
|
|
2
|
-
import { PublishType } from '../publish-api/publishing-profile-item.js';
|
|
2
|
+
import { PublishType, } from '../publish-api/publishing-profile-item.js';
|
|
3
3
|
export class PublishingProfile {
|
|
4
|
-
constructor(
|
|
5
|
-
|
|
4
|
+
constructor(profile) {
|
|
5
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
6
|
+
this.profile = profile;
|
|
7
|
+
this.languageConfigs = Object.fromEntries([
|
|
8
|
+
[Language.CSHARP, ((_a = profile.cSharpConfiguration) === null || _a === void 0 ? void 0 : _a.isEnabled) ? PublishingProfile.createCSharpConfiguration(profile.cSharpConfiguration) : undefined],
|
|
9
|
+
[Language.GO, ((_b = profile.goConfiguration) === null || _b === void 0 ? void 0 : _b.isEnabled) ? PublishingProfile.createGoConfiguration(profile.goConfiguration) : undefined],
|
|
10
|
+
[Language.JAVA, ((_c = profile.javaConfiguration) === null || _c === void 0 ? void 0 : _c.isEnabled) ? PublishingProfile.createJavaConfiguration(profile.javaConfiguration) : undefined],
|
|
11
|
+
[Language.PHP, ((_d = profile.phpConfiguration) === null || _d === void 0 ? void 0 : _d.isEnabled) ? PublishingProfile.createPhpConfiguration(profile.phpConfiguration) : undefined],
|
|
12
|
+
[Language.PYTHON, ((_e = profile.pythonConfiguration) === null || _e === void 0 ? void 0 : _e.isEnabled) ? PublishingProfile.createPythonConfiguration(profile.pythonConfiguration) : undefined],
|
|
13
|
+
[Language.RUBY, ((_f = profile.rubyConfiguration) === null || _f === void 0 ? void 0 : _f.isEnabled) ? PublishingProfile.createRubyConfiguration(profile.rubyConfiguration) : undefined],
|
|
14
|
+
[Language.TYPESCRIPT, ((_g = profile.typeScriptConfiguration) === null || _g === void 0 ? void 0 : _g.isEnabled) ? PublishingProfile.createTypeScriptConfiguration(profile.typeScriptConfiguration) : undefined]
|
|
15
|
+
].filter(([, data]) => data !== undefined));
|
|
16
|
+
this.gitConfigs = Object.fromEntries([
|
|
17
|
+
[Language.CSHARP, ((_h = profile.cSharpGitConfiguration) === null || _h === void 0 ? void 0 : _h.isEnabled) ? profile.cSharpGitConfiguration : undefined],
|
|
18
|
+
[Language.GO, ((_j = profile.goGitConfiguration) === null || _j === void 0 ? void 0 : _j.isEnabled) ? profile.goGitConfiguration : undefined],
|
|
19
|
+
[Language.JAVA, ((_k = profile.javaGitConfiguration) === null || _k === void 0 ? void 0 : _k.isEnabled) ? profile.javaGitConfiguration : undefined],
|
|
20
|
+
[Language.PHP, ((_l = profile.phpGitConfiguration) === null || _l === void 0 ? void 0 : _l.isEnabled) ? profile.phpGitConfiguration : undefined],
|
|
21
|
+
[Language.PYTHON, ((_m = profile.pythonGitConfiguration) === null || _m === void 0 ? void 0 : _m.isEnabled) ? profile.pythonGitConfiguration : undefined],
|
|
22
|
+
[Language.RUBY, ((_o = profile.rubyGitConfiguration) === null || _o === void 0 ? void 0 : _o.isEnabled) ? profile.rubyGitConfiguration : undefined],
|
|
23
|
+
[Language.TYPESCRIPT, ((_p = profile.typeScriptGitConfiguration) === null || _p === void 0 ? void 0 : _p.isEnabled) ? profile.typeScriptGitConfiguration : undefined]
|
|
24
|
+
].filter(([, config]) => config !== undefined));
|
|
6
25
|
}
|
|
7
26
|
static create(item) {
|
|
8
27
|
return new PublishingProfile(item);
|
|
9
28
|
}
|
|
10
29
|
toString() {
|
|
11
|
-
return this.
|
|
30
|
+
return this.profile.name;
|
|
12
31
|
}
|
|
13
32
|
hasEnabledLanguages() {
|
|
14
|
-
|
|
15
|
-
return languageConfigs.some(({ packageConfig, gitConfig }) => (packageConfig === null || packageConfig === void 0 ? void 0 : packageConfig.isEnabled) || (gitConfig === null || gitConfig === void 0 ? void 0 : gitConfig.isEnabled));
|
|
33
|
+
return Object.keys(this.languageConfigs).length > 0 || Object.keys(this.gitConfigs).length > 0;
|
|
16
34
|
}
|
|
17
35
|
isLanguageEnabled(language) {
|
|
18
|
-
|
|
19
|
-
return (packageConfig === null || packageConfig === void 0 ? void 0 : packageConfig.isEnabled) === true || (gitConfig === null || gitConfig === void 0 ? void 0 : gitConfig.isEnabled) === true;
|
|
36
|
+
return language in this.languageConfigs || language in this.gitConfigs;
|
|
20
37
|
}
|
|
21
38
|
getEnabledLanguages() {
|
|
22
|
-
|
|
23
|
-
return languageConfigs
|
|
24
|
-
.filter(({ packageConfig, gitConfig }) => (packageConfig === null || packageConfig === void 0 ? void 0 : packageConfig.isEnabled) || (gitConfig === null || gitConfig === void 0 ? void 0 : gitConfig.isEnabled))
|
|
25
|
-
.map(({ language }) => language);
|
|
39
|
+
return [...new Set([...Object.keys(this.languageConfigs), ...Object.keys(this.gitConfigs)])];
|
|
26
40
|
}
|
|
27
41
|
getPublishTypesForLanguage(language) {
|
|
28
|
-
const { packageConfig, gitConfig } = this.getLanguageConfig(language);
|
|
29
42
|
const types = [];
|
|
30
|
-
if (
|
|
43
|
+
if (language in this.gitConfigs)
|
|
31
44
|
types.push(PublishType.SourceCodePublishing);
|
|
32
|
-
if (
|
|
45
|
+
if (language in this.languageConfigs)
|
|
33
46
|
types.push(PublishType.PackagePublishing);
|
|
34
47
|
return types;
|
|
35
48
|
}
|
|
@@ -39,67 +52,103 @@ export class PublishingProfile {
|
|
|
39
52
|
}
|
|
40
53
|
toPublishingProfileSummaryGroup() {
|
|
41
54
|
return {
|
|
42
|
-
apiGroupName: this.
|
|
43
|
-
profiles: [{ name: this.
|
|
55
|
+
apiGroupName: this.profile.apiGroupName,
|
|
56
|
+
profiles: [{ name: this.profile.name, id: this.profile.id, enabledLanguages: this.getEnabledLanguages() }]
|
|
44
57
|
};
|
|
45
58
|
}
|
|
46
59
|
toPublishingProfileWithLanguagesGroup() {
|
|
47
60
|
return {
|
|
48
|
-
apiGroupName: this.
|
|
49
|
-
profiles: [
|
|
61
|
+
apiGroupName: this.profile.apiGroupName,
|
|
62
|
+
profiles: [
|
|
63
|
+
{
|
|
64
|
+
profile: this.profile,
|
|
65
|
+
enabledLanguages: this.getEnabledLanguages()
|
|
66
|
+
}
|
|
67
|
+
]
|
|
50
68
|
};
|
|
51
69
|
}
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
return
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
70
|
+
getPackageConfigurationDataForLanguage(language) {
|
|
71
|
+
return this.languageConfigs[language];
|
|
72
|
+
}
|
|
73
|
+
static createCSharpConfiguration(config) {
|
|
74
|
+
return {
|
|
75
|
+
packageId: config.packageId,
|
|
76
|
+
authors: config.authors,
|
|
77
|
+
description: config.description,
|
|
78
|
+
title: config.title,
|
|
79
|
+
packageTags: config.packageTags,
|
|
80
|
+
repositoryUrl: config.repositoryUrl,
|
|
81
|
+
repositoryType: config.repositoryType,
|
|
82
|
+
packageProjectUrl: config.packageProjectUrl,
|
|
83
|
+
packageIcon: config.packageIcon,
|
|
84
|
+
packageReleaseNotes: config.packageReleaseNotes,
|
|
85
|
+
copyright: config.copyright
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
static createJavaConfiguration(config) {
|
|
89
|
+
return {
|
|
90
|
+
groupId: config.groupId,
|
|
91
|
+
artifactId: config.artifactId,
|
|
92
|
+
name: config.name,
|
|
93
|
+
description: config.description,
|
|
94
|
+
url: config.url,
|
|
95
|
+
developers: config.developers,
|
|
96
|
+
distributionManagement: config.distributionManagement,
|
|
97
|
+
scm: config.scm
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
static createPhpConfiguration(config) {
|
|
101
|
+
return {
|
|
102
|
+
vendorName: config.vendorName,
|
|
103
|
+
projectName: config.projectName,
|
|
104
|
+
description: config.description,
|
|
105
|
+
type: config.type,
|
|
106
|
+
keywords: config.keywords,
|
|
107
|
+
homepage: config.homepage,
|
|
108
|
+
authors: config.authors,
|
|
109
|
+
support: config.support
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
static createPythonConfiguration(config) {
|
|
113
|
+
return {
|
|
114
|
+
name: config.name,
|
|
115
|
+
description: config.description,
|
|
116
|
+
authors: config.authors,
|
|
117
|
+
maintainers: config.maintainers,
|
|
118
|
+
keywords: config.keywords,
|
|
119
|
+
classifiers: config.classifiers,
|
|
120
|
+
urls: Object.fromEntries(config.urls.map(({ key, value }) => [key, value]))
|
|
121
|
+
};
|
|
122
|
+
}
|
|
123
|
+
static createRubyConfiguration(config) {
|
|
124
|
+
return {
|
|
125
|
+
name: config.name,
|
|
126
|
+
authors: config.authors,
|
|
127
|
+
summary: config.summary,
|
|
128
|
+
description: config.description,
|
|
129
|
+
email: config.email,
|
|
130
|
+
homepage: config.homepage,
|
|
131
|
+
metadata: Object.fromEntries(config.metadata.map(({ key, value }) => [key, value])),
|
|
132
|
+
postInstallMessage: config.postInstallMessage,
|
|
133
|
+
requirements: config.requirements
|
|
134
|
+
};
|
|
135
|
+
}
|
|
136
|
+
static createTypeScriptConfiguration(config) {
|
|
137
|
+
return {
|
|
138
|
+
name: config.name,
|
|
139
|
+
author: config.author,
|
|
140
|
+
description: config.description,
|
|
141
|
+
contributors: config.contributors,
|
|
142
|
+
bugs: config.bugs,
|
|
143
|
+
homepage: config.homepage,
|
|
144
|
+
keywords: config.keywords,
|
|
145
|
+
repository: config.repository,
|
|
146
|
+
};
|
|
147
|
+
}
|
|
148
|
+
static createGoConfiguration(config) {
|
|
149
|
+
return {
|
|
150
|
+
packageName: config.packageName
|
|
151
|
+
};
|
|
103
152
|
}
|
|
104
153
|
}
|
|
105
154
|
//# sourceMappingURL=publishing-profile.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"publishing-profile.js","sourceRoot":"","sources":["../../../src/types/publish/publishing-profile.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC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zB,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,UAAU,EAAE,MAAM,CAAC,UAAU;SAC9B,CAAC;IACR,CAAC;IAEO,MAAM,CAAC,qBAAqB,CAAC,MAA2B;QAC9D,OAAO;YACD,WAAW,EAAE,MAAM,CAAC,WAAW;SAChC,CAAC;IACR,CAAC;CACF"}
|
|
@@ -7,15 +7,15 @@ export interface KeyValueItem {
|
|
|
7
7
|
key: string;
|
|
8
8
|
value: string;
|
|
9
9
|
}
|
|
10
|
-
export interface
|
|
10
|
+
export interface GitConfigurationItem {
|
|
11
11
|
isEnabled: boolean;
|
|
12
12
|
credentialsId: string;
|
|
13
|
-
}
|
|
14
|
-
export interface GitConfigurationItem extends BaseConfigurationItem {
|
|
15
13
|
repositoryName: string;
|
|
16
14
|
branch: string;
|
|
17
15
|
}
|
|
18
|
-
export interface CSharpConfigurationItem
|
|
16
|
+
export interface CSharpConfigurationItem {
|
|
17
|
+
isEnabled: boolean;
|
|
18
|
+
credentialsId: string;
|
|
19
19
|
packageId: string;
|
|
20
20
|
authors: string | null;
|
|
21
21
|
description: string | null;
|
|
@@ -28,7 +28,9 @@ export interface CSharpConfigurationItem extends BaseConfigurationItem {
|
|
|
28
28
|
packageReleaseNotes: string | null;
|
|
29
29
|
copyright: string | null;
|
|
30
30
|
}
|
|
31
|
-
export interface GoConfigurationItem
|
|
31
|
+
export interface GoConfigurationItem {
|
|
32
|
+
isEnabled: boolean;
|
|
33
|
+
credentialsId: string;
|
|
32
34
|
packageName: string;
|
|
33
35
|
}
|
|
34
36
|
export interface JavaDeveloper {
|
|
@@ -50,7 +52,9 @@ export interface JavaScm {
|
|
|
50
52
|
developerConnection: string;
|
|
51
53
|
url: string;
|
|
52
54
|
}
|
|
53
|
-
export interface JavaConfigurationItem
|
|
55
|
+
export interface JavaConfigurationItem {
|
|
56
|
+
isEnabled: boolean;
|
|
57
|
+
credentialsId: string;
|
|
54
58
|
groupId: string;
|
|
55
59
|
artifactId: string;
|
|
56
60
|
name: string;
|
|
@@ -77,7 +81,9 @@ export interface PhpSupport {
|
|
|
77
81
|
docs: string | null;
|
|
78
82
|
rss: string | null;
|
|
79
83
|
}
|
|
80
|
-
export interface PhpConfigurationItem
|
|
84
|
+
export interface PhpConfigurationItem {
|
|
85
|
+
isEnabled: boolean;
|
|
86
|
+
credentialsId: string;
|
|
81
87
|
gitCredentialsId: string;
|
|
82
88
|
repositoryName: string;
|
|
83
89
|
branchName: string;
|
|
@@ -95,7 +101,9 @@ export interface PythonPerson {
|
|
|
95
101
|
email: string | null;
|
|
96
102
|
name: string | null;
|
|
97
103
|
}
|
|
98
|
-
export interface PythonConfigurationItem
|
|
104
|
+
export interface PythonConfigurationItem {
|
|
105
|
+
isEnabled: boolean;
|
|
106
|
+
credentialsId: string;
|
|
99
107
|
name: string;
|
|
100
108
|
description: string | null;
|
|
101
109
|
authors: PythonPerson[];
|
|
@@ -104,7 +112,9 @@ export interface PythonConfigurationItem extends BaseConfigurationItem {
|
|
|
104
112
|
classifiers: string[];
|
|
105
113
|
urls: KeyValueItem[];
|
|
106
114
|
}
|
|
107
|
-
export interface RubyConfigurationItem
|
|
115
|
+
export interface RubyConfigurationItem {
|
|
116
|
+
isEnabled: boolean;
|
|
117
|
+
credentialsId: string;
|
|
108
118
|
name: string;
|
|
109
119
|
authors: string[];
|
|
110
120
|
summary: string;
|
|
@@ -129,7 +139,9 @@ export interface TsRepository {
|
|
|
129
139
|
url: string | null;
|
|
130
140
|
directory: string | null;
|
|
131
141
|
}
|
|
132
|
-
export interface TypeScriptConfigurationItem
|
|
142
|
+
export interface TypeScriptConfigurationItem {
|
|
143
|
+
isEnabled: boolean;
|
|
144
|
+
credentialsId: string;
|
|
133
145
|
name: string;
|
|
134
146
|
author: TsPerson;
|
|
135
147
|
description: string | null;
|
|
@@ -159,11 +171,6 @@ export interface PublishingProfileItem {
|
|
|
159
171
|
rubyGitConfiguration: GitConfigurationItem | null;
|
|
160
172
|
typeScriptGitConfiguration: GitConfigurationItem | null;
|
|
161
173
|
}
|
|
162
|
-
export interface LanguagePublishingConfig {
|
|
163
|
-
language: Language;
|
|
164
|
-
packageConfig: BaseConfigurationItem | null;
|
|
165
|
-
gitConfig: BaseConfigurationItem | null;
|
|
166
|
-
}
|
|
167
174
|
export interface PublishingProfileWithLanguages {
|
|
168
175
|
profile: PublishingProfileItem;
|
|
169
176
|
enabledLanguages: Language[];
|
package/lib/types/sdl/sdl.d.ts
CHANGED
|
@@ -1,38 +1,10 @@
|
|
|
1
|
-
import { TocEndpoint, TocModelPage, TocWebhookPage, TocCallbackPage } from '../toc/toc.js';
|
|
2
|
-
export type EndpointGroup = Map<string, TocEndpoint[]>;
|
|
3
|
-
export type WebhookGroup = Map<string, TocWebhookPage[]>;
|
|
4
|
-
export type CallbackGroup = Map<string, TocCallbackPage[]>;
|
|
5
|
-
export type SdlTocComponents = {
|
|
6
|
-
endpointGroups: EndpointGroup;
|
|
7
|
-
models: TocModelPage[];
|
|
8
|
-
webhookGroups: WebhookGroup;
|
|
9
|
-
callbackGroups: CallbackGroup;
|
|
10
|
-
};
|
|
11
1
|
export interface Sdl {
|
|
12
2
|
readonly Endpoints: SdlEndpoint[];
|
|
13
|
-
readonly CustomTypes: SdlModel[];
|
|
14
|
-
readonly Webhooks: SdlWebhook[];
|
|
15
3
|
}
|
|
16
4
|
export interface SdlEndpoint {
|
|
17
5
|
readonly Name: string;
|
|
18
6
|
readonly Description: string;
|
|
19
7
|
readonly Group: string;
|
|
20
|
-
readonly Callbacks: SdlCallback[];
|
|
21
|
-
}
|
|
22
|
-
export interface SdlModel {
|
|
23
|
-
readonly Name: string;
|
|
24
|
-
}
|
|
25
|
-
export interface SdlCallback {
|
|
26
|
-
readonly Id: string;
|
|
27
|
-
readonly CallbackGroupName?: string;
|
|
28
|
-
}
|
|
29
|
-
export interface SdlWebhook {
|
|
30
|
-
readonly Id: string;
|
|
31
|
-
readonly WebhookGroupName?: string;
|
|
32
8
|
}
|
|
33
9
|
export declare function getEndpointDescription(endpointGroups: Map<string, SdlEndpoint[]>, endpointGroupName: string, endpointName: string): string;
|
|
34
10
|
export declare function getEndpointGroupsFromSdl(sdl: Sdl): Map<string, SdlEndpoint[]>;
|
|
35
|
-
export declare function extractEndpointGroupsForToc(sdl: Sdl): Map<string, TocEndpoint[]>;
|
|
36
|
-
export declare function extractModelsForToc(sdl: Sdl): TocModelPage[];
|
|
37
|
-
export declare function extractWebhooksForToc(sdl: Sdl): Map<string, TocWebhookPage[]>;
|
|
38
|
-
export declare function extractCallbacksForToc(sdl: Sdl): Map<string, TocCallbackPage[]>;
|
package/lib/types/sdl/sdl.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { toTitleCase } from '../../utils/string-utils.js';
|
|
2
1
|
export function getEndpointDescription(endpointGroups, endpointGroupName, endpointName) {
|
|
3
2
|
return endpointGroups.get(endpointGroupName).find((e) => e.Name === endpointName).Description;
|
|
4
3
|
}
|
|
@@ -11,135 +10,9 @@ export function getEndpointGroupsFromSdl(sdl) {
|
|
|
11
10
|
endpointGroups.get(endpoint.Group).push({
|
|
12
11
|
Name: endpoint.Name,
|
|
13
12
|
Description: endpoint.Description,
|
|
14
|
-
Group: endpoint.Group
|
|
15
|
-
Callbacks: endpoint.Callbacks
|
|
13
|
+
Group: endpoint.Group
|
|
16
14
|
});
|
|
17
15
|
}
|
|
18
16
|
return endpointGroups;
|
|
19
17
|
}
|
|
20
|
-
export function extractEndpointGroupsForToc(sdl) {
|
|
21
|
-
const endpointGroups = new Map();
|
|
22
|
-
const endpoints = sdl.Endpoints.map((e) => ({
|
|
23
|
-
generate: null,
|
|
24
|
-
from: 'endpoint',
|
|
25
|
-
endpointName: e.Name,
|
|
26
|
-
endpointGroup: e.Group
|
|
27
|
-
}));
|
|
28
|
-
endpoints.forEach((endpoint) => {
|
|
29
|
-
const group = endpoint.endpointGroup;
|
|
30
|
-
if (!endpointGroups.has(group)) {
|
|
31
|
-
endpointGroups.set(group, []);
|
|
32
|
-
}
|
|
33
|
-
endpointGroups.get(group).push(endpoint);
|
|
34
|
-
});
|
|
35
|
-
return endpointGroups;
|
|
36
|
-
}
|
|
37
|
-
export function extractModelsForToc(sdl) {
|
|
38
|
-
return sdl.CustomTypes.map((e) => ({
|
|
39
|
-
generate: null,
|
|
40
|
-
from: 'model',
|
|
41
|
-
modelName: e.Name
|
|
42
|
-
}));
|
|
43
|
-
}
|
|
44
|
-
export function extractWebhooksForToc(sdl) {
|
|
45
|
-
var _a;
|
|
46
|
-
if (sdl.Webhooks.length === 0) {
|
|
47
|
-
return new Map();
|
|
48
|
-
}
|
|
49
|
-
let groupedWebhooks = new Map();
|
|
50
|
-
const ungrouped = [];
|
|
51
|
-
for (const webhook of sdl.Webhooks) {
|
|
52
|
-
const event = {
|
|
53
|
-
generate: null,
|
|
54
|
-
from: 'webhook',
|
|
55
|
-
webhookName: webhook.Id,
|
|
56
|
-
webhookGroup: (_a = webhook.WebhookGroupName) !== null && _a !== void 0 ? _a : null
|
|
57
|
-
};
|
|
58
|
-
if (webhook.WebhookGroupName) {
|
|
59
|
-
const groupTitle = toTitleCase(webhook.WebhookGroupName);
|
|
60
|
-
if (!groupedWebhooks.has(groupTitle)) {
|
|
61
|
-
groupedWebhooks.set(groupTitle, [
|
|
62
|
-
{
|
|
63
|
-
generate: null,
|
|
64
|
-
from: 'webhook-group-overview',
|
|
65
|
-
webhookGroup: webhook.WebhookGroupName
|
|
66
|
-
}
|
|
67
|
-
]);
|
|
68
|
-
}
|
|
69
|
-
groupedWebhooks.get(groupTitle).push(event);
|
|
70
|
-
}
|
|
71
|
-
else {
|
|
72
|
-
ungrouped.push(event);
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
let ungroupedWebhooks = new Map();
|
|
76
|
-
if (ungrouped.length > 0) {
|
|
77
|
-
const uniqueGroupName = getUniqueGroupName('Webhooks', new Set(groupedWebhooks.keys()));
|
|
78
|
-
const uniqueGroupTitle = toTitleCase(uniqueGroupName);
|
|
79
|
-
ungroupedWebhooks.set(uniqueGroupTitle, [
|
|
80
|
-
{
|
|
81
|
-
generate: null,
|
|
82
|
-
from: 'webhook-group-overview',
|
|
83
|
-
webhookGroup: uniqueGroupName
|
|
84
|
-
},
|
|
85
|
-
...ungrouped.map((event) => (Object.assign(Object.assign({}, event), { webhookGroup: uniqueGroupName })))
|
|
86
|
-
]);
|
|
87
|
-
}
|
|
88
|
-
return new Map([...[...groupedWebhooks].sort((a, b) => a[0].localeCompare(b[0])), ...ungroupedWebhooks]);
|
|
89
|
-
}
|
|
90
|
-
export function extractCallbacksForToc(sdl) {
|
|
91
|
-
var _a;
|
|
92
|
-
if (sdl.Endpoints.length === 0) {
|
|
93
|
-
return new Map();
|
|
94
|
-
}
|
|
95
|
-
let groupedCallbacks = new Map();
|
|
96
|
-
const ungrouped = [];
|
|
97
|
-
for (const callback of sdl.Endpoints.flatMap((e) => e.Callbacks)) {
|
|
98
|
-
const event = {
|
|
99
|
-
generate: null,
|
|
100
|
-
from: 'callback',
|
|
101
|
-
callbackName: callback.Id,
|
|
102
|
-
callbackGroup: (_a = callback.CallbackGroupName) !== null && _a !== void 0 ? _a : null
|
|
103
|
-
};
|
|
104
|
-
if (callback.CallbackGroupName) {
|
|
105
|
-
const groupTitle = toTitleCase(callback.CallbackGroupName);
|
|
106
|
-
if (!groupedCallbacks.has(groupTitle)) {
|
|
107
|
-
groupedCallbacks.set(groupTitle, [
|
|
108
|
-
{
|
|
109
|
-
generate: null,
|
|
110
|
-
from: 'callback-group-overview',
|
|
111
|
-
callbackGroup: callback.CallbackGroupName
|
|
112
|
-
}
|
|
113
|
-
]);
|
|
114
|
-
}
|
|
115
|
-
groupedCallbacks.get(groupTitle).push(event);
|
|
116
|
-
}
|
|
117
|
-
else {
|
|
118
|
-
ungrouped.push(event);
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
let ungroupedCallbacks = new Map();
|
|
122
|
-
if (ungrouped.length > 0) {
|
|
123
|
-
const uniqueGroupName = getUniqueGroupName('Callbacks', new Set(groupedCallbacks.keys()));
|
|
124
|
-
const uniqueGroupTitle = toTitleCase(uniqueGroupName);
|
|
125
|
-
ungroupedCallbacks.set(uniqueGroupTitle, [
|
|
126
|
-
{
|
|
127
|
-
generate: null,
|
|
128
|
-
from: 'callback-group-overview',
|
|
129
|
-
callbackGroup: uniqueGroupName
|
|
130
|
-
},
|
|
131
|
-
...ungrouped.map((event) => (Object.assign(Object.assign({}, event), { callbackGroup: uniqueGroupName })))
|
|
132
|
-
]);
|
|
133
|
-
}
|
|
134
|
-
return new Map([...[...groupedCallbacks].sort((a, b) => a[0].localeCompare(b[0])), ...ungroupedCallbacks]);
|
|
135
|
-
}
|
|
136
|
-
function getUniqueGroupName(baseName, existingGroups) {
|
|
137
|
-
let counter = 1;
|
|
138
|
-
let name = baseName;
|
|
139
|
-
while (existingGroups.has(toTitleCase(name))) {
|
|
140
|
-
name = `${baseName}${counter}`;
|
|
141
|
-
counter++;
|
|
142
|
-
}
|
|
143
|
-
return name;
|
|
144
|
-
}
|
|
145
18
|
//# sourceMappingURL=sdl.js.map
|
package/lib/types/sdl/sdl.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdl.js","sourceRoot":"","sources":["../../../src/types/sdl/sdl.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sdl.js","sourceRoot":"","sources":["../../../src/types/sdl/sdl.ts"],"names":[],"mappings":"AAUA,MAAM,UAAU,sBAAsB,CACpC,cAA0C,EAC1C,iBAAyB,EACzB,YAAoB;IAEpB,OAAO,cAAc,CAAC,GAAG,CAAC,iBAAiB,CAAE,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,YAAY,CAAE,CAAC,WAAW,CAAC;AAClG,CAAC;AAED,MAAM,UAAU,wBAAwB,CAAC,GAAQ;IAC/C,MAAM,cAAc,GAAG,IAAI,GAAG,EAAyB,CAAC;IACxD,KAAK,MAAM,QAAQ,IAAI,GAAG,CAAC,SAAS,EAAE,CAAC;QACrC,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC;YACxC,cAAc,CAAC,GAAG,CAAC,QAAQ,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;QACzC,CAAC;QAED,cAAc,CAAC,GAAG,CAAC,QAAQ,CAAC,KAAK,CAAE,CAAC,IAAI,CAAC;YACvC,IAAI,EAAE,QAAQ,CAAC,IAAI;YACnB,WAAW,EAAE,QAAQ,CAAC,WAAW;YACjC,KAAK,EAAE,QAAQ,CAAC,KAAK;SACtB,CAAC,CAAC;IACL,CAAC;IACD,OAAO,cAAc,CAAC;AACxB,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { TocEndpointPage, TocModelPage, TocWebhookPage, TocCallbackPage, TocContainerModelPage, TocInputModelPage } from './toc.js';
|
|
2
|
+
export interface InputModel {
|
|
3
|
+
readonly name: string;
|
|
4
|
+
readonly group: string;
|
|
5
|
+
}
|
|
6
|
+
export interface TocData {
|
|
7
|
+
readonly endpoints: Record<string, string[]>;
|
|
8
|
+
readonly models: string[];
|
|
9
|
+
readonly enums: string[];
|
|
10
|
+
readonly errors: string[];
|
|
11
|
+
readonly webhooks: Record<string, string[]>;
|
|
12
|
+
readonly callbacks: Record<string, string[]>;
|
|
13
|
+
readonly containers: string[];
|
|
14
|
+
readonly inputModels: InputModel[];
|
|
15
|
+
}
|
|
16
|
+
export type EndpointGroups = Map<string, TocEndpointPage[]>;
|
|
17
|
+
export type WebhookGroups = Map<string, TocWebhookPage[]>;
|
|
18
|
+
export type CallbackGroups = Map<string, TocCallbackPage[]>;
|
|
19
|
+
export declare class TocComponents {
|
|
20
|
+
readonly endpointGroups: EndpointGroups;
|
|
21
|
+
readonly models: TocModelPage[];
|
|
22
|
+
readonly enums: TocModelPage[];
|
|
23
|
+
readonly errors: TocModelPage[];
|
|
24
|
+
readonly containerModels: TocContainerModelPage[];
|
|
25
|
+
readonly inputModels: TocInputModelPage[];
|
|
26
|
+
readonly webhookGroups: WebhookGroups;
|
|
27
|
+
readonly callbackGroups: CallbackGroups;
|
|
28
|
+
private constructor();
|
|
29
|
+
static empty(): TocComponents;
|
|
30
|
+
static fromTocData(tocData: TocData): TocComponents;
|
|
31
|
+
private static toEndpointGroups;
|
|
32
|
+
private static toTocModelPages;
|
|
33
|
+
private static toTocContainerModelPages;
|
|
34
|
+
private static toTocInputModelPages;
|
|
35
|
+
private static toWebhookGroups;
|
|
36
|
+
private static toCallbackGroups;
|
|
37
|
+
}
|