@restorecommerce/facade 0.3.3 → 0.3.4

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/CHANGELOG.md CHANGED
@@ -3,6 +3,18 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [0.3.4](https://github.com/restorecommerce/libs/compare/@restorecommerce/facade@0.3.3...@restorecommerce/facade@0.3.4) (2022-03-04)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **facade:** added scope for all mutations and queries ([3b4df19](https://github.com/restorecommerce/libs/commit/3b4df196fa8bbbdc169846c588d3d53c85a4c091))
12
+ * **facade:** fixed enum type mapping for nested object ([f452229](https://github.com/restorecommerce/libs/commit/f452229fc3ceec7205d079884a55076578e5a975))
13
+
14
+
15
+
16
+
17
+
6
18
  ## [0.3.3](https://github.com/restorecommerce/libs/compare/@restorecommerce/facade@0.3.2...@restorecommerce/facade@0.3.3) (2022-03-01)
7
19
 
8
20
  **Note:** Version bump only for package @restorecommerce/facade
@@ -7,7 +7,6 @@ const graphql_upload_1 = require("graphql-upload");
7
7
  const utils_1 = require("./utils");
8
8
  const types_1 = require("./types");
9
9
  const ts_proto_descriptors_1 = require("ts-proto-descriptors");
10
- const _ = require("lodash");
11
10
  exports.registeredTypings = new Map();
12
11
  exports.scalarTypes = ['Boolean', 'Int', 'Float', 'String', 'ID', 'Upload'];
13
12
  const typeNameAndNameSpaceMapping = new Map();
@@ -81,12 +80,6 @@ const recursiveEnumCheck = (typeName, enumMap, prevFieldName, traversedFields) =
81
80
  // skip loop as this GQL type is already traversed
82
81
  continue;
83
82
  }
84
- if (!prevFieldName || _.isEmpty(prevFieldName)) {
85
- prevFieldName = fieldName;
86
- }
87
- if (prevFieldName && prevFieldName != fieldName) {
88
- fieldName = prevFieldName + '.' + fieldName;
89
- }
90
83
  (0, exports.recursiveEnumCheck)(fieldType, enumMap, fieldName, traversedFields);
91
84
  }
92
85
  }
@@ -173,6 +166,13 @@ const registerTyping = (protoPackage, message, methodDef, opts, inputOpts) => {
173
166
  type: ModeType
174
167
  };
175
168
  }
169
+ // add scope to all mutations / queries
170
+ if (!result.scope) {
171
+ result['scope'] = {
172
+ description: 'target scope',
173
+ type: graphql_1.GraphQLString
174
+ };
175
+ }
176
176
  return result;
177
177
  };
