@takeshape/schema 8.30.0 → 8.35.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/migration-utils.js +186 -0
- package/es/migration.js +105 -4
- package/es/mocks.js +1 -0
- package/es/project-schema/index.js +1 -0
- package/es/project-schema/v3.11.0.js +1 -0
- package/es/schema-util.js +15 -10
- package/es/schemas/index.js +4 -3
- package/es/schemas/index.ts +4 -2
- package/es/schemas/project-schema/v3.11.0.json +2135 -0
- package/es/services.js +57 -255
- package/es/types/types.js +9 -0
- package/es/types/utils.js +19 -12
- package/examples/latest/blog-schema.json +2 -1
- package/examples/latest/brewery-schema.json +2 -1
- package/examples/latest/complex-project-schema.json +2 -1
- package/examples/latest/fabric-ecommerce.json +2 -2
- package/examples/latest/frank-and-fred-schema.json +2 -1
- package/examples/latest/massive-schema.json +2 -1
- package/examples/latest/mill-components-schema.json +2 -1
- package/examples/latest/pet-oneof-array.json +2 -1
- package/examples/latest/post-schema.json +2 -1
- package/examples/latest/pruned-shopify-product-schema.json +2 -2
- package/examples/latest/real-world-schema.json +2 -1
- package/examples/latest/recursive-repeater-schema.json +2 -1
- package/examples/latest/recursive-schema.json +2 -1
- package/examples/latest/rick-and-morty-ast.json +1 -1
- package/examples/latest/rick-and-morty-graphql.json +1 -1
- package/examples/latest/rick-and-morty-rest.json +1 -1
- package/examples/latest/schema-with-repeater-draftjs.json +2 -1
- package/examples/latest/shape-books-v3_2_0.json +2 -1
- package/examples/latest/shape-books.json +2 -1
- package/examples/latest/shopify-lookbook.json +1 -1
- package/examples/latest/shopify-store-with-widget.json +2 -2
- package/examples/latest/stripe-starter-resolved.json +2 -2
- package/examples/latest/user-schema-no-required.json +2 -1
- package/examples/latest/user-schema-with-defaults.json +2 -1
- package/lib/migration-utils.d.ts +18 -0
- package/lib/migration-utils.d.ts.map +1 -0
- package/lib/migration-utils.js +203 -0
- package/lib/migration.d.ts +3 -3
- package/lib/migration.d.ts.map +1 -1
- package/lib/migration.js +110 -5
- package/lib/mocks.d.ts.map +1 -1
- package/lib/mocks.js +1 -0
- package/lib/project-schema/index.d.ts +3 -1
- package/lib/project-schema/index.d.ts.map +1 -1
- package/lib/project-schema/index.js +26 -13
- package/lib/project-schema/latest.d.ts +26 -17
- package/lib/project-schema/latest.d.ts.map +1 -1
- package/lib/project-schema/v3.11.0.d.ts +1211 -0
- package/lib/project-schema/v3.11.0.d.ts.map +1 -0
- package/lib/project-schema/v3.11.0.js +5 -0
- package/lib/schema-util.d.ts.map +1 -1
- package/lib/schema-util.js +16 -10
- package/lib/schemas/index.d.ts +2051 -2
- package/lib/schemas/index.d.ts.map +1 -1
- package/lib/schemas/index.js +17 -15
- package/lib/schemas/index.ts +4 -2
- package/lib/schemas/project-schema/v3.11.0.json +2135 -0
- package/lib/services.d.ts +11 -27
- package/lib/services.d.ts.map +1 -1
- package/lib/services.js +54 -261
- package/lib/types/types.d.ts +16 -5
- package/lib/types/types.d.ts.map +1 -1
- package/lib/types/types.js +9 -0
- package/lib/types/utils.d.ts +8 -5
- package/lib/types/utils.d.ts.map +1 -1
- package/lib/types/utils.js +25 -13
- package/lib/validate.d.ts +1 -1
- package/lib/validate.d.ts.map +1 -1
- package/package.json +6 -5
|
@@ -395,7 +395,7 @@
|
|
|
395
395
|
"namespace": "Stripe",
|
|
396
396
|
"serviceType": "openapi",
|
|
397
397
|
"authenticationType": "bearer",
|
|
398
|
-
"authentication": "
|
|
398
|
+
"authentication": "abc",
|
|
399
399
|
"options": {
|
|
400
400
|
"endpoint": "https://api.stripe.com/",
|
|
401
401
|
"spec": "https://raw.githubusercontent.com/stripe/openapi/master/openapi/spec3.json"
|
|
@@ -29312,5 +29312,5 @@
|
|
|
29312
29312
|
}
|
|
29313
29313
|
}
|
|
29314
29314
|
},
|
|
29315
|
-
"schemaVersion": "3.
|
|
29315
|
+
"schemaVersion": "3.11.0"
|
|
29316
29316
|
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is a stop-gap for this story: https://app.shortcut.com/takeshape/story/7140/reorganize-schema-migration-ts-into-a-directory
|
|
3
|
+
*/
|
|
4
|
+
import type { ServiceKey } from './types/types';
|
|
5
|
+
import type { StoredServiceConfigV3_1_0, ServiceConfigV3_1_0 } from './project-schema';
|
|
6
|
+
/**
|
|
7
|
+
* `graphql:my-key` `my-key`
|
|
8
|
+
*/
|
|
9
|
+
export declare function parseV3ServiceStr(service: string): {
|
|
10
|
+
provider?: string;
|
|
11
|
+
id: string;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Ensures a consistent service config, inluding updating the service
|
|
15
|
+
* authentication object.
|
|
16
|
+
*/
|
|
17
|
+
export declare function updateServiceConfigV3ToV3_1(serviceConfig: Record<string, unknown>, serviceKey: ServiceKey): StoredServiceConfigV3_1_0 | ServiceConfigV3_1_0;
|
|
18
|
+
//# sourceMappingURL=migration-utils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"migration-utils.d.ts","sourceRoot":"","sources":["../../src/migration-utils.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAC,UAAU,EAA2B,MAAM,eAAe,CAAC;AACxE,OAAO,KAAK,EAAC,yBAAyB,EAAE,mBAAmB,EAA8B,MAAM,kBAAkB,CAAC;AAQlH;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,GAAG;IAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAC,CAGlF;AAED;;;GAGG;AAEH,wBAAgB,2BAA2B,CACzC,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACtC,UAAU,EAAE,UAAU,GACrB,yBAAyB,GAAG,mBAAmB,CAkGjD"}
|
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.parseV3ServiceStr = parseV3ServiceStr;
|
|
7
|
+
exports.updateServiceConfigV3ToV3_1 = updateServiceConfigV3ToV3_1;
|
|
8
|
+
|
|
9
|
+
var _utils = require("./types/utils");
|
|
10
|
+
|
|
11
|
+
var _util = require("@takeshape/util");
|
|
12
|
+
|
|
13
|
+
var _isObject = _interopRequireDefault(require("lodash/isObject"));
|
|
14
|
+
|
|
15
|
+
var _isString = _interopRequireDefault(require("lodash/isString"));
|
|
16
|
+
|
|
17
|
+
var _isUndefined = _interopRequireDefault(require("lodash/isUndefined"));
|
|
18
|
+
|
|
19
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* This file is a stop-gap for this story: https://app.shortcut.com/takeshape/story/7140/reorganize-schema-migration-ts-into-a-directory
|
|
23
|
+
*/
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* `graphql:my-key` `my-key`
|
|
27
|
+
*/
|
|
28
|
+
function parseV3ServiceStr(service) {
|
|
29
|
+
const parts = service.split(':');
|
|
30
|
+
return {
|
|
31
|
+
provider: parts.length > 1 ? parts[0] : undefined,
|
|
32
|
+
id: parts.length > 1 ? parts[1] : parts[0]
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Ensures a consistent service config, inluding updating the service
|
|
37
|
+
* authentication object.
|
|
38
|
+
*/
|
|
39
|
+
// eslint-disable-next-line complexity
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
function updateServiceConfigV3ToV3_1(serviceConfig, serviceKey) {
|
|
43
|
+
if ((0, _utils.isAnyServiceConfig)(serviceConfig)) {
|
|
44
|
+
if ((0, _isString.default)(serviceConfig.authentication) || (0, _isUndefined.default)(serviceConfig.authentication)) {
|
|
45
|
+
return serviceConfig;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
return serviceConfig;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
const {
|
|
52
|
+
auth
|
|
53
|
+
} = serviceConfig;
|
|
54
|
+
const serviceParams = serviceConfig.params || {};
|
|
55
|
+
let {
|
|
56
|
+
provider: serviceKeyProvider,
|
|
57
|
+
id: serviceKeyId
|
|
58
|
+
} = parseV3ServiceStr(serviceKey);
|
|
59
|
+
const authType = serviceParams.authType || undefined;
|
|
60
|
+
const title = serviceParams.name || serviceKeyId;
|
|
61
|
+
|
|
62
|
+
if (serviceKeyId === 'vercel') {
|
|
63
|
+
serviceKeyProvider = 'vercel';
|
|
64
|
+
} else if (serviceKeyId === 'netlify') {
|
|
65
|
+
serviceKeyProvider = 'netlify';
|
|
66
|
+
} // Example schemas had this in params, which are untyped, so adding here just in case
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
if (serviceParams.type === 'rest') {
|
|
70
|
+
serviceKeyProvider = 'rest';
|
|
71
|
+
} else if (serviceParams.type === 'graphql' && serviceKeyProvider !== 'shopify') {
|
|
72
|
+
serviceKeyProvider = 'graphql';
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
let provider;
|
|
76
|
+
let authenticationType;
|
|
77
|
+
let serviceType;
|
|
78
|
+
let namespace;
|
|
79
|
+
|
|
80
|
+
if (serviceKeyProvider === 'shopify') {
|
|
81
|
+
provider = 'shopify';
|
|
82
|
+
authenticationType = 'oauth2Bearer';
|
|
83
|
+
serviceType = 'graphql';
|
|
84
|
+
namespace = serviceParams.namespace ?? 'Shopify';
|
|
85
|
+
} else if (serviceKeyProvider === 'takeshape') {
|
|
86
|
+
provider = 'takeshape';
|
|
87
|
+
authenticationType = 'none';
|
|
88
|
+
serviceType = 'takeshape';
|
|
89
|
+
namespace = serviceParams.namespace ?? 'TakeShape';
|
|
90
|
+
} else if (serviceKeyProvider === 'bigcommerce') {
|
|
91
|
+
provider = 'bigcommerce';
|
|
92
|
+
authenticationType = 'bearer';
|
|
93
|
+
serviceType = 'graphql';
|
|
94
|
+
namespace = serviceParams.namespace ?? 'BigCommerce';
|
|
95
|
+
} else if (serviceKeyProvider === 'rest') {
|
|
96
|
+
provider = 'generic';
|
|
97
|
+
authenticationType = mapAuthType(authType, auth);
|
|
98
|
+
serviceType = 'rest';
|
|
99
|
+
namespace = serviceParams.namespace ?? (0, _util.pascalCase)(title);
|
|
100
|
+
} else if (serviceKeyProvider === 'graphql') {
|
|
101
|
+
provider = 'generic';
|
|
102
|
+
authenticationType = mapAuthType(authType, auth);
|
|
103
|
+
serviceType = 'graphql';
|
|
104
|
+
namespace = serviceParams.namespace ?? (0, _util.pascalCase)(title);
|
|
105
|
+
} else if (serviceKeyProvider === 'vercel') {
|
|
106
|
+
provider = 'vercel';
|
|
107
|
+
authenticationType = 'oauth2Bearer';
|
|
108
|
+
serviceType = 'deployment';
|
|
109
|
+
} else if (serviceKeyProvider === 'netlify') {
|
|
110
|
+
provider = 'netlify';
|
|
111
|
+
authenticationType = 'oauth2Bearer';
|
|
112
|
+
serviceType = 'deployment';
|
|
113
|
+
} else {
|
|
114
|
+
provider = 'generic';
|
|
115
|
+
authenticationType = mapAuthType(authType, auth);
|
|
116
|
+
serviceType = 'unknown';
|
|
117
|
+
namespace = serviceParams.namespace ?? (0, _util.pascalCase)(title);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
const updatedServiceConfig = {
|
|
121
|
+
title,
|
|
122
|
+
id: serviceKey,
|
|
123
|
+
provider,
|
|
124
|
+
namespace,
|
|
125
|
+
serviceType,
|
|
126
|
+
authenticationType,
|
|
127
|
+
options: { ...serviceParams
|
|
128
|
+
}
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
if (serviceConfig.auth && (0, _isObject.default)(serviceConfig.auth)) {
|
|
132
|
+
const authentication = updateServiceAuthentication(updatedServiceConfig.authenticationType, serviceConfig.auth, serviceParams);
|
|
133
|
+
return { ...updatedServiceConfig,
|
|
134
|
+
authentication
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
return updatedServiceConfig;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* V1/V3 unencrypted `auth` -> V3.1 `authentication
|
|
142
|
+
*/
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
function updateServiceAuthentication(authenticationType, legacyAuth, legacyParams) {
|
|
146
|
+
if (authenticationType === 'oauth2Bearer') {
|
|
147
|
+
return {
|
|
148
|
+
token: legacyAuth.accessToken,
|
|
149
|
+
scope: legacyAuth.scope,
|
|
150
|
+
header: legacyParams.authHeader
|
|
151
|
+
};
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
if (authenticationType === 'searchParams' && legacyParams.authProp) {
|
|
155
|
+
return [{
|
|
156
|
+
name: legacyParams.authProp,
|
|
157
|
+
value: legacyAuth.accessToken
|
|
158
|
+
}];
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
if (authenticationType === 'basic') {
|
|
162
|
+
const [username, password] = Buffer.from(legacyAuth.accessToken, 'base64').toString('utf-8').split(':');
|
|
163
|
+
return {
|
|
164
|
+
username,
|
|
165
|
+
password
|
|
166
|
+
};
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
if (authenticationType === 'bearer') {
|
|
170
|
+
return {
|
|
171
|
+
token: legacyAuth.accessToken,
|
|
172
|
+
header: legacyParams.authHeader
|
|
173
|
+
};
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
function mapAuthType(authType, auth) {
|
|
178
|
+
if (authType === 'none') {
|
|
179
|
+
return 'none';
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
if (authType === 'searchParams') {
|
|
183
|
+
return 'searchParams';
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
if (authType === 'bearer') {
|
|
187
|
+
return 'bearer';
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
if (authType === 'bearer') {
|
|
191
|
+
return 'basic';
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
if (!auth) {
|
|
195
|
+
return 'none';
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
if (auth) {
|
|
199
|
+
return 'bearer';
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
return 'unknown';
|
|
203
|
+
}
|
package/lib/migration.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import type { ProjectSchema, AnyProjectSchema, ProjectSchemaV1_0_0, ProjectSchemaV3_0_0, ProjectSchemaV3_1_0, ProjectSchemaV3_2_0, ProjectSchemaV3_3_0, ProjectSchemaV3_4_0, ProjectSchemaV3_5_0, ProjectSchemaV3_5_1, ProjectSchemaV3_6_0, ProjectSchemaV3_7_0, ProjectSchemaV3_8_0, ProjectSchemaV3_9_0, ProjectSchemaV3_10_0, PropertySchema, ContentTypeV1_0_0, ContentSchemaV1_0_0, Relationship, FormConfig, Workflow, Shape, ShapeMapV3_0_0, ContentSchemaV3_0_0 } from './project-schema';
|
|
2
|
-
import type { EncryptFn } from './services';
|
|
3
|
-
import { SafeDecryptFn } from './services';
|
|
1
|
+
import type { ProjectSchema, AnyProjectSchema, ProjectSchemaV1_0_0, ProjectSchemaV3_0_0, ProjectSchemaV3_1_0, ProjectSchemaV3_2_0, ProjectSchemaV3_3_0, ProjectSchemaV3_4_0, ProjectSchemaV3_5_0, ProjectSchemaV3_5_1, ProjectSchemaV3_6_0, ProjectSchemaV3_7_0, ProjectSchemaV3_8_0, ProjectSchemaV3_9_0, ProjectSchemaV3_10_0, ProjectSchemaV3_11_0, PropertySchema, ContentTypeV1_0_0, ContentSchemaV1_0_0, Relationship, FormConfig, Workflow, Shape, ShapeMapV3_0_0, ContentSchemaV3_0_0 } from './project-schema';
|
|
2
|
+
import type { EncryptFn, SafeDecryptFn } from './services';
|
|
4
3
|
export declare const listTypePrefix = "PaginatedList";
|
|
5
4
|
interface ConversionParams {
|
|
6
5
|
shapeName: string;
|
|
@@ -44,6 +43,7 @@ export declare function migrateToV3_7(projectSchema: ProjectSchemaV3_6_0): Proje
|
|
|
44
43
|
export declare function migrateToV3_8(projectSchema: ProjectSchemaV3_7_0): ProjectSchemaV3_8_0;
|
|
45
44
|
export declare function migrateToV3_9_0(projectSchema: ProjectSchemaV3_8_0): ProjectSchemaV3_9_0;
|
|
46
45
|
export declare function migrateToV3_10(projectSchema: ProjectSchemaV3_9_0): ProjectSchemaV3_10_0;
|
|
46
|
+
export declare function migrateToV3_11_0({ decryptFn, encryptFn }: ProjectSchemaMigrationContext, projectSchema: ProjectSchemaV3_10_0): ProjectSchemaV3_11_0;
|
|
47
47
|
export declare function migrateToLatestProjectSchema(context: ProjectSchemaMigrationContext, projectSchema: AnyProjectSchema): Promise<ProjectSchema>;
|
|
48
48
|
export declare function normalizeSchemaVersion(version?: string): string;
|
|
49
49
|
export declare function isV1Like(schema: {
|
package/lib/migration.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"migration.d.ts","sourceRoot":"","sources":["../../src/migration.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,oBAAoB,EASpB,cAAc,EACd,iBAAiB,EAEjB,mBAAmB,EACnB,YAAY,EACZ,UAAU,EACV,QAAQ,EAER,KAAK,EACL,cAAc,EAOd,mBAAmB,
|
|
1
|
+
{"version":3,"file":"migration.d.ts","sourceRoot":"","sources":["../../src/migration.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EAC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SAAS,EAAE,SAAS,EAAC,EAAE,6BAA6B,EACrD,aAAa,EAAE,oBAAoB,GAClC,oBAAoB,CA6FtB;AAED,wBAAsB,4BAA4B,CAChD,OAAO,EAAE,6BAA6B,EACtC,aAAa,EAAE,gBAAgB,GAC9B,OAAO,CAAC,aAAa,CAAC,CA0DxB;AAED,wBAAgB,sBAAsB,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,CAE/D;AAED,wBAAgB,QAAQ,CAAC,MAAM,EAAE;IAAC,aAAa,CAAC,EAAE,MAAM,CAAA;CAAC,GAAG,OAAO,CAElE;AAED,wBAAgB,IAAI,CAAC,MAAM,EAAE,gBAAgB,GAAG,MAAM,IAAI,mBAAmB,CAE5E;AAED,wBAAgB,QAAQ,CAAC,MAAM,EAAE;IAAC,aAAa,CAAC,EAAE,MAAM,CAAA;CAAC,GAAG,OAAO,CAElE;AAED,wBAAgB,IAAI,CAAC,MAAM,EAAE,gBAAgB,GAAG,MAAM,IAAI,mBAAmB,CAE5E;AAED,wBAAsB,YAAY,CAChC,OAAO,EAAE,6BAA6B,EACtC,MAAM,CAAC,EAAE,gBAAgB,GACxB,OAAO,CAAC,aAAa,GAAG,SAAS,CAAC,CAMpC"}
|
package/lib/migration.js
CHANGED
|
@@ -16,6 +16,7 @@ exports.migrateToLatestProjectSchema = migrateToLatestProjectSchema;
|
|
|
16
16
|
exports.migrateToV3 = migrateToV3;
|
|
17
17
|
exports.migrateToV3_1 = migrateToV3_1;
|
|
18
18
|
exports.migrateToV3_10 = migrateToV3_10;
|
|
19
|
+
exports.migrateToV3_11_0 = migrateToV3_11_0;
|
|
19
20
|
exports.migrateToV3_2 = migrateToV3_2;
|
|
20
21
|
exports.migrateToV3_3 = migrateToV3_3;
|
|
21
22
|
exports.migrateToV3_4 = migrateToV3_4;
|
|
@@ -33,16 +34,20 @@ var _forEach = _interopRequireDefault(require("lodash/forEach"));
|
|
|
33
34
|
|
|
34
35
|
var _pick = _interopRequireDefault(require("lodash/pick"));
|
|
35
36
|
|
|
37
|
+
var _mapValues = _interopRequireDefault(require("lodash/mapValues"));
|
|
38
|
+
|
|
39
|
+
var _isObject = _interopRequireDefault(require("lodash/isObject"));
|
|
40
|
+
|
|
41
|
+
var _fromPairs = _interopRequireDefault(require("lodash/fromPairs"));
|
|
42
|
+
|
|
36
43
|
var _util = require("@takeshape/util");
|
|
37
44
|
|
|
38
45
|
var _schemaUtil = require("./schema-util");
|
|
39
46
|
|
|
40
|
-
var
|
|
47
|
+
var _migrationUtils = require("./migration-utils");
|
|
41
48
|
|
|
42
49
|
var _utils = require("./types/utils");
|
|
43
50
|
|
|
44
|
-
var _mapValues = _interopRequireDefault(require("lodash/mapValues"));
|
|
45
|
-
|
|
46
51
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
47
52
|
|
|
48
53
|
const listTypePrefix = 'PaginatedList';
|
|
@@ -321,12 +326,12 @@ async function migrateToV3_1(context, projectSchema) {
|
|
|
321
326
|
if (projectSchema.services) {
|
|
322
327
|
services = await (0, _pReduce.default)(Object.entries(projectSchema.services), async (serviceMap, [serviceKey, serviceConfig]) => {
|
|
323
328
|
const auth = serviceConfig.auth && decryptFn(serviceConfig.auth);
|
|
324
|
-
const updatedServiceConfig = (0,
|
|
329
|
+
const updatedServiceConfig = (0, _migrationUtils.updateServiceConfigV3ToV3_1)({ ...serviceConfig,
|
|
325
330
|
auth
|
|
326
331
|
}, serviceKey);
|
|
327
332
|
const authentication = updatedServiceConfig === null || updatedServiceConfig === void 0 ? void 0 : updatedServiceConfig.authentication;
|
|
328
333
|
serviceMap[serviceKey] = { ...updatedServiceConfig,
|
|
329
|
-
authentication: (0,
|
|
334
|
+
authentication: authentication && (0, _isObject.default)(authentication) ? encryptFn(authentication) : authentication
|
|
330
335
|
};
|
|
331
336
|
return serviceMap;
|
|
332
337
|
}, {});
|
|
@@ -549,6 +554,102 @@ function migrateToV3_10(projectSchema) {
|
|
|
549
554
|
};
|
|
550
555
|
}
|
|
551
556
|
|
|
557
|
+
function migrateToV3_11_0({
|
|
558
|
+
decryptFn,
|
|
559
|
+
encryptFn
|
|
560
|
+
}, projectSchema) {
|
|
561
|
+
const migratedServices = [];
|
|
562
|
+
|
|
563
|
+
for (const [serviceKey, serviceConfig] of Object.entries(projectSchema.services ?? {})) {
|
|
564
|
+
const {
|
|
565
|
+
authenticationType,
|
|
566
|
+
authentication
|
|
567
|
+
} = serviceConfig; // Migrate authentication, ensuring now required properties
|
|
568
|
+
|
|
569
|
+
if (authentication && authenticationType !== 'unknown' && authenticationType !== 'none') {
|
|
570
|
+
const decrypted = decryptFn(authentication);
|
|
571
|
+
|
|
572
|
+
if (!decrypted) {
|
|
573
|
+
throw new Error(`Service "${serviceKey}" authentication could not be decrypted. Please contact support.`);
|
|
574
|
+
}
|
|
575
|
+
|
|
576
|
+
let migrated;
|
|
577
|
+
|
|
578
|
+
if (authenticationType === 'searchParams') {
|
|
579
|
+
migrated = {
|
|
580
|
+
params: decrypted,
|
|
581
|
+
type: authenticationType
|
|
582
|
+
};
|
|
583
|
+
}
|
|
584
|
+
|
|
585
|
+
if (authenticationType === 'basic') {
|
|
586
|
+
migrated = {
|
|
587
|
+
username: '',
|
|
588
|
+
password: '',
|
|
589
|
+
...decrypted,
|
|
590
|
+
type: authenticationType
|
|
591
|
+
};
|
|
592
|
+
}
|
|
593
|
+
|
|
594
|
+
if (authenticationType === 'bearer') {
|
|
595
|
+
migrated = {
|
|
596
|
+
token: '',
|
|
597
|
+
...decrypted,
|
|
598
|
+
type: authenticationType
|
|
599
|
+
};
|
|
600
|
+
}
|
|
601
|
+
|
|
602
|
+
if (authenticationType === 'oauth2Bearer') {
|
|
603
|
+
migrated = {
|
|
604
|
+
token: '',
|
|
605
|
+
...decrypted,
|
|
606
|
+
type: authenticationType
|
|
607
|
+
};
|
|
608
|
+
}
|
|
609
|
+
|
|
610
|
+
if (authenticationType === 'oauth2') {
|
|
611
|
+
migrated = {
|
|
612
|
+
grantType: 'clientCredentials',
|
|
613
|
+
clientId: '',
|
|
614
|
+
...decrypted,
|
|
615
|
+
type: authenticationType
|
|
616
|
+
};
|
|
617
|
+
}
|
|
618
|
+
|
|
619
|
+
if (authenticationType === 'aws') {
|
|
620
|
+
migrated = {
|
|
621
|
+
awsAccessKeyId: '',
|
|
622
|
+
awsSecretAccessKey: '',
|
|
623
|
+
...decrypted,
|
|
624
|
+
type: authenticationType
|
|
625
|
+
};
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
if (authenticationType === 'custom') {
|
|
629
|
+
migrated = { ...decrypted,
|
|
630
|
+
type: authenticationType
|
|
631
|
+
};
|
|
632
|
+
}
|
|
633
|
+
|
|
634
|
+
if (migrated) {
|
|
635
|
+
const migratedServiceConfig = { ...serviceConfig,
|
|
636
|
+
authentication: encryptFn(migrated)
|
|
637
|
+
};
|
|
638
|
+
migratedServices.push([serviceKey, migratedServiceConfig]);
|
|
639
|
+
} else {
|
|
640
|
+
migratedServices.push([serviceKey, serviceConfig]);
|
|
641
|
+
}
|
|
642
|
+
} else {
|
|
643
|
+
migratedServices.push([serviceKey, serviceConfig]);
|
|
644
|
+
}
|
|
645
|
+
}
|
|
646
|
+
|
|
647
|
+
return { ...projectSchema,
|
|
648
|
+
services: (0, _fromPairs.default)(migratedServices),
|
|
649
|
+
schemaVersion: '3.11.0'
|
|
650
|
+
};
|
|
651
|
+
}
|
|
652
|
+
|
|
552
653
|
async function migrateToLatestProjectSchema(context, projectSchema) {
|
|
553
654
|
if (projectSchema.schemaVersion === '4.0.0') {
|
|
554
655
|
throw new Error('You are using an unreleased schema version. Migration is not possible');
|
|
@@ -602,6 +703,10 @@ async function migrateToLatestProjectSchema(context, projectSchema) {
|
|
|
602
703
|
projectSchema = migrateToV3_10(projectSchema);
|
|
603
704
|
}
|
|
604
705
|
|
|
706
|
+
if ((0, _utils.isProjectSchemaV3_10)(projectSchema)) {
|
|
707
|
+
projectSchema = migrateToV3_11_0(context, projectSchema);
|
|
708
|
+
}
|
|
709
|
+
|
|
605
710
|
return projectSchema;
|
|
606
711
|
}
|
|
607
712
|
|
package/lib/mocks.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mocks.d.ts","sourceRoot":"","sources":["../../src/mocks.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,aAAa,EAAE,aAAa,EAAE,mBAAmB,EAAC,MAAM,kBAAkB,CAAC;AACxF,OAAO,KAAK,EAAC,UAAU,EAAC,MAAM,eAAe,CAAC;AAI9C;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,GAAE,OAAO,CAAC,aAAa,CAAM,GAAG,aAAa,CAKtG;AAED;;GAEG;AACH,wBAAgB,4BAA4B,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,GAAE,OAAO,CAAC,aAAa,CAAM,GAAG,aAAa,CAKlH;AAED,wBAAgB,uBAAuB,CAAC,UAAU,EAAE,UAAU,EAAE,aAAa,CAAC,EAAE,OAAO,CAAC,aAAa,CAAC,GAAG,aAAa,
|
|
1
|
+
{"version":3,"file":"mocks.d.ts","sourceRoot":"","sources":["../../src/mocks.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,aAAa,EAAE,aAAa,EAAE,mBAAmB,EAAC,MAAM,kBAAkB,CAAC;AACxF,OAAO,KAAK,EAAC,UAAU,EAAC,MAAM,eAAe,CAAC;AAI9C;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,GAAE,OAAO,CAAC,aAAa,CAAM,GAAG,aAAa,CAKtG;AAED;;GAEG;AACH,wBAAgB,4BAA4B,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,GAAE,OAAO,CAAC,aAAa,CAAM,GAAG,aAAa,CAKlH;AAED,wBAAgB,uBAAuB,CAAC,UAAU,EAAE,UAAU,EAAE,aAAa,CAAC,EAAE,OAAO,CAAC,aAAa,CAAC,GAAG,aAAa,CAiBrH;AAED,wBAAgB,6BAA6B,CAC3C,UAAU,EAAE,UAAU,EACtB,aAAa,CAAC,EAAE,OAAO,CAAC,mBAAmB,CAAC,GAC3C,mBAAmB,CAMrB"}
|
package/lib/mocks.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export * from './latest';
|
|
2
2
|
export * from './v4.0.0';
|
|
3
|
+
export * from './v3.11.0';
|
|
3
4
|
export * from './v3.10.0';
|
|
4
5
|
export * from './v3.9.0';
|
|
5
6
|
export * from './v3.8.0';
|
|
@@ -14,6 +15,7 @@ export * from './v3.1.0';
|
|
|
14
15
|
export * from './v3.0.0';
|
|
15
16
|
export * from './v1.0.0';
|
|
16
17
|
import { ProjectSchemaV4_0_0 } from './v4.0.0';
|
|
18
|
+
import { ProjectSchemaV3_11_0 } from './v3.11.0';
|
|
17
19
|
import { ProjectSchemaV3_10_0 } from './v3.10.0';
|
|
18
20
|
import { ProjectSchemaV3_9_0 } from './v3.9.0';
|
|
19
21
|
import { ProjectSchemaV3_8_0 } from './v3.8.0';
|
|
@@ -28,5 +30,5 @@ import { ProjectSchemaV3_1_0 } from './v3.1.0';
|
|
|
28
30
|
import { ProjectSchemaV3_0_0 } from './v3.0.0';
|
|
29
31
|
import { ProjectSchemaV1_0_0 } from './v1.0.0';
|
|
30
32
|
import { ProjectSchema } from './latest';
|
|
31
|
-
export declare type AnyProjectSchema = ProjectSchemaV4_0_0 | ProjectSchemaV3_10_0 | ProjectSchemaV3_9_0 | ProjectSchemaV3_8_0 | ProjectSchemaV3_7_0 | ProjectSchemaV3_6_0 | ProjectSchemaV3_5_1 | ProjectSchemaV3_5_0 | ProjectSchemaV3_4_0 | ProjectSchemaV3_3_0 | ProjectSchemaV3_2_0 | ProjectSchemaV3_1_0 | ProjectSchemaV3_0_0 | ProjectSchemaV1_0_0 | ProjectSchema;
|
|
33
|
+
export declare type AnyProjectSchema = ProjectSchemaV4_0_0 | ProjectSchemaV3_11_0 | ProjectSchemaV3_10_0 | ProjectSchemaV3_9_0 | ProjectSchemaV3_8_0 | ProjectSchemaV3_7_0 | ProjectSchemaV3_6_0 | ProjectSchemaV3_5_1 | ProjectSchemaV3_5_0 | ProjectSchemaV3_4_0 | ProjectSchemaV3_3_0 | ProjectSchemaV3_2_0 | ProjectSchemaV3_1_0 | ProjectSchemaV3_0_0 | ProjectSchemaV1_0_0 | ProjectSchema;
|
|
32
34
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/project-schema/index.ts"],"names":[],"mappings":"AACA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,oBAAoB,EAAC,MAAM,WAAW,CAAC;AAC/C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBA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AC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAC,aAAa,EAAC,MAAM,UAAU,CAAC;AACvC,oBAAY,gBAAgB,GACxB,mBAAmB,GACnB,oBAAoB,GACpB,oBAAoB,GACpB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,aAAa,CAAC"}
|
|
@@ -30,7 +30,7 @@ Object.keys(_v).forEach(function (key) {
|
|
|
30
30
|
});
|
|
31
31
|
});
|
|
32
32
|
|
|
33
|
-
var _v2 = require("./v3.
|
|
33
|
+
var _v2 = require("./v3.11.0");
|
|
34
34
|
|
|
35
35
|
Object.keys(_v2).forEach(function (key) {
|
|
36
36
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -43,7 +43,7 @@ Object.keys(_v2).forEach(function (key) {
|
|
|
43
43
|
});
|
|
44
44
|
});
|
|
45
45
|
|
|
46
|
-
var _v3 = require("./v3.
|
|
46
|
+
var _v3 = require("./v3.10.0");
|
|
47
47
|
|
|
48
48
|
Object.keys(_v3).forEach(function (key) {
|
|
49
49
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -56,7 +56,7 @@ Object.keys(_v3).forEach(function (key) {
|
|
|
56
56
|
});
|
|
57
57
|
});
|
|
58
58
|
|
|
59
|
-
var _v4 = require("./v3.
|
|
59
|
+
var _v4 = require("./v3.9.0");
|
|
60
60
|
|
|
61
61
|
Object.keys(_v4).forEach(function (key) {
|
|
62
62
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -69,7 +69,7 @@ Object.keys(_v4).forEach(function (key) {
|
|
|
69
69
|
});
|
|
70
70
|
});
|
|
71
71
|
|
|
72
|
-
var _v5 = require("./v3.
|
|
72
|
+
var _v5 = require("./v3.8.0");
|
|
73
73
|
|
|
74
74
|
Object.keys(_v5).forEach(function (key) {
|
|
75
75
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -82,7 +82,7 @@ Object.keys(_v5).forEach(function (key) {
|
|
|
82
82
|
});
|
|
83
83
|
});
|
|
84
84
|
|
|
85
|
-
var _v6 = require("./v3.
|
|
85
|
+
var _v6 = require("./v3.7.0");
|
|
86
86
|
|
|
87
87
|
Object.keys(_v6).forEach(function (key) {
|
|
88
88
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -95,7 +95,7 @@ Object.keys(_v6).forEach(function (key) {
|
|
|
95
95
|
});
|
|
96
96
|
});
|
|
97
97
|
|
|
98
|
-
var _v7 = require("./v3.
|
|
98
|
+
var _v7 = require("./v3.6.0");
|
|
99
99
|
|
|
100
100
|
Object.keys(_v7).forEach(function (key) {
|
|
101
101
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -108,7 +108,7 @@ Object.keys(_v7).forEach(function (key) {
|
|
|
108
108
|
});
|
|
109
109
|
});
|
|
110
110
|
|
|
111
|
-
var _v8 = require("./v3.5.
|
|
111
|
+
var _v8 = require("./v3.5.1");
|
|
112
112
|
|
|
113
113
|
Object.keys(_v8).forEach(function (key) {
|
|
114
114
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -121,7 +121,7 @@ Object.keys(_v8).forEach(function (key) {
|
|
|
121
121
|
});
|
|
122
122
|
});
|
|
123
123
|
|
|
124
|
-
var _v9 = require("./v3.
|
|
124
|
+
var _v9 = require("./v3.5.0");
|
|
125
125
|
|
|
126
126
|
Object.keys(_v9).forEach(function (key) {
|
|
127
127
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -134,7 +134,7 @@ Object.keys(_v9).forEach(function (key) {
|
|
|
134
134
|
});
|
|
135
135
|
});
|
|
136
136
|
|
|
137
|
-
var _v10 = require("./v3.
|
|
137
|
+
var _v10 = require("./v3.4.0");
|
|
138
138
|
|
|
139
139
|
Object.keys(_v10).forEach(function (key) {
|
|
140
140
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -147,7 +147,7 @@ Object.keys(_v10).forEach(function (key) {
|
|
|
147
147
|
});
|
|
148
148
|
});
|
|
149
149
|
|
|
150
|
-
var _v11 = require("./v3.
|
|
150
|
+
var _v11 = require("./v3.3.0");
|
|
151
151
|
|
|
152
152
|
Object.keys(_v11).forEach(function (key) {
|
|
153
153
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -160,7 +160,7 @@ Object.keys(_v11).forEach(function (key) {
|
|
|
160
160
|
});
|
|
161
161
|
});
|
|
162
162
|
|
|
163
|
-
var _v12 = require("./v3.
|
|
163
|
+
var _v12 = require("./v3.2.0");
|
|
164
164
|
|
|
165
165
|
Object.keys(_v12).forEach(function (key) {
|
|
166
166
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -173,7 +173,7 @@ Object.keys(_v12).forEach(function (key) {
|
|
|
173
173
|
});
|
|
174
174
|
});
|
|
175
175
|
|
|
176
|
-
var _v13 = require("./v3.
|
|
176
|
+
var _v13 = require("./v3.1.0");
|
|
177
177
|
|
|
178
178
|
Object.keys(_v13).forEach(function (key) {
|
|
179
179
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -186,7 +186,7 @@ Object.keys(_v13).forEach(function (key) {
|
|
|
186
186
|
});
|
|
187
187
|
});
|
|
188
188
|
|
|
189
|
-
var _v14 = require("./
|
|
189
|
+
var _v14 = require("./v3.0.0");
|
|
190
190
|
|
|
191
191
|
Object.keys(_v14).forEach(function (key) {
|
|
192
192
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -197,4 +197,17 @@ Object.keys(_v14).forEach(function (key) {
|
|
|
197
197
|
return _v14[key];
|
|
198
198
|
}
|
|
199
199
|
});
|
|
200
|
+
});
|
|
201
|
+
|
|
202
|
+
var _v15 = require("./v1.0.0");
|
|
203
|
+
|
|
204
|
+
Object.keys(_v15).forEach(function (key) {
|
|
205
|
+
if (key === "default" || key === "__esModule") return;
|
|
206
|
+
if (key in exports && exports[key] === _v15[key]) return;
|
|
207
|
+
Object.defineProperty(exports, key, {
|
|
208
|
+
enumerable: true,
|
|
209
|
+
get: function () {
|
|
210
|
+
return _v15[key];
|
|
211
|
+
}
|
|
212
|
+
});
|
|
200
213
|
});
|