@ampsec/platform-client 58.3.0 → 58.3.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.
@@ -14,7 +14,7 @@ export declare const _SimpleAssetDto: z.ZodObject<{
14
14
  }>;
15
15
  export type SimpleAssetDto = z.infer<typeof _SimpleAssetDto>;
16
16
  export declare const _AssetUpsertDto: z.ZodObject<{
17
- id: z.ZodOptional<z.ZodString>;
17
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
18
18
  etag: z.ZodString;
19
19
  extKeys: z.ZodObject<{
20
20
  extId: z.ZodOptional<z.ZodString>;
@@ -56,26 +56,11 @@ export declare const _AssetUpsertDto: z.ZodObject<{
56
56
  assetType?: GlobalAssetType | undefined;
57
57
  }>;
58
58
  export type AssetUpsertDto = z.infer<typeof _AssetUpsertDto>;
59
- export declare const _AssetDto: z.ZodIntersection<z.ZodObject<{
60
- id: z.ZodString;
59
+ export declare const _AssetDto: z.ZodObject<{
61
60
  createdAt: z.ZodString;
62
61
  updatedAt: z.ZodString;
63
62
  deletedAt: z.ZodNullable<z.ZodString>;
64
- etag: z.ZodString;
65
- }, "strip", z.ZodTypeAny, {
66
- id: string;
67
- createdAt: string;
68
- updatedAt: string;
69
- deletedAt: string | null;
70
- etag: string;
71
- }, {
72
- id: string;
73
- createdAt: string;
74
- updatedAt: string;
75
- deletedAt: string | null;
76
- etag: string;
77
- }>, z.ZodObject<{
78
- id: z.ZodOptional<z.ZodString>;
63
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
79
64
  etag: z.ZodString;
80
65
  extKeys: z.ZodObject<{
81
66
  extId: z.ZodOptional<z.ZodString>;
@@ -94,6 +79,9 @@ export declare const _AssetDto: z.ZodIntersection<z.ZodObject<{
94
79
  uid: z.ZodOptional<z.ZodString>;
95
80
  assetType: z.ZodOptional<z.ZodNativeEnum<typeof GlobalAssetType>>;
96
81
  }, "strip", z.ZodTypeAny, {
82
+ createdAt: string;
83
+ updatedAt: string;
84
+ deletedAt: string | null;
97
85
  etag: string;
98
86
  displayValue: string;
99
87
  extKeys: {
@@ -105,6 +93,9 @@ export declare const _AssetDto: z.ZodIntersection<z.ZodObject<{
105
93
  uid?: string | undefined;
106
94
  assetType?: GlobalAssetType | undefined;
107
95
  }, {
96
+ createdAt: string;
97
+ updatedAt: string;
98
+ deletedAt: string | null;
108
99
  etag: string;
109
100
  displayValue: string;
110
101
  extKeys: {
@@ -115,5 +106,5 @@ export declare const _AssetDto: z.ZodIntersection<z.ZodObject<{
115
106
  id?: string | undefined;
116
107
  uid?: string | undefined;
117
108
  assetType?: GlobalAssetType | undefined;
118
- }>>;
109
+ }>;
119
110
  export type AssetDto = z.infer<typeof _AssetDto>;
@@ -11,7 +11,7 @@ exports._SimpleAssetDto = zod_1.z.object({
11
11
  /** Human readable name of the asset */
12
12
  displayValue: zod_1.z.string().optional(),
13
13
  });
14
- exports._AssetUpsertDto = base_dto_1._ChangeAwareUpsertDto.extend({
14
+ exports._AssetUpsertDto = base_dto_1._ChangeAwareUpsertDto.merge(zod_1.z.object({
15
15
  /** External Keys */
16
16
  extKeys: assetKeys_1._AssetKeys,
17
17
  /** Asset display value */
@@ -20,6 +20,6 @@ exports._AssetUpsertDto = base_dto_1._ChangeAwareUpsertDto.extend({
20
20
  uid: zod_1.z.string().optional(),
21
21
  /** Asset type */
22
22
  assetType: zod_1.z.nativeEnum(globalAsset_type_1.GlobalAssetType).optional(),
23
- });
24
- exports._AssetDto = base_dto_1._ChangeAwareDto.and(exports._AssetUpsertDto);
23
+ }));
24
+ exports._AssetDto = base_dto_1._ChangeAwareDto.merge(exports._AssetUpsertDto);
25
25
  //# sourceMappingURL=assets.dto.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"assets.dto.js","sourceRoot":"","sources":["../../../src/dto/assets.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AACtB,2CAAuC;AACvC,yCAAkE;AAClE,+DAAyD;AAE5C,QAAA,eAAe,GAAG,OAAC,CAAC,MAAM,CAAC;IACtC,sBAAsB;IACtB,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACzB,uCAAuC;IACvC,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACpC,CAAC,CAAC;AAIU,QAAA,eAAe,GAAG,gCAAqB,CAAC,MAAM,CAAC;IAC1D,oBAAoB;IACpB,OAAO,EAAE,sBAAU;IACnB,0BAA0B;IAC1B,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE;IACxB,iCAAiC;IACjC,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC1B,iBAAiB;IACjB,SAAS,EAAE,OAAC,CAAC,UAAU,CAAC,kCAAe,CAAC,CAAC,QAAQ,EAAE;CACpD,CAAC,CAAC;AAIU,QAAA,SAAS,GAAG,0BAAe,CAAC,GAAG,CAAC,uBAAe,CAAC,CAAC"}
1
+ {"version":3,"file":"assets.dto.js","sourceRoot":"","sources":["../../../src/dto/assets.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AACtB,2CAAuC;AACvC,yCAAkE;AAClE,+DAAyD;AAE5C,QAAA,eAAe,GAAG,OAAC,CAAC,MAAM,CAAC;IACtC,sBAAsB;IACtB,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACzB,uCAAuC;IACvC,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACpC,CAAC,CAAC;AAIU,QAAA,eAAe,GAAG,gCAAqB,CAAC,KAAK,CACxD,OAAC,CAAC,MAAM,CAAC;IACP,oBAAoB;IACpB,OAAO,EAAE,sBAAU;IACnB,0BAA0B;IAC1B,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE;IACxB,iCAAiC;IACjC,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC1B,iBAAiB;IACjB,SAAS,EAAE,OAAC,CAAC,UAAU,CAAC,kCAAe,CAAC,CAAC,QAAQ,EAAE;CACpD,CAAC,CACH,CAAC;AAIW,QAAA,SAAS,GAAG,0BAAe,CAAC,KAAK,CAAC,uBAAe,CAAC,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { z } from 'zod';
2
2
  export declare const _BaseUpsertDto: z.ZodObject<{
3
- id: z.ZodOptional<z.ZodString>;
3
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
4
4
  }, "strip", z.ZodTypeAny, {
5
5
  id?: string | undefined;
6
6
  }, {
@@ -8,24 +8,24 @@ export declare const _BaseUpsertDto: z.ZodObject<{
8
8
  }>;
9
9
  export type BaseUpsertDto = z.infer<typeof _BaseUpsertDto>;
10
10
  export declare const _BaseDto: z.ZodObject<{
11
- id: z.ZodString;
11
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
12
12
  createdAt: z.ZodString;
13
13
  updatedAt: z.ZodString;
14
14
  deletedAt: z.ZodNullable<z.ZodString>;
15
15
  }, "strip", z.ZodTypeAny, {
16
- id: string;
17
16
  createdAt: string;
18
17
  updatedAt: string;
19
18
  deletedAt: string | null;
19
+ id?: string | undefined;
20
20
  }, {
21
- id: string;
22
21
  createdAt: string;
23
22
  updatedAt: string;
24
23
  deletedAt: string | null;
24
+ id?: string | undefined;
25
25
  }>;
26
26
  export type BaseDto = z.infer<typeof _BaseDto>;
27
27
  export declare const _ChangeAwareUpsertDto: z.ZodObject<{
28
- id: z.ZodOptional<z.ZodString>;
28
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
29
29
  etag: z.ZodString;
30
30
  }, "strip", z.ZodTypeAny, {
31
31
  etag: string;
@@ -36,22 +36,22 @@ export declare const _ChangeAwareUpsertDto: z.ZodObject<{
36
36
  }>;
37
37
  export type ChangeAwareUpsertDto = z.infer<typeof _ChangeAwareUpsertDto>;
38
38
  export declare const _ChangeAwareDto: z.ZodObject<{
39
- id: z.ZodString;
39
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
40
40
  createdAt: z.ZodString;
41
41
  updatedAt: z.ZodString;
42
42
  deletedAt: z.ZodNullable<z.ZodString>;
43
43
  etag: z.ZodString;
44
44
  }, "strip", z.ZodTypeAny, {
45
- id: string;
46
45
  createdAt: string;
47
46
  updatedAt: string;
48
47
  deletedAt: string | null;
49
48
  etag: string;
49
+ id?: string | undefined;
50
50
  }, {
51
- id: string;
52
51
  createdAt: string;
53
52
  updatedAt: string;
54
53
  deletedAt: string | null;
55
54
  etag: string;
55
+ id?: string | undefined;
56
56
  }>;
57
57
  export type ChangeAwareDto = z.infer<typeof _ChangeAwareDto>;
@@ -3,15 +3,15 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports._ChangeAwareDto = exports._ChangeAwareUpsertDto = exports._BaseDto = exports._BaseUpsertDto = void 0;
4
4
  const zod_1 = require("zod");
5
5
  exports._BaseUpsertDto = zod_1.z.object({
6
- id: zod_1.z.string().optional(),
6
+ id: zod_1.z.union([zod_1.z.string(), zod_1.z.undefined()]).optional(),
7
7
  });
8
8
  exports._BaseDto = zod_1.z.object({
9
- id: zod_1.z.string(),
9
+ id: zod_1.z.union([zod_1.z.string(), zod_1.z.undefined()]).optional(),
10
10
  createdAt: zod_1.z.string(),
11
11
  updatedAt: zod_1.z.string(),
12
12
  deletedAt: zod_1.z.string().nullable(),
13
13
  });
14
- const WithEtag = { etag: zod_1.z.string() };
15
- exports._ChangeAwareUpsertDto = exports._BaseUpsertDto.extend(WithEtag);
16
- exports._ChangeAwareDto = exports._BaseDto.extend(WithEtag);
14
+ const WithEtag = zod_1.z.object({ etag: zod_1.z.string() });
15
+ exports._ChangeAwareUpsertDto = exports._BaseUpsertDto.merge(WithEtag);
16
+ exports._ChangeAwareDto = exports._BaseDto.merge(WithEtag);
17
17
  //# sourceMappingURL=base.dto.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"base.dto.js","sourceRoot":"","sources":["../../../src/dto/base.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AAET,QAAA,cAAc,GAAG,OAAC,CAAC,MAAM,CAAC;IACrC,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC1B,CAAC,CAAC;AAIU,QAAA,QAAQ,GAAG,OAAC,CAAC,MAAM,CAAC;IAC/B,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE;IACd,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;IACrB,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;IACrB,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACjC,CAAC,CAAC;AAIH,MAAM,QAAQ,GAAG,EAAC,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE,EAAC,CAAC;AAEvB,QAAA,qBAAqB,GAAG,sBAAc,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;AAIxD,QAAA,eAAe,GAAG,gBAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC"}
1
+ {"version":3,"file":"base.dto.js","sourceRoot":"","sources":["../../../src/dto/base.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AAET,QAAA,cAAc,GAAG,OAAC,CAAC,MAAM,CAAC;IACrC,EAAE,EAAE,OAAC,CAAC,KAAK,CAAC,CAAC,OAAC,CAAC,MAAM,EAAE,EAAE,OAAC,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,QAAQ,EAAE;CACpD,CAAC,CAAC;AAIU,QAAA,QAAQ,GAAG,OAAC,CAAC,MAAM,CAAC;IAC/B,EAAE,EAAE,OAAC,CAAC,KAAK,CAAC,CAAC,OAAC,CAAC,MAAM,EAAE,EAAE,OAAC,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,QAAQ,EAAE;IACnD,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;IACrB,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;IACrB,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACjC,CAAC,CAAC;AAIH,MAAM,QAAQ,GAAG,OAAC,CAAC,MAAM,CAAC,EAAC,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE,EAAC,CAAC,CAAC;AAEjC,QAAA,qBAAqB,GAAG,sBAAc,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;AAIvD,QAAA,eAAe,GAAG,gBAAQ,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC"}
@@ -39,26 +39,11 @@ export declare const _UserCoverageReport: z.ZodObject<{
39
39
  score: z.ZodOptional<z.ZodNumber>;
40
40
  firstName: z.ZodOptional<z.ZodString>;
41
41
  lastName: z.ZodOptional<z.ZodString>;
42
- userAccounts: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodIntersection<z.ZodObject<{
43
- id: z.ZodString;
42
+ userAccounts: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
44
43
  createdAt: z.ZodString;
45
44
  updatedAt: z.ZodString;
46
45
  deletedAt: z.ZodNullable<z.ZodString>;
47
- etag: z.ZodString;
48
- }, "strip", z.ZodTypeAny, {
49
- id: string;
50
- createdAt: string;
51
- updatedAt: string;
52
- deletedAt: string | null;
53
- etag: string;
54
- }, {
55
- id: string;
56
- createdAt: string;
57
- updatedAt: string;
58
- deletedAt: string | null;
59
- etag: string;
60
- }>, z.ZodObject<{
61
- id: z.ZodOptional<z.ZodString>;
46
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
62
47
  etag: z.ZodString;
63
48
  uid: z.ZodString;
64
49
  cid: z.ZodString;
@@ -68,6 +53,9 @@ export declare const _UserCoverageReport: z.ZodObject<{
68
53
  }, "strip", z.ZodTypeAny, {
69
54
  cid: string;
70
55
  uid: string;
56
+ createdAt: string;
57
+ updatedAt: string;
58
+ deletedAt: string | null;
71
59
  email: string;
72
60
  etag: string;
73
61
  extId: string;
@@ -76,75 +64,77 @@ export declare const _UserCoverageReport: z.ZodObject<{
76
64
  }, {
77
65
  cid: string;
78
66
  uid: string;
67
+ createdAt: string;
68
+ updatedAt: string;
69
+ deletedAt: string | null;
79
70
  email: string;
80
71
  etag: string;
81
72
  extId: string;
82
73
  id?: string | undefined;
83
74
  meta?: unknown;
84
- }>>, "many">>;
85
- assetAccounts: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodIntersection<z.ZodObject<{
86
- id: z.ZodString;
75
+ }>, "many">>;
76
+ assetAccounts: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
87
77
  createdAt: z.ZodString;
88
78
  updatedAt: z.ZodString;
89
79
  deletedAt: z.ZodNullable<z.ZodString>;
80
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
90
81
  etag: z.ZodString;
91
- }, "strip", z.ZodTypeAny, {
92
- id: string;
93
- createdAt: string;
94
- updatedAt: string;
95
- deletedAt: string | null;
96
- etag: string;
97
- }, {
98
- id: string;
99
- createdAt: string;
100
- updatedAt: string;
101
- deletedAt: string | null;
102
- etag: string;
103
- }>, z.ZodObject<{
104
- id: z.ZodOptional<z.ZodString>;
105
- etag: z.ZodString;
106
- uid: z.ZodString;
82
+ extKeys: z.ZodObject<{
83
+ extId: z.ZodOptional<z.ZodString>;
84
+ sn: z.ZodOptional<z.ZodString>;
85
+ macs: z.ZodArray<z.ZodString, "many">;
86
+ }, "strip", z.ZodTypeAny, {
87
+ macs: string[];
88
+ extId?: string | undefined;
89
+ sn?: string | undefined;
90
+ }, {
91
+ macs: string[];
92
+ extId?: string | undefined;
93
+ sn?: string | undefined;
94
+ }>;
107
95
  cid: z.ZodString;
108
- email: z.ZodString;
109
- extId: z.ZodString;
96
+ aid: z.ZodString;
97
+ uid: z.ZodOptional<z.ZodString>;
98
+ displayValue: z.ZodString;
110
99
  meta: z.ZodUnknown;
111
100
  }, "strip", z.ZodTypeAny, {
112
101
  cid: string;
113
- uid: string;
114
- email: string;
102
+ aid: string;
103
+ createdAt: string;
104
+ updatedAt: string;
105
+ deletedAt: string | null;
115
106
  etag: string;
116
- extId: string;
107
+ displayValue: string;
108
+ extKeys: {
109
+ macs: string[];
110
+ extId?: string | undefined;
111
+ sn?: string | undefined;
112
+ };
117
113
  id?: string | undefined;
114
+ uid?: string | undefined;
118
115
  meta?: unknown;
119
116
  }, {
120
117
  cid: string;
121
- uid: string;
122
- email: string;
118
+ aid: string;
119
+ createdAt: string;
120
+ updatedAt: string;
121
+ deletedAt: string | null;
123
122
  etag: string;
124
- extId: string;
123
+ displayValue: string;
124
+ extKeys: {
125
+ macs: string[];
126
+ extId?: string | undefined;
127
+ sn?: string | undefined;
128
+ };
125
129
  id?: string | undefined;
130
+ uid?: string | undefined;
126
131
  meta?: unknown;
127
- }>>, "many">>;
128
- assets: z.ZodArray<z.ZodIntersection<z.ZodObject<{
129
- id: z.ZodString;
132
+ }>, "many">>;
133
+ assets: z.ZodArray<z.ZodObject<{
130
134
  createdAt: z.ZodString;
131
135
  updatedAt: z.ZodString;
132
136
  deletedAt: z.ZodNullable<z.ZodString>;
133
- etag: z.ZodString;
134
- }, "strip", z.ZodTypeAny, {
135
- id: string;
136
- createdAt: string;
137
- updatedAt: string;
138
- deletedAt: string | null;
139
- etag: string;
140
- }, {
141
- id: string;
142
- createdAt: string;
143
- updatedAt: string;
144
- deletedAt: string | null;
145
- etag: string;
146
- }>, z.ZodObject<{
147
- id: z.ZodOptional<z.ZodString>;
137
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
148
138
  etag: z.ZodString;
149
139
  extKeys: z.ZodObject<{
150
140
  extId: z.ZodOptional<z.ZodString>;
@@ -163,6 +153,9 @@ export declare const _UserCoverageReport: z.ZodObject<{
163
153
  uid: z.ZodOptional<z.ZodString>;
164
154
  assetType: z.ZodOptional<z.ZodNativeEnum<typeof import("./enums").GlobalAssetType>>;
165
155
  }, "strip", z.ZodTypeAny, {
156
+ createdAt: string;
157
+ updatedAt: string;
158
+ deletedAt: string | null;
166
159
  etag: string;
167
160
  displayValue: string;
168
161
  extKeys: {
@@ -174,6 +167,9 @@ export declare const _UserCoverageReport: z.ZodObject<{
174
167
  uid?: string | undefined;
175
168
  assetType?: import("./enums").GlobalAssetType | undefined;
176
169
  }, {
170
+ createdAt: string;
171
+ updatedAt: string;
172
+ deletedAt: string | null;
177
173
  etag: string;
178
174
  displayValue: string;
179
175
  extKeys: {
@@ -184,46 +180,42 @@ export declare const _UserCoverageReport: z.ZodObject<{
184
180
  id?: string | undefined;
185
181
  uid?: string | undefined;
186
182
  assetType?: import("./enums").GlobalAssetType | undefined;
187
- }>>, "many">;
183
+ }>, "many">;
188
184
  }, "strip", z.ZodTypeAny, {
189
- userAccounts: Record<string, ({
190
- id: string;
185
+ userAccounts: Record<string, {
186
+ cid: string;
187
+ uid: string;
191
188
  createdAt: string;
192
189
  updatedAt: string;
193
190
  deletedAt: string | null;
194
- etag: string;
195
- } & {
196
- cid: string;
197
- uid: string;
198
191
  email: string;
199
192
  etag: string;
200
193
  extId: string;
201
194
  id?: string | undefined;
202
195
  meta?: unknown;
203
- })[]>;
204
- assetAccounts: Record<string, ({
205
- id: string;
196
+ }[]>;
197
+ assetAccounts: Record<string, {
198
+ cid: string;
199
+ aid: string;
206
200
  createdAt: string;
207
201
  updatedAt: string;
208
202
  deletedAt: string | null;
209
203
  etag: string;
210
- } & {
211
- cid: string;
212
- uid: string;
213
- email: string;
214
- etag: string;
215
- extId: string;
204
+ displayValue: string;
205
+ extKeys: {
206
+ macs: string[];
207
+ extId?: string | undefined;
208
+ sn?: string | undefined;
209
+ };
216
210
  id?: string | undefined;
211
+ uid?: string | undefined;
217
212
  meta?: unknown;
218
- })[]>;
219
- assets: ({
220
- id: string;
213
+ }[]>;
214
+ assets: {
221
215
  createdAt: string;
222
216
  updatedAt: string;
223
217
  deletedAt: string | null;
224
218
  etag: string;
225
- } & {
226
- etag: string;
227
219
  displayValue: string;
228
220
  extKeys: {
229
221
  macs: string[];
@@ -233,7 +225,7 @@ export declare const _UserCoverageReport: z.ZodObject<{
233
225
  id?: string | undefined;
234
226
  uid?: string | undefined;
235
227
  assetType?: import("./enums").GlobalAssetType | undefined;
236
- })[];
228
+ }[];
237
229
  id?: string | undefined;
238
230
  organization?: string | undefined;
239
231
  department?: string | undefined;
@@ -242,44 +234,40 @@ export declare const _UserCoverageReport: z.ZodObject<{
242
234
  firstName?: string | undefined;
243
235
  lastName?: string | undefined;
244
236
  }, {
245
- userAccounts: Record<string, ({
246
- id: string;
237
+ userAccounts: Record<string, {
238
+ cid: string;
239
+ uid: string;
247
240
  createdAt: string;
248
241
  updatedAt: string;
249
242
  deletedAt: string | null;
250
- etag: string;
251
- } & {
252
- cid: string;
253
- uid: string;
254
243
  email: string;
255
244
  etag: string;
256
245
  extId: string;
257
246
  id?: string | undefined;
258
247
  meta?: unknown;
259
- })[]>;
260
- assetAccounts: Record<string, ({
261
- id: string;
248
+ }[]>;
249
+ assetAccounts: Record<string, {
250
+ cid: string;
251
+ aid: string;
262
252
  createdAt: string;
263
253
  updatedAt: string;
264
254
  deletedAt: string | null;
265
255
  etag: string;
266
- } & {
267
- cid: string;
268
- uid: string;
269
- email: string;
270
- etag: string;
271
- extId: string;
256
+ displayValue: string;
257
+ extKeys: {
258
+ macs: string[];
259
+ extId?: string | undefined;
260
+ sn?: string | undefined;
261
+ };
272
262
  id?: string | undefined;
263
+ uid?: string | undefined;
273
264
  meta?: unknown;
274
- })[]>;
275
- assets: ({
276
- id: string;
265
+ }[]>;
266
+ assets: {
277
267
  createdAt: string;
278
268
  updatedAt: string;
279
269
  deletedAt: string | null;
280
270
  etag: string;
281
- } & {
282
- etag: string;
283
271
  displayValue: string;
284
272
  extKeys: {
285
273
  macs: string[];
@@ -289,7 +277,7 @@ export declare const _UserCoverageReport: z.ZodObject<{
289
277
  id?: string | undefined;
290
278
  uid?: string | undefined;
291
279
  assetType?: import("./enums").GlobalAssetType | undefined;
292
- })[];
280
+ }[];
293
281
  id?: string | undefined;
294
282
  organization?: string | undefined;
295
283
  department?: string | undefined;
@@ -6,13 +6,13 @@ const assets_dto_1 = require("./assets.dto");
6
6
  const saasAssets_dto_1 = require("./saasAssets.dto");
7
7
  const saasUsers_dto_1 = require("./saasUsers.dto");
8
8
  const users_dto_1 = require("./users.dto");
9
- exports._UserCoverageSummary = users_dto_1._SimpleUserDto.extend({
9
+ exports._UserCoverageSummary = users_dto_1._SimpleUserDto.merge(zod_1.z.object({
10
10
  userAccounts: zod_1.z.record(zod_1.z.number()),
11
11
  assetAccounts: zod_1.z.record(zod_1.z.number()),
12
- });
13
- exports._UserCoverageReport = users_dto_1._SimpleUserDto.extend({
12
+ }));
13
+ exports._UserCoverageReport = users_dto_1._SimpleUserDto.merge(zod_1.z.object({
14
14
  userAccounts: zod_1.z.record(zod_1.z.array(saasUsers_dto_1._SaasUserDto)),
15
15
  assetAccounts: zod_1.z.record(zod_1.z.array(saasAssets_dto_1._SaasAssetDto)),
16
16
  assets: zod_1.z.array(assets_dto_1._AssetDto),
17
- });
17
+ }));
18
18
  //# sourceMappingURL=coverage.dto.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"coverage.dto.js","sourceRoot":"","sources":["../../../src/dto/coverage.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AACtB,6CAAuC;AACvC,qDAA+C;AAC/C,mDAA6C;AAC7C,2CAA2C;AAE9B,QAAA,oBAAoB,GAAG,0BAAc,CAAC,MAAM,CAAC;IACxD,YAAY,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC;IAClC,aAAa,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC;CACpC,CAAC,CAAC;AAIU,QAAA,mBAAmB,GAAG,0BAAc,CAAC,MAAM,CAAC;IACvD,YAAY,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,KAAK,CAAC,4BAAY,CAAC,CAAC;IAC7C,aAAa,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,KAAK,CAAC,8BAAa,CAAC,CAAC;IAC/C,MAAM,EAAE,OAAC,CAAC,KAAK,CAAC,sBAAS,CAAC;CAC3B,CAAC,CAAC"}
1
+ {"version":3,"file":"coverage.dto.js","sourceRoot":"","sources":["../../../src/dto/coverage.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AACtB,6CAAuC;AACvC,qDAA+C;AAC/C,mDAA6C;AAC7C,2CAA2C;AAE9B,QAAA,oBAAoB,GAAG,0BAAc,CAAC,KAAK,CACtD,OAAC,CAAC,MAAM,CAAC;IACP,YAAY,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC;IAClC,aAAa,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC;CACpC,CAAC,CACH,CAAC;AAIW,QAAA,mBAAmB,GAAG,0BAAc,CAAC,KAAK,CACrD,OAAC,CAAC,MAAM,CAAC;IACP,YAAY,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,KAAK,CAAC,4BAAY,CAAC,CAAC;IAC7C,aAAa,EAAE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,KAAK,CAAC,8BAAa,CAAC,CAAC;IAC/C,MAAM,EAAE,OAAC,CAAC,KAAK,CAAC,sBAAS,CAAC;CAC3B,CAAC,CACH,CAAC"}
@@ -1,7 +1,6 @@
1
1
  import { z } from 'zod';
2
- import { _SaasUserDto } from './saasUsers.dto';
3
2
  export declare const _SaasAssetUpsertDto: z.ZodObject<{
4
- id: z.ZodOptional<z.ZodString>;
3
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
5
4
  etag: z.ZodString;
6
5
  extKeys: z.ZodObject<{
7
6
  extId: z.ZodOptional<z.ZodString>;
@@ -49,47 +48,61 @@ export declare const _SaasAssetUpsertDto: z.ZodObject<{
49
48
  meta?: unknown;
50
49
  }>;
51
50
  export type SaasAssetUpsertDto = z.infer<typeof _SaasAssetUpsertDto>;
52
- export declare const _SaasAssetDto: z.ZodIntersection<z.ZodObject<{
53
- id: z.ZodString;
51
+ export declare const _SaasAssetDto: z.ZodObject<{
54
52
  createdAt: z.ZodString;
55
53
  updatedAt: z.ZodString;
56
54
  deletedAt: z.ZodNullable<z.ZodString>;
55
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
57
56
  etag: z.ZodString;
58
- }, "strip", z.ZodTypeAny, {
59
- id: string;
60
- createdAt: string;
61
- updatedAt: string;
62
- deletedAt: string | null;
63
- etag: string;
64
- }, {
65
- id: string;
66
- createdAt: string;
67
- updatedAt: string;
68
- deletedAt: string | null;
69
- etag: string;
70
- }>, z.ZodObject<{
71
- id: z.ZodOptional<z.ZodString>;
72
- etag: z.ZodString;
73
- uid: z.ZodString;
57
+ extKeys: z.ZodObject<{
58
+ extId: z.ZodOptional<z.ZodString>;
59
+ sn: z.ZodOptional<z.ZodString>;
60
+ macs: z.ZodArray<z.ZodString, "many">;
61
+ }, "strip", z.ZodTypeAny, {
62
+ macs: string[];
63
+ extId?: string | undefined;
64
+ sn?: string | undefined;
65
+ }, {
66
+ macs: string[];
67
+ extId?: string | undefined;
68
+ sn?: string | undefined;
69
+ }>;
74
70
  cid: z.ZodString;
75
- email: z.ZodString;
76
- extId: z.ZodString;
71
+ aid: z.ZodString;
72
+ uid: z.ZodOptional<z.ZodString>;
73
+ displayValue: z.ZodString;
77
74
  meta: z.ZodUnknown;
78
75
  }, "strip", z.ZodTypeAny, {
79
76
  cid: string;
80
- uid: string;
81
- email: string;
77
+ aid: string;
78
+ createdAt: string;
79
+ updatedAt: string;
80
+ deletedAt: string | null;
82
81
  etag: string;
83
- extId: string;
82
+ displayValue: string;
83
+ extKeys: {
84
+ macs: string[];
85
+ extId?: string | undefined;
86
+ sn?: string | undefined;
87
+ };
84
88
  id?: string | undefined;
89
+ uid?: string | undefined;
85
90
  meta?: unknown;
86
91
  }, {
87
92
  cid: string;
88
- uid: string;
89
- email: string;
93
+ aid: string;
94
+ createdAt: string;
95
+ updatedAt: string;
96
+ deletedAt: string | null;
90
97
  etag: string;
91
- extId: string;
98
+ displayValue: string;
99
+ extKeys: {
100
+ macs: string[];
101
+ extId?: string | undefined;
102
+ sn?: string | undefined;
103
+ };
92
104
  id?: string | undefined;
105
+ uid?: string | undefined;
93
106
  meta?: unknown;
94
- }>>;
95
- export type SaasAssetDto = z.infer<typeof _SaasUserDto>;
107
+ }>;
108
+ export type SaasAssetDto = z.infer<typeof _SaasAssetDto>;
@@ -4,8 +4,7 @@ exports._SaasAssetDto = exports._SaasAssetUpsertDto = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const assetKeys_1 = require("./assetKeys");
6
6
  const base_dto_1 = require("./base.dto");
7
- const saasUsers_dto_1 = require("./saasUsers.dto");
8
- exports._SaasAssetUpsertDto = base_dto_1._ChangeAwareUpsertDto.extend({
7
+ exports._SaasAssetUpsertDto = base_dto_1._ChangeAwareUpsertDto.merge(zod_1.z.object({
9
8
  /** External Ids */
10
9
  extKeys: assetKeys_1._AssetKeys,
11
10
  /** Connector Id */
@@ -18,6 +17,6 @@ exports._SaasAssetUpsertDto = base_dto_1._ChangeAwareUpsertDto.extend({
18
17
  displayValue: zod_1.z.string(),
19
18
  /** Information specific to this asset */
20
19
  meta: zod_1.z.unknown(),
21
- });
22
- exports._SaasAssetDto = base_dto_1._ChangeAwareDto.and(saasUsers_dto_1._SaasUserUpsertDto);
20
+ }));
21
+ exports._SaasAssetDto = base_dto_1._ChangeAwareDto.merge(exports._SaasAssetUpsertDto);
23
22
  //# sourceMappingURL=saasAssets.dto.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"saasAssets.dto.js","sourceRoot":"","sources":["../../../src/dto/saasAssets.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AACtB,2CAAuC;AACvC,yCAAkE;AAClE,mDAAiE;AAEpD,QAAA,mBAAmB,GAAG,gCAAqB,CAAC,MAAM,CAAC;IAC9D,mBAAmB;IACnB,OAAO,EAAE,sBAAU;IACnB,mBAAmB;IACnB,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,eAAe;IACf,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,cAAc;IACd,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC1B,0BAA0B;IAC1B,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE;IACxB,yCAAyC;IACzC,IAAI,EAAE,OAAC,CAAC,OAAO,EAAE;CAClB,CAAC,CAAC;AAIU,QAAA,aAAa,GAAG,0BAAe,CAAC,GAAG,CAAC,kCAAkB,CAAC,CAAC"}
1
+ {"version":3,"file":"saasAssets.dto.js","sourceRoot":"","sources":["../../../src/dto/saasAssets.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AACtB,2CAAuC;AACvC,yCAAkE;AAErD,QAAA,mBAAmB,GAAG,gCAAqB,CAAC,KAAK,CAC5D,OAAC,CAAC,MAAM,CAAC;IACP,mBAAmB;IACnB,OAAO,EAAE,sBAAU;IACnB,mBAAmB;IACnB,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,eAAe;IACf,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,cAAc;IACd,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC1B,0BAA0B;IAC1B,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE;IACxB,yCAAyC;IACzC,IAAI,EAAE,OAAC,CAAC,OAAO,EAAE;CAClB,CAAC,CACH,CAAC;AAIW,QAAA,aAAa,GAAG,0BAAe,CAAC,KAAK,CAAC,2BAAmB,CAAC,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { z } from 'zod';
2
2
  export declare const _SaasUserUpsertDto: z.ZodObject<{
3
- id: z.ZodOptional<z.ZodString>;
3
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
4
4
  etag: z.ZodString;
5
5
  uid: z.ZodString;
6
6
  cid: z.ZodString;
@@ -25,26 +25,11 @@ export declare const _SaasUserUpsertDto: z.ZodObject<{
25
25
  meta?: unknown;
26
26
  }>;
27
27
  export type SaasUserUpsertDto = z.infer<typeof _SaasUserUpsertDto>;
28
- export declare const _SaasUserDto: z.ZodIntersection<z.ZodObject<{
29
- id: z.ZodString;
28
+ export declare const _SaasUserDto: z.ZodObject<{
30
29
  createdAt: z.ZodString;
31
30
  updatedAt: z.ZodString;
32
31
  deletedAt: z.ZodNullable<z.ZodString>;
33
- etag: z.ZodString;
34
- }, "strip", z.ZodTypeAny, {
35
- id: string;
36
- createdAt: string;
37
- updatedAt: string;
38
- deletedAt: string | null;
39
- etag: string;
40
- }, {
41
- id: string;
42
- createdAt: string;
43
- updatedAt: string;
44
- deletedAt: string | null;
45
- etag: string;
46
- }>, z.ZodObject<{
47
- id: z.ZodOptional<z.ZodString>;
32
+ id: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodUndefined]>>;
48
33
  etag: z.ZodString;
49
34
  uid: z.ZodString;
50
35
  cid: z.ZodString;
@@ -54,6 +39,9 @@ export declare const _SaasUserDto: z.ZodIntersection<z.ZodObject<{
54
39
  }, "strip", z.ZodTypeAny, {
55
40
  cid: string;
56
41
  uid: string;
42
+ createdAt: string;
43
+ updatedAt: string;
44
+ deletedAt: string | null;
57
45
  email: string;
58
46
  etag: string;
59
47
  extId: string;
@@ -62,10 +50,13 @@ export declare const _SaasUserDto: z.ZodIntersection<z.ZodObject<{
62
50
  }, {
63
51
  cid: string;
64
52
  uid: string;
53
+ createdAt: string;
54
+ updatedAt: string;
55
+ deletedAt: string | null;
65
56
  email: string;
66
57
  etag: string;
67
58
  extId: string;
68
59
  id?: string | undefined;
69
60
  meta?: unknown;
70
- }>>;
61
+ }>;
71
62
  export type SaasUserDto = z.infer<typeof _SaasUserDto>;
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports._SaasUserDto = exports._SaasUserUpsertDto = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const base_dto_1 = require("./base.dto");
6
- exports._SaasUserUpsertDto = base_dto_1._ChangeAwareUpsertDto.extend({
6
+ exports._SaasUserUpsertDto = base_dto_1._ChangeAwareUpsertDto.merge(zod_1.z.object({
7
7
  /** User Id */
8
8
  uid: zod_1.z.string(),
9
9
  /** Connector Id */
@@ -14,6 +14,6 @@ exports._SaasUserUpsertDto = base_dto_1._ChangeAwareUpsertDto.extend({
14
14
  extId: zod_1.z.string(),
15
15
  /** Additional information specific to this Saas User */
16
16
  meta: zod_1.z.unknown(),
17
- });
18
- exports._SaasUserDto = base_dto_1._ChangeAwareDto.and(exports._SaasUserUpsertDto);
17
+ }));
18
+ exports._SaasUserDto = base_dto_1._ChangeAwareDto.merge(exports._SaasUserUpsertDto);
19
19
  //# sourceMappingURL=saasUsers.dto.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"saasUsers.dto.js","sourceRoot":"","sources":["../../../src/dto/saasUsers.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AACtB,yCAAkE;AAErD,QAAA,kBAAkB,GAAG,gCAAqB,CAAC,MAAM,CAAC;IAC7D,cAAc;IACd,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,mBAAmB;IACnB,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,qBAAqB;IACrB,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;IACjB,kBAAkB;IAClB,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;IACjB,wDAAwD;IACxD,IAAI,EAAE,OAAC,CAAC,OAAO,EAAE;CAClB,CAAC,CAAC;AAIU,QAAA,YAAY,GAAG,0BAAe,CAAC,GAAG,CAAC,0BAAkB,CAAC,CAAC"}
1
+ {"version":3,"file":"saasUsers.dto.js","sourceRoot":"","sources":["../../../src/dto/saasUsers.dto.ts"],"names":[],"mappings":";;;AAAA,6BAAsB;AACtB,yCAAkE;AAErD,QAAA,kBAAkB,GAAG,gCAAqB,CAAC,KAAK,CAC3D,OAAC,CAAC,MAAM,CAAC;IACP,cAAc;IACd,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,mBAAmB;IACnB,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,qBAAqB;IACrB,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;IACjB,kBAAkB;IAClB,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;IACjB,wDAAwD;IACxD,IAAI,EAAE,OAAC,CAAC,OAAO,EAAE;CAClB,CAAC,CACH,CAAC;AAIW,QAAA,YAAY,GAAG,0BAAe,CAAC,KAAK,CAAC,0BAAkB,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ampsec/platform-client",
3
- "version": "58.3.0",
3
+ "version": "58.3.1",
4
4
  "description": "",
5
5
  "main": "build/src/index.js",
6
6
  "runkitExampleFilename": "example/main.js",
@@ -12,19 +12,21 @@ export const _SimpleAssetDto = z.object({
12
12
 
13
13
  export type SimpleAssetDto = z.infer<typeof _SimpleAssetDto>;
14
14
 
15
- export const _AssetUpsertDto = _ChangeAwareUpsertDto.extend({
16
- /** External Keys */
17
- extKeys: _AssetKeys,
18
- /** Asset display value */
19
- displayValue: z.string(),
20
- /** User Id of the asset owner */
21
- uid: z.string().optional(),
22
- /** Asset type */
23
- assetType: z.nativeEnum(GlobalAssetType).optional(),
24
- });
15
+ export const _AssetUpsertDto = _ChangeAwareUpsertDto.merge(
16
+ z.object({
17
+ /** External Keys */
18
+ extKeys: _AssetKeys,
19
+ /** Asset display value */
20
+ displayValue: z.string(),
21
+ /** User Id of the asset owner */
22
+ uid: z.string().optional(),
23
+ /** Asset type */
24
+ assetType: z.nativeEnum(GlobalAssetType).optional(),
25
+ })
26
+ );
25
27
 
26
28
  export type AssetUpsertDto = z.infer<typeof _AssetUpsertDto>;
27
29
 
28
- export const _AssetDto = _ChangeAwareDto.and(_AssetUpsertDto);
30
+ export const _AssetDto = _ChangeAwareDto.merge(_AssetUpsertDto);
29
31
 
30
32
  export type AssetDto = z.infer<typeof _AssetDto>;
@@ -1,13 +1,13 @@
1
1
  import {z} from 'zod';
2
2
 
3
3
  export const _BaseUpsertDto = z.object({
4
- id: z.string().optional(),
4
+ id: z.union([z.string(), z.undefined()]).optional(),
5
5
  });
6
6
 
7
7
  export type BaseUpsertDto = z.infer<typeof _BaseUpsertDto>;
8
8
 
9
9
  export const _BaseDto = z.object({
10
- id: z.string(),
10
+ id: z.union([z.string(), z.undefined()]).optional(),
11
11
  createdAt: z.string(),
12
12
  updatedAt: z.string(),
13
13
  deletedAt: z.string().nullable(),
@@ -15,11 +15,11 @@ export const _BaseDto = z.object({
15
15
 
16
16
  export type BaseDto = z.infer<typeof _BaseDto>;
17
17
 
18
- const WithEtag = {etag: z.string()};
18
+ const WithEtag = z.object({etag: z.string()});
19
19
 
20
- export const _ChangeAwareUpsertDto = _BaseUpsertDto.extend(WithEtag);
20
+ export const _ChangeAwareUpsertDto = _BaseUpsertDto.merge(WithEtag);
21
21
 
22
22
  export type ChangeAwareUpsertDto = z.infer<typeof _ChangeAwareUpsertDto>;
23
23
 
24
- export const _ChangeAwareDto = _BaseDto.extend(WithEtag);
24
+ export const _ChangeAwareDto = _BaseDto.merge(WithEtag);
25
25
  export type ChangeAwareDto = z.infer<typeof _ChangeAwareDto>;
@@ -4,17 +4,21 @@ import {_SaasAssetDto} from './saasAssets.dto';
4
4
  import {_SaasUserDto} from './saasUsers.dto';
5
5
  import {_SimpleUserDto} from './users.dto';
6
6
 
7
- export const _UserCoverageSummary = _SimpleUserDto.extend({
8
- userAccounts: z.record(z.number()),
9
- assetAccounts: z.record(z.number()),
10
- });
7
+ export const _UserCoverageSummary = _SimpleUserDto.merge(
8
+ z.object({
9
+ userAccounts: z.record(z.number()),
10
+ assetAccounts: z.record(z.number()),
11
+ })
12
+ );
11
13
 
12
14
  export type UserCoverageSummary = z.infer<typeof _UserCoverageSummary>;
13
15
 
14
- export const _UserCoverageReport = _SimpleUserDto.extend({
15
- userAccounts: z.record(z.array(_SaasUserDto)),
16
- assetAccounts: z.record(z.array(_SaasAssetDto)),
17
- assets: z.array(_AssetDto),
18
- });
16
+ export const _UserCoverageReport = _SimpleUserDto.merge(
17
+ z.object({
18
+ userAccounts: z.record(z.array(_SaasUserDto)),
19
+ assetAccounts: z.record(z.array(_SaasAssetDto)),
20
+ assets: z.array(_AssetDto),
21
+ })
22
+ );
19
23
 
20
24
  export type UserCoverageReport = z.infer<typeof _UserCoverageReport>;
@@ -1,25 +1,26 @@
1
1
  import {z} from 'zod';
2
2
  import {_AssetKeys} from './assetKeys';
3
3
  import {_ChangeAwareDto, _ChangeAwareUpsertDto} from './base.dto';
4
- import {_SaasUserDto, _SaasUserUpsertDto} from './saasUsers.dto';
5
4
 
6
- export const _SaasAssetUpsertDto = _ChangeAwareUpsertDto.extend({
7
- /** External Ids */
8
- extKeys: _AssetKeys,
9
- /** Connector Id */
10
- cid: z.string(),
11
- /** Asset Id */
12
- aid: z.string(),
13
- /** User Id */
14
- uid: z.string().optional(),
15
- /** Asset display value */
16
- displayValue: z.string(),
17
- /** Information specific to this asset */
18
- meta: z.unknown(),
19
- });
5
+ export const _SaasAssetUpsertDto = _ChangeAwareUpsertDto.merge(
6
+ z.object({
7
+ /** External Ids */
8
+ extKeys: _AssetKeys,
9
+ /** Connector Id */
10
+ cid: z.string(),
11
+ /** Asset Id */
12
+ aid: z.string(),
13
+ /** User Id */
14
+ uid: z.string().optional(),
15
+ /** Asset display value */
16
+ displayValue: z.string(),
17
+ /** Information specific to this asset */
18
+ meta: z.unknown(),
19
+ })
20
+ );
20
21
 
21
22
  export type SaasAssetUpsertDto = z.infer<typeof _SaasAssetUpsertDto>;
22
23
 
23
- export const _SaasAssetDto = _ChangeAwareDto.and(_SaasUserUpsertDto);
24
+ export const _SaasAssetDto = _ChangeAwareDto.merge(_SaasAssetUpsertDto);
24
25
 
25
- export type SaasAssetDto = z.infer<typeof _SaasUserDto>;
26
+ export type SaasAssetDto = z.infer<typeof _SaasAssetDto>;
@@ -1,21 +1,23 @@
1
1
  import {z} from 'zod';
2
2
  import {_ChangeAwareDto, _ChangeAwareUpsertDto} from './base.dto';
3
3
 
4
- export const _SaasUserUpsertDto = _ChangeAwareUpsertDto.extend({
5
- /** User Id */
6
- uid: z.string(),
7
- /** Connector Id */
8
- cid: z.string(),
9
- /** External email */
10
- email: z.string(),
11
- /** External Id */
12
- extId: z.string(),
13
- /** Additional information specific to this Saas User */
14
- meta: z.unknown(),
15
- });
4
+ export const _SaasUserUpsertDto = _ChangeAwareUpsertDto.merge(
5
+ z.object({
6
+ /** User Id */
7
+ uid: z.string(),
8
+ /** Connector Id */
9
+ cid: z.string(),
10
+ /** External email */
11
+ email: z.string(),
12
+ /** External Id */
13
+ extId: z.string(),
14
+ /** Additional information specific to this Saas User */
15
+ meta: z.unknown(),
16
+ })
17
+ );
16
18
 
17
19
  export type SaasUserUpsertDto = z.infer<typeof _SaasUserUpsertDto>;
18
20
 
19
- export const _SaasUserDto = _ChangeAwareDto.and(_SaasUserUpsertDto);
21
+ export const _SaasUserDto = _ChangeAwareDto.merge(_SaasUserUpsertDto);
20
22
 
21
23
  export type SaasUserDto = z.infer<typeof _SaasUserDto>;