@reventlessdev/rescript-pulumi-aws 2.4.0-alpha.43

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.
Files changed (169) hide show
  1. package/CHANGELOG.md +366 -0
  2. package/LICENSE +202 -0
  3. package/README.md +19 -0
  4. package/package.json +52 -0
  5. package/rescript.json +27 -0
  6. package/scripts/bundle-resolvers.mjs +77 -0
  7. package/src/AWS/Aws_AvailabilityZone.res +9 -0
  8. package/src/AWS/Aws_AvailabilityZone.res.mjs +9 -0
  9. package/src/AWS/Aws_AvailabilityZone.resi +9 -0
  10. package/src/AWS/Aws_Aws.res +29 -0
  11. package/src/AWS/Aws_Aws.res.mjs +32 -0
  12. package/src/AWS/Aws_Common.res +2 -0
  13. package/src/AWS/Aws_Common.res.mjs +2 -0
  14. package/src/AWS/Aws_Provider.res +10 -0
  15. package/src/AWS/Aws_Provider.res.mjs +2 -0
  16. package/src/Acm/Acm.res +5 -0
  17. package/src/Acm/Acm.res.mjs +12 -0
  18. package/src/Acm/Acm_Certificate.res +27 -0
  19. package/src/Acm/Acm_Certificate.res.mjs +2 -0
  20. package/src/Acm/Acm_CertificateValidation.res +22 -0
  21. package/src/Acm/Acm_CertificateValidation.res.mjs +2 -0
  22. package/src/AppSync/AppSync.res +7 -0
  23. package/src/AppSync/AppSync.res.mjs +18 -0
  24. package/src/AppSync/AppSync_DataSource.res +93 -0
  25. package/src/AppSync/AppSync_DataSource.res.mjs +42 -0
  26. package/src/AppSync/AppSync_Function.res +75 -0
  27. package/src/AppSync/AppSync_Function.res.mjs +36 -0
  28. package/src/AppSync/AppSync_GraphQLApi.res +65 -0
  29. package/src/AppSync/AppSync_GraphQLApi.res.mjs +20 -0
  30. package/src/AppSync/AppSync_Resolver.res +229 -0
  31. package/src/AppSync/AppSync_Resolver.res.mjs +113 -0
  32. package/src/AppSync/AppSync_ResolverRuntime.res +214 -0
  33. package/src/AppSync/AppSync_ResolverRuntime.res.mjs +15 -0
  34. package/src/AppSync/AppSync_Resolver_Functions.res +998 -0
  35. package/src/AppSync/AppSync_Resolver_Functions.res.mjs +913 -0
  36. package/src/Aws.res +5 -0
  37. package/src/Aws.res.mjs +16 -0
  38. package/src/AwsNative/AppSync/AwsNative_AppSync_Api.res +92 -0
  39. package/src/AwsNative/AppSync/AwsNative_AppSync_Api.res.mjs +12 -0
  40. package/src/AwsNative/AppSync/AwsNative_AppSync_ChannelNamespace.res +81 -0
  41. package/src/AwsNative/AppSync/AwsNative_AppSync_ChannelNamespace.res.mjs +18 -0
  42. package/src/AwsNative/AppSync/AwsNative_AppSync_Resolver.res +39 -0
  43. package/src/AwsNative/AppSync/AwsNative_AppSync_Resolver.res.mjs +12 -0
  44. package/src/AwsNative/AwsNative.res +10 -0
  45. package/src/AwsNative/AwsNative.res.mjs +13 -0
  46. package/src/CloudFront/CloudFront.res +5 -0
  47. package/src/CloudFront/CloudFront.res.mjs +12 -0
  48. package/src/CloudFront/CloudFront_Distribution.res +81 -0
  49. package/src/CloudFront/CloudFront_Distribution.res.mjs +2 -0
  50. package/src/CloudFront/CloudFront_OriginAccessControl.res +20 -0
  51. package/src/CloudFront/CloudFront_OriginAccessControl.res.mjs +2 -0
  52. package/src/Cloudwatch/Cloudwatch.res +7 -0
  53. package/src/Cloudwatch/Cloudwatch.res.mjs +18 -0
  54. package/src/Cloudwatch/Cloudwatch_EventRule.res +52 -0
  55. package/src/Cloudwatch/Cloudwatch_EventRule.res.mjs +37 -0
  56. package/src/Cloudwatch/Cloudwatch_EventTarget.res +28 -0
  57. package/src/Cloudwatch/Cloudwatch_EventTarget.res.mjs +25 -0
  58. package/src/Cloudwatch/Cloudwatch_LogGroup.res +14 -0
  59. package/src/Cloudwatch/Cloudwatch_LogGroup.res.mjs +2 -0
  60. package/src/Cloudwatch/Cloudwatch_LogMetricFilter.res +28 -0
  61. package/src/Cloudwatch/Cloudwatch_LogMetricFilter.res.mjs +2 -0
  62. package/src/Cognito/Cognito.res +8 -0
  63. package/src/Cognito/Cognito.res.mjs +21 -0
  64. package/src/Cognito/Cognito_IdentityPool.res +148 -0
  65. package/src/Cognito/Cognito_IdentityPool.res.mjs +65 -0
  66. package/src/Cognito/Cognito_IdentityPoolRoleAttachment.res +18 -0
  67. package/src/Cognito/Cognito_IdentityPoolRoleAttachment.res.mjs +2 -0
  68. package/src/Cognito/Cognito_UserGroup.res +16 -0
  69. package/src/Cognito/Cognito_UserGroup.res.mjs +2 -0
  70. package/src/Cognito/Cognito_UserPool.res +125 -0
  71. package/src/Cognito/Cognito_UserPool.res.mjs +44 -0
  72. package/src/Cognito/Cognito_UserPoolClient.res +33 -0
  73. package/src/Cognito/Cognito_UserPoolClient.res.mjs +2 -0
  74. package/src/DynamoDb/DynamoDb.res +5 -0
  75. package/src/DynamoDb/DynamoDb.res.mjs +12 -0
  76. package/src/DynamoDb/DynamoDb_Stream.res +41 -0
  77. package/src/DynamoDb/DynamoDb_Stream.res.mjs +2 -0
  78. package/src/DynamoDb/DynamoDb_Table.res +66 -0
  79. package/src/DynamoDb/DynamoDb_Table.res.mjs +2 -0
  80. package/src/EC2/EC2.res +13 -0
  81. package/src/EC2/EC2.res.mjs +36 -0
  82. package/src/EC2/EC2_Common.res +13 -0
  83. package/src/EC2/EC2_Common.res.mjs +22 -0
  84. package/src/EC2/EC2_DefaultSecurityGroup.res +22 -0
  85. package/src/EC2/EC2_DefaultSecurityGroup.res.mjs +19 -0
  86. package/src/EC2/EC2_Eip.res +24 -0
  87. package/src/EC2/EC2_Eip.res.mjs +18 -0
  88. package/src/EC2/EC2_InternetGateway.res +25 -0
  89. package/src/EC2/EC2_InternetGateway.res.mjs +18 -0
  90. package/src/EC2/EC2_NatGateway.res +30 -0
  91. package/src/EC2/EC2_NatGateway.res.mjs +18 -0
  92. package/src/EC2/EC2_RouteTable.res +49 -0
  93. package/src/EC2/EC2_RouteTable.res.mjs +38 -0
  94. package/src/EC2/EC2_RouteTableAssociation.res +30 -0
  95. package/src/EC2/EC2_RouteTableAssociation.res.mjs +18 -0
  96. package/src/EC2/EC2_SecurityGroup.res +44 -0
  97. package/src/EC2/EC2_SecurityGroup.res.mjs +49 -0
  98. package/src/EC2/EC2_Subnet.res +31 -0
  99. package/src/EC2/EC2_Subnet.res.mjs +19 -0
  100. package/src/EC2/EC2_Vpc.res +25 -0
  101. package/src/EC2/EC2_Vpc.res.mjs +18 -0
  102. package/src/EC2/EC2_VpcEndpoint.res +43 -0
  103. package/src/EC2/EC2_VpcEndpoint.res.mjs +22 -0
  104. package/src/ECS/ECS.res +6 -0
  105. package/src/ECS/ECS.res.mjs +15 -0
  106. package/src/ECS/ECS_Cluster.res +10 -0
  107. package/src/ECS/ECS_Cluster.res.mjs +2 -0
  108. package/src/ECS/ECS_Container.res +58 -0
  109. package/src/ECS/ECS_Container.res.mjs +2 -0
  110. package/src/ECS/ECS_TaskDefinition.res +31 -0
  111. package/src/ECS/ECS_TaskDefinition.res.mjs +2 -0
  112. package/src/IAM/IAM.res +148 -0
  113. package/src/IAM/IAM.res.mjs +61 -0
  114. package/src/IAM/IAM_ManagedPolicies.res +32 -0
  115. package/src/IAM/IAM_ManagedPolicies.res.mjs +2 -0
  116. package/src/IAM/PolicyDocument.res +163 -0
  117. package/src/IAM/PolicyDocument.res.mjs +164 -0
  118. package/src/Kinesis/Kinesis.res +4 -0
  119. package/src/Kinesis/Kinesis.res.mjs +9 -0
  120. package/src/Kinesis/Kinesis_Stream.res +70 -0
  121. package/src/Kinesis/Kinesis_Stream.res.mjs +9 -0
  122. package/src/Lambda/EventSourceMapping.res +78 -0
  123. package/src/Lambda/EventSourceMapping.res.mjs +2 -0
  124. package/src/Lambda/FunctionUrl.res +41 -0
  125. package/src/Lambda/FunctionUrl.res.mjs +2 -0
  126. package/src/Lambda/Lambda.res +270 -0
  127. package/src/Lambda/Lambda.res.mjs +94 -0
  128. package/src/Route53/Route53.res +4 -0
  129. package/src/Route53/Route53.res.mjs +9 -0
  130. package/src/Route53/Route53_Record.res +36 -0
  131. package/src/Route53/Route53_Record.res.mjs +2 -0
  132. package/src/S3/S3.res +10 -0
  133. package/src/S3/S3.res.mjs +27 -0
  134. package/src/S3/S3_Bucket.res +236 -0
  135. package/src/S3/S3_Bucket.res.mjs +2 -0
  136. package/src/S3/S3_BucketAclV2.res +24 -0
  137. package/src/S3/S3_BucketAclV2.res.mjs +2 -0
  138. package/src/S3/S3_BucketObject.res +22 -0
  139. package/src/S3/S3_BucketObject.res.mjs +2 -0
  140. package/src/S3/S3_BucketOwnershipControls.res +19 -0
  141. package/src/S3/S3_BucketOwnershipControls.res.mjs +2 -0
  142. package/src/S3/S3_BucketPolicy.res +13 -0
  143. package/src/S3/S3_BucketPolicy.res.mjs +2 -0
  144. package/src/S3/S3_BucketPublicAccessBlock.res +16 -0
  145. package/src/S3/S3_BucketPublicAccessBlock.res.mjs +2 -0
  146. package/src/S3/S3_BucketV2.res +11 -0
  147. package/src/S3/S3_BucketV2.res.mjs +2 -0
  148. package/src/SES/SES.bs.js +11 -0
  149. package/src/SES/SES.res +25 -0
  150. package/src/SES/SES.res.mjs +12 -0
  151. package/src/SNS/SNS.res +5 -0
  152. package/src/SNS/SNS.res.mjs +12 -0
  153. package/src/SNS/SNS_Topic.res +71 -0
  154. package/src/SNS/SNS_Topic.res.mjs +2 -0
  155. package/src/SNS/SNS_TopicSubscription.res +21 -0
  156. package/src/SNS/SNS_TopicSubscription.res.mjs +2 -0
  157. package/src/SQS/SQS.res +5 -0
  158. package/src/SQS/SQS.res.mjs +12 -0
  159. package/src/SQS/SQS_Queue.res +92 -0
  160. package/src/SQS/SQS_Queue.res.mjs +19 -0
  161. package/src/SQS/SQS_QueuePolicy.res +13 -0
  162. package/src/SQS/SQS_QueuePolicy.res.mjs +2 -0
  163. package/src/SecretsManager/GetSecretVersion.res +37 -0
  164. package/src/SecretsManager/GetSecretVersion.res.mjs +23 -0
  165. package/src/example/CustomDomainExample.res +71 -0
  166. package/src/example/CustomDomainExample.res.mjs +57 -0
  167. package/tests/AppSync_Resolver_FunctionsTest.mjs +597 -0
  168. package/tests/__mocks__/appsync-utils.mjs +26 -0
  169. package/tests/resolverTestHelper.mjs +46 -0