178
178
  const resultObj = new graphql_1.GraphQLObjectType({
@@ -3,23 +3,9 @@ export declare const capitalizeProtoName: (name: string) => string;
3
3
  export declare const convertyCamelToSnakeCase: (entity: string) => string;
4
4
  export declare const getKeys: (obj: any) => string[];
5
5
  export declare const decodeBufferFields: (items: any, bufferFields: string[]) => any;
6
- interface EnumMetaData {
7
- name: string;
8
- number: number;
9
- options?: any;
10
- }
11
- /**
12
- * recursively find the path and updates the object with given value, this function
13
- * also takes care to handle if there is an array at any position in the path
14
- * @param path path in dot notation
15
- * @param val value to be updated in Object
16
- * @param obj Object
17
- */
18
- export declare const updateJSON: (path: string, val: EnumMetaData[], obj: any) => void;
19
6
  /**
20
7
  * converts enum string values to integers reading from the inputTyping
21
8
  * @param TypingData input typing
22
9
  * @param req request object from which the enum strings to be replaced
23
10
  */
24
11
  export declare const convertEnumToInt: (inputTyping: TypingData, req: any) => any;
25
- export {};
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.convertEnumToInt = exports.updateJSON = exports.decodeBufferFields = exports.getKeys = exports.convertyCamelToSnakeCase = exports.capitalizeProtoName = void 0;
3
+ exports.convertEnumToInt = exports.decodeBufferFields = exports.getKeys = exports.convertyCamelToSnakeCase = exports.capitalizeProtoName = void 0;
4
4
  const _ = require("lodash");
5
5
  const registry_1 = require("./registry");
6
6
  const capitalizeProtoName = (name) => {
@@ -50,50 +50,25 @@ const decodeBufferFields = (items, bufferFields) => {
50
50
  };
51
51
  exports.decodeBufferFields = decodeBufferFields;
52
52
  /**
53
- * recursively find the path and updates the object with given value, this function
53
+ * recursively find the id and updates the object with given value, this function
54
54
  * also takes care to handle if there is an array at any position in the path
55
- * @param path path in dot notation
55
+ * @param id property of the object
56
56
  * @param val value to be updated in Object
57
57
  * @param obj Object
58
58
  */
59
- const updateJSON = (path, val, obj) => {
60
- let fields = path.split('.');
61
- let result = obj;
62
- let j = 0;
63
- for (let i = 0, n = fields.length; i < n && result !== undefined; i++) {
64
- let field = fields[i];
65
- if (i === n - 1) {
66
- // reset value finally after iterating to the position (only if value already exists)
67
- if (result[field]) {
68
- const foundElement = val.find((e) => e.name === result[field]);
69
- result[field] = foundElement === null || foundElement === void 0 ? void 0 : foundElement.number;
59
+ const updateJSON = (id, value, obj) => {
60
+ for (const [k, v] of Object.entries(obj)) {
61
+ if (k === id) {
62
+ const foundObj = value.find((e) => e.name === obj[k]);
63
+ if (foundObj) {
64
+ obj[k] = foundObj.number;
70
65
  }
71
66
  }
72
- else {
73
- if (_.isArray(result[field])) {
74
- // till i < n concat new fields
75
- let newField = '';
76
- for (let k = i + 1; k < n; k++) {
77
- if (newField && !_.isEmpty(newField)) {
78
- newField = newField + '.' + fields[k];
79
- }
80
- else {
81
- newField = fields[k];
82
- }
83
- }
84
- for (; j < result[field].length; j++) {
85
- // recurisve call to update each element if its an array
86
- (0, exports.updateJSON)(newField, val, result[field][j]);
87
- }
88
- }
89
- else {
90
- // update object till final path is reached
91
- result = result[field];
92
- }
67
+ else if (typeof v === "object") {
68
+ updateJSON(id, value, v);
93
69
  }
94
70
  }
95
71
  };
96
- exports.updateJSON = updateJSON;
97
72
  /**
98
73
  * converts enum string values to integers reading from the inputTyping
99
74
  * @param TypingData input typing
@@ -128,7 +103,8 @@ const convertEnumToInt = (inputTyping, req) => {
128
103
  const enumTyping = (0, registry_1.getTyping)(enumNameSpace);
129
104
  const enumIntMapping = (enumTyping === null || enumTyping === void 0 ? void 0 : enumTyping.meta).value;
130
105
  if (enumIntMapping && _.isArray(enumIntMapping) && enumIntMapping.length > 0) {
131
- (0, exports.updateJSON)(val, enumIntMapping, req);
106
+ // val refers to property name
107
+ updateJSON(val, enumIntMapping, req);
132
108
  }
133
109
  }
134
110
  }
@@ -78,25 +78,35 @@ export declare type IoRestorecommerceStatusOperationStatus = {
78
78
  export declare type IIoRestorecommerceAccessControlRequest = {
79
79
  target?: InputMaybe<IIoRestorecommerceRuleTarget>;
80
80
  context?: InputMaybe<IIoRestorecommerceAccessControlContext>;
81
+ /** target scope */
82
+ scope?: InputMaybe<Scalars['String']>;
81
83
  };
82
84
  export declare type IIoRestorecommerceRuleTarget = {
83
85
  subject?: InputMaybe<Array<IIoRestorecommerceAttributeAttribute>>;
84
86
  resources?: InputMaybe<Array<IIoRestorecommerceAttributeAttribute>>;
85
87
  action?: InputMaybe<Array<IIoRestorecommerceAttributeAttribute>>;
88
+ /** target scope */
89
+ scope?: InputMaybe<Scalars['String']>;
86
90
  };
87
91
  export declare type IIoRestorecommerceAttributeAttribute = {
88
92
  id?: InputMaybe<Scalars['String']>;
89
93
  value?: InputMaybe<Scalars['String']>;
90
94
  attribute?: InputMaybe<Array<IIoRestorecommerceAttributeAttribute>>;
95
+ /** target scope */
96
+ scope?: InputMaybe<Scalars['String']>;
91
97
  };
92
98
  export declare type IIoRestorecommerceAccessControlContext = {
93
99
  subject?: InputMaybe<IGoogleProtobufAny>;
94
100
  resources?: InputMaybe<Array<IGoogleProtobufAny>>;
95
101
  security?: InputMaybe<IGoogleProtobufAny>;
102
+ /** target scope */
103
+ scope?: InputMaybe<Scalars['String']>;
96
104
  };
97
105
  export declare type IGoogleProtobufAny = {
98
106
  typeUrl?: InputMaybe<Scalars['String']>;
99
107
  value?: InputMaybe<Scalars['Upload']>;
108
+ /** target scope */
109
+ scope?: InputMaybe<Scalars['String']>;
100
110
  };
101
111
  export declare type ProtoIoRestorecommerceAccessControlReverseQuery = {
102
112
  __typename?: 'ProtoIoRestorecommerceAccessControlReverseQuery';
@@ -247,10 +257,14 @@ export declare type IIoRestorecommerceResourcebaseReadRequest = {
247
257
  localesLimiter?: InputMaybe<Array<Scalars['String']>>;
248
258
  customQueries?: InputMaybe<Array<Scalars['String']>>;
249
259
  customArguments?: InputMaybe<IGoogleProtobufAny>;
260
+ /** target scope */
261
+ scope?: InputMaybe<Scalars['String']>;
250
262
  };
251
263
  export declare type IIoRestorecommerceResourcebaseSort = {
252
264
  field?: InputMaybe<Scalars['String']>;
253
265
  order?: InputMaybe<IoRestorecommerceResourcebaseSortSortOrder>;
266
+ /** target scope */
267
+ scope?: InputMaybe<Scalars['String']>;
254
268
  };
255
269
  export declare enum IoRestorecommerceResourcebaseSortSortOrder {
256
270
  Unsorted = 0,
@@ -260,6 +274,8 @@ export declare enum IoRestorecommerceResourcebaseSortSortOrder {
260
274
  export declare type IIoRestorecommerceResourcebaseFilterOp = {
261
275
  filter?: InputMaybe<Array<IIoRestorecommerceResourcebaseFilter>>;
262
276
  operator?: InputMaybe<IoRestorecommerceResourcebaseFilterOpOperator>;
277
+ /** target scope */
278
+ scope?: InputMaybe<Scalars['String']>;
263
279
  };
264
280
  export declare type IIoRestorecommerceResourcebaseFilter = {
265
281
  field?: InputMaybe<Scalars['String']>;
@@ -267,6 +283,8 @@ export declare type IIoRestorecommerceResourcebaseFilter = {
267
283
  value?: InputMaybe<Scalars['String']>;
268
284
  type?: InputMaybe<IoRestorecommerceResourcebaseFilterValueType>;
269
285
  filters?: InputMaybe<Array<IIoRestorecommerceFilterFilterOp>>;
286
+ /** target scope */
287
+ scope?: InputMaybe<Scalars['String']>;
270
288
  };
271
289
  export declare enum IoRestorecommerceResourcebaseFilterOperation {
272
290
  Eq = 0,
@@ -289,6 +307,8 @@ export declare enum IoRestorecommerceResourcebaseFilterValueType {
289
307
  export declare type IIoRestorecommerceFilterFilterOp = {
290
308
  filter?: InputMaybe<Array<IIoRestorecommerceFilterFilter>>;
291
309
  operator?: InputMaybe<IoRestorecommerceFilterFilterOpOperator>;
310
+ /** target scope */
311
+ scope?: InputMaybe<Scalars['String']>;
292
312
  };
293
313
  export declare type IIoRestorecommerceFilterFilter = {
294
314
  field?: InputMaybe<Scalars['String']>;
@@ -296,6 +316,8 @@ export declare type IIoRestorecommerceFilterFilter = {
296
316
  value?: InputMaybe<Scalars['String']>;
297
317
  type?: InputMaybe<IoRestorecommerceFilterFilterValueType>;
298
318
  filters?: InputMaybe<Array<IIoRestorecommerceFilterFilterOp>>;
319
+ /** target scope */
320
+ scope?: InputMaybe<Scalars['String']>;
299
321
  };
300
322
  export declare enum IoRestorecommerceResourcebaseFilterOpOperator {
301
323
  And = 0,
@@ -304,6 +326,8 @@ export declare enum IoRestorecommerceResourcebaseFilterOpOperator {
304
326
  export declare type IIoRestorecommerceResourcebaseFieldFilter = {
305
327
  name?: InputMaybe<Scalars['String']>;
306
328
  include?: InputMaybe<Scalars['Boolean']>;
329
+ /** target scope */
330
+ scope?: InputMaybe<Scalars['String']>;
307
331
  };
308
332
  export declare type AccessControlRuleQuery = {
309
333
  __typename?: 'AccessControlRuleQuery';
@@ -396,6 +420,8 @@ export declare type IIoRestorecommercePolicyPolicyList = {
396
420
  items?: InputMaybe<Array<IIoRestorecommercePolicyPolicy>>;
397
421
  totalCount?: InputMaybe<Scalars['Int']>;
398
422
  mode?: InputMaybe<ModeType>;
423
+ /** target scope */
424
+ scope?: InputMaybe<Scalars['String']>;
399
425
  };
400
426
  export declare type IIoRestorecommercePolicyPolicy = {
401
427
  id?: InputMaybe<Scalars['String']>;
@@ -407,6 +433,8 @@ export declare type IIoRestorecommercePolicyPolicy = {
407
433
  effect?: InputMaybe<IoRestorecommerceRuleEffect>;
408
434
  combiningAlgorithm?: InputMaybe<Scalars['String']>;
409
435
  evaluationCacheable?: InputMaybe<Scalars['Boolean']>;
436
+ /** target scope */
437
+ scope?: InputMaybe<Scalars['String']>;
410
438
  };
411
439
  export declare type IIoRestorecommerceMetaMeta = {
412
440
  created?: InputMaybe<Scalars['Float']>;
@@ -414,9 +442,13 @@ export declare type IIoRestorecommerceMetaMeta = {
414
442
  modifiedBy?: InputMaybe<Scalars['String']>;
415
443
  owner?: InputMaybe<Array<IIoRestorecommerceAttributeAttribute>>;
416
444
  acl?: InputMaybe<Array<IIoRestorecommerceAttributeAttributeObj>>;
445
+ /** target scope */
446
+ scope?: InputMaybe<Scalars['String']>;
417
447
  };
418
448
  export declare type IIoRestorecommerceAttributeAttributeObj = {
419
449
  attribute?: InputMaybe<IIoRestorecommerceAttributeAttribute>;
450
+ /** target scope */
451
+ scope?: InputMaybe<Scalars['String']>;
420
452
  };
421
453
  export declare enum ModeType {
422
454
  Create = "CREATE",
@@ -435,6 +467,8 @@ export declare type IoRestorecommerceResourcebaseDeleteResponse = {
435
467
  export declare type IIoRestorecommerceResourcebaseDeleteRequest = {
436
468
  collection?: InputMaybe<Scalars['Boolean']>;
437
469
  ids?: InputMaybe<Array<Scalars['String']>>;
470
+ /** target scope */
471
+ scope?: InputMaybe<Scalars['String']>;
438
472
  };
439
473
  export declare type AccessControlRuleMutation = {
440
474
  __typename?: 'AccessControlRuleMutation';
@@ -451,6 +485,8 @@ export declare type IIoRestorecommerceRuleRuleList = {
451
485
  items?: InputMaybe<Array<IIoRestorecommerceRuleRule>>;
452
486
  totalCount?: InputMaybe<Scalars['Int']>;
453
487
  mode?: InputMaybe<ModeType>;
488
+ /** target scope */
489
+ scope?: InputMaybe<Scalars['String']>;
454
490
  };
455
491
  export declare type IIoRestorecommerceRuleRule = {
456
492
  id?: InputMaybe<Scalars['String']>;
@@ -462,10 +498,14 @@ export declare type IIoRestorecommerceRuleRule = {
462
498
  condition?: InputMaybe<Scalars['String']>;
463
499
  effect?: InputMaybe<IoRestorecommerceRuleEffect>;
464
500
  evaluationCacheable?: InputMaybe<Scalars['Boolean']>;
501
+ /** target scope */
502
+ scope?: InputMaybe<Scalars['String']>;
465
503
  };
466
504
  export declare type IIoRestorecommerceRuleContextQuery = {
467
505
  filters?: InputMaybe<Array<IIoRestorecommerceFilterFilterOp>>;
468
506
  query?: InputMaybe<Scalars['String']>;
507
+ /** target scope */
508
+ scope?: InputMaybe<Scalars['String']>;
469
509
  };
470
510
  export declare type AccessControlPolicySetMutation = {
471
511
  __typename?: 'AccessControlPolicySetMutation';
@@ -482,6 +522,8 @@ export declare type IIoRestorecommercePolicySetPolicySetList = {
482
522
  items?: InputMaybe<Array<IIoRestorecommercePolicySetPolicySet>>;
483
523
  totalCount?: InputMaybe<Scalars['Int']>;
484
524
  mode?: InputMaybe<ModeType>;
525
+ /** target scope */
526
+ scope?: InputMaybe<Scalars['String']>;
485
527
  };
486
528
  export declare type IIoRestorecommercePolicySetPolicySet = {
487
529
  id?: InputMaybe<Scalars['String']>;
@@ -491,6 +533,8 @@ export declare type IIoRestorecommercePolicySetPolicySet = {
491
533
  target?: InputMaybe<IIoRestorecommerceRuleTarget>;
492
534
  combiningAlgorithm?: InputMaybe<Scalars['String']>;
493
535
  policies?: InputMaybe<Array<Scalars['String']>>;
536
+ /** target scope */
537
+ scope?: InputMaybe<Scalars['String']>;
494
538
  };
495
539
  export declare type WithIndex<TObject> = TObject & Record<string, any>;
496
540
  export declare type ResolversObject<TObject> = WithIndex<TObject>;
@@ -162,10 +162,14 @@ export declare type IIoRestorecommerceResourcebaseReadRequest = {
162
162
  localesLimiter?: InputMaybe<Array<Scalars['String']>>;
163
163
  customQueries?: InputMaybe<Array<Scalars['String']>>;
164
164
  customArguments?: InputMaybe<IGoogleProtobufAny>;
165
+ /** target scope */
166
+ scope?: InputMaybe<Scalars['String']>;
165
167
  };
166
168
  export declare type IIoRestorecommerceResourcebaseSort = {
167
169
  field?: InputMaybe<Scalars['String']>;
168
170
  order?: InputMaybe<IoRestorecommerceResourcebaseSortSortOrder>;
171
+ /** target scope */
172
+ scope?: InputMaybe<Scalars['String']>;
169
173
  };
170
174
  export declare enum IoRestorecommerceResourcebaseSortSortOrder {
171
175
  Unsorted = 0,
@@ -175,6 +179,8 @@ export declare enum IoRestorecommerceResourcebaseSortSortOrder {
175
179
  export declare type IIoRestorecommerceResourcebaseFilterOp = {
176
180
  filter?: InputMaybe<Array<IIoRestorecommerceResourcebaseFilter>>;
177
181
  operator?: InputMaybe<IoRestorecommerceResourcebaseFilterOpOperator>;
182
+ /** target scope */
183
+ scope?: InputMaybe<Scalars['String']>;
178
184
  };
179
185
  export declare type IIoRestorecommerceResourcebaseFilter = {
180
186
  field?: InputMaybe<Scalars['String']>;
@@ -182,6 +188,8 @@ export declare type IIoRestorecommerceResourcebaseFilter = {
182
188
  value?: InputMaybe<Scalars['String']>;
183
189
  type?: InputMaybe<IoRestorecommerceResourcebaseFilterValueType>;
184
190
  filters?: InputMaybe<Array<IIoRestorecommerceFilterFilterOp>>;
191
+ /** target scope */
192
+ scope?: InputMaybe<Scalars['String']>;
185
193
  };
186
194
  export declare enum IoRestorecommerceResourcebaseFilterOperation {
187
195
  Eq = 0,
@@ -204,6 +212,8 @@ export declare enum IoRestorecommerceResourcebaseFilterValueType {
204
212
  export declare type IIoRestorecommerceFilterFilterOp = {
205
213
  filter?: InputMaybe<Array<IIoRestorecommerceFilterFilter>>;
206
214
  operator?: InputMaybe<IoRestorecommerceFilterFilterOpOperator>;
215
+ /** target scope */
216
+ scope?: InputMaybe<Scalars['String']>;
207
217
  };
208
218
  export declare type IIoRestorecommerceFilterFilter = {
209
219
  field?: InputMaybe<Scalars['String']>;
@@ -211,6 +221,8 @@ export declare type IIoRestorecommerceFilterFilter = {
211
221
  value?: InputMaybe<Scalars['String']>;
212
222
  type?: InputMaybe<IoRestorecommerceFilterFilterValueType>;
213
223
  filters?: InputMaybe<Array<IIoRestorecommerceFilterFilterOp>>;
224
+ /** target scope */
225
+ scope?: InputMaybe<Scalars['String']>;
214
226
  };
215
227
  export declare enum IoRestorecommerceFilterFilterOperation {
216
228
  Eq = 0,
@@ -241,10 +253,14 @@ export declare enum IoRestorecommerceResourcebaseFilterOpOperator {
241
253
  export declare type IIoRestorecommerceResourcebaseFieldFilter = {
242
254
  name?: InputMaybe<Scalars['String']>;
243
255
  include?: InputMaybe<Scalars['Boolean']>;
256
+ /** target scope */
257
+ scope?: InputMaybe<Scalars['String']>;
244
258
  };
245
259
  export declare type IGoogleProtobufAny = {
246
260
  typeUrl?: InputMaybe<Scalars['String']>;
247
261
  value?: InputMaybe<Scalars['Upload']>;
262
+ /** target scope */
263
+ scope?: InputMaybe<Scalars['String']>;
248
264
  };
249
265
  export declare type CatalogProductPrototypeQuery = {
250
266
  __typename?: 'CatalogProductPrototypeQuery';
@@ -398,6 +414,8 @@ export declare type IIoRestorecommerceProductProductList = {
398
414
  items?: InputMaybe<Array<IIoRestorecommerceProductMainProduct>>;
399
415
  totalCount?: InputMaybe<Scalars['Int']>;
400
416
  mode?: InputMaybe<ModeType>;
417
+ /** target scope */
418
+ scope?: InputMaybe<Scalars['String']>;
401
419
  };
402
420
  export declare type IIoRestorecommerceProductMainProduct = {
403
421
  id?: InputMaybe<Scalars['String']>;
@@ -405,6 +423,8 @@ export declare type IIoRestorecommerceProductMainProduct = {
405
423
  bundle?: InputMaybe<IIoRestorecommerceProductBundle>;
406
424
  active?: InputMaybe<Scalars['Boolean']>;
407
425
  meta?: InputMaybe<IIoRestorecommerceMetaMeta>;
426
+ /** target scope */
427
+ scope?: InputMaybe<Scalars['String']>;
408
428
  };
409
429
  export declare type IIoRestorecommerceProductProduct = {
410
430
  id?: InputMaybe<Scalars['String']>;
@@ -417,9 +437,13 @@ export declare type IIoRestorecommerceProductProduct = {
417
437
  taxId?: InputMaybe<Array<Scalars['String']>>;
418
438
  variants?: InputMaybe<Array<IIoRestorecommerceProductVariant>>;
419
439
  gtin?: InputMaybe<Scalars['String']>;
440
+ /** target scope */
441
+ scope?: InputMaybe<Scalars['String']>;
420
442
  };
421
443
  export declare type IIoRestorecommerceProductIdentifier = {
422
444
  id?: InputMaybe<Scalars['String']>;
445
+ /** target scope */
446
+ scope?: InputMaybe<Scalars['String']>;
423
447
  };
424
448
  export declare type IIoRestorecommerceProductVariant = {
425
449
  id?: InputMaybe<Scalars['String']>;
@@ -433,6 +457,8 @@ export declare type IIoRestorecommerceProductVariant = {
433
457
  stockKeepingUnit?: InputMaybe<Scalars['String']>;
434
458
  templateVariant?: InputMaybe<Scalars['String']>;
435
459
  attributes?: InputMaybe<Array<IIoRestorecommerceAttributeAttribute>>;
460
+ /** target scope */
461
+ scope?: InputMaybe<Scalars['String']>;
436
462
  };
437
463
  export declare type IIoRestorecommerceImageImage = {
438
464
  id?: InputMaybe<Scalars['String']>;
@@ -443,11 +469,15 @@ export declare type IIoRestorecommerceImageImage = {
443
469
  width?: InputMaybe<Scalars['Float']>;
444
470
  height?: InputMaybe<Scalars['Float']>;
445
471
  length?: InputMaybe<Scalars['Float']>;
472
+ /** target scope */
473
+ scope?: InputMaybe<Scalars['String']>;
446
474
  };
447
475
  export declare type IIoRestorecommerceAttributeAttribute = {
448
476
  id?: InputMaybe<Scalars['String']>;
449
477
  value?: InputMaybe<Scalars['String']>;
450
478
  attribute?: InputMaybe<Array<IIoRestorecommerceAttributeAttribute>>;
479
+ /** target scope */
480
+ scope?: InputMaybe<Scalars['String']>;
451
481
  };
452
482
  export declare type IIoRestorecommerceProductBundle = {
453
483
  id?: InputMaybe<Scalars['String']>;
@@ -456,10 +486,14 @@ export declare type IIoRestorecommerceProductBundle = {
456
486
  image?: InputMaybe<Array<IIoRestorecommerceImageImage>>;
457
487
  product?: InputMaybe<Array<IIoRestorecommerceProductBundleProduct>>;
458
488
  price?: InputMaybe<Scalars['Float']>;
489
+ /** target scope */
490
+ scope?: InputMaybe<Scalars['String']>;
459
491
  };
460
492
  export declare type IIoRestorecommerceProductBundleProduct = {
461
493
  productId?: InputMaybe<Scalars['String']>;
462
494
  quantity?: InputMaybe<Scalars['Int']>;
495
+ /** target scope */
496
+ scope?: InputMaybe<Scalars['String']>;
463
497
  };
464
498
  export declare type IIoRestorecommerceMetaMeta = {
465
499
  created?: InputMaybe<Scalars['Float']>;
@@ -467,9 +501,13 @@ export declare type IIoRestorecommerceMetaMeta = {
467
501
  modifiedBy?: InputMaybe<Scalars['String']>;
468
502
  owner?: InputMaybe<Array<IIoRestorecommerceAttributeAttribute>>;
469
503
  acl?: InputMaybe<Array<IIoRestorecommerceAttributeAttributeObj>>;
504
+ /** target scope */
505
+ scope?: InputMaybe<Scalars['String']>;
470
506
  };
471
507
  export declare type IIoRestorecommerceAttributeAttributeObj = {
472
508
  attribute?: InputMaybe<IIoRestorecommerceAttributeAttribute>;
509
+ /** target scope */
510
+ scope?: InputMaybe<Scalars['String']>;
473
511
  };
474
512
  export declare enum ModeType {
475
513
  Create = "CREATE",
@@ -488,6 +526,8 @@ export declare type IoRestorecommerceResourcebaseDeleteResponse = {
488
526
  export declare type IIoRestorecommerceResourcebaseDeleteRequest = {
489
527
  collection?: InputMaybe<Scalars['Boolean']>;
490
528
  ids?: InputMaybe<Array<Scalars['String']>>;
529
+ /** target scope */
530
+ scope?: InputMaybe<Scalars['String']>;
491
531
  };
492
532
  export declare type CatalogProductPrototypeMutation = {
493
533
  __typename?: 'CatalogProductPrototypeMutation';
@@ -504,6 +544,8 @@ export declare type IIoRestorecommerceProductPrototypeProductPrototypeList = {
504
544
  items?: InputMaybe<Array<IIoRestorecommerceProductPrototypeProductPrototype>>;
505
545
  totalCount?: InputMaybe<Scalars['Int']>;
506
546
  mode?: InputMaybe<ModeType>;
547
+ /** target scope */
548
+ scope?: InputMaybe<Scalars['String']>;
507
549
  };
508
550
  export declare type IIoRestorecommerceProductPrototypeProductPrototype = {
509
551
  id?: InputMaybe<Scalars['String']>;
@@ -512,6 +554,8 @@ export declare type IIoRestorecommerceProductPrototypeProductPrototype = {
512
554
  version?: InputMaybe<Scalars['String']>;
513
555
  description?: InputMaybe<Scalars['String']>;
514
556
  categoryId?: InputMaybe<Scalars['String']>;
557
+ /** target scope */
558
+ scope?: InputMaybe<Scalars['String']>;
515
559
  };
516
560
  export declare type CatalogProductCategoryMutation = {
517
561
  __typename?: 'CatalogProductCategoryMutation';
@@ -528,6 +572,8 @@ export declare type IIoRestorecommerceProductCategoryProductCategoryList = {
528
572
  items?: InputMaybe<Array<IIoRestorecommerceProductCategoryProductCategory>>;
529
573
  totalCount?: InputMaybe<Scalars['Int']>;
530
574
  mode?: InputMaybe<ModeType>;
575
+ /** target scope */
576
+ scope?: InputMaybe<Scalars['String']>;
531
577
  };
532
578
  export declare type IIoRestorecommerceProductCategoryProductCategory = {
533
579
  id?: InputMaybe<Scalars['String']>;
@@ -537,9 +583,13 @@ export declare type IIoRestorecommerceProductCategoryProductCategory = {
537
583
  priceGroupId?: InputMaybe<Scalars['String']>;
538
584
  image?: InputMaybe<IIoRestorecommerceImageImage>;
539
585
  parent?: InputMaybe<IIoRestorecommerceProductCategoryParent>;
586
+ /** target scope */
587
+ scope?: InputMaybe<Scalars['String']>;
540
588
  };
541
589
  export declare type IIoRestorecommerceProductCategoryParent = {
542
590
  parentId?: InputMaybe<Scalars['String']>;
591
+ /** target scope */
592
+ scope?: InputMaybe<Scalars['String']>;
543
593
  };
544
594
  export declare type CatalogPriceGroupMutation = {
545
595
  __typename?: 'CatalogPriceGroupMutation';
@@ -556,12 +606,16 @@ export declare type IIoRestorecommercePriceGroupPriceGroupList = {
556
606
  items?: InputMaybe<Array<IIoRestorecommercePriceGroupPriceGroup>>;
557
607
  totalCount?: InputMaybe<Scalars['Int']>;
558
608
  mode?: InputMaybe<ModeType>;
609
+ /** target scope */
610
+ scope?: InputMaybe<Scalars['String']>;
559
611
  };
560
612
  export declare type IIoRestorecommercePriceGroupPriceGroup = {
561
613
  id?: InputMaybe<Scalars['String']>;
562
614
  meta?: InputMaybe<IIoRestorecommerceMetaMeta>;
563
615
  name?: InputMaybe<Scalars['String']>;
564
616
  description?: InputMaybe<Scalars['String']>;
617
+ /** target scope */
618
+ scope?: InputMaybe<Scalars['String']>;
565
619
  };
566
620
  export declare type CatalogManufacturerMutation = {
567
621
  __typename?: 'CatalogManufacturerMutation';
@@ -578,12 +632,16 @@ export declare type IIoRestorecommerceManufacturerManufacturerList = {
578
632
  items?: InputMaybe<Array<IIoRestorecommerceManufacturerManufacturer>>;
579
633
  totalCount?: InputMaybe<Scalars['Int']>;
580
634
  mode?: InputMaybe<ModeType>;
635
+ /** target scope */
636
+ scope?: InputMaybe<Scalars['String']>;
581
637
  };
582
638
  export declare type IIoRestorecommerceManufacturerManufacturer = {
583
639
  id?: InputMaybe<Scalars['String']>;
584
640
  meta?: InputMaybe<IIoRestorecommerceMetaMeta>;
585
641
  name?: InputMaybe<Scalars['String']>;
586
642
  description?: InputMaybe<Scalars['String']>;
643
+ /** target scope */
644
+ scope?: InputMaybe<Scalars['String']>;
587
645
  };
588
646
  export declare type WithIndex<TObject> = TObject & Record<string, any>;
589
647
  export declare type ResolversObject<TObject> = WithIndex<TObject>;