@@ -0,0 +1,913 @@
1
+ // Generated by ReScript, PLEASE EDIT WITH CARE
2
+
3
+
4
+ let resultResponseCode = `
5
+ export function response(ctx) {
6
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
7
+ return ctx.result;
8
+ }`;
9
+
10
+ let firstResultResponseCode = `
11
+ export function response(ctx) {
12
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
13
+ return ctx.result.items[0] ?? null;
14
+ }`;
15
+
16
+ let resultListResponseCode = `
17
+ export function response(ctx) {
18
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
19
+ return ctx.result.items;
20
+ }`;
21
+
22
+ let importUtil = `import { util } from '@aws-appsync/utils';`;
23
+
24
+ let pipelinePassThrough = importUtil + `
25
+ export function request(ctx) { return {}; }
26
+ ` + resultResponseCode + `
27
+ `;
28
+
29
+ let nodeDecodeGlobalId = importUtil + `
30
+ export function request(ctx) {
31
+ const globalId = ctx.args.id;
32
+ try {
33
+ const decoded = util.base64Decode(globalId);
34
+ const colonIdx = decoded.indexOf(':');
35
+ if (colonIdx > 0) {
36
+ ctx.stash.typeName = decoded.substring(0, colonIdx);
37
+ ctx.stash.localId = decoded.substring(colonIdx + 1);
38
+ }
39
+ } catch (e) {
40
+ ctx.stash.typeName = null;
41
+ ctx.stash.localId = null;
42
+ }
43
+ return { payload: null };
44
+ }
45
+ export function response(ctx) {
46
+ return ctx.stash;
47
+ }
48
+ `;
49
+
50
+ function nodeGetItemForType(typeName) {
51
+ return importUtil + `
52
+ export function request(ctx) {
53
+ if (ctx.stash.typeName !== '` + typeName + `') return runtime.earlyReturn(ctx.prev.result);
54
+ return {
55
+ operation: 'GetItem',
56
+ key: { id: util.dynamodb.toDynamoDB(ctx.stash.localId) }
57
+ };
58
+ }
59
+ export function response(ctx) {
60
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
61
+ if (!ctx.result) return null;
62
+ return { ...ctx.result, __typename: '` + typeName + `', id: ctx.args.id };
63
+ }
64
+ `;
65
+ }
66
+
67
+ let getItemById = importUtil + `
68
+ export function request(ctx) {
69
+ return {
70
+ operation: 'GetItem',
71
+ key: { id: util.dynamodb.toDynamoDB(ctx.args.id) }
72
+ };
73
+ }
74
+ ` + resultResponseCode + `
75
+ `;
76
+
77
+ let queryById = importUtil + `
78
+ export function request(ctx) {
79
+ return {
80
+ operation: 'Query',
81
+ query: {
82
+ expression: 'id = :id',
83
+ expressionValues: { ':id': util.dynamodb.toDynamoDB(ctx.args.id) }
84
+ }
85
+ };
86
+ }
87
+ ` + resultResponseCode + `
88
+ `;
89
+
90
+ function queryItemsWithSortConditions(sortField) {
91
+ return importUtil + `
92
+ const encodeCursor = (skValue) => util.base64Encode(skValue);
93
+ const decodeCursor = (cursor) => util.base64Decode(cursor);
94
+ export function request(ctx) {
95
+ const args = ctx.args;
96
+ const filter = args.filter ?? {};
97
+ const isBackward = args.last != null;
98
+ const expressionNames = { '#id': 'id' };
99
+ const expressionValues = { ':id': util.dynamodb.toDynamoDB(args.id) };
100
+ let skCondition;
101
+ if (filter.eq != null) {
102
+ expressionValues[':eq'] = util.dynamodb.toDynamoDB(filter.eq);
103
+ skCondition = '#sk = :eq';
104
+ } else if (filter.prefix != null) {
105
+ expressionValues[':prefix'] = util.dynamodb.toDynamoDB(filter.prefix);
106
+ skCondition = 'begins_with(#sk, :prefix)';
107
+ } else if (filter.from != null && filter.to != null) {
108
+ expressionValues[':from'] = util.dynamodb.toDynamoDB(filter.from);
109
+ expressionValues[':to'] = util.dynamodb.toDynamoDB(filter.to);
110
+ skCondition = '#sk BETWEEN :from AND :to';
111
+ } else if (filter.from != null) {
112
+ expressionValues[':from'] = util.dynamodb.toDynamoDB(filter.from);
113
+ skCondition = '#sk >= :from';
114
+ } else if (filter.to != null) {
115
+ expressionValues[':to'] = util.dynamodb.toDynamoDB(filter.to);
116
+ skCondition = '#sk <= :to';
117
+ }
118
+ if (isBackward && args.before != null) {
119
+ const beforeKey = decodeCursor(args.before);
120
+ expressionValues[':cursor'] = util.dynamodb.toDynamoDB(beforeKey);
121
+ const cursorCond = '#sk < :cursor';
122
+ skCondition = skCondition ? \`(\${skCondition}) AND \${cursorCond}\` : cursorCond;
123
+ } else if (!isBackward && args.after != null) {
124
+ const afterKey = decodeCursor(args.after);
125
+ expressionValues[':cursor'] = util.dynamodb.toDynamoDB(afterKey);
126
+ const cursorCond = '#sk > :cursor';
127
+ skCondition = skCondition ? \`(\${skCondition}) AND \${cursorCond}\` : cursorCond;
128
+ }
129
+ if (skCondition) expressionNames['#sk'] = '` + sortField + `';
130
+ const expression = skCondition ? \`#id = :id AND \${skCondition}\` : '#id = :id';
131
+ const orderDesc = filter.order === 'DESC';
132
+ const scanForward = isBackward ? orderDesc : !orderDesc;
133
+ const pageSize = isBackward ? (args.last ?? 50) : (args.first ?? 50);
134
+ return {
135
+ operation: 'Query',
136
+ query: { expression, expressionNames, expressionValues },
137
+ scanIndexForward: scanForward,
138
+ limit: pageSize + 1,
139
+ };
140
+ }
141
+ export function response(ctx) {
142
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
143
+ const args = ctx.args;
144
+ const filter = args.filter ?? {};
145
+ const isBackward = args.last != null;
146
+ const pageSize = isBackward ? (args.last ?? 50) : (args.first ?? 50);
147
+ let items = ctx.result.items ?? [];
148
+ const hasMore = items.length > pageSize;
149
+ if (hasMore) items = items.slice(0, pageSize);
150
+ if (isBackward) items = items.reverse();
151
+ const edges = items.map(item => ({ node: item, cursor: encodeCursor(item['` + sortField + `'] ?? '') }));
152
+ const startCursor = edges.length > 0 ? edges[0].cursor : null;
153
+ const endCursor = edges.length > 0 ? edges[edges.length - 1].cursor : null;
154
+ return {
155
+ edges,
156
+ pageInfo: {
157
+ hasNextPage: !isBackward && hasMore,
158
+ hasPreviousPage: isBackward && hasMore,
159
+ startCursor,
160
+ endCursor,
161
+ },
162
+ };
163
+ }
164
+ `;
165
+ }
166
+
167
+ function queryByIdSort(sortField) {
168
+ return importUtil + `
169
+ export function request(ctx) {
170
+ return {
171
+ operation: 'Query',
172
+ query: {
173
+ expression: 'id = :id AND #` + sortField + ` = :` + sortField + `',
174
+ expressionNames: { '#` + sortField + `': '` + sortField + `' },
175
+ expressionValues: {
176
+ ':id': util.dynamodb.toDynamoDB(ctx.args.id),
177
+ ':` + sortField + `': util.dynamodb.toDynamoDB(ctx.args.` + sortField + `)
178
+ }
179
+ }
180
+ };
181
+ }
182
+ ` + firstResultResponseCode + `
183
+ `;
184
+ }
185
+
186
+ function queryByIndex(index) {
187
+ return importUtil + `
188
+ export function request(ctx) {
189
+ return {
190
+ operation: 'Query',
191
+ query: {
192
+ expression: '#` + index + ` = :` + index + `',
193
+ expressionNames: { '#` + index + `': '` + index + `' },
194
+ expressionValues: { ':` + index + `': util.dynamodb.toDynamoDB(ctx.args.` + index + `) }
195
+ },
196
+ index: '` + index + `'
197
+ };
198
+ }
199
+ ` + resultResponseCode + `
200
+ `;
201
+ }
202
+
203
+ function queryByIndexDeletable(index) {
204
+ return importUtil + `
205
+ export function request(ctx) {
206
+ const req = {
207
+ operation: 'Query',
208
+ query: {
209
+ expression: '#` + index + ` = :` + index + `',
210
+ expressionNames: { '#` + index + `': '` + index + `' },
211
+ expressionValues: { ':` + index + `': util.dynamodb.toDynamoDB(ctx.args.` + index + `) }
212
+ },
213
+ index: '` + index + `'
214
+ };
215
+ if (ctx.args.hideDeleted) {
216
+ req.filter = {
217
+ expression: '#deleted = :false',
218
+ expressionNames: { '#deleted': 'deleted' },
219
+ expressionValues: { ':false': util.dynamodb.toBoolean(false) }
220
+ };
221
+ }
222
+ return req;
223
+ }
224
+ ` + resultResponseCode + `
225
+ `;
226
+ }
227
+
228
+ function queryByIndexSort(index, idField, sortField) {
229
+ return importUtil + `
230
+ export function request(ctx) {
231
+ const query = ctx.args.` + sortField + `
232
+ ? {
233
+ expression: '#` + idField + ` = :` + idField + ` AND #` + sortField + ` = :` + sortField + `',
234
+ expressionNames: { '#` + idField + `': '` + idField + `', '#` + sortField + `': '` + sortField + `' },
235
+ expressionValues: {
236
+ ':` + idField + `': util.dynamodb.toDynamoDB(ctx.args.` + idField + `),
237
+ ':` + sortField + `': util.dynamodb.toDynamoDB(ctx.args.` + sortField + `)
238
+ }
239
+ }
240
+ : {
241
+ expression: '#` + idField + ` = :` + idField + `',
242
+ expressionNames: { '#` + idField + `': '` + idField + `' },
243
+ expressionValues: { ':` + idField + `': util.dynamodb.toDynamoDB(ctx.args.` + idField + `) }
244
+ };
245
+ return { operation: 'Query', query, index: '` + index + `' };
246
+ }
247
+ ` + resultResponseCode + `
248
+ `;
249
+ }
250
+
251
+ function queryByIndexFiltered(index, idField) {
252
+ return importUtil + `
253
+ export function request(ctx) {
254
+ const args = ctx.args;
255
+ const query = {
256
+ expression: '#` + idField + ` = :` + idField + `',
257
+ expressionNames: { '#` + idField + `': '` + idField + `' },
258
+ expressionValues: { ':` + idField + `': util.dynamodb.toDynamoDB(args.` + idField + `) }
259
+ };
260
+ let expression = '';
261
+ const names = {};
262
+ const values = {};
263
+ Object.keys(args).forEach(key => {
264
+ const value = args[key];
265
+ if (key === '` + idField + `' || key === 'limit' || key === 'nextToken' || key === 'forward') return;
266
+ if (value == null || value === '') return;
267
+ if (expression) expression += ' AND';
268
+ if (key === 'hideDeleted') {
269
+ if (value === true) {
270
+ expression += ' #deleted = :false';
271
+ names['#deleted'] = 'deleted';
272
+ values[':false'] = false;
273
+ }
274
+ } else {
275
+ expression += ' contains(#' + key + ', :' + key + ')';
276
+ names['#' + key] = key;
277
+ values[':' + key] = '' + value;
278
+ }
279
+ });
280
+ const result = {
281
+ operation: 'Query',
282
+ query,
283
+ index: '` + index + `',
284
+ limit: (args.limit ?? 50),
285
+ nextToken: (args.nextToken ?? null),
286
+ scanIndexForward: (args.forward ?? true)
287
+ };
288
+ if (expression) {
289
+ result.filter = { expression, expressionNames: names, expressionValues: util.dynamodb.toMapValues(values) };
290
+ }
291
+ return result;
292
+ }
293
+ ` + resultResponseCode + `
294
+ `;
295
+ }
296
+
297
+ function queryByIndexSortFiltered(index, idField, sortField) {
298
+ return importUtil + `
299
+ export function request(ctx) {
300
+ const args = ctx.args;
301
+ const query = args.` + sortField + `
302
+ ? {
303
+ expression: '#` + idField + ` = :` + idField + ` AND #` + sortField + ` = :` + sortField + `',
304
+ expressionNames: { '#` + idField + `': '` + idField + `', '#` + sortField + `': '` + sortField + `' },
305
+ expressionValues: {
306
+ ':` + idField + `': util.dynamodb.toDynamoDB(args.` + idField + `),
307
+ ':` + sortField + `': util.dynamodb.toDynamoDB(args.` + sortField + `)
308
+ }
309
+ }
310
+ : {
311
+ expression: '#` + idField + ` = :` + idField + `',
312
+ expressionNames: { '#` + idField + `': '` + idField + `' },
313
+ expressionValues: { ':` + idField + `': util.dynamodb.toDynamoDB(args.` + idField + `) }
314
+ };
315
+ let expression = '';
316
+ const names = {};
317
+ const values = {};
318
+ Object.keys(args).forEach(key => {
319
+ const value = args[key];
320
+ if (key === '` + idField + `' || key === '` + sortField + `' || key === 'limit' || key === 'nextToken' || key === 'forward') return;
321
+ if (value == null || value === '') return;
322
+ if (expression) expression += ' AND';
323
+ if (key === 'hideDeleted') {
324
+ if (value === true) {
325
+ expression += ' #deleted = :false';
326
+ names['#deleted'] = 'deleted';
327
+ values[':false'] = false;
328
+ }
329
+ } else {
330
+ expression += ' contains(#' + key + ', :' + key + ')';
331
+ names['#' + key] = key;
332
+ values[':' + key] = '' + value;
333
+ }
334
+ });
335
+ const result = {
336
+ operation: 'Query',
337
+ query,
338
+ index: '` + index + `',
339
+ limit: (args.limit ?? 50),
340
+ nextToken: (args.nextToken ?? null),
341
+ scanIndexForward: (args.forward ?? true)
342
+ };
343
+ if (expression) {
344
+ result.filter = { expression, expressionNames: names, expressionValues: util.dynamodb.toMapValues(values) };
345
+ }
346
+ return result;
347
+ }
348
+ ` + resultResponseCode + `
349
+ `;
350
+ }
351
+
352
+ let listAllItems = importUtil + `
353
+ export function request(ctx) {
354
+ return {
355
+ operation: 'Scan',
356
+ limit: (ctx.args.limit ?? 50),
357
+ nextToken: (ctx.args.nextToken ?? null)
358
+ };
359
+ }
360
+ ` + resultResponseCode + `
361
+ `;
362
+
363
+ function listAllItemsConnection(labelField, filterFieldsOpt, rangeFieldsOpt, sortFieldsOpt) {
364
+ let filterFields = filterFieldsOpt !== undefined ? filterFieldsOpt : [];
365
+ let rangeFields = rangeFieldsOpt !== undefined ? rangeFieldsOpt : [];
366
+ let sortFields = sortFieldsOpt !== undefined ? sortFieldsOpt : [];
367
+ let filterClauses = filterFields.map(f => `
368
+ if (filter.` + f + `Eq !== undefined && filter.` + f + `Eq !== null && filter.` + f + `Eq !== '') {
369
+ names['#` + f + `'] = '` + f + `';
370
+ values[':` + f + `Eq'] = util.dynamodb.toDynamoDB(filter.` + f + `Eq);
371
+ parts.push('#` + f + ` = :` + f + `Eq');
372
+ }`).join("");
373
+ let rangeClauses = rangeFields.map(f => `
374
+ if (filter.` + f + `From !== undefined && filter.` + f + `From !== null && filter.` + f + `From !== '') {
375
+ names['#` + f + `'] = '` + f + `';
376
+ values[':` + f + `From'] = util.dynamodb.toDynamoDB(filter.` + f + `From);
377
+ parts.push('#` + f + ` >= :` + f + `From');
378
+ }
379
+ if (filter.` + f + `To !== undefined && filter.` + f + `To !== null && filter.` + f + `To !== '') {
380
+ names['#` + f + `'] = '` + f + `';
381
+ values[':` + f + `To'] = util.dynamodb.toDynamoDB(filter.` + f + `To);
382
+ parts.push('#` + f + ` <= :` + f + `To');
383
+ }`).join("");
384
+ let sortFieldsLiteral = sortFields.map(f => `'` + f + `'`).join(", ");
385
+ let sortBlock = sortFields.length === 0 ? "" : `
386
+ // Per-page sort (Scan returns items in indeterminate order; ScanIndexForward
387
+ // does not apply to Scan). Global ordering across pages requires v1.5 index
388
+ // promotion; @scanSort is per-page even then.
389
+ const orderBy = ctx.args.orderBy;
390
+ const sortFields = [` + sortFieldsLiteral + `];
391
+ if (orderBy && orderBy.field && sortFields.indexOf(orderBy.field) >= 0) {
392
+ const field = orderBy.field;
393
+ const nulls = items.filter(it => it[field] === null || it[field] === undefined);
394
+ const nonNulls = items.filter(it => it[field] !== null && it[field] !== undefined);
395
+ const encoded = nonNulls.map(it => {
396
+ const v = it[field];
397
+ const key = (typeof v === 'number')
398
+ ? ('0000000000000000000000' + v).slice(-22)
399
+ : ('' + v);
400
+ return key + '\\x01' + JSON.stringify(it);
401
+ });
402
+ encoded.sort();
403
+ if (orderBy.direction === 'DESC') encoded.reverse();
404
+ items = encoded.map(e => JSON.parse(e.split('\\x01')[1])).concat(nulls);
405
+ }`;
406
+ return importUtil + `
407
+ export function request(ctx) {
408
+ const filter = ctx.args.filter ?? {};
409
+ const names = {};
410
+ const values = {};
411
+ const parts = [];
412
+ if (typeof filter.search === 'string' && filter.search.length > 0) {
413
+ names['#label'] = '` + labelField + `';
414
+ values[':search'] = util.dynamodb.toDynamoDB(filter.search);
415
+ parts.push('contains(#label, :search)');
416
+ }
417
+ if (typeof filter.searchPrefix === 'string' && filter.searchPrefix.length > 0) {
418
+ names['#label'] = '` + labelField + `';
419
+ values[':searchPrefix'] = util.dynamodb.toDynamoDB(filter.searchPrefix);
420
+ parts.push('begins_with(#label, :searchPrefix)');
421
+ }
422
+ if (Array.isArray(filter.ids) && filter.ids.length > 0) {
423
+ names['#id'] = 'id';
424
+ const placeholders = filter.ids.map((id, i) => {
425
+ const key = ':id' + i;
426
+ values[key] = util.dynamodb.toDynamoDB(id);
427
+ return key;
428
+ });
429
+ parts.push('#id IN (' + placeholders.join(', ') + ')');
430
+ }` + filterClauses + rangeClauses + `
431
+ const req = {
432
+ operation: 'Scan',
433
+ limit: (ctx.args.first ?? 50),
434
+ nextToken: (ctx.args.after ?? null),
435
+ };
436
+ if (parts.length > 0) {
437
+ req.filter = {
438
+ expression: parts.join(' AND '),
439
+ expressionNames: names,
440
+ expressionValues: values,
441
+ };
442
+ }
443
+ return req;
444
+ }
445
+ export function response(ctx) {
446
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
447
+ let items = ctx.result?.items ?? [];` + sortBlock + `
448
+ const edges = items.map((item, i) => ({
449
+ node: item,
450
+ cursor: ctx.args.after ? ctx.args.after + '_' + i : '' + i,
451
+ }));
452
+ return {
453
+ edges,
454
+ pageInfo: {
455
+ hasNextPage: !!ctx.result?.nextToken,
456
+ hasPreviousPage: !!ctx.args.after,
457
+ startCursor: edges.length > 0 ? edges[0].cursor : null,
458
+ endCursor: edges.length > 0 ? edges[edges.length - 1].cursor : null,
459
+ },
460
+ };
461
+ }
462
+ `;
463
+ }
464
+
465
+ function resolveId(sourceIdField) {
466
+ return importUtil + `
467
+ export function request(ctx) {
468
+ if (!ctx.source.` + sourceIdField + `) return runtime.earlyReturn(null);
469
+ return {
470
+ operation: 'Query',
471
+ query: {
472
+ expression: '#id = :id',
473
+ expressionNames: { '#id': 'id' },
474
+ expressionValues: { ':id': util.dynamodb.toDynamoDB(ctx.source.` + sourceIdField + `) }
475
+ },
476
+ limit: (ctx.args.limit ?? 50),
477
+ nextToken: (ctx.args.nextToken ?? null),
478
+ scanIndexForward: (ctx.args.forward ?? true)
479
+ };
480
+ }
481
+ ` + firstResultResponseCode + `
482
+ `;
483
+ }
484
+
485
+ function resolveIdSort(sourceIdField, sourceSortField, targetSortField) {
486
+ return importUtil + `
487
+ export function request(ctx) {
488
+ return {
489
+ operation: 'Query',
490
+ query: {
491
+ expression: '#id = :id AND #` + targetSortField + ` = :` + targetSortField + `',
492
+ expressionNames: { '#id': 'id', '#` + targetSortField + `': '` + targetSortField + `' },
493
+ expressionValues: {
494
+ ':id': util.dynamodb.toDynamoDB(ctx.source.` + sourceIdField + `),
495
+ ':` + targetSortField + `': util.dynamodb.toDynamoDB(ctx.source.` + sourceSortField + `)
496
+ }
497
+ },
498
+ limit: (ctx.args.limit ?? 50),
499
+ nextToken: (ctx.args.nextToken ?? null),
500
+ scanIndexForward: (ctx.args.forward ?? true)
501
+ };
502
+ }
503
+ ` + firstResultResponseCode + `
504
+ `;
505
+ }
506
+
507
+ function resolveIdSortArgument(sourceIdField, sourceSortArgument, targetSortField) {
508
+ return importUtil + `
509
+ export function request(ctx) {
510
+ const query = ctx.args.` + sourceSortArgument + `
511
+ ? {
512
+ expression: '#id = :id AND #` + targetSortField + ` = :` + targetSortField + `',
513
+ expressionNames: { '#id': 'id', '#` + targetSortField + `': '` + targetSortField + `' },
514
+ expressionValues: {
515
+ ':id': util.dynamodb.toDynamoDB(ctx.source.` + sourceIdField + `),
516
+ ':` + targetSortField + `': util.dynamodb.toDynamoDB(ctx.args.` + sourceSortArgument + `)
517
+ }
518
+ }
519
+ : {
520
+ expression: '#id = :id',
521
+ expressionNames: { '#id': 'id' },
522
+ expressionValues: { ':id': util.dynamodb.toDynamoDB(ctx.source.` + sourceIdField + `) }
523
+ };
524
+ return {
525
+ operation: 'Query',
526
+ query,
527
+ limit: (ctx.args.limit ?? 50),
528
+ nextToken: (ctx.args.nextToken ?? null),
529
+ scanIndexForward: (ctx.args.forward ?? true)
530
+ };
531
+ }
532
+ ` + firstResultResponseCode + `
533
+ `;
534
+ }
535
+
536
+ function resolveIdByIndex(index, sourceIdField, targetIdField) {
537
+ return importUtil + `
538
+ export function request(ctx) {
539
+ return {
540
+ operation: 'Query',
541
+ query: {
542
+ expression: '#` + targetIdField + ` = :` + targetIdField + `',
543
+ expressionNames: { '#` + targetIdField + `': '` + targetIdField + `' },
544
+ expressionValues: { ':` + targetIdField + `': util.dynamodb.toDynamoDB(ctx.source.` + sourceIdField + `) }
545
+ },
546
+ index: '` + index + `',
547
+ limit: (ctx.args.limit ?? 50),
548
+ nextToken: (ctx.args.nextToken ?? null),
549
+ scanIndexForward: (ctx.args.forward ?? true)
550
+ };
551
+ }
552
+ ` + firstResultResponseCode + `
553
+ `;
554
+ }
555
+
556
+ function resolveIdByIndexSort(index, sourceIdField, sourceSortField, targetIdField, targetSortField) {
557
+ return importUtil + `
558
+ export function request(ctx) {
559
+ return {
560
+ operation: 'Query',
561
+ query: {
562
+ expression: '#` + targetIdField + ` = :` + targetIdField + ` AND #` + targetSortField + ` = :` + targetSortField + `',
563
+ expressionNames: { '#` + targetIdField + `': '` + targetIdField + `', '#` + targetSortField + `': '` + targetSortField + `' },
564
+ expressionValues: {
565
+ ':` + targetIdField + `': util.dynamodb.toDynamoDB(ctx.source.` + sourceIdField + `),
566
+ ':` + targetSortField + `': util.dynamodb.toDynamoDB(ctx.source.` + sourceSortField + `)
567
+ }
568
+ },
569
+ index: '` + index + `',
570
+ limit: (ctx.args.limit ?? 50),
571
+ nextToken: (ctx.args.nextToken ?? null),
572
+ scanIndexForward: (ctx.args.forward ?? true)
573
+ };
574
+ }
575
+ ` + firstResultResponseCode + `
576
+ `;
577
+ }
578
+
579
+ function resolveIdByIndexSortArgument(index, sourceIdField, sourceSortArgument, targetIdField, targetSortField) {
580
+ return importUtil + `
581
+ export function request(ctx) {
582
+ const query = ctx.args.` + sourceSortArgument + `
583
+ ? {
584
+ expression: '#` + targetIdField + ` = :` + targetIdField + ` AND #` + targetSortField + ` = :` + targetSortField + `',
585
+ expressionNames: { '#` + targetIdField + `': '` + targetIdField + `', '#` + targetSortField + `': '` + targetSortField + `' },
586
+ expressionValues: {
587
+ ':` + targetIdField + `': util.dynamodb.toDynamoDB(ctx.source.` + sourceIdField + `),
588
+ ':` + targetSortField + `': util.dynamodb.toDynamoDB(ctx.args.` + sourceSortArgument + `)
589
+ }
590
+ }
591
+ : {
592
+ expression: '#` + targetIdField + ` = :` + targetIdField + `',
593
+ expressionNames: { '#` + targetIdField + `': '` + targetIdField + `' },
594
+ expressionValues: { ':` + targetIdField + `': util.dynamodb.toDynamoDB(ctx.source.` + sourceIdField + `) }
595
+ };
596
+ return {
597
+ operation: 'Query',
598
+ query,
599
+ index: '` + index + `',
600
+ limit: (ctx.args.limit ?? 50),
601
+ nextToken: (ctx.args.nextToken ?? null),
602
+ scanIndexForward: (ctx.args.forward ?? true)
603
+ };
604
+ }
605
+ ` + firstResultResponseCode + `
606
+ `;
607
+ }
608
+
609
+ function resolveIds(tableName, idsField, sortField) {
610
+ let keysCode = sortField !== undefined ? `id => ({ id: util.dynamodb.toString(id.id), ` + sortField + `: util.dynamodb.toString(id.` + sortField + `) })` : `id => ({ id: util.dynamodb.toString(id) })`;
611
+ return importUtil + `
612
+ import { runtime } from '@aws-appsync/utils';
613
+ export function request(ctx) {
614
+ const idList = ctx.source.` + idsField + `;
615
+ if (idList && idList.length > 0) {
616
+ return {
617
+ operation: 'BatchGetItem',
618
+ tables: {
619
+ '` + tableName + `': {
620
+ keys: idList.map(` + keysCode + `),
621
+ consistentRead: true
622
+ }
623
+ }
624
+ };
625
+ }
626
+ return { operation: 'GetItem', key: { id: util.dynamodb.toString(ctx.source.id) } };
627
+ }
628
+ export function response(ctx) {
629
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
630
+ return ctx.result;
631
+ }
632
+ `;
633
+ }
634
+
635
+ function batchGetItemsByIds(tableName) {
636
+ return importUtil + `
637
+ import { runtime } from '@aws-appsync/utils';
638
+ export function request(ctx) {
639
+ const ids = ctx.args.ids ?? [];
640
+ if (ids.length === 0) return runtime.earlyReturn([]);
641
+ return {
642
+ operation: 'BatchGetItem',
643
+ tables: {
644
+ '` + tableName + `': {
645
+ keys: ids.map(id => ({ id: util.dynamodb.toDynamoDB(id) })),
646
+ consistentRead: true,
647
+ }
648
+ }
649
+ };
650
+ }
651
+ export function response(ctx) {
652
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
653
+ // BatchGetItem returns null in the result array for keys that don't exist
654
+ // in the table, preserving index correspondence with the input. The SDL
655
+ // returns this field as \`[T!]!\` (non-null element list), so any single
656
+ // missing id makes the entire field fail with "Cannot return null for
657
+ // non-nullable type" and the caller sees data=null. Filter the nulls so
658
+ // the field returns just the items that were found.
659
+ return (ctx.result?.data?.['` + tableName + `'] ?? []).filter(item => item !== null);
660
+ }
661
+ `;
662
+ }
663
+
664
+ let putItem = importUtil + `
665
+ export function request(ctx) {
666
+ return {
667
+ operation: 'PutItem',
668
+ key: { id: util.dynamodb.toDynamoDB(ctx.args.id) },
669
+ attributeValues: util.dynamodb.toMapValues(ctx.args)
670
+ };
671
+ }
672
+ ` + resultResponseCode + `
673
+ `;
674
+
675
+ function addItemToList(listName, itemName) {
676
+ return importUtil + `
677
+ export function request(ctx) {
678
+ return {
679
+ operation: 'UpdateItem',
680
+ key: { id: util.dynamodb.toDynamoDB(ctx.args.id) },
681
+ update: {
682
+ expression: 'SET #list = list_append(#list, :item)',
683
+ expressionNames: { '#list': '` + listName + `' },
684
+ expressionValues: { ':item': util.dynamodb.toList([util.dynamodb.toDynamoDB(ctx.args.` + itemName + `)]) }
685
+ }
686
+ };
687
+ }
688
+ ` + resultResponseCode + `
689
+ `;
690
+ }
691
+
692
+ let deleteItem = importUtil + `
693
+ export function request(ctx) {
694
+ return {
695
+ operation: 'DeleteItem',
696
+ key: { id: util.dynamodb.toString(ctx.args.id) }
697
+ };
698
+ }
699
+ ` + resultResponseCode + `
700
+ `;
701
+
702
+ function invokeCommandGenerator(command) {
703
+ return importUtil + `
704
+ export function request(ctx) {
705
+ const id = ctx.identity;
706
+ const isCognito = id != null && id.sub != null;
707
+ return {
708
+ operation: 'Invoke',
709
+ payload: {
710
+ command: '` + command + `',
711
+ arguments: ctx.args,
712
+ meta: {
713
+ ip: id?.sourceIp ?? null,
714
+ user: id?.username ?? null,
715
+ info: ctx.info.parentTypeName + '.' + ctx.info.fieldName
716
+ },
717
+ identity: isCognito
718
+ ? {
719
+ userId: id.sub,
720
+ username: id.username,
721
+ groups: id.claims?.['cognito:groups'] ?? [],
722
+ claims: id.claims,
723
+ provider: 'Cognito'
724
+ }
725
+ : id != null
726
+ ? {
727
+ userArn: id.userArn ?? null,
728
+ accountId: id.accountId ?? null,
729
+ username: id.username ?? null,
730
+ provider: 'IAM'
731
+ }
732
+ : null
733
+ }
734
+ };
735
+ }
736
+ ` + resultResponseCode + `
737
+ `;
738
+ }
739
+
740
+ function invokeDcbMutation(tag) {
741
+ return importUtil + `
742
+ export function request(ctx) {
743
+ const id = ctx.identity;
744
+ const isCognito = id != null && id.sub != null;
745
+ return {
746
+ operation: 'Invoke',
747
+ payload: {
748
+ command: '` + tag + `',
749
+ arguments: ctx.args,
750
+ meta: {
751
+ ip: id?.sourceIp ?? null,
752
+ user: id?.username ?? null,
753
+ info: ctx.info.parentTypeName + '.' + ctx.info.fieldName
754
+ },
755
+ identity: isCognito
756
+ ? {
757
+ userId: id.sub,
758
+ username: id.username,
759
+ groups: id.claims?.['cognito:groups'] ?? [],
760
+ claims: id.claims,
761
+ provider: 'Cognito'
762
+ }
763
+ : id != null
764
+ ? {
765
+ userArn: id.userArn ?? null,
766
+ accountId: id.accountId ?? null,
767
+ username: id.username ?? null,
768
+ provider: 'IAM'
769
+ }
770
+ : null
771
+ }
772
+ };
773
+ }
774
+ ` + resultResponseCode + `
775
+ `;
776
+ }
777
+
778
+ function invokeInboundTranslation(fieldName) {
779
+ return importUtil + `
780
+ export function request(ctx) {
781
+ return {
782
+ operation: 'Invoke',
783
+ payload: {
784
+ __inboundTranslation: true,
785
+ fieldName: '` + fieldName + `',
786
+ arguments: ctx.args
787
+ }
788
+ };
789
+ }
790
+ ` + resultResponseCode + `
791
+ `;
792
+ }
793
+
794
+ function uncapitalize(str) {
795
+ let first = str[0];
796
+ if (first !== undefined) {
797
+ return first.toLowerCase().concat(str.slice(1));
798
+ } else {
799
+ return "";
800
+ }
801
+ }
802
+
803
+ function authorizeIndexedAccess(index, group) {
804
+ let authIdName = uncapitalize(group) + "Id";
805
+ return importUtil + `
806
+ import { runtime } from '@aws-appsync/utils';
807
+ export function request(ctx) {
808
+ const groups = ctx.identity.claims?.['cognito:groups'] ?? [];
809
+ if (groups.includes('` + group + `')) {
810
+ return { operation: 'GetItem', key: { id: util.dynamodb.toDynamoDB(ctx.args.` + index + `) } };
811
+ }
812
+ return runtime.earlyReturn({ ` + authIdName + `: [ctx.identity.username] });
813
+ }
814
+ export function response(ctx) {
815
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
816
+ if (ctx.result.` + authIdName + ` === ctx.identity.username) return ctx.result;
817
+ return util.unauthorized();
818
+ }
819
+ `;
820
+ }
821
+
822
+ function authorizeIndexedAccessResponse(param) {
823
+ return resultResponseCode;
824
+ }
825
+
826
+ function resolveIdResult(tableName, idField) {
827
+ return `
828
+ export function response(ctx) {
829
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
830
+ if (ctx.source.` + idField + `) return ctx.result.data['` + tableName + `'][0] ?? null;
831
+ return null;
832
+ }
833
+ `;
834
+ }
835
+
836
+ function resolveIdResults(tableName, idField) {
837
+ return `
838
+ export function response(ctx) {
839
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
840
+ if (ctx.source.` + idField + `) return ctx.result.data['` + tableName + `'] ?? null;
841
+ return null;
842
+ }
843
+ `;
844
+ }
845
+
846
+ function resolveIdsResult(tableName, idsField) {
847
+ return `
848
+ export function response(ctx) {
849
+ if (ctx.error) util.error(ctx.error.message, ctx.error.type);
850
+ const idList = ctx.source.` + idsField + `;
851
+ return (idList && idList.length > 0) ? ctx.result.data['` + tableName + `'] : [];
852
+ }
853
+ `;
854
+ }
855
+
856
+ let authorizeIndexedAccessRequest = authorizeIndexedAccess;
857
+
858
+ let result = resultResponseCode;
859
+
860
+ let firstResult = firstResultResponseCode;
861
+
862
+ let resultList = resultListResponseCode;
863
+
864
+ let $$null = `
865
+ export function response(ctx) { return null; }
866
+ `;
867
+
868
+ export {
869
+ resultResponseCode,
870
+ firstResultResponseCode,
871
+ resultListResponseCode,
872
+ importUtil,
873
+ pipelinePassThrough,
874
+ nodeDecodeGlobalId,
875
+ nodeGetItemForType,
876
+ getItemById,
877
+ queryById,
878
+ queryItemsWithSortConditions,
879
+ queryByIdSort,
880
+ queryByIndex,
881
+ queryByIndexDeletable,
882
+ queryByIndexSort,
883
+ queryByIndexFiltered,
884
+ queryByIndexSortFiltered,
885
+ listAllItems,
886
+ listAllItemsConnection,
887
+ resolveId,
888
+ resolveIdSort,
889
+ resolveIdSortArgument,
890
+ resolveIdByIndex,
891
+ resolveIdByIndexSort,
892
+ resolveIdByIndexSortArgument,
893
+ resolveIds,
894
+ batchGetItemsByIds,
895
+ putItem,
896
+ addItemToList,
897
+ deleteItem,
898
+ invokeCommandGenerator,
899
+ invokeDcbMutation,
900
+ invokeInboundTranslation,
901
+ uncapitalize,
902
+ authorizeIndexedAccess,
903
+ authorizeIndexedAccessRequest,
904
+ authorizeIndexedAccessResponse,
905
+ result,
906
+ firstResult,
907
+ resultList,
908
+ resolveIdResult,
909
+ resolveIdResults,
910
+ resolveIdsResult,
911
+ $$null,
912
+ }
913
+ /* No side effect */