@aws-amplify/graphql-model-transformer 1.3.3-alpha.9 → 1.3.3-cb-test-beta.0

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 (58) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/lib/rds-lambda.zip +0 -0
  3. package/package.json +6 -6
  4. package/rds-lambda/node_modules/.package-lock.json +207 -207
  5. package/rds-lambda/node_modules/@aws-sdk/client-ssm/package.json +14 -14
  6. package/rds-lambda/node_modules/@aws-sdk/client-sso/package.json +11 -11
  7. package/rds-lambda/node_modules/@aws-sdk/client-sso-oidc/package.json +11 -11
  8. package/rds-lambda/node_modules/@aws-sdk/client-sts/package.json +14 -14
  9. package/rds-lambda/node_modules/@aws-sdk/config-resolver/package.json +2 -2
  10. package/rds-lambda/node_modules/@aws-sdk/credential-provider-env/package.json +2 -2
  11. package/rds-lambda/node_modules/@aws-sdk/credential-provider-imds/package.json +3 -3
  12. package/rds-lambda/node_modules/@aws-sdk/credential-provider-ini/package.json +8 -8
  13. package/rds-lambda/node_modules/@aws-sdk/credential-provider-node/package.json +9 -9
  14. package/rds-lambda/node_modules/@aws-sdk/credential-provider-process/package.json +3 -3
  15. package/rds-lambda/node_modules/@aws-sdk/credential-provider-sso/package.json +5 -5
  16. package/rds-lambda/node_modules/@aws-sdk/credential-provider-web-identity/package.json +2 -2
  17. package/rds-lambda/node_modules/@aws-sdk/fetch-http-handler/package.json +1 -1
  18. package/rds-lambda/node_modules/@aws-sdk/middleware-retry/package.json +2 -2
  19. package/rds-lambda/node_modules/@aws-sdk/middleware-sdk-sts/package.json +2 -2
  20. package/rds-lambda/node_modules/@aws-sdk/middleware-signing/package.json +3 -3
  21. package/rds-lambda/node_modules/@aws-sdk/middleware-user-agent/package.json +2 -2
  22. package/rds-lambda/node_modules/@aws-sdk/node-config-provider/package.json +3 -3
  23. package/rds-lambda/node_modules/@aws-sdk/node-http-handler/package.json +1 -1
  24. package/rds-lambda/node_modules/@aws-sdk/property-provider/package.json +1 -1
  25. package/rds-lambda/node_modules/@aws-sdk/shared-ini-file-loader/package.json +1 -1
  26. package/rds-lambda/node_modules/@aws-sdk/signature-v4/package.json +1 -1
  27. package/rds-lambda/node_modules/@aws-sdk/token-providers/package.json +4 -4
  28. package/rds-lambda/node_modules/@aws-sdk/util-defaults-mode-browser/package.json +2 -2
  29. package/rds-lambda/node_modules/@aws-sdk/util-defaults-mode-node/package.json +5 -5
  30. package/rds-lambda/node_modules/@aws-sdk/util-endpoints/dist-cjs/lib/aws/partitions.json +11 -0
  31. package/rds-lambda/node_modules/@aws-sdk/util-endpoints/dist-es/lib/aws/partitions.json +11 -0
  32. package/rds-lambda/node_modules/@aws-sdk/util-endpoints/package.json +1 -1
  33. package/rds-lambda/node_modules/@aws-sdk/util-user-agent-node/package.json +2 -2
  34. package/rds-lambda/node_modules/@sinonjs/fake-timers/README.md +1 -4
  35. package/rds-lambda/node_modules/@sinonjs/fake-timers/package.json +1 -1
  36. package/rds-lambda/node_modules/@smithy/protocol-http/package.json +3 -2
  37. package/rds-lambda/node_modules/@smithy/types/package.json +7 -2
  38. package/rds-lambda/node_modules/@types/node/README.md +1 -1
  39. package/rds-lambda/node_modules/@types/node/package.json +2 -2
  40. package/rds-lambda/node_modules/browserslist/package.json +3 -3
  41. package/rds-lambda/node_modules/caniuse-lite/package.json +1 -1
  42. package/rds-lambda/node_modules/cjs-module-lexer/LICENSE +10 -10
  43. package/rds-lambda/node_modules/cjs-module-lexer/README.md +461 -453
  44. package/rds-lambda/node_modules/cjs-module-lexer/dist/lexer.mjs +1 -1
  45. package/rds-lambda/node_modules/cjs-module-lexer/package.json +45 -43
  46. package/rds-lambda/node_modules/electron-to-chromium/full-chromium-versions.json +1 -1
  47. package/rds-lambda/node_modules/electron-to-chromium/full-versions.json +1 -1
  48. package/rds-lambda/node_modules/electron-to-chromium/package.json +1 -1
  49. package/rds-lambda/node_modules/jest-snapshot/node_modules/semver/package.json +4 -4
  50. package/rds-lambda/node_modules/pirates/package.json +6 -6
  51. package/rds-lambda/node_modules/ts-jest/node_modules/semver/package.json +4 -4
  52. package/rds-lambda/package-lock.json +207 -207
  53. package/src/__tests__/__snapshots__/model-transformer-override.test.ts.snap +4620 -0
  54. package/src/__tests__/model-transformer-override.test.ts +73 -0
  55. package/src/__tests__/model-transformer.test.ts +2 -0
  56. package/src/__tests__/overrides/build/override.js +16 -0
  57. package/tsconfig.tsbuildinfo +1 -1
  58. package/rds-lambda/node_modules/cjs-module-lexer/CHANGELOG.md +0 -40
@@ -0,0 +1,4620 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`ModelTransformer: should not override model objects when override file does not exist 1`] = `
4
+ Object {
5
+ "Conditions": Object {
6
+ "HasEnvironmentParameter": Object {
7
+ "Fn::Not": Array [
8
+ Object {
9
+ "Fn::Equals": Array [
10
+ Object {
11
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
12
+ },
13
+ "NONE",
14
+ ],
15
+ },
16
+ ],
17
+ },
18
+ "ShouldUsePayPerRequestBilling": Object {
19
+ "Fn::Equals": Array [
20
+ Object {
21
+ "Ref": "DynamoDBBillingMode",
22
+ },
23
+ "PAY_PER_REQUEST",
24
+ ],
25
+ },
26
+ "ShouldUsePointInTimeRecovery": Object {
27
+ "Fn::Equals": Array [
28
+ Object {
29
+ "Ref": "DynamoDBEnablePointInTimeRecovery",
30
+ },
31
+ "true",
32
+ ],
33
+ },
34
+ "ShouldUseServerSideEncryption": Object {
35
+ "Fn::Equals": Array [
36
+ Object {
37
+ "Ref": "DynamoDBEnableServerSideEncryption",
38
+ },
39
+ "true",
40
+ ],
41
+ },
42
+ },
43
+ "Outputs": Object {
44
+ "GetAttPostDataSourceName": Object {
45
+ "Description": "Your model DataSource name.",
46
+ "Export": Object {
47
+ "Name": Object {
48
+ "Fn::Join": Array [
49
+ ":",
50
+ Array [
51
+ Object {
52
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
53
+ },
54
+ "GetAtt:PostDataSource:Name",
55
+ ],
56
+ ],
57
+ },
58
+ },
59
+ "Value": Object {
60
+ "Fn::GetAtt": Array [
61
+ "PostDataSource",
62
+ "Name",
63
+ ],
64
+ },
65
+ },
66
+ "GetAttPostTableName": Object {
67
+ "Description": "Your DynamoDB table name.",
68
+ "Export": Object {
69
+ "Name": Object {
70
+ "Fn::Join": Array [
71
+ ":",
72
+ Array [
73
+ Object {
74
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
75
+ },
76
+ "GetAtt:PostTable:Name",
77
+ ],
78
+ ],
79
+ },
80
+ },
81
+ "Value": Object {
82
+ "Ref": "PostTable",
83
+ },
84
+ },
85
+ "GetAttPostTableStreamArn": Object {
86
+ "Description": "Your DynamoDB table StreamArn.",
87
+ "Export": Object {
88
+ "Name": Object {
89
+ "Fn::Join": Array [
90
+ ":",
91
+ Array [
92
+ Object {
93
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
94
+ },
95
+ "GetAtt:PostTable:StreamArn",
96
+ ],
97
+ ],
98
+ },
99
+ },
100
+ "Value": Object {
101
+ "Fn::GetAtt": Array [
102
+ "PostTable",
103
+ "StreamArn",
104
+ ],
105
+ },
106
+ },
107
+ "transformerrootstackPostMutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunctionB82DB57BFunctionId": Object {
108
+ "Value": Object {
109
+ "Fn::GetAtt": Array [
110
+ "MutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunction9E444A7F",
111
+ "FunctionId",
112
+ ],
113
+ },
114
+ },
115
+ "transformerrootstackPostMutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunction148F70DDFunctionId": Object {
116
+ "Value": Object {
117
+ "Fn::GetAtt": Array [
118
+ "MutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunctionBAC7D532",
119
+ "FunctionId",
120
+ ],
121
+ },
122
+ },
123
+ "transformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId": Object {
124
+ "Value": Object {
125
+ "Fn::GetAtt": Array [
126
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
127
+ "FunctionId",
128
+ ],
129
+ },
130
+ },
131
+ "transformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId": Object {
132
+ "Value": Object {
133
+ "Fn::GetAtt": Array [
134
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868",
135
+ "FunctionId",
136
+ ],
137
+ },
138
+ },
139
+ },
140
+ "Parameters": Object {
141
+ "DynamoDBBillingMode": Object {
142
+ "AllowedValues": Array [
143
+ "PAY_PER_REQUEST",
144
+ "PROVISIONED",
145
+ ],
146
+ "Default": "PAY_PER_REQUEST",
147
+ "Description": "Configure @model types to create DynamoDB tables with PAY_PER_REQUEST or PROVISIONED billing modes.",
148
+ "Type": "String",
149
+ },
150
+ "DynamoDBEnablePointInTimeRecovery": Object {
151
+ "AllowedValues": Array [
152
+ "true",
153
+ "false",
154
+ ],
155
+ "Default": "false",
156
+ "Description": "Whether to enable Point in Time Recovery on the table.",
157
+ "Type": "String",
158
+ },
159
+ "DynamoDBEnableServerSideEncryption": Object {
160
+ "AllowedValues": Array [
161
+ "true",
162
+ "false",
163
+ ],
164
+ "Default": "true",
165
+ "Description": "Enable server side encryption powered by KMS.",
166
+ "Type": "String",
167
+ },
168
+ "DynamoDBModelTableReadIOPS": Object {
169
+ "Default": 5,
170
+ "Description": "The number of read IOPS the table should support.",
171
+ "Type": "Number",
172
+ },
173
+ "DynamoDBModelTableWriteIOPS": Object {
174
+ "Default": 5,
175
+ "Description": "The number of write IOPS the table should support.",
176
+ "Type": "Number",
177
+ },
178
+ "referencetotransformerrootstackGraphQLAPI20497F53ApiId": Object {
179
+ "Type": "String",
180
+ },
181
+ "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name": Object {
182
+ "Type": "String",
183
+ },
184
+ "referencetotransformerrootstackS3DeploymentBucket7592718ARef": Object {
185
+ "Type": "String",
186
+ },
187
+ "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref": Object {
188
+ "Type": "String",
189
+ },
190
+ "referencetotransformerrootstackenv10C5A902Ref": Object {
191
+ "Type": "String",
192
+ },
193
+ },
194
+ "Resources": Object {
195
+ "CreatePostResolver": Object {
196
+ "Properties": Object {
197
+ "ApiId": Object {
198
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
199
+ },
200
+ "FieldName": "createPost",
201
+ "Kind": "PIPELINE",
202
+ "PipelineConfig": Object {
203
+ "Functions": Array [
204
+ Object {
205
+ "Fn::GetAtt": Array [
206
+ "MutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunction9E444A7F",
207
+ "FunctionId",
208
+ ],
209
+ },
210
+ Object {
211
+ "Fn::GetAtt": Array [
212
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
213
+ "FunctionId",
214
+ ],
215
+ },
216
+ Object {
217
+ "Fn::GetAtt": Array [
218
+ "MutationCreatePostDataResolverFnMutationCreatePostDataResolverFnAppSyncFunctionE45E2000",
219
+ "FunctionId",
220
+ ],
221
+ },
222
+ ],
223
+ },
224
+ "RequestMappingTemplate": Object {
225
+ "Fn::Join": Array [
226
+ "",
227
+ Array [
228
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
229
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"createPost\\"))
230
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
231
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
232
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
233
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
234
+ Object {
235
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
236
+ },
237
+ "\\"))
238
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
239
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
240
+ Object {
241
+ "Ref": "PostTable",
242
+ },
243
+ "\\"))
244
+ $util.toJson({})",
245
+ ],
246
+ ],
247
+ },
248
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
249
+ "TypeName": "Mutation",
250
+ },
251
+ "Type": "AWS::AppSync::Resolver",
252
+ },
253
+ "DeletePostResolver": Object {
254
+ "Properties": Object {
255
+ "ApiId": Object {
256
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
257
+ },
258
+ "FieldName": "deletePost",
259
+ "Kind": "PIPELINE",
260
+ "PipelineConfig": Object {
261
+ "Functions": Array [
262
+ Object {
263
+ "Fn::GetAtt": Array [
264
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
265
+ "FunctionId",
266
+ ],
267
+ },
268
+ Object {
269
+ "Fn::GetAtt": Array [
270
+ "MutationDeletePostDataResolverFnMutationDeletePostDataResolverFnAppSyncFunction45B37C12",
271
+ "FunctionId",
272
+ ],
273
+ },
274
+ ],
275
+ },
276
+ "RequestMappingTemplate": Object {
277
+ "Fn::Join": Array [
278
+ "",
279
+ Array [
280
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
281
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"deletePost\\"))
282
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
283
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
284
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
285
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
286
+ Object {
287
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
288
+ },
289
+ "\\"))
290
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
291
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
292
+ Object {
293
+ "Ref": "PostTable",
294
+ },
295
+ "\\"))
296
+ $util.toJson({})",
297
+ ],
298
+ ],
299
+ },
300
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
301
+ "TypeName": "Mutation",
302
+ },
303
+ "Type": "AWS::AppSync::Resolver",
304
+ },
305
+ "DynamoDBAccess71ABE5AE": Object {
306
+ "Properties": Object {
307
+ "PolicyDocument": Object {
308
+ "Statement": Array [
309
+ Object {
310
+ "Action": Array [
311
+ "dynamodb:BatchGetItem",
312
+ "dynamodb:BatchWriteItem",
313
+ "dynamodb:PutItem",
314
+ "dynamodb:DeleteItem",
315
+ "dynamodb:GetItem",
316
+ "dynamodb:Scan",
317
+ "dynamodb:Query",
318
+ "dynamodb:UpdateItem",
319
+ ],
320
+ "Effect": "Allow",
321
+ "Resource": Array [
322
+ Object {
323
+ "Fn::Sub": Array [
324
+ "arn:aws:dynamodb:\${AWS::Region}:\${AWS::AccountId}:table/\${tablename}",
325
+ Object {
326
+ "tablename": Object {
327
+ "Fn::Join": Array [
328
+ "",
329
+ Array [
330
+ "Post-",
331
+ Object {
332
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
333
+ },
334
+ "-",
335
+ Object {
336
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
337
+ },
338
+ ],
339
+ ],
340
+ },
341
+ },
342
+ ],
343
+ },
344
+ Object {
345
+ "Fn::Sub": Array [
346
+ "arn:aws:dynamodb:\${AWS::Region}:\${AWS::AccountId}:table/\${tablename}/*",
347
+ Object {
348
+ "tablename": Object {
349
+ "Fn::Join": Array [
350
+ "",
351
+ Array [
352
+ "Post-",
353
+ Object {
354
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
355
+ },
356
+ "-",
357
+ Object {
358
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
359
+ },
360
+ ],
361
+ ],
362
+ },
363
+ },
364
+ ],
365
+ },
366
+ ],
367
+ },
368
+ ],
369
+ "Version": "2012-10-17",
370
+ },
371
+ "PolicyName": "DynamoDBAccess71ABE5AE",
372
+ "Roles": Array [
373
+ Object {
374
+ "Ref": "PostIAMRole83BF708F",
375
+ },
376
+ ],
377
+ },
378
+ "Type": "AWS::IAM::Policy",
379
+ },
380
+ "GetPostResolver": Object {
381
+ "Properties": Object {
382
+ "ApiId": Object {
383
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
384
+ },
385
+ "FieldName": "getPost",
386
+ "Kind": "PIPELINE",
387
+ "PipelineConfig": Object {
388
+ "Functions": Array [
389
+ Object {
390
+ "Fn::GetAtt": Array [
391
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
392
+ "FunctionId",
393
+ ],
394
+ },
395
+ Object {
396
+ "Fn::GetAtt": Array [
397
+ "QueryGetPostDataResolverFnQueryGetPostDataResolverFnAppSyncFunction06724190",
398
+ "FunctionId",
399
+ ],
400
+ },
401
+ ],
402
+ },
403
+ "RequestMappingTemplate": Object {
404
+ "Fn::Join": Array [
405
+ "",
406
+ Array [
407
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Query\\"))
408
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"getPost\\"))
409
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
410
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
411
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
412
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
413
+ Object {
414
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
415
+ },
416
+ "\\"))
417
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
418
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
419
+ Object {
420
+ "Ref": "PostTable",
421
+ },
422
+ "\\"))
423
+ $util.toJson({})",
424
+ ],
425
+ ],
426
+ },
427
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
428
+ "TypeName": "Query",
429
+ },
430
+ "Type": "AWS::AppSync::Resolver",
431
+ },
432
+ "ListPostResolver": Object {
433
+ "Properties": Object {
434
+ "ApiId": Object {
435
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
436
+ },
437
+ "FieldName": "listPosts",
438
+ "Kind": "PIPELINE",
439
+ "PipelineConfig": Object {
440
+ "Functions": Array [
441
+ Object {
442
+ "Fn::GetAtt": Array [
443
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
444
+ "FunctionId",
445
+ ],
446
+ },
447
+ Object {
448
+ "Fn::GetAtt": Array [
449
+ "QueryListPostsDataResolverFnQueryListPostsDataResolverFnAppSyncFunction3D526AB7",
450
+ "FunctionId",
451
+ ],
452
+ },
453
+ ],
454
+ },
455
+ "RequestMappingTemplate": Object {
456
+ "Fn::Join": Array [
457
+ "",
458
+ Array [
459
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Query\\"))
460
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"listPosts\\"))
461
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
462
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
463
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
464
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
465
+ Object {
466
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
467
+ },
468
+ "\\"))
469
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
470
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
471
+ Object {
472
+ "Ref": "PostTable",
473
+ },
474
+ "\\"))
475
+ $util.toJson({})",
476
+ ],
477
+ ],
478
+ },
479
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
480
+ "TypeName": "Query",
481
+ },
482
+ "Type": "AWS::AppSync::Resolver",
483
+ },
484
+ "MutationCreatePostDataResolverFnMutationCreatePostDataResolverFnAppSyncFunctionE45E2000": Object {
485
+ "DependsOn": Array [
486
+ "PostDataSource",
487
+ ],
488
+ "Properties": Object {
489
+ "ApiId": Object {
490
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
491
+ },
492
+ "DataSourceName": Object {
493
+ "Fn::GetAtt": Array [
494
+ "PostDataSource",
495
+ "Name",
496
+ ],
497
+ },
498
+ "FunctionVersion": "2018-05-29",
499
+ "Name": "MutationCreatePostDataResolverFn",
500
+ "RequestMappingTemplateS3Location": Object {
501
+ "Fn::Join": Array [
502
+ "",
503
+ Array [
504
+ "s3://",
505
+ Object {
506
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
507
+ },
508
+ "/",
509
+ Object {
510
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
511
+ },
512
+ "/resolvers/Mutation.createPost.req.vtl",
513
+ ],
514
+ ],
515
+ },
516
+ "ResponseMappingTemplateS3Location": Object {
517
+ "Fn::Join": Array [
518
+ "",
519
+ Array [
520
+ "s3://",
521
+ Object {
522
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
523
+ },
524
+ "/",
525
+ Object {
526
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
527
+ },
528
+ "/resolvers/Mutation.createPost.res.vtl",
529
+ ],
530
+ ],
531
+ },
532
+ },
533
+ "Type": "AWS::AppSync::FunctionConfiguration",
534
+ },
535
+ "MutationDeletePostDataResolverFnMutationDeletePostDataResolverFnAppSyncFunction45B37C12": Object {
536
+ "DependsOn": Array [
537
+ "PostDataSource",
538
+ ],
539
+ "Properties": Object {
540
+ "ApiId": Object {
541
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
542
+ },
543
+ "DataSourceName": Object {
544
+ "Fn::GetAtt": Array [
545
+ "PostDataSource",
546
+ "Name",
547
+ ],
548
+ },
549
+ "FunctionVersion": "2018-05-29",
550
+ "Name": "MutationDeletePostDataResolverFn",
551
+ "RequestMappingTemplateS3Location": Object {
552
+ "Fn::Join": Array [
553
+ "",
554
+ Array [
555
+ "s3://",
556
+ Object {
557
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
558
+ },
559
+ "/",
560
+ Object {
561
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
562
+ },
563
+ "/resolvers/Mutation.deletePost.req.vtl",
564
+ ],
565
+ ],
566
+ },
567
+ "ResponseMappingTemplateS3Location": Object {
568
+ "Fn::Join": Array [
569
+ "",
570
+ Array [
571
+ "s3://",
572
+ Object {
573
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
574
+ },
575
+ "/",
576
+ Object {
577
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
578
+ },
579
+ "/resolvers/Mutation.deletePost.res.vtl",
580
+ ],
581
+ ],
582
+ },
583
+ },
584
+ "Type": "AWS::AppSync::FunctionConfiguration",
585
+ },
586
+ "MutationUpdatePostDataResolverFnMutationUpdatePostDataResolverFnAppSyncFunctionBF7D410D": Object {
587
+ "DependsOn": Array [
588
+ "PostDataSource",
589
+ ],
590
+ "Properties": Object {
591
+ "ApiId": Object {
592
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
593
+ },
594
+ "DataSourceName": Object {
595
+ "Fn::GetAtt": Array [
596
+ "PostDataSource",
597
+ "Name",
598
+ ],
599
+ },
600
+ "FunctionVersion": "2018-05-29",
601
+ "Name": "MutationUpdatePostDataResolverFn",
602
+ "RequestMappingTemplateS3Location": Object {
603
+ "Fn::Join": Array [
604
+ "",
605
+ Array [
606
+ "s3://",
607
+ Object {
608
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
609
+ },
610
+ "/",
611
+ Object {
612
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
613
+ },
614
+ "/resolvers/Mutation.updatePost.req.vtl",
615
+ ],
616
+ ],
617
+ },
618
+ "ResponseMappingTemplateS3Location": Object {
619
+ "Fn::Join": Array [
620
+ "",
621
+ Array [
622
+ "s3://",
623
+ Object {
624
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
625
+ },
626
+ "/",
627
+ Object {
628
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
629
+ },
630
+ "/resolvers/Mutation.updatePost.res.vtl",
631
+ ],
632
+ ],
633
+ },
634
+ },
635
+ "Type": "AWS::AppSync::FunctionConfiguration",
636
+ },
637
+ "MutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunction9E444A7F": Object {
638
+ "Properties": Object {
639
+ "ApiId": Object {
640
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
641
+ },
642
+ "DataSourceName": Object {
643
+ "Ref": "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name",
644
+ },
645
+ "FunctionVersion": "2018-05-29",
646
+ "Name": "MutationcreatePostinit0Function",
647
+ "RequestMappingTemplateS3Location": Object {
648
+ "Fn::Join": Array [
649
+ "",
650
+ Array [
651
+ "s3://",
652
+ Object {
653
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
654
+ },
655
+ "/",
656
+ Object {
657
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
658
+ },
659
+ "/resolvers/Mutation.createPost.init.1.req.vtl",
660
+ ],
661
+ ],
662
+ },
663
+ "ResponseMappingTemplate": "$util.toJson({})",
664
+ },
665
+ "Type": "AWS::AppSync::FunctionConfiguration",
666
+ },
667
+ "MutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunctionBAC7D532": Object {
668
+ "Properties": Object {
669
+ "ApiId": Object {
670
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
671
+ },
672
+ "DataSourceName": Object {
673
+ "Ref": "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name",
674
+ },
675
+ "FunctionVersion": "2018-05-29",
676
+ "Name": "MutationupdatePostinit0Function",
677
+ "RequestMappingTemplateS3Location": Object {
678
+ "Fn::Join": Array [
679
+ "",
680
+ Array [
681
+ "s3://",
682
+ Object {
683
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
684
+ },
685
+ "/",
686
+ Object {
687
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
688
+ },
689
+ "/resolvers/Mutation.updatePost.init.1.req.vtl",
690
+ ],
691
+ ],
692
+ },
693
+ "ResponseMappingTemplate": "$util.toJson({})",
694
+ },
695
+ "Type": "AWS::AppSync::FunctionConfiguration",
696
+ },
697
+ "PostDataSource": Object {
698
+ "DependsOn": Array [
699
+ "PostIAMRole83BF708F",
700
+ ],
701
+ "Properties": Object {
702
+ "ApiId": Object {
703
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
704
+ },
705
+ "DynamoDBConfig": Object {
706
+ "AwsRegion": Object {
707
+ "Ref": "AWS::Region",
708
+ },
709
+ "TableName": Object {
710
+ "Ref": "PostTable",
711
+ },
712
+ },
713
+ "Name": "PostTable",
714
+ "ServiceRoleArn": Object {
715
+ "Fn::GetAtt": Array [
716
+ "PostIAMRole83BF708F",
717
+ "Arn",
718
+ ],
719
+ },
720
+ "Type": "AMAZON_DYNAMODB",
721
+ },
722
+ "Type": "AWS::AppSync::DataSource",
723
+ },
724
+ "PostIAMRole83BF708F": Object {
725
+ "Properties": Object {
726
+ "AssumeRolePolicyDocument": Object {
727
+ "Statement": Array [
728
+ Object {
729
+ "Action": "sts:AssumeRole",
730
+ "Effect": "Allow",
731
+ "Principal": Object {
732
+ "Service": "appsync.amazonaws.com",
733
+ },
734
+ },
735
+ ],
736
+ "Version": "2012-10-17",
737
+ },
738
+ "RoleName": Object {
739
+ "Fn::Join": Array [
740
+ "",
741
+ Array [
742
+ "PostIAMRolebbce9b-",
743
+ Object {
744
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
745
+ },
746
+ "-",
747
+ Object {
748
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
749
+ },
750
+ ],
751
+ ],
752
+ },
753
+ },
754
+ "Type": "AWS::IAM::Role",
755
+ },
756
+ "PostIAMRoleDefaultPolicy04190CA0": Object {
757
+ "Properties": Object {
758
+ "PolicyDocument": Object {
759
+ "Statement": Array [
760
+ Object {
761
+ "Action": Array [
762
+ "dynamodb:BatchGetItem",
763
+ "dynamodb:GetRecords",
764
+ "dynamodb:GetShardIterator",
765
+ "dynamodb:Query",
766
+ "dynamodb:GetItem",
767
+ "dynamodb:Scan",
768
+ "dynamodb:ConditionCheckItem",
769
+ "dynamodb:BatchWriteItem",
770
+ "dynamodb:PutItem",
771
+ "dynamodb:UpdateItem",
772
+ "dynamodb:DeleteItem",
773
+ "dynamodb:DescribeTable",
774
+ ],
775
+ "Effect": "Allow",
776
+ "Resource": Array [
777
+ Object {
778
+ "Fn::GetAtt": Array [
779
+ "PostTable",
780
+ "Arn",
781
+ ],
782
+ },
783
+ Object {
784
+ "Ref": "AWS::NoValue",
785
+ },
786
+ ],
787
+ },
788
+ ],
789
+ "Version": "2012-10-17",
790
+ },
791
+ "PolicyName": "PostIAMRoleDefaultPolicy04190CA0",
792
+ "Roles": Array [
793
+ Object {
794
+ "Ref": "PostIAMRole83BF708F",
795
+ },
796
+ ],
797
+ },
798
+ "Type": "AWS::IAM::Policy",
799
+ },
800
+ "PostTable": Object {
801
+ "DeletionPolicy": "Delete",
802
+ "Properties": Object {
803
+ "AttributeDefinitions": Array [
804
+ Object {
805
+ "AttributeName": "id",
806
+ "AttributeType": "S",
807
+ },
808
+ ],
809
+ "BillingMode": Object {
810
+ "Fn::If": Array [
811
+ "ShouldUsePayPerRequestBilling",
812
+ "PAY_PER_REQUEST",
813
+ Object {
814
+ "Ref": "AWS::NoValue",
815
+ },
816
+ ],
817
+ },
818
+ "KeySchema": Array [
819
+ Object {
820
+ "AttributeName": "id",
821
+ "KeyType": "HASH",
822
+ },
823
+ ],
824
+ "PointInTimeRecoverySpecification": Object {
825
+ "Fn::If": Array [
826
+ "ShouldUsePointInTimeRecovery",
827
+ Object {
828
+ "PointInTimeRecoveryEnabled": true,
829
+ },
830
+ Object {
831
+ "Ref": "AWS::NoValue",
832
+ },
833
+ ],
834
+ },
835
+ "ProvisionedThroughput": Object {
836
+ "Fn::If": Array [
837
+ "ShouldUsePayPerRequestBilling",
838
+ Object {
839
+ "Ref": "AWS::NoValue",
840
+ },
841
+ Object {
842
+ "ReadCapacityUnits": Object {
843
+ "Ref": "DynamoDBModelTableReadIOPS",
844
+ },
845
+ "WriteCapacityUnits": Object {
846
+ "Ref": "DynamoDBModelTableWriteIOPS",
847
+ },
848
+ },
849
+ ],
850
+ },
851
+ "SSESpecification": Object {
852
+ "SSEEnabled": Object {
853
+ "Fn::If": Array [
854
+ "ShouldUseServerSideEncryption",
855
+ true,
856
+ false,
857
+ ],
858
+ },
859
+ },
860
+ "StreamSpecification": Object {
861
+ "StreamViewType": "NEW_AND_OLD_IMAGES",
862
+ },
863
+ "TableName": Object {
864
+ "Fn::Join": Array [
865
+ "",
866
+ Array [
867
+ "Post-",
868
+ Object {
869
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
870
+ },
871
+ "-",
872
+ Object {
873
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
874
+ },
875
+ ],
876
+ ],
877
+ },
878
+ },
879
+ "Type": "AWS::DynamoDB::Table",
880
+ "UpdateReplacePolicy": "Delete",
881
+ },
882
+ "QueryGetPostDataResolverFnQueryGetPostDataResolverFnAppSyncFunction06724190": Object {
883
+ "DependsOn": Array [
884
+ "PostDataSource",
885
+ ],
886
+ "Properties": Object {
887
+ "ApiId": Object {
888
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
889
+ },
890
+ "DataSourceName": Object {
891
+ "Fn::GetAtt": Array [
892
+ "PostDataSource",
893
+ "Name",
894
+ ],
895
+ },
896
+ "FunctionVersion": "2018-05-29",
897
+ "Name": "QueryGetPostDataResolverFn",
898
+ "RequestMappingTemplateS3Location": Object {
899
+ "Fn::Join": Array [
900
+ "",
901
+ Array [
902
+ "s3://",
903
+ Object {
904
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
905
+ },
906
+ "/",
907
+ Object {
908
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
909
+ },
910
+ "/resolvers/Query.getPost.req.vtl",
911
+ ],
912
+ ],
913
+ },
914
+ "ResponseMappingTemplateS3Location": Object {
915
+ "Fn::Join": Array [
916
+ "",
917
+ Array [
918
+ "s3://",
919
+ Object {
920
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
921
+ },
922
+ "/",
923
+ Object {
924
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
925
+ },
926
+ "/resolvers/Query.getPost.res.vtl",
927
+ ],
928
+ ],
929
+ },
930
+ },
931
+ "Type": "AWS::AppSync::FunctionConfiguration",
932
+ },
933
+ "QueryListPostsDataResolverFnQueryListPostsDataResolverFnAppSyncFunction3D526AB7": Object {
934
+ "DependsOn": Array [
935
+ "PostDataSource",
936
+ ],
937
+ "Properties": Object {
938
+ "ApiId": Object {
939
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
940
+ },
941
+ "DataSourceName": Object {
942
+ "Fn::GetAtt": Array [
943
+ "PostDataSource",
944
+ "Name",
945
+ ],
946
+ },
947
+ "FunctionVersion": "2018-05-29",
948
+ "Name": "QueryListPostsDataResolverFn",
949
+ "RequestMappingTemplateS3Location": Object {
950
+ "Fn::Join": Array [
951
+ "",
952
+ Array [
953
+ "s3://",
954
+ Object {
955
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
956
+ },
957
+ "/",
958
+ Object {
959
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
960
+ },
961
+ "/resolvers/Query.listPosts.req.vtl",
962
+ ],
963
+ ],
964
+ },
965
+ "ResponseMappingTemplateS3Location": Object {
966
+ "Fn::Join": Array [
967
+ "",
968
+ Array [
969
+ "s3://",
970
+ Object {
971
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
972
+ },
973
+ "/",
974
+ Object {
975
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
976
+ },
977
+ "/resolvers/Query.listPosts.res.vtl",
978
+ ],
979
+ ],
980
+ },
981
+ },
982
+ "Type": "AWS::AppSync::FunctionConfiguration",
983
+ },
984
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F": Object {
985
+ "Properties": Object {
986
+ "ApiId": Object {
987
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
988
+ },
989
+ "DataSourceName": Object {
990
+ "Ref": "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name",
991
+ },
992
+ "FunctionVersion": "2018-05-29",
993
+ "Name": "QuerygetPostpostAuth0Function",
994
+ "RequestMappingTemplateS3Location": Object {
995
+ "Fn::Join": Array [
996
+ "",
997
+ Array [
998
+ "s3://",
999
+ Object {
1000
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
1001
+ },
1002
+ "/",
1003
+ Object {
1004
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
1005
+ },
1006
+ "/resolvers/Query.getPost.postAuth.1.req.vtl",
1007
+ ],
1008
+ ],
1009
+ },
1010
+ "ResponseMappingTemplate": "$util.toJson({})",
1011
+ },
1012
+ "Type": "AWS::AppSync::FunctionConfiguration",
1013
+ },
1014
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868": Object {
1015
+ "Properties": Object {
1016
+ "ApiId": Object {
1017
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1018
+ },
1019
+ "DataSourceName": Object {
1020
+ "Ref": "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name",
1021
+ },
1022
+ "FunctionVersion": "2018-05-29",
1023
+ "Name": "SubscriptionOnCreatePostDataResolverFn",
1024
+ "RequestMappingTemplateS3Location": Object {
1025
+ "Fn::Join": Array [
1026
+ "",
1027
+ Array [
1028
+ "s3://",
1029
+ Object {
1030
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
1031
+ },
1032
+ "/",
1033
+ Object {
1034
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
1035
+ },
1036
+ "/resolvers/Subscription.onCreatePost.req.vtl",
1037
+ ],
1038
+ ],
1039
+ },
1040
+ "ResponseMappingTemplateS3Location": Object {
1041
+ "Fn::Join": Array [
1042
+ "",
1043
+ Array [
1044
+ "s3://",
1045
+ Object {
1046
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
1047
+ },
1048
+ "/",
1049
+ Object {
1050
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
1051
+ },
1052
+ "/resolvers/Subscription.onCreatePost.res.vtl",
1053
+ ],
1054
+ ],
1055
+ },
1056
+ },
1057
+ "Type": "AWS::AppSync::FunctionConfiguration",
1058
+ },
1059
+ "SubscriptiononCreatePostResolver": Object {
1060
+ "Properties": Object {
1061
+ "ApiId": Object {
1062
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1063
+ },
1064
+ "FieldName": "onCreatePost",
1065
+ "Kind": "PIPELINE",
1066
+ "PipelineConfig": Object {
1067
+ "Functions": Array [
1068
+ Object {
1069
+ "Fn::GetAtt": Array [
1070
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
1071
+ "FunctionId",
1072
+ ],
1073
+ },
1074
+ Object {
1075
+ "Fn::GetAtt": Array [
1076
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868",
1077
+ "FunctionId",
1078
+ ],
1079
+ },
1080
+ ],
1081
+ },
1082
+ "RequestMappingTemplate": Object {
1083
+ "Fn::Join": Array [
1084
+ "",
1085
+ Array [
1086
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
1087
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onCreatePost\\"))
1088
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
1089
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
1090
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
1091
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
1092
+ Object {
1093
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1094
+ },
1095
+ "\\"))
1096
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
1097
+
1098
+ $util.toJson({})",
1099
+ ],
1100
+ ],
1101
+ },
1102
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
1103
+ "TypeName": "Subscription",
1104
+ },
1105
+ "Type": "AWS::AppSync::Resolver",
1106
+ },
1107
+ "SubscriptiononDeletePostResolver": Object {
1108
+ "Properties": Object {
1109
+ "ApiId": Object {
1110
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1111
+ },
1112
+ "FieldName": "onDeletePost",
1113
+ "Kind": "PIPELINE",
1114
+ "PipelineConfig": Object {
1115
+ "Functions": Array [
1116
+ Object {
1117
+ "Fn::GetAtt": Array [
1118
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
1119
+ "FunctionId",
1120
+ ],
1121
+ },
1122
+ Object {
1123
+ "Fn::GetAtt": Array [
1124
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868",
1125
+ "FunctionId",
1126
+ ],
1127
+ },
1128
+ ],
1129
+ },
1130
+ "RequestMappingTemplate": Object {
1131
+ "Fn::Join": Array [
1132
+ "",
1133
+ Array [
1134
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
1135
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onDeletePost\\"))
1136
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
1137
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
1138
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
1139
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
1140
+ Object {
1141
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1142
+ },
1143
+ "\\"))
1144
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
1145
+
1146
+ $util.toJson({})",
1147
+ ],
1148
+ ],
1149
+ },
1150
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
1151
+ "TypeName": "Subscription",
1152
+ },
1153
+ "Type": "AWS::AppSync::Resolver",
1154
+ },
1155
+ "SubscriptiononUpdatePostResolver": Object {
1156
+ "Properties": Object {
1157
+ "ApiId": Object {
1158
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1159
+ },
1160
+ "FieldName": "onUpdatePost",
1161
+ "Kind": "PIPELINE",
1162
+ "PipelineConfig": Object {
1163
+ "Functions": Array [
1164
+ Object {
1165
+ "Fn::GetAtt": Array [
1166
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
1167
+ "FunctionId",
1168
+ ],
1169
+ },
1170
+ Object {
1171
+ "Fn::GetAtt": Array [
1172
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868",
1173
+ "FunctionId",
1174
+ ],
1175
+ },
1176
+ ],
1177
+ },
1178
+ "RequestMappingTemplate": Object {
1179
+ "Fn::Join": Array [
1180
+ "",
1181
+ Array [
1182
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
1183
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onUpdatePost\\"))
1184
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
1185
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
1186
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
1187
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
1188
+ Object {
1189
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1190
+ },
1191
+ "\\"))
1192
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
1193
+
1194
+ $util.toJson({})",
1195
+ ],
1196
+ ],
1197
+ },
1198
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
1199
+ "TypeName": "Subscription",
1200
+ },
1201
+ "Type": "AWS::AppSync::Resolver",
1202
+ },
1203
+ "UpdatePostResolver": Object {
1204
+ "Properties": Object {
1205
+ "ApiId": Object {
1206
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1207
+ },
1208
+ "FieldName": "updatePost",
1209
+ "Kind": "PIPELINE",
1210
+ "PipelineConfig": Object {
1211
+ "Functions": Array [
1212
+ Object {
1213
+ "Fn::GetAtt": Array [
1214
+ "MutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunctionBAC7D532",
1215
+ "FunctionId",
1216
+ ],
1217
+ },
1218
+ Object {
1219
+ "Fn::GetAtt": Array [
1220
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
1221
+ "FunctionId",
1222
+ ],
1223
+ },
1224
+ Object {
1225
+ "Fn::GetAtt": Array [
1226
+ "MutationUpdatePostDataResolverFnMutationUpdatePostDataResolverFnAppSyncFunctionBF7D410D",
1227
+ "FunctionId",
1228
+ ],
1229
+ },
1230
+ ],
1231
+ },
1232
+ "RequestMappingTemplate": Object {
1233
+ "Fn::Join": Array [
1234
+ "",
1235
+ Array [
1236
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
1237
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"updatePost\\"))
1238
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
1239
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
1240
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
1241
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
1242
+ Object {
1243
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1244
+ },
1245
+ "\\"))
1246
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
1247
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
1248
+ Object {
1249
+ "Ref": "PostTable",
1250
+ },
1251
+ "\\"))
1252
+ $util.toJson({})",
1253
+ ],
1254
+ ],
1255
+ },
1256
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
1257
+ "TypeName": "Mutation",
1258
+ },
1259
+ "Type": "AWS::AppSync::Resolver",
1260
+ },
1261
+ },
1262
+ }
1263
+ `;
1264
+
1265
+ exports[`ModelTransformer: should not override model objects when override file does not exist 2`] = `
1266
+ Object {
1267
+ "Conditions": Object {
1268
+ "HasEnvironmentParameter": Object {
1269
+ "Fn::Not": Array [
1270
+ Object {
1271
+ "Fn::Equals": Array [
1272
+ Object {
1273
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
1274
+ },
1275
+ "NONE",
1276
+ ],
1277
+ },
1278
+ ],
1279
+ },
1280
+ "ShouldUsePayPerRequestBilling": Object {
1281
+ "Fn::Equals": Array [
1282
+ Object {
1283
+ "Ref": "DynamoDBBillingMode",
1284
+ },
1285
+ "PAY_PER_REQUEST",
1286
+ ],
1287
+ },
1288
+ "ShouldUsePointInTimeRecovery": Object {
1289
+ "Fn::Equals": Array [
1290
+ Object {
1291
+ "Ref": "DynamoDBEnablePointInTimeRecovery",
1292
+ },
1293
+ "true",
1294
+ ],
1295
+ },
1296
+ "ShouldUseServerSideEncryption": Object {
1297
+ "Fn::Equals": Array [
1298
+ Object {
1299
+ "Ref": "DynamoDBEnableServerSideEncryption",
1300
+ },
1301
+ "true",
1302
+ ],
1303
+ },
1304
+ },
1305
+ "Outputs": Object {
1306
+ "GetAttCommentDataSourceName": Object {
1307
+ "Description": "Your model DataSource name.",
1308
+ "Export": Object {
1309
+ "Name": Object {
1310
+ "Fn::Join": Array [
1311
+ ":",
1312
+ Array [
1313
+ Object {
1314
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1315
+ },
1316
+ "GetAtt:CommentDataSource:Name",
1317
+ ],
1318
+ ],
1319
+ },
1320
+ },
1321
+ "Value": Object {
1322
+ "Fn::GetAtt": Array [
1323
+ "CommentDataSource",
1324
+ "Name",
1325
+ ],
1326
+ },
1327
+ },
1328
+ "GetAttCommentTableName": Object {
1329
+ "Description": "Your DynamoDB table name.",
1330
+ "Export": Object {
1331
+ "Name": Object {
1332
+ "Fn::Join": Array [
1333
+ ":",
1334
+ Array [
1335
+ Object {
1336
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1337
+ },
1338
+ "GetAtt:CommentTable:Name",
1339
+ ],
1340
+ ],
1341
+ },
1342
+ },
1343
+ "Value": Object {
1344
+ "Ref": "CommentTable",
1345
+ },
1346
+ },
1347
+ "GetAttCommentTableStreamArn": Object {
1348
+ "Description": "Your DynamoDB table StreamArn.",
1349
+ "Export": Object {
1350
+ "Name": Object {
1351
+ "Fn::Join": Array [
1352
+ ":",
1353
+ Array [
1354
+ Object {
1355
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1356
+ },
1357
+ "GetAtt:CommentTable:StreamArn",
1358
+ ],
1359
+ ],
1360
+ },
1361
+ },
1362
+ "Value": Object {
1363
+ "Fn::GetAtt": Array [
1364
+ "CommentTable",
1365
+ "StreamArn",
1366
+ ],
1367
+ },
1368
+ },
1369
+ },
1370
+ "Parameters": Object {
1371
+ "DynamoDBBillingMode": Object {
1372
+ "AllowedValues": Array [
1373
+ "PAY_PER_REQUEST",
1374
+ "PROVISIONED",
1375
+ ],
1376
+ "Default": "PAY_PER_REQUEST",
1377
+ "Description": "Configure @model types to create DynamoDB tables with PAY_PER_REQUEST or PROVISIONED billing modes.",
1378
+ "Type": "String",
1379
+ },
1380
+ "DynamoDBEnablePointInTimeRecovery": Object {
1381
+ "AllowedValues": Array [
1382
+ "true",
1383
+ "false",
1384
+ ],
1385
+ "Default": "false",
1386
+ "Description": "Whether to enable Point in Time Recovery on the table.",
1387
+ "Type": "String",
1388
+ },
1389
+ "DynamoDBEnableServerSideEncryption": Object {
1390
+ "AllowedValues": Array [
1391
+ "true",
1392
+ "false",
1393
+ ],
1394
+ "Default": "true",
1395
+ "Description": "Enable server side encryption powered by KMS.",
1396
+ "Type": "String",
1397
+ },
1398
+ "DynamoDBModelTableReadIOPS": Object {
1399
+ "Default": 5,
1400
+ "Description": "The number of read IOPS the table should support.",
1401
+ "Type": "Number",
1402
+ },
1403
+ "DynamoDBModelTableWriteIOPS": Object {
1404
+ "Default": 5,
1405
+ "Description": "The number of write IOPS the table should support.",
1406
+ "Type": "Number",
1407
+ },
1408
+ "referencetotransformerrootstackGraphQLAPI20497F53ApiId": Object {
1409
+ "Type": "String",
1410
+ },
1411
+ "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostMutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunctionB82DB57BFunctionId": Object {
1412
+ "Type": "String",
1413
+ },
1414
+ "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostMutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunction148F70DDFunctionId": Object {
1415
+ "Type": "String",
1416
+ },
1417
+ "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId": Object {
1418
+ "Type": "String",
1419
+ },
1420
+ "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId": Object {
1421
+ "Type": "String",
1422
+ },
1423
+ "referencetotransformerrootstackS3DeploymentBucket7592718ARef": Object {
1424
+ "Type": "String",
1425
+ },
1426
+ "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref": Object {
1427
+ "Type": "String",
1428
+ },
1429
+ "referencetotransformerrootstackenv10C5A902Ref": Object {
1430
+ "Type": "String",
1431
+ },
1432
+ },
1433
+ "Resources": Object {
1434
+ "CommentDataSource": Object {
1435
+ "DependsOn": Array [
1436
+ "CommentIAMRoleD5EC5F51",
1437
+ ],
1438
+ "Properties": Object {
1439
+ "ApiId": Object {
1440
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1441
+ },
1442
+ "DynamoDBConfig": Object {
1443
+ "AwsRegion": Object {
1444
+ "Ref": "AWS::Region",
1445
+ },
1446
+ "TableName": Object {
1447
+ "Ref": "CommentTable",
1448
+ },
1449
+ },
1450
+ "Name": "CommentTable",
1451
+ "ServiceRoleArn": Object {
1452
+ "Fn::GetAtt": Array [
1453
+ "CommentIAMRoleD5EC5F51",
1454
+ "Arn",
1455
+ ],
1456
+ },
1457
+ "Type": "AMAZON_DYNAMODB",
1458
+ },
1459
+ "Type": "AWS::AppSync::DataSource",
1460
+ },
1461
+ "CommentIAMRoleD5EC5F51": Object {
1462
+ "Properties": Object {
1463
+ "AssumeRolePolicyDocument": Object {
1464
+ "Statement": Array [
1465
+ Object {
1466
+ "Action": "sts:AssumeRole",
1467
+ "Effect": "Allow",
1468
+ "Principal": Object {
1469
+ "Service": "appsync.amazonaws.com",
1470
+ },
1471
+ },
1472
+ ],
1473
+ "Version": "2012-10-17",
1474
+ },
1475
+ "RoleName": Object {
1476
+ "Fn::Join": Array [
1477
+ "",
1478
+ Array [
1479
+ "CommentIAMRole20388d-",
1480
+ Object {
1481
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1482
+ },
1483
+ "-",
1484
+ Object {
1485
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
1486
+ },
1487
+ ],
1488
+ ],
1489
+ },
1490
+ },
1491
+ "Type": "AWS::IAM::Role",
1492
+ },
1493
+ "CommentIAMRoleDefaultPolicyA8D6F6B5": Object {
1494
+ "Properties": Object {
1495
+ "PolicyDocument": Object {
1496
+ "Statement": Array [
1497
+ Object {
1498
+ "Action": Array [
1499
+ "dynamodb:BatchGetItem",
1500
+ "dynamodb:GetRecords",
1501
+ "dynamodb:GetShardIterator",
1502
+ "dynamodb:Query",
1503
+ "dynamodb:GetItem",
1504
+ "dynamodb:Scan",
1505
+ "dynamodb:ConditionCheckItem",
1506
+ "dynamodb:BatchWriteItem",
1507
+ "dynamodb:PutItem",
1508
+ "dynamodb:UpdateItem",
1509
+ "dynamodb:DeleteItem",
1510
+ "dynamodb:DescribeTable",
1511
+ ],
1512
+ "Effect": "Allow",
1513
+ "Resource": Array [
1514
+ Object {
1515
+ "Fn::GetAtt": Array [
1516
+ "CommentTable",
1517
+ "Arn",
1518
+ ],
1519
+ },
1520
+ Object {
1521
+ "Ref": "AWS::NoValue",
1522
+ },
1523
+ ],
1524
+ },
1525
+ ],
1526
+ "Version": "2012-10-17",
1527
+ },
1528
+ "PolicyName": "CommentIAMRoleDefaultPolicyA8D6F6B5",
1529
+ "Roles": Array [
1530
+ Object {
1531
+ "Ref": "CommentIAMRoleD5EC5F51",
1532
+ },
1533
+ ],
1534
+ },
1535
+ "Type": "AWS::IAM::Policy",
1536
+ },
1537
+ "CommentTable": Object {
1538
+ "DeletionPolicy": "Delete",
1539
+ "Properties": Object {
1540
+ "AttributeDefinitions": Array [
1541
+ Object {
1542
+ "AttributeName": "id",
1543
+ "AttributeType": "S",
1544
+ },
1545
+ ],
1546
+ "BillingMode": Object {
1547
+ "Fn::If": Array [
1548
+ "ShouldUsePayPerRequestBilling",
1549
+ "PAY_PER_REQUEST",
1550
+ Object {
1551
+ "Ref": "AWS::NoValue",
1552
+ },
1553
+ ],
1554
+ },
1555
+ "KeySchema": Array [
1556
+ Object {
1557
+ "AttributeName": "id",
1558
+ "KeyType": "HASH",
1559
+ },
1560
+ ],
1561
+ "PointInTimeRecoverySpecification": Object {
1562
+ "Fn::If": Array [
1563
+ "ShouldUsePointInTimeRecovery",
1564
+ Object {
1565
+ "PointInTimeRecoveryEnabled": true,
1566
+ },
1567
+ Object {
1568
+ "Ref": "AWS::NoValue",
1569
+ },
1570
+ ],
1571
+ },
1572
+ "ProvisionedThroughput": Object {
1573
+ "Fn::If": Array [
1574
+ "ShouldUsePayPerRequestBilling",
1575
+ Object {
1576
+ "Ref": "AWS::NoValue",
1577
+ },
1578
+ Object {
1579
+ "ReadCapacityUnits": Object {
1580
+ "Ref": "DynamoDBModelTableReadIOPS",
1581
+ },
1582
+ "WriteCapacityUnits": Object {
1583
+ "Ref": "DynamoDBModelTableWriteIOPS",
1584
+ },
1585
+ },
1586
+ ],
1587
+ },
1588
+ "SSESpecification": Object {
1589
+ "SSEEnabled": Object {
1590
+ "Fn::If": Array [
1591
+ "ShouldUseServerSideEncryption",
1592
+ true,
1593
+ false,
1594
+ ],
1595
+ },
1596
+ },
1597
+ "StreamSpecification": Object {
1598
+ "StreamViewType": "NEW_AND_OLD_IMAGES",
1599
+ },
1600
+ "TableName": Object {
1601
+ "Fn::Join": Array [
1602
+ "",
1603
+ Array [
1604
+ "Comment-",
1605
+ Object {
1606
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1607
+ },
1608
+ "-",
1609
+ Object {
1610
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
1611
+ },
1612
+ ],
1613
+ ],
1614
+ },
1615
+ },
1616
+ "Type": "AWS::DynamoDB::Table",
1617
+ "UpdateReplacePolicy": "Delete",
1618
+ },
1619
+ "CreateCommentResolver": Object {
1620
+ "Properties": Object {
1621
+ "ApiId": Object {
1622
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1623
+ },
1624
+ "FieldName": "createComment",
1625
+ "Kind": "PIPELINE",
1626
+ "PipelineConfig": Object {
1627
+ "Functions": Array [
1628
+ Object {
1629
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostMutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunctionB82DB57BFunctionId",
1630
+ },
1631
+ Object {
1632
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
1633
+ },
1634
+ Object {
1635
+ "Fn::GetAtt": Array [
1636
+ "MutationCreateCommentDataResolverFnMutationCreateCommentDataResolverFnAppSyncFunctionD019FFE0",
1637
+ "FunctionId",
1638
+ ],
1639
+ },
1640
+ ],
1641
+ },
1642
+ "RequestMappingTemplate": Object {
1643
+ "Fn::Join": Array [
1644
+ "",
1645
+ Array [
1646
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
1647
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"createComment\\"))
1648
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
1649
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
1650
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
1651
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
1652
+ Object {
1653
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1654
+ },
1655
+ "\\"))
1656
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
1657
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
1658
+ Object {
1659
+ "Ref": "CommentTable",
1660
+ },
1661
+ "\\"))
1662
+ $util.toJson({})",
1663
+ ],
1664
+ ],
1665
+ },
1666
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
1667
+ "TypeName": "Mutation",
1668
+ },
1669
+ "Type": "AWS::AppSync::Resolver",
1670
+ },
1671
+ "DeleteCommentResolver": Object {
1672
+ "Properties": Object {
1673
+ "ApiId": Object {
1674
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1675
+ },
1676
+ "FieldName": "deleteComment",
1677
+ "Kind": "PIPELINE",
1678
+ "PipelineConfig": Object {
1679
+ "Functions": Array [
1680
+ Object {
1681
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
1682
+ },
1683
+ Object {
1684
+ "Fn::GetAtt": Array [
1685
+ "MutationDeleteCommentDataResolverFnMutationDeleteCommentDataResolverFnAppSyncFunctionD661C8CB",
1686
+ "FunctionId",
1687
+ ],
1688
+ },
1689
+ ],
1690
+ },
1691
+ "RequestMappingTemplate": Object {
1692
+ "Fn::Join": Array [
1693
+ "",
1694
+ Array [
1695
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
1696
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"deleteComment\\"))
1697
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
1698
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
1699
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
1700
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
1701
+ Object {
1702
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1703
+ },
1704
+ "\\"))
1705
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
1706
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
1707
+ Object {
1708
+ "Ref": "CommentTable",
1709
+ },
1710
+ "\\"))
1711
+ $util.toJson({})",
1712
+ ],
1713
+ ],
1714
+ },
1715
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
1716
+ "TypeName": "Mutation",
1717
+ },
1718
+ "Type": "AWS::AppSync::Resolver",
1719
+ },
1720
+ "DynamoDBAccess71ABE5AE": Object {
1721
+ "Properties": Object {
1722
+ "PolicyDocument": Object {
1723
+ "Statement": Array [
1724
+ Object {
1725
+ "Action": Array [
1726
+ "dynamodb:BatchGetItem",
1727
+ "dynamodb:BatchWriteItem",
1728
+ "dynamodb:PutItem",
1729
+ "dynamodb:DeleteItem",
1730
+ "dynamodb:GetItem",
1731
+ "dynamodb:Scan",
1732
+ "dynamodb:Query",
1733
+ "dynamodb:UpdateItem",
1734
+ ],
1735
+ "Effect": "Allow",
1736
+ "Resource": Array [
1737
+ Object {
1738
+ "Fn::Sub": Array [
1739
+ "arn:aws:dynamodb:\${AWS::Region}:\${AWS::AccountId}:table/\${tablename}",
1740
+ Object {
1741
+ "tablename": Object {
1742
+ "Fn::Join": Array [
1743
+ "",
1744
+ Array [
1745
+ "Comment-",
1746
+ Object {
1747
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1748
+ },
1749
+ "-",
1750
+ Object {
1751
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
1752
+ },
1753
+ ],
1754
+ ],
1755
+ },
1756
+ },
1757
+ ],
1758
+ },
1759
+ Object {
1760
+ "Fn::Sub": Array [
1761
+ "arn:aws:dynamodb:\${AWS::Region}:\${AWS::AccountId}:table/\${tablename}/*",
1762
+ Object {
1763
+ "tablename": Object {
1764
+ "Fn::Join": Array [
1765
+ "",
1766
+ Array [
1767
+ "Comment-",
1768
+ Object {
1769
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1770
+ },
1771
+ "-",
1772
+ Object {
1773
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
1774
+ },
1775
+ ],
1776
+ ],
1777
+ },
1778
+ },
1779
+ ],
1780
+ },
1781
+ ],
1782
+ },
1783
+ ],
1784
+ "Version": "2012-10-17",
1785
+ },
1786
+ "PolicyName": "DynamoDBAccess71ABE5AE",
1787
+ "Roles": Array [
1788
+ Object {
1789
+ "Ref": "CommentIAMRoleD5EC5F51",
1790
+ },
1791
+ ],
1792
+ },
1793
+ "Type": "AWS::IAM::Policy",
1794
+ },
1795
+ "GetCommentResolver": Object {
1796
+ "Properties": Object {
1797
+ "ApiId": Object {
1798
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1799
+ },
1800
+ "FieldName": "getComment",
1801
+ "Kind": "PIPELINE",
1802
+ "PipelineConfig": Object {
1803
+ "Functions": Array [
1804
+ Object {
1805
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
1806
+ },
1807
+ Object {
1808
+ "Fn::GetAtt": Array [
1809
+ "QueryGetCommentDataResolverFnQueryGetCommentDataResolverFnAppSyncFunction8473E2B0",
1810
+ "FunctionId",
1811
+ ],
1812
+ },
1813
+ ],
1814
+ },
1815
+ "RequestMappingTemplate": Object {
1816
+ "Fn::Join": Array [
1817
+ "",
1818
+ Array [
1819
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Query\\"))
1820
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"getComment\\"))
1821
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
1822
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
1823
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
1824
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
1825
+ Object {
1826
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1827
+ },
1828
+ "\\"))
1829
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
1830
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
1831
+ Object {
1832
+ "Ref": "CommentTable",
1833
+ },
1834
+ "\\"))
1835
+ $util.toJson({})",
1836
+ ],
1837
+ ],
1838
+ },
1839
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
1840
+ "TypeName": "Query",
1841
+ },
1842
+ "Type": "AWS::AppSync::Resolver",
1843
+ },
1844
+ "ListCommentResolver": Object {
1845
+ "Properties": Object {
1846
+ "ApiId": Object {
1847
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1848
+ },
1849
+ "FieldName": "listComments",
1850
+ "Kind": "PIPELINE",
1851
+ "PipelineConfig": Object {
1852
+ "Functions": Array [
1853
+ Object {
1854
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
1855
+ },
1856
+ Object {
1857
+ "Fn::GetAtt": Array [
1858
+ "QueryListCommentsDataResolverFnQueryListCommentsDataResolverFnAppSyncFunction474D4A91",
1859
+ "FunctionId",
1860
+ ],
1861
+ },
1862
+ ],
1863
+ },
1864
+ "RequestMappingTemplate": Object {
1865
+ "Fn::Join": Array [
1866
+ "",
1867
+ Array [
1868
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Query\\"))
1869
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"listComments\\"))
1870
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
1871
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
1872
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
1873
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
1874
+ Object {
1875
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1876
+ },
1877
+ "\\"))
1878
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
1879
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
1880
+ Object {
1881
+ "Ref": "CommentTable",
1882
+ },
1883
+ "\\"))
1884
+ $util.toJson({})",
1885
+ ],
1886
+ ],
1887
+ },
1888
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
1889
+ "TypeName": "Query",
1890
+ },
1891
+ "Type": "AWS::AppSync::Resolver",
1892
+ },
1893
+ "MutationCreateCommentDataResolverFnMutationCreateCommentDataResolverFnAppSyncFunctionD019FFE0": Object {
1894
+ "DependsOn": Array [
1895
+ "CommentDataSource",
1896
+ ],
1897
+ "Properties": Object {
1898
+ "ApiId": Object {
1899
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1900
+ },
1901
+ "DataSourceName": Object {
1902
+ "Fn::GetAtt": Array [
1903
+ "CommentDataSource",
1904
+ "Name",
1905
+ ],
1906
+ },
1907
+ "FunctionVersion": "2018-05-29",
1908
+ "Name": "MutationCreateCommentDataResolverFn",
1909
+ "RequestMappingTemplateS3Location": Object {
1910
+ "Fn::Join": Array [
1911
+ "",
1912
+ Array [
1913
+ "s3://",
1914
+ Object {
1915
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
1916
+ },
1917
+ "/",
1918
+ Object {
1919
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
1920
+ },
1921
+ "/resolvers/Mutation.createComment.req.vtl",
1922
+ ],
1923
+ ],
1924
+ },
1925
+ "ResponseMappingTemplateS3Location": Object {
1926
+ "Fn::Join": Array [
1927
+ "",
1928
+ Array [
1929
+ "s3://",
1930
+ Object {
1931
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
1932
+ },
1933
+ "/",
1934
+ Object {
1935
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
1936
+ },
1937
+ "/resolvers/Mutation.createComment.res.vtl",
1938
+ ],
1939
+ ],
1940
+ },
1941
+ },
1942
+ "Type": "AWS::AppSync::FunctionConfiguration",
1943
+ },
1944
+ "MutationDeleteCommentDataResolverFnMutationDeleteCommentDataResolverFnAppSyncFunctionD661C8CB": Object {
1945
+ "DependsOn": Array [
1946
+ "CommentDataSource",
1947
+ ],
1948
+ "Properties": Object {
1949
+ "ApiId": Object {
1950
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
1951
+ },
1952
+ "DataSourceName": Object {
1953
+ "Fn::GetAtt": Array [
1954
+ "CommentDataSource",
1955
+ "Name",
1956
+ ],
1957
+ },
1958
+ "FunctionVersion": "2018-05-29",
1959
+ "Name": "MutationDeleteCommentDataResolverFn",
1960
+ "RequestMappingTemplateS3Location": Object {
1961
+ "Fn::Join": Array [
1962
+ "",
1963
+ Array [
1964
+ "s3://",
1965
+ Object {
1966
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
1967
+ },
1968
+ "/",
1969
+ Object {
1970
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
1971
+ },
1972
+ "/resolvers/Mutation.deleteComment.req.vtl",
1973
+ ],
1974
+ ],
1975
+ },
1976
+ "ResponseMappingTemplateS3Location": Object {
1977
+ "Fn::Join": Array [
1978
+ "",
1979
+ Array [
1980
+ "s3://",
1981
+ Object {
1982
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
1983
+ },
1984
+ "/",
1985
+ Object {
1986
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
1987
+ },
1988
+ "/resolvers/Mutation.deleteComment.res.vtl",
1989
+ ],
1990
+ ],
1991
+ },
1992
+ },
1993
+ "Type": "AWS::AppSync::FunctionConfiguration",
1994
+ },
1995
+ "MutationUpdateCommentDataResolverFnMutationUpdateCommentDataResolverFnAppSyncFunctionB47372B5": Object {
1996
+ "DependsOn": Array [
1997
+ "CommentDataSource",
1998
+ ],
1999
+ "Properties": Object {
2000
+ "ApiId": Object {
2001
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2002
+ },
2003
+ "DataSourceName": Object {
2004
+ "Fn::GetAtt": Array [
2005
+ "CommentDataSource",
2006
+ "Name",
2007
+ ],
2008
+ },
2009
+ "FunctionVersion": "2018-05-29",
2010
+ "Name": "MutationUpdateCommentDataResolverFn",
2011
+ "RequestMappingTemplateS3Location": Object {
2012
+ "Fn::Join": Array [
2013
+ "",
2014
+ Array [
2015
+ "s3://",
2016
+ Object {
2017
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2018
+ },
2019
+ "/",
2020
+ Object {
2021
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2022
+ },
2023
+ "/resolvers/Mutation.updateComment.req.vtl",
2024
+ ],
2025
+ ],
2026
+ },
2027
+ "ResponseMappingTemplateS3Location": Object {
2028
+ "Fn::Join": Array [
2029
+ "",
2030
+ Array [
2031
+ "s3://",
2032
+ Object {
2033
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2034
+ },
2035
+ "/",
2036
+ Object {
2037
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2038
+ },
2039
+ "/resolvers/Mutation.updateComment.res.vtl",
2040
+ ],
2041
+ ],
2042
+ },
2043
+ },
2044
+ "Type": "AWS::AppSync::FunctionConfiguration",
2045
+ },
2046
+ "QueryGetCommentDataResolverFnQueryGetCommentDataResolverFnAppSyncFunction8473E2B0": Object {
2047
+ "DependsOn": Array [
2048
+ "CommentDataSource",
2049
+ ],
2050
+ "Properties": Object {
2051
+ "ApiId": Object {
2052
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2053
+ },
2054
+ "DataSourceName": Object {
2055
+ "Fn::GetAtt": Array [
2056
+ "CommentDataSource",
2057
+ "Name",
2058
+ ],
2059
+ },
2060
+ "FunctionVersion": "2018-05-29",
2061
+ "Name": "QueryGetCommentDataResolverFn",
2062
+ "RequestMappingTemplateS3Location": Object {
2063
+ "Fn::Join": Array [
2064
+ "",
2065
+ Array [
2066
+ "s3://",
2067
+ Object {
2068
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2069
+ },
2070
+ "/",
2071
+ Object {
2072
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2073
+ },
2074
+ "/resolvers/Query.getComment.req.vtl",
2075
+ ],
2076
+ ],
2077
+ },
2078
+ "ResponseMappingTemplateS3Location": Object {
2079
+ "Fn::Join": Array [
2080
+ "",
2081
+ Array [
2082
+ "s3://",
2083
+ Object {
2084
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2085
+ },
2086
+ "/",
2087
+ Object {
2088
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2089
+ },
2090
+ "/resolvers/Query.getComment.res.vtl",
2091
+ ],
2092
+ ],
2093
+ },
2094
+ },
2095
+ "Type": "AWS::AppSync::FunctionConfiguration",
2096
+ },
2097
+ "QueryListCommentsDataResolverFnQueryListCommentsDataResolverFnAppSyncFunction474D4A91": Object {
2098
+ "DependsOn": Array [
2099
+ "CommentDataSource",
2100
+ ],
2101
+ "Properties": Object {
2102
+ "ApiId": Object {
2103
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2104
+ },
2105
+ "DataSourceName": Object {
2106
+ "Fn::GetAtt": Array [
2107
+ "CommentDataSource",
2108
+ "Name",
2109
+ ],
2110
+ },
2111
+ "FunctionVersion": "2018-05-29",
2112
+ "Name": "QueryListCommentsDataResolverFn",
2113
+ "RequestMappingTemplateS3Location": Object {
2114
+ "Fn::Join": Array [
2115
+ "",
2116
+ Array [
2117
+ "s3://",
2118
+ Object {
2119
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2120
+ },
2121
+ "/",
2122
+ Object {
2123
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2124
+ },
2125
+ "/resolvers/Query.listComments.req.vtl",
2126
+ ],
2127
+ ],
2128
+ },
2129
+ "ResponseMappingTemplateS3Location": Object {
2130
+ "Fn::Join": Array [
2131
+ "",
2132
+ Array [
2133
+ "s3://",
2134
+ Object {
2135
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2136
+ },
2137
+ "/",
2138
+ Object {
2139
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2140
+ },
2141
+ "/resolvers/Query.listComments.res.vtl",
2142
+ ],
2143
+ ],
2144
+ },
2145
+ },
2146
+ "Type": "AWS::AppSync::FunctionConfiguration",
2147
+ },
2148
+ "SubscriptiononCreateCommentResolver": Object {
2149
+ "Properties": Object {
2150
+ "ApiId": Object {
2151
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2152
+ },
2153
+ "FieldName": "onCreateComment",
2154
+ "Kind": "PIPELINE",
2155
+ "PipelineConfig": Object {
2156
+ "Functions": Array [
2157
+ Object {
2158
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
2159
+ },
2160
+ Object {
2161
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId",
2162
+ },
2163
+ ],
2164
+ },
2165
+ "RequestMappingTemplate": Object {
2166
+ "Fn::Join": Array [
2167
+ "",
2168
+ Array [
2169
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
2170
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onCreateComment\\"))
2171
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
2172
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
2173
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
2174
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
2175
+ Object {
2176
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2177
+ },
2178
+ "\\"))
2179
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
2180
+
2181
+ $util.toJson({})",
2182
+ ],
2183
+ ],
2184
+ },
2185
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
2186
+ "TypeName": "Subscription",
2187
+ },
2188
+ "Type": "AWS::AppSync::Resolver",
2189
+ },
2190
+ "SubscriptiononDeleteCommentResolver": Object {
2191
+ "Properties": Object {
2192
+ "ApiId": Object {
2193
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2194
+ },
2195
+ "FieldName": "onDeleteComment",
2196
+ "Kind": "PIPELINE",
2197
+ "PipelineConfig": Object {
2198
+ "Functions": Array [
2199
+ Object {
2200
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
2201
+ },
2202
+ Object {
2203
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId",
2204
+ },
2205
+ ],
2206
+ },
2207
+ "RequestMappingTemplate": Object {
2208
+ "Fn::Join": Array [
2209
+ "",
2210
+ Array [
2211
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
2212
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onDeleteComment\\"))
2213
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
2214
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
2215
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
2216
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
2217
+ Object {
2218
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2219
+ },
2220
+ "\\"))
2221
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
2222
+
2223
+ $util.toJson({})",
2224
+ ],
2225
+ ],
2226
+ },
2227
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
2228
+ "TypeName": "Subscription",
2229
+ },
2230
+ "Type": "AWS::AppSync::Resolver",
2231
+ },
2232
+ "SubscriptiononUpdateCommentResolver": Object {
2233
+ "Properties": Object {
2234
+ "ApiId": Object {
2235
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2236
+ },
2237
+ "FieldName": "onUpdateComment",
2238
+ "Kind": "PIPELINE",
2239
+ "PipelineConfig": Object {
2240
+ "Functions": Array [
2241
+ Object {
2242
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
2243
+ },
2244
+ Object {
2245
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId",
2246
+ },
2247
+ ],
2248
+ },
2249
+ "RequestMappingTemplate": Object {
2250
+ "Fn::Join": Array [
2251
+ "",
2252
+ Array [
2253
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
2254
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onUpdateComment\\"))
2255
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
2256
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
2257
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
2258
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
2259
+ Object {
2260
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2261
+ },
2262
+ "\\"))
2263
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
2264
+
2265
+ $util.toJson({})",
2266
+ ],
2267
+ ],
2268
+ },
2269
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
2270
+ "TypeName": "Subscription",
2271
+ },
2272
+ "Type": "AWS::AppSync::Resolver",
2273
+ },
2274
+ "UpdateCommentResolver": Object {
2275
+ "Properties": Object {
2276
+ "ApiId": Object {
2277
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2278
+ },
2279
+ "FieldName": "updateComment",
2280
+ "Kind": "PIPELINE",
2281
+ "PipelineConfig": Object {
2282
+ "Functions": Array [
2283
+ Object {
2284
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostMutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunction148F70DDFunctionId",
2285
+ },
2286
+ Object {
2287
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
2288
+ },
2289
+ Object {
2290
+ "Fn::GetAtt": Array [
2291
+ "MutationUpdateCommentDataResolverFnMutationUpdateCommentDataResolverFnAppSyncFunctionB47372B5",
2292
+ "FunctionId",
2293
+ ],
2294
+ },
2295
+ ],
2296
+ },
2297
+ "RequestMappingTemplate": Object {
2298
+ "Fn::Join": Array [
2299
+ "",
2300
+ Array [
2301
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
2302
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"updateComment\\"))
2303
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
2304
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
2305
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
2306
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
2307
+ Object {
2308
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2309
+ },
2310
+ "\\"))
2311
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
2312
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
2313
+ Object {
2314
+ "Ref": "CommentTable",
2315
+ },
2316
+ "\\"))
2317
+ $util.toJson({})",
2318
+ ],
2319
+ ],
2320
+ },
2321
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
2322
+ "TypeName": "Mutation",
2323
+ },
2324
+ "Type": "AWS::AppSync::Resolver",
2325
+ },
2326
+ },
2327
+ }
2328
+ `;
2329
+
2330
+ exports[`ModelTransformer: should override model objects when given override config 1`] = `
2331
+ Object {
2332
+ "Conditions": Object {
2333
+ "HasEnvironmentParameter": Object {
2334
+ "Fn::Not": Array [
2335
+ Object {
2336
+ "Fn::Equals": Array [
2337
+ Object {
2338
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
2339
+ },
2340
+ "NONE",
2341
+ ],
2342
+ },
2343
+ ],
2344
+ },
2345
+ "ShouldUsePayPerRequestBilling": Object {
2346
+ "Fn::Equals": Array [
2347
+ Object {
2348
+ "Ref": "DynamoDBBillingMode",
2349
+ },
2350
+ "PAY_PER_REQUEST",
2351
+ ],
2352
+ },
2353
+ "ShouldUsePointInTimeRecovery": Object {
2354
+ "Fn::Equals": Array [
2355
+ Object {
2356
+ "Ref": "DynamoDBEnablePointInTimeRecovery",
2357
+ },
2358
+ "true",
2359
+ ],
2360
+ },
2361
+ "ShouldUseServerSideEncryption": Object {
2362
+ "Fn::Equals": Array [
2363
+ Object {
2364
+ "Ref": "DynamoDBEnableServerSideEncryption",
2365
+ },
2366
+ "true",
2367
+ ],
2368
+ },
2369
+ },
2370
+ "Outputs": Object {
2371
+ "GetAttPostDataSourceName": Object {
2372
+ "Description": "Your model DataSource name.",
2373
+ "Export": Object {
2374
+ "Name": Object {
2375
+ "Fn::Join": Array [
2376
+ ":",
2377
+ Array [
2378
+ Object {
2379
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2380
+ },
2381
+ "GetAtt:PostDataSource:Name",
2382
+ ],
2383
+ ],
2384
+ },
2385
+ },
2386
+ "Value": Object {
2387
+ "Fn::GetAtt": Array [
2388
+ "PostDataSource",
2389
+ "Name",
2390
+ ],
2391
+ },
2392
+ },
2393
+ "GetAttPostTableName": Object {
2394
+ "Description": "Your DynamoDB table name.",
2395
+ "Export": Object {
2396
+ "Name": Object {
2397
+ "Fn::Join": Array [
2398
+ ":",
2399
+ Array [
2400
+ Object {
2401
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2402
+ },
2403
+ "GetAtt:PostTable:Name",
2404
+ ],
2405
+ ],
2406
+ },
2407
+ },
2408
+ "Value": Object {
2409
+ "Ref": "PostTable",
2410
+ },
2411
+ },
2412
+ "GetAttPostTableStreamArn": Object {
2413
+ "Description": "Your DynamoDB table StreamArn.",
2414
+ "Export": Object {
2415
+ "Name": Object {
2416
+ "Fn::Join": Array [
2417
+ ":",
2418
+ Array [
2419
+ Object {
2420
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2421
+ },
2422
+ "GetAtt:PostTable:StreamArn",
2423
+ ],
2424
+ ],
2425
+ },
2426
+ },
2427
+ "Value": Object {
2428
+ "Fn::GetAtt": Array [
2429
+ "PostTable",
2430
+ "StreamArn",
2431
+ ],
2432
+ },
2433
+ },
2434
+ "transformerrootstackPostMutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunctionB82DB57BFunctionId": Object {
2435
+ "Value": Object {
2436
+ "Fn::GetAtt": Array [
2437
+ "MutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunction9E444A7F",
2438
+ "FunctionId",
2439
+ ],
2440
+ },
2441
+ },
2442
+ "transformerrootstackPostMutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunction148F70DDFunctionId": Object {
2443
+ "Value": Object {
2444
+ "Fn::GetAtt": Array [
2445
+ "MutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunctionBAC7D532",
2446
+ "FunctionId",
2447
+ ],
2448
+ },
2449
+ },
2450
+ "transformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId": Object {
2451
+ "Value": Object {
2452
+ "Fn::GetAtt": Array [
2453
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
2454
+ "FunctionId",
2455
+ ],
2456
+ },
2457
+ },
2458
+ "transformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId": Object {
2459
+ "Value": Object {
2460
+ "Fn::GetAtt": Array [
2461
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868",
2462
+ "FunctionId",
2463
+ ],
2464
+ },
2465
+ },
2466
+ },
2467
+ "Parameters": Object {
2468
+ "DynamoDBBillingMode": Object {
2469
+ "AllowedValues": Array [
2470
+ "PAY_PER_REQUEST",
2471
+ "PROVISIONED",
2472
+ ],
2473
+ "Default": "PAY_PER_REQUEST",
2474
+ "Description": "Configure @model types to create DynamoDB tables with PAY_PER_REQUEST or PROVISIONED billing modes.",
2475
+ "Type": "String",
2476
+ },
2477
+ "DynamoDBEnablePointInTimeRecovery": Object {
2478
+ "AllowedValues": Array [
2479
+ "true",
2480
+ "false",
2481
+ ],
2482
+ "Default": "false",
2483
+ "Description": "Whether to enable Point in Time Recovery on the table.",
2484
+ "Type": "String",
2485
+ },
2486
+ "DynamoDBEnableServerSideEncryption": Object {
2487
+ "AllowedValues": Array [
2488
+ "true",
2489
+ "false",
2490
+ ],
2491
+ "Default": "true",
2492
+ "Description": "Enable server side encryption powered by KMS.",
2493
+ "Type": "String",
2494
+ },
2495
+ "DynamoDBModelTableReadIOPS": Object {
2496
+ "Default": 5,
2497
+ "Description": "The number of read IOPS the table should support.",
2498
+ "Type": "Number",
2499
+ },
2500
+ "DynamoDBModelTableWriteIOPS": Object {
2501
+ "Default": 5,
2502
+ "Description": "The number of write IOPS the table should support.",
2503
+ "Type": "Number",
2504
+ },
2505
+ "referencetotransformerrootstackGraphQLAPI20497F53ApiId": Object {
2506
+ "Type": "String",
2507
+ },
2508
+ "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name": Object {
2509
+ "Type": "String",
2510
+ },
2511
+ "referencetotransformerrootstackS3DeploymentBucket7592718ARef": Object {
2512
+ "Type": "String",
2513
+ },
2514
+ "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref": Object {
2515
+ "Type": "String",
2516
+ },
2517
+ "referencetotransformerrootstackenv10C5A902Ref": Object {
2518
+ "Type": "String",
2519
+ },
2520
+ },
2521
+ "Resources": Object {
2522
+ "CreatePostResolver": Object {
2523
+ "Properties": Object {
2524
+ "ApiId": Object {
2525
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2526
+ },
2527
+ "FieldName": "createPost",
2528
+ "Kind": "PIPELINE",
2529
+ "PipelineConfig": Object {
2530
+ "Functions": Array [
2531
+ Object {
2532
+ "Fn::GetAtt": Array [
2533
+ "MutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunction9E444A7F",
2534
+ "FunctionId",
2535
+ ],
2536
+ },
2537
+ Object {
2538
+ "Fn::GetAtt": Array [
2539
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
2540
+ "FunctionId",
2541
+ ],
2542
+ },
2543
+ Object {
2544
+ "Fn::GetAtt": Array [
2545
+ "MutationCreatePostDataResolverFnMutationCreatePostDataResolverFnAppSyncFunctionE45E2000",
2546
+ "FunctionId",
2547
+ ],
2548
+ },
2549
+ ],
2550
+ },
2551
+ "RequestMappingTemplate": Object {
2552
+ "Fn::Join": Array [
2553
+ "",
2554
+ Array [
2555
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
2556
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"createPost\\"))
2557
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
2558
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
2559
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
2560
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
2561
+ Object {
2562
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2563
+ },
2564
+ "\\"))
2565
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
2566
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
2567
+ Object {
2568
+ "Ref": "PostTable",
2569
+ },
2570
+ "\\"))
2571
+ $util.toJson({})",
2572
+ ],
2573
+ ],
2574
+ },
2575
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
2576
+ "TypeName": "Mutation",
2577
+ },
2578
+ "Type": "AWS::AppSync::Resolver",
2579
+ },
2580
+ "DeletePostResolver": Object {
2581
+ "Properties": Object {
2582
+ "ApiId": Object {
2583
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2584
+ },
2585
+ "FieldName": "deletePost",
2586
+ "Kind": "PIPELINE",
2587
+ "PipelineConfig": Object {
2588
+ "Functions": Array [
2589
+ Object {
2590
+ "Fn::GetAtt": Array [
2591
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
2592
+ "FunctionId",
2593
+ ],
2594
+ },
2595
+ Object {
2596
+ "Fn::GetAtt": Array [
2597
+ "MutationDeletePostDataResolverFnMutationDeletePostDataResolverFnAppSyncFunction45B37C12",
2598
+ "FunctionId",
2599
+ ],
2600
+ },
2601
+ ],
2602
+ },
2603
+ "RequestMappingTemplate": Object {
2604
+ "Fn::Join": Array [
2605
+ "",
2606
+ Array [
2607
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
2608
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"deletePost\\"))
2609
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
2610
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
2611
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
2612
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
2613
+ Object {
2614
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2615
+ },
2616
+ "\\"))
2617
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
2618
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
2619
+ Object {
2620
+ "Ref": "PostTable",
2621
+ },
2622
+ "\\"))
2623
+ $util.toJson({})",
2624
+ ],
2625
+ ],
2626
+ },
2627
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
2628
+ "TypeName": "Mutation",
2629
+ },
2630
+ "Type": "AWS::AppSync::Resolver",
2631
+ },
2632
+ "DynamoDBAccess71ABE5AE": Object {
2633
+ "Properties": Object {
2634
+ "PolicyDocument": Object {
2635
+ "Statement": Array [
2636
+ Object {
2637
+ "Action": Array [
2638
+ "dynamodb:BatchGetItem",
2639
+ "dynamodb:BatchWriteItem",
2640
+ "dynamodb:PutItem",
2641
+ "dynamodb:DeleteItem",
2642
+ "dynamodb:GetItem",
2643
+ "dynamodb:Scan",
2644
+ "dynamodb:Query",
2645
+ "dynamodb:UpdateItem",
2646
+ ],
2647
+ "Effect": "Allow",
2648
+ "Resource": Array [
2649
+ Object {
2650
+ "Fn::Sub": Array [
2651
+ "arn:aws:dynamodb:\${AWS::Region}:\${AWS::AccountId}:table/\${tablename}",
2652
+ Object {
2653
+ "tablename": Object {
2654
+ "Fn::Join": Array [
2655
+ "",
2656
+ Array [
2657
+ "Post-",
2658
+ Object {
2659
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2660
+ },
2661
+ "-",
2662
+ Object {
2663
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
2664
+ },
2665
+ ],
2666
+ ],
2667
+ },
2668
+ },
2669
+ ],
2670
+ },
2671
+ Object {
2672
+ "Fn::Sub": Array [
2673
+ "arn:aws:dynamodb:\${AWS::Region}:\${AWS::AccountId}:table/\${tablename}/*",
2674
+ Object {
2675
+ "tablename": Object {
2676
+ "Fn::Join": Array [
2677
+ "",
2678
+ Array [
2679
+ "Post-",
2680
+ Object {
2681
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2682
+ },
2683
+ "-",
2684
+ Object {
2685
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
2686
+ },
2687
+ ],
2688
+ ],
2689
+ },
2690
+ },
2691
+ ],
2692
+ },
2693
+ ],
2694
+ },
2695
+ ],
2696
+ "Version": "2012-10-17",
2697
+ },
2698
+ "PolicyName": "DynamoDBAccess71ABE5AE",
2699
+ "Roles": Array [
2700
+ Object {
2701
+ "Ref": "PostIAMRole83BF708F",
2702
+ },
2703
+ ],
2704
+ },
2705
+ "Type": "AWS::IAM::Policy",
2706
+ },
2707
+ "GetPostResolver": Object {
2708
+ "Properties": Object {
2709
+ "ApiId": Object {
2710
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2711
+ },
2712
+ "FieldName": "getPost",
2713
+ "Kind": "PIPELINE",
2714
+ "PipelineConfig": Object {
2715
+ "Functions": Array [
2716
+ Object {
2717
+ "Fn::GetAtt": Array [
2718
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
2719
+ "FunctionId",
2720
+ ],
2721
+ },
2722
+ Object {
2723
+ "Fn::GetAtt": Array [
2724
+ "QueryGetPostDataResolverFnQueryGetPostDataResolverFnAppSyncFunction06724190",
2725
+ "FunctionId",
2726
+ ],
2727
+ },
2728
+ ],
2729
+ },
2730
+ "RequestMappingTemplate": Object {
2731
+ "Fn::Join": Array [
2732
+ "",
2733
+ Array [
2734
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Query\\"))
2735
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"getPost\\"))
2736
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
2737
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
2738
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
2739
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
2740
+ Object {
2741
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2742
+ },
2743
+ "\\"))
2744
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
2745
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
2746
+ Object {
2747
+ "Ref": "PostTable",
2748
+ },
2749
+ "\\"))
2750
+ $util.toJson({})",
2751
+ ],
2752
+ ],
2753
+ },
2754
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
2755
+ "TypeName": "Query",
2756
+ },
2757
+ "Type": "AWS::AppSync::Resolver",
2758
+ },
2759
+ "ListPostResolver": Object {
2760
+ "Properties": Object {
2761
+ "ApiId": Object {
2762
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2763
+ },
2764
+ "FieldName": "listPosts",
2765
+ "Kind": "PIPELINE",
2766
+ "PipelineConfig": Object {
2767
+ "Functions": Array [
2768
+ Object {
2769
+ "Fn::GetAtt": Array [
2770
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
2771
+ "FunctionId",
2772
+ ],
2773
+ },
2774
+ Object {
2775
+ "Fn::GetAtt": Array [
2776
+ "QueryListPostsDataResolverFnQueryListPostsDataResolverFnAppSyncFunction3D526AB7",
2777
+ "FunctionId",
2778
+ ],
2779
+ },
2780
+ ],
2781
+ },
2782
+ "RequestMappingTemplate": Object {
2783
+ "Fn::Join": Array [
2784
+ "",
2785
+ Array [
2786
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Query\\"))
2787
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"listPosts\\"))
2788
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
2789
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
2790
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
2791
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
2792
+ Object {
2793
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2794
+ },
2795
+ "\\"))
2796
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
2797
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
2798
+ Object {
2799
+ "Ref": "PostTable",
2800
+ },
2801
+ "\\"))
2802
+ $util.toJson({})",
2803
+ ],
2804
+ ],
2805
+ },
2806
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
2807
+ "TypeName": "Query",
2808
+ },
2809
+ "Type": "AWS::AppSync::Resolver",
2810
+ },
2811
+ "MutationCreatePostDataResolverFnMutationCreatePostDataResolverFnAppSyncFunctionE45E2000": Object {
2812
+ "DependsOn": Array [
2813
+ "PostDataSource",
2814
+ ],
2815
+ "Properties": Object {
2816
+ "ApiId": Object {
2817
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2818
+ },
2819
+ "DataSourceName": Object {
2820
+ "Fn::GetAtt": Array [
2821
+ "PostDataSource",
2822
+ "Name",
2823
+ ],
2824
+ },
2825
+ "FunctionVersion": "2018-05-29",
2826
+ "Name": "MutationCreatePostDataResolverFn",
2827
+ "RequestMappingTemplateS3Location": Object {
2828
+ "Fn::Join": Array [
2829
+ "",
2830
+ Array [
2831
+ "s3://",
2832
+ Object {
2833
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2834
+ },
2835
+ "/",
2836
+ Object {
2837
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2838
+ },
2839
+ "/resolvers/Mutation.createPost.req.vtl",
2840
+ ],
2841
+ ],
2842
+ },
2843
+ "ResponseMappingTemplateS3Location": Object {
2844
+ "Fn::Join": Array [
2845
+ "",
2846
+ Array [
2847
+ "s3://",
2848
+ Object {
2849
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2850
+ },
2851
+ "/",
2852
+ Object {
2853
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2854
+ },
2855
+ "/resolvers/Mutation.createPost.res.vtl",
2856
+ ],
2857
+ ],
2858
+ },
2859
+ },
2860
+ "Type": "AWS::AppSync::FunctionConfiguration",
2861
+ },
2862
+ "MutationDeletePostDataResolverFnMutationDeletePostDataResolverFnAppSyncFunction45B37C12": Object {
2863
+ "DependsOn": Array [
2864
+ "PostDataSource",
2865
+ ],
2866
+ "Properties": Object {
2867
+ "ApiId": Object {
2868
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2869
+ },
2870
+ "DataSourceName": Object {
2871
+ "Fn::GetAtt": Array [
2872
+ "PostDataSource",
2873
+ "Name",
2874
+ ],
2875
+ },
2876
+ "FunctionVersion": "2018-05-29",
2877
+ "Name": "MutationDeletePostDataResolverFn",
2878
+ "RequestMappingTemplateS3Location": Object {
2879
+ "Fn::Join": Array [
2880
+ "",
2881
+ Array [
2882
+ "s3://",
2883
+ Object {
2884
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2885
+ },
2886
+ "/",
2887
+ Object {
2888
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2889
+ },
2890
+ "/resolvers/Mutation.deletePost.req.vtl",
2891
+ ],
2892
+ ],
2893
+ },
2894
+ "ResponseMappingTemplateS3Location": Object {
2895
+ "Fn::Join": Array [
2896
+ "",
2897
+ Array [
2898
+ "s3://",
2899
+ Object {
2900
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2901
+ },
2902
+ "/",
2903
+ Object {
2904
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2905
+ },
2906
+ "/resolvers/Mutation.deletePost.res.vtl",
2907
+ ],
2908
+ ],
2909
+ },
2910
+ },
2911
+ "Type": "AWS::AppSync::FunctionConfiguration",
2912
+ },
2913
+ "MutationUpdatePostDataResolverFnMutationUpdatePostDataResolverFnAppSyncFunctionBF7D410D": Object {
2914
+ "DependsOn": Array [
2915
+ "PostDataSource",
2916
+ ],
2917
+ "Properties": Object {
2918
+ "ApiId": Object {
2919
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2920
+ },
2921
+ "DataSourceName": Object {
2922
+ "Fn::GetAtt": Array [
2923
+ "PostDataSource",
2924
+ "Name",
2925
+ ],
2926
+ },
2927
+ "FunctionVersion": "2018-05-29",
2928
+ "Name": "MutationUpdatePostDataResolverFn",
2929
+ "RequestMappingTemplateS3Location": Object {
2930
+ "Fn::Join": Array [
2931
+ "",
2932
+ Array [
2933
+ "s3://",
2934
+ Object {
2935
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2936
+ },
2937
+ "/",
2938
+ Object {
2939
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2940
+ },
2941
+ "/resolvers/Mutation.updatePost.req.vtl",
2942
+ ],
2943
+ ],
2944
+ },
2945
+ "ResponseMappingTemplateS3Location": Object {
2946
+ "Fn::Join": Array [
2947
+ "",
2948
+ Array [
2949
+ "s3://",
2950
+ Object {
2951
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2952
+ },
2953
+ "/",
2954
+ Object {
2955
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2956
+ },
2957
+ "/resolvers/Mutation.updatePost.res.vtl",
2958
+ ],
2959
+ ],
2960
+ },
2961
+ },
2962
+ "Type": "AWS::AppSync::FunctionConfiguration",
2963
+ },
2964
+ "MutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunction9E444A7F": Object {
2965
+ "Properties": Object {
2966
+ "ApiId": Object {
2967
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2968
+ },
2969
+ "DataSourceName": Object {
2970
+ "Ref": "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name",
2971
+ },
2972
+ "FunctionVersion": "2018-05-29",
2973
+ "Name": "MutationcreatePostinit0Function",
2974
+ "RequestMappingTemplateS3Location": Object {
2975
+ "Fn::Join": Array [
2976
+ "",
2977
+ Array [
2978
+ "s3://",
2979
+ Object {
2980
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
2981
+ },
2982
+ "/",
2983
+ Object {
2984
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
2985
+ },
2986
+ "/resolvers/Mutation.createPost.init.1.req.vtl",
2987
+ ],
2988
+ ],
2989
+ },
2990
+ "ResponseMappingTemplate": "$util.toJson({})",
2991
+ },
2992
+ "Type": "AWS::AppSync::FunctionConfiguration",
2993
+ },
2994
+ "MutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunctionBAC7D532": Object {
2995
+ "Properties": Object {
2996
+ "ApiId": Object {
2997
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
2998
+ },
2999
+ "DataSourceName": Object {
3000
+ "Ref": "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name",
3001
+ },
3002
+ "FunctionVersion": "2018-05-29",
3003
+ "Name": "MutationupdatePostinit0Function",
3004
+ "RequestMappingTemplateS3Location": Object {
3005
+ "Fn::Join": Array [
3006
+ "",
3007
+ Array [
3008
+ "s3://",
3009
+ Object {
3010
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
3011
+ },
3012
+ "/",
3013
+ Object {
3014
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
3015
+ },
3016
+ "/resolvers/Mutation.updatePost.init.1.req.vtl",
3017
+ ],
3018
+ ],
3019
+ },
3020
+ "ResponseMappingTemplate": "$util.toJson({})",
3021
+ },
3022
+ "Type": "AWS::AppSync::FunctionConfiguration",
3023
+ },
3024
+ "PostDataSource": Object {
3025
+ "DependsOn": Array [
3026
+ "PostIAMRole83BF708F",
3027
+ ],
3028
+ "Properties": Object {
3029
+ "ApiId": Object {
3030
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3031
+ },
3032
+ "DynamoDBConfig": Object {
3033
+ "AwsRegion": Object {
3034
+ "Ref": "AWS::Region",
3035
+ },
3036
+ "TableName": Object {
3037
+ "Ref": "PostTable",
3038
+ },
3039
+ },
3040
+ "Name": "PostTable",
3041
+ "ServiceRoleArn": Object {
3042
+ "Fn::GetAtt": Array [
3043
+ "PostIAMRole83BF708F",
3044
+ "Arn",
3045
+ ],
3046
+ },
3047
+ "Type": "AMAZON_DYNAMODB",
3048
+ },
3049
+ "Type": "AWS::AppSync::DataSource",
3050
+ },
3051
+ "PostIAMRole83BF708F": Object {
3052
+ "Properties": Object {
3053
+ "AssumeRolePolicyDocument": Object {
3054
+ "Statement": Array [
3055
+ Object {
3056
+ "Action": "sts:AssumeRole",
3057
+ "Effect": "Allow",
3058
+ "Principal": Object {
3059
+ "Service": "appsync.amazonaws.com",
3060
+ },
3061
+ },
3062
+ ],
3063
+ "Version": "2012-10-17",
3064
+ },
3065
+ "RoleName": Object {
3066
+ "Fn::Join": Array [
3067
+ "",
3068
+ Array [
3069
+ "PostIAMRolebbce9b-",
3070
+ Object {
3071
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3072
+ },
3073
+ "-",
3074
+ Object {
3075
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
3076
+ },
3077
+ ],
3078
+ ],
3079
+ },
3080
+ },
3081
+ "Type": "AWS::IAM::Role",
3082
+ },
3083
+ "PostIAMRoleDefaultPolicy04190CA0": Object {
3084
+ "Properties": Object {
3085
+ "PolicyDocument": Object {
3086
+ "Statement": Array [
3087
+ Object {
3088
+ "Action": Array [
3089
+ "dynamodb:BatchGetItem",
3090
+ "dynamodb:GetRecords",
3091
+ "dynamodb:GetShardIterator",
3092
+ "dynamodb:Query",
3093
+ "dynamodb:GetItem",
3094
+ "dynamodb:Scan",
3095
+ "dynamodb:ConditionCheckItem",
3096
+ "dynamodb:BatchWriteItem",
3097
+ "dynamodb:PutItem",
3098
+ "dynamodb:UpdateItem",
3099
+ "dynamodb:DeleteItem",
3100
+ "dynamodb:DescribeTable",
3101
+ ],
3102
+ "Effect": "Allow",
3103
+ "Resource": Array [
3104
+ Object {
3105
+ "Fn::GetAtt": Array [
3106
+ "PostTable",
3107
+ "Arn",
3108
+ ],
3109
+ },
3110
+ Object {
3111
+ "Ref": "AWS::NoValue",
3112
+ },
3113
+ ],
3114
+ },
3115
+ ],
3116
+ "Version": "2012-10-17",
3117
+ },
3118
+ "PolicyName": "PostIAMRoleDefaultPolicy04190CA0",
3119
+ "Roles": Array [
3120
+ Object {
3121
+ "Ref": "PostIAMRole83BF708F",
3122
+ },
3123
+ ],
3124
+ },
3125
+ "Type": "AWS::IAM::Policy",
3126
+ },
3127
+ "PostTable": Object {
3128
+ "DeletionPolicy": "Delete",
3129
+ "Properties": Object {
3130
+ "AttributeDefinitions": Array [
3131
+ Object {
3132
+ "AttributeName": "id",
3133
+ "AttributeType": "S",
3134
+ },
3135
+ ],
3136
+ "BillingMode": "PROVISIONED",
3137
+ "KeySchema": Array [
3138
+ Object {
3139
+ "AttributeName": "id",
3140
+ "KeyType": "HASH",
3141
+ },
3142
+ ],
3143
+ "PointInTimeRecoverySpecification": Object {
3144
+ "Fn::If": Array [
3145
+ "ShouldUsePointInTimeRecovery",
3146
+ Object {
3147
+ "PointInTimeRecoveryEnabled": true,
3148
+ },
3149
+ Object {
3150
+ "Ref": "AWS::NoValue",
3151
+ },
3152
+ ],
3153
+ },
3154
+ "ProvisionedThroughput": Object {
3155
+ "Fn::If": Array [
3156
+ "ShouldUsePayPerRequestBilling",
3157
+ Object {
3158
+ "Ref": "AWS::NoValue",
3159
+ },
3160
+ Object {
3161
+ "ReadCapacityUnits": Object {
3162
+ "Ref": "DynamoDBModelTableReadIOPS",
3163
+ },
3164
+ "WriteCapacityUnits": Object {
3165
+ "Ref": "DynamoDBModelTableWriteIOPS",
3166
+ },
3167
+ },
3168
+ ],
3169
+ },
3170
+ "SSESpecification": Object {
3171
+ "SSEEnabled": Object {
3172
+ "Fn::If": Array [
3173
+ "ShouldUseServerSideEncryption",
3174
+ true,
3175
+ false,
3176
+ ],
3177
+ },
3178
+ },
3179
+ "StreamSpecification": Object {
3180
+ "StreamViewType": "NEW_AND_OLD_IMAGES",
3181
+ },
3182
+ "TableName": Object {
3183
+ "Fn::Join": Array [
3184
+ "",
3185
+ Array [
3186
+ "Post-",
3187
+ Object {
3188
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3189
+ },
3190
+ "-",
3191
+ Object {
3192
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
3193
+ },
3194
+ ],
3195
+ ],
3196
+ },
3197
+ },
3198
+ "Type": "AWS::DynamoDB::Table",
3199
+ "UpdateReplacePolicy": "Delete",
3200
+ },
3201
+ "QueryGetPostDataResolverFnQueryGetPostDataResolverFnAppSyncFunction06724190": Object {
3202
+ "DependsOn": Array [
3203
+ "PostDataSource",
3204
+ ],
3205
+ "Properties": Object {
3206
+ "ApiId": Object {
3207
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3208
+ },
3209
+ "DataSourceName": Object {
3210
+ "Fn::GetAtt": Array [
3211
+ "PostDataSource",
3212
+ "Name",
3213
+ ],
3214
+ },
3215
+ "FunctionVersion": "2018-05-29",
3216
+ "Name": "QueryGetPostDataResolverFn",
3217
+ "RequestMappingTemplateS3Location": Object {
3218
+ "Fn::Join": Array [
3219
+ "",
3220
+ Array [
3221
+ "s3://",
3222
+ Object {
3223
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
3224
+ },
3225
+ "/",
3226
+ Object {
3227
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
3228
+ },
3229
+ "/resolvers/Query.getPost.req.vtl",
3230
+ ],
3231
+ ],
3232
+ },
3233
+ "ResponseMappingTemplateS3Location": Object {
3234
+ "Fn::Join": Array [
3235
+ "",
3236
+ Array [
3237
+ "s3://",
3238
+ Object {
3239
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
3240
+ },
3241
+ "/",
3242
+ Object {
3243
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
3244
+ },
3245
+ "/resolvers/Query.getPost.res.vtl",
3246
+ ],
3247
+ ],
3248
+ },
3249
+ },
3250
+ "Type": "AWS::AppSync::FunctionConfiguration",
3251
+ },
3252
+ "QueryListPostsDataResolverFnQueryListPostsDataResolverFnAppSyncFunction3D526AB7": Object {
3253
+ "DependsOn": Array [
3254
+ "PostDataSource",
3255
+ ],
3256
+ "Properties": Object {
3257
+ "ApiId": Object {
3258
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3259
+ },
3260
+ "DataSourceName": Object {
3261
+ "Fn::GetAtt": Array [
3262
+ "PostDataSource",
3263
+ "Name",
3264
+ ],
3265
+ },
3266
+ "FunctionVersion": "2018-05-29",
3267
+ "Name": "QueryListPostsDataResolverFn",
3268
+ "RequestMappingTemplateS3Location": Object {
3269
+ "Fn::Join": Array [
3270
+ "",
3271
+ Array [
3272
+ "s3://",
3273
+ Object {
3274
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
3275
+ },
3276
+ "/",
3277
+ Object {
3278
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
3279
+ },
3280
+ "/resolvers/Query.listPosts.req.vtl",
3281
+ ],
3282
+ ],
3283
+ },
3284
+ "ResponseMappingTemplateS3Location": Object {
3285
+ "Fn::Join": Array [
3286
+ "",
3287
+ Array [
3288
+ "s3://",
3289
+ Object {
3290
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
3291
+ },
3292
+ "/",
3293
+ Object {
3294
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
3295
+ },
3296
+ "/resolvers/Query.listPosts.res.vtl",
3297
+ ],
3298
+ ],
3299
+ },
3300
+ },
3301
+ "Type": "AWS::AppSync::FunctionConfiguration",
3302
+ },
3303
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F": Object {
3304
+ "Properties": Object {
3305
+ "ApiId": Object {
3306
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3307
+ },
3308
+ "DataSourceName": Object {
3309
+ "Ref": "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name",
3310
+ },
3311
+ "FunctionVersion": "2018-05-29",
3312
+ "Name": "QuerygetPostpostAuth0Function",
3313
+ "RequestMappingTemplateS3Location": Object {
3314
+ "Fn::Join": Array [
3315
+ "",
3316
+ Array [
3317
+ "s3://",
3318
+ Object {
3319
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
3320
+ },
3321
+ "/",
3322
+ Object {
3323
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
3324
+ },
3325
+ "/resolvers/Query.getPost.postAuth.1.req.vtl",
3326
+ ],
3327
+ ],
3328
+ },
3329
+ "ResponseMappingTemplate": "$util.toJson({})",
3330
+ },
3331
+ "Type": "AWS::AppSync::FunctionConfiguration",
3332
+ },
3333
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868": Object {
3334
+ "Properties": Object {
3335
+ "ApiId": Object {
3336
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3337
+ },
3338
+ "DataSourceName": Object {
3339
+ "Ref": "referencetotransformerrootstackGraphQLAPINONEDS2BA9D1C8Name",
3340
+ },
3341
+ "FunctionVersion": "2018-05-29",
3342
+ "Name": "SubscriptionOnCreatePostDataResolverFn",
3343
+ "RequestMappingTemplateS3Location": Object {
3344
+ "Fn::Join": Array [
3345
+ "",
3346
+ Array [
3347
+ "s3://",
3348
+ Object {
3349
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
3350
+ },
3351
+ "/",
3352
+ Object {
3353
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
3354
+ },
3355
+ "/resolvers/Subscription.onCreatePost.req.vtl",
3356
+ ],
3357
+ ],
3358
+ },
3359
+ "ResponseMappingTemplateS3Location": Object {
3360
+ "Fn::Join": Array [
3361
+ "",
3362
+ Array [
3363
+ "s3://",
3364
+ Object {
3365
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
3366
+ },
3367
+ "/",
3368
+ Object {
3369
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
3370
+ },
3371
+ "/resolvers/Subscription.onCreatePost.res.vtl",
3372
+ ],
3373
+ ],
3374
+ },
3375
+ },
3376
+ "Type": "AWS::AppSync::FunctionConfiguration",
3377
+ },
3378
+ "SubscriptiononCreatePostResolver": Object {
3379
+ "Properties": Object {
3380
+ "ApiId": Object {
3381
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3382
+ },
3383
+ "FieldName": "onCreatePost",
3384
+ "Kind": "PIPELINE",
3385
+ "PipelineConfig": Object {
3386
+ "Functions": Array [
3387
+ Object {
3388
+ "Fn::GetAtt": Array [
3389
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
3390
+ "FunctionId",
3391
+ ],
3392
+ },
3393
+ Object {
3394
+ "Fn::GetAtt": Array [
3395
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868",
3396
+ "FunctionId",
3397
+ ],
3398
+ },
3399
+ ],
3400
+ },
3401
+ "RequestMappingTemplate": Object {
3402
+ "Fn::Join": Array [
3403
+ "",
3404
+ Array [
3405
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
3406
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onCreatePost\\"))
3407
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
3408
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
3409
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
3410
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
3411
+ Object {
3412
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3413
+ },
3414
+ "\\"))
3415
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
3416
+
3417
+ $util.toJson({})",
3418
+ ],
3419
+ ],
3420
+ },
3421
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
3422
+ "TypeName": "Subscription",
3423
+ },
3424
+ "Type": "AWS::AppSync::Resolver",
3425
+ },
3426
+ "SubscriptiononDeletePostResolver": Object {
3427
+ "Properties": Object {
3428
+ "ApiId": Object {
3429
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3430
+ },
3431
+ "FieldName": "onDeletePost",
3432
+ "Kind": "PIPELINE",
3433
+ "PipelineConfig": Object {
3434
+ "Functions": Array [
3435
+ Object {
3436
+ "Fn::GetAtt": Array [
3437
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
3438
+ "FunctionId",
3439
+ ],
3440
+ },
3441
+ Object {
3442
+ "Fn::GetAtt": Array [
3443
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868",
3444
+ "FunctionId",
3445
+ ],
3446
+ },
3447
+ ],
3448
+ },
3449
+ "RequestMappingTemplate": Object {
3450
+ "Fn::Join": Array [
3451
+ "",
3452
+ Array [
3453
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
3454
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onDeletePost\\"))
3455
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
3456
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
3457
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
3458
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
3459
+ Object {
3460
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3461
+ },
3462
+ "\\"))
3463
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
3464
+
3465
+ $util.toJson({})",
3466
+ ],
3467
+ ],
3468
+ },
3469
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
3470
+ "TypeName": "Subscription",
3471
+ },
3472
+ "Type": "AWS::AppSync::Resolver",
3473
+ },
3474
+ "SubscriptiononUpdatePostResolver": Object {
3475
+ "Properties": Object {
3476
+ "ApiId": Object {
3477
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3478
+ },
3479
+ "FieldName": "onUpdatePost",
3480
+ "Kind": "PIPELINE",
3481
+ "PipelineConfig": Object {
3482
+ "Functions": Array [
3483
+ Object {
3484
+ "Fn::GetAtt": Array [
3485
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
3486
+ "FunctionId",
3487
+ ],
3488
+ },
3489
+ Object {
3490
+ "Fn::GetAtt": Array [
3491
+ "SubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionB4572868",
3492
+ "FunctionId",
3493
+ ],
3494
+ },
3495
+ ],
3496
+ },
3497
+ "RequestMappingTemplate": "mockTemplate",
3498
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
3499
+ "TypeName": "Subscription",
3500
+ },
3501
+ "Type": "AWS::AppSync::Resolver",
3502
+ },
3503
+ "UpdatePostResolver": Object {
3504
+ "Properties": Object {
3505
+ "ApiId": Object {
3506
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3507
+ },
3508
+ "FieldName": "updatePost",
3509
+ "Kind": "PIPELINE",
3510
+ "PipelineConfig": Object {
3511
+ "Functions": Array [
3512
+ Object {
3513
+ "Fn::GetAtt": Array [
3514
+ "MutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunctionBAC7D532",
3515
+ "FunctionId",
3516
+ ],
3517
+ },
3518
+ Object {
3519
+ "Fn::GetAtt": Array [
3520
+ "QuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunctionC72E5C0F",
3521
+ "FunctionId",
3522
+ ],
3523
+ },
3524
+ Object {
3525
+ "Fn::GetAtt": Array [
3526
+ "MutationUpdatePostDataResolverFnMutationUpdatePostDataResolverFnAppSyncFunctionBF7D410D",
3527
+ "FunctionId",
3528
+ ],
3529
+ },
3530
+ ],
3531
+ },
3532
+ "RequestMappingTemplate": Object {
3533
+ "Fn::Join": Array [
3534
+ "",
3535
+ Array [
3536
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
3537
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"updatePost\\"))
3538
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
3539
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
3540
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
3541
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
3542
+ Object {
3543
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3544
+ },
3545
+ "\\"))
3546
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
3547
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
3548
+ Object {
3549
+ "Ref": "PostTable",
3550
+ },
3551
+ "\\"))
3552
+ $util.toJson({})",
3553
+ ],
3554
+ ],
3555
+ },
3556
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
3557
+ "TypeName": "Mutation",
3558
+ },
3559
+ "Type": "AWS::AppSync::Resolver",
3560
+ },
3561
+ },
3562
+ }
3563
+ `;
3564
+
3565
+ exports[`ModelTransformer: should override model objects when given override config 2`] = `
3566
+ Object {
3567
+ "Conditions": Object {
3568
+ "HasEnvironmentParameter": Object {
3569
+ "Fn::Not": Array [
3570
+ Object {
3571
+ "Fn::Equals": Array [
3572
+ Object {
3573
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
3574
+ },
3575
+ "NONE",
3576
+ ],
3577
+ },
3578
+ ],
3579
+ },
3580
+ "ShouldUsePayPerRequestBilling": Object {
3581
+ "Fn::Equals": Array [
3582
+ Object {
3583
+ "Ref": "DynamoDBBillingMode",
3584
+ },
3585
+ "PAY_PER_REQUEST",
3586
+ ],
3587
+ },
3588
+ "ShouldUsePointInTimeRecovery": Object {
3589
+ "Fn::Equals": Array [
3590
+ Object {
3591
+ "Ref": "DynamoDBEnablePointInTimeRecovery",
3592
+ },
3593
+ "true",
3594
+ ],
3595
+ },
3596
+ "ShouldUseServerSideEncryption": Object {
3597
+ "Fn::Equals": Array [
3598
+ Object {
3599
+ "Ref": "DynamoDBEnableServerSideEncryption",
3600
+ },
3601
+ "true",
3602
+ ],
3603
+ },
3604
+ },
3605
+ "Outputs": Object {
3606
+ "GetAttCommentDataSourceName": Object {
3607
+ "Description": "Your model DataSource name.",
3608
+ "Export": Object {
3609
+ "Name": Object {
3610
+ "Fn::Join": Array [
3611
+ ":",
3612
+ Array [
3613
+ Object {
3614
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3615
+ },
3616
+ "GetAtt:CommentDataSource:Name",
3617
+ ],
3618
+ ],
3619
+ },
3620
+ },
3621
+ "Value": Object {
3622
+ "Fn::GetAtt": Array [
3623
+ "CommentDataSource",
3624
+ "Name",
3625
+ ],
3626
+ },
3627
+ },
3628
+ "GetAttCommentTableName": Object {
3629
+ "Description": "Your DynamoDB table name.",
3630
+ "Export": Object {
3631
+ "Name": Object {
3632
+ "Fn::Join": Array [
3633
+ ":",
3634
+ Array [
3635
+ Object {
3636
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3637
+ },
3638
+ "GetAtt:CommentTable:Name",
3639
+ ],
3640
+ ],
3641
+ },
3642
+ },
3643
+ "Value": Object {
3644
+ "Ref": "CommentTable",
3645
+ },
3646
+ },
3647
+ "GetAttCommentTableStreamArn": Object {
3648
+ "Description": "Your DynamoDB table StreamArn.",
3649
+ "Export": Object {
3650
+ "Name": Object {
3651
+ "Fn::Join": Array [
3652
+ ":",
3653
+ Array [
3654
+ Object {
3655
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3656
+ },
3657
+ "GetAtt:CommentTable:StreamArn",
3658
+ ],
3659
+ ],
3660
+ },
3661
+ },
3662
+ "Value": Object {
3663
+ "Fn::GetAtt": Array [
3664
+ "CommentTable",
3665
+ "StreamArn",
3666
+ ],
3667
+ },
3668
+ },
3669
+ },
3670
+ "Parameters": Object {
3671
+ "DynamoDBBillingMode": Object {
3672
+ "AllowedValues": Array [
3673
+ "PAY_PER_REQUEST",
3674
+ "PROVISIONED",
3675
+ ],
3676
+ "Default": "PAY_PER_REQUEST",
3677
+ "Description": "Configure @model types to create DynamoDB tables with PAY_PER_REQUEST or PROVISIONED billing modes.",
3678
+ "Type": "String",
3679
+ },
3680
+ "DynamoDBEnablePointInTimeRecovery": Object {
3681
+ "AllowedValues": Array [
3682
+ "true",
3683
+ "false",
3684
+ ],
3685
+ "Default": "false",
3686
+ "Description": "Whether to enable Point in Time Recovery on the table.",
3687
+ "Type": "String",
3688
+ },
3689
+ "DynamoDBEnableServerSideEncryption": Object {
3690
+ "AllowedValues": Array [
3691
+ "true",
3692
+ "false",
3693
+ ],
3694
+ "Default": "true",
3695
+ "Description": "Enable server side encryption powered by KMS.",
3696
+ "Type": "String",
3697
+ },
3698
+ "DynamoDBModelTableReadIOPS": Object {
3699
+ "Default": 5,
3700
+ "Description": "The number of read IOPS the table should support.",
3701
+ "Type": "Number",
3702
+ },
3703
+ "DynamoDBModelTableWriteIOPS": Object {
3704
+ "Default": 5,
3705
+ "Description": "The number of write IOPS the table should support.",
3706
+ "Type": "Number",
3707
+ },
3708
+ "referencetotransformerrootstackGraphQLAPI20497F53ApiId": Object {
3709
+ "Type": "String",
3710
+ },
3711
+ "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostMutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunctionB82DB57BFunctionId": Object {
3712
+ "Type": "String",
3713
+ },
3714
+ "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostMutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunction148F70DDFunctionId": Object {
3715
+ "Type": "String",
3716
+ },
3717
+ "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId": Object {
3718
+ "Type": "String",
3719
+ },
3720
+ "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId": Object {
3721
+ "Type": "String",
3722
+ },
3723
+ "referencetotransformerrootstackS3DeploymentBucket7592718ARef": Object {
3724
+ "Type": "String",
3725
+ },
3726
+ "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref": Object {
3727
+ "Type": "String",
3728
+ },
3729
+ "referencetotransformerrootstackenv10C5A902Ref": Object {
3730
+ "Type": "String",
3731
+ },
3732
+ },
3733
+ "Resources": Object {
3734
+ "CommentDataSource": Object {
3735
+ "DependsOn": Array [
3736
+ "CommentIAMRoleD5EC5F51",
3737
+ ],
3738
+ "Properties": Object {
3739
+ "ApiId": Object {
3740
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3741
+ },
3742
+ "DynamoDBConfig": Object {
3743
+ "AwsRegion": Object {
3744
+ "Ref": "AWS::Region",
3745
+ },
3746
+ "TableName": Object {
3747
+ "Ref": "CommentTable",
3748
+ },
3749
+ },
3750
+ "Name": "CommentTable",
3751
+ "ServiceRoleArn": Object {
3752
+ "Fn::GetAtt": Array [
3753
+ "CommentIAMRoleD5EC5F51",
3754
+ "Arn",
3755
+ ],
3756
+ },
3757
+ "Type": "AMAZON_DYNAMODB",
3758
+ },
3759
+ "Type": "AWS::AppSync::DataSource",
3760
+ },
3761
+ "CommentIAMRoleD5EC5F51": Object {
3762
+ "Properties": Object {
3763
+ "AssumeRolePolicyDocument": Object {
3764
+ "Statement": Array [
3765
+ Object {
3766
+ "Action": "sts:AssumeRole",
3767
+ "Effect": "Allow",
3768
+ "Principal": Object {
3769
+ "Service": "appsync.amazonaws.com",
3770
+ },
3771
+ },
3772
+ ],
3773
+ "Version": "2012-10-17",
3774
+ },
3775
+ "RoleName": Object {
3776
+ "Fn::Join": Array [
3777
+ "",
3778
+ Array [
3779
+ "CommentIAMRole20388d-",
3780
+ Object {
3781
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3782
+ },
3783
+ "-",
3784
+ Object {
3785
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
3786
+ },
3787
+ ],
3788
+ ],
3789
+ },
3790
+ },
3791
+ "Type": "AWS::IAM::Role",
3792
+ },
3793
+ "CommentIAMRoleDefaultPolicyA8D6F6B5": Object {
3794
+ "Properties": Object {
3795
+ "PolicyDocument": Object {
3796
+ "Statement": Array [
3797
+ Object {
3798
+ "Action": Array [
3799
+ "dynamodb:BatchGetItem",
3800
+ "dynamodb:GetRecords",
3801
+ "dynamodb:GetShardIterator",
3802
+ "dynamodb:Query",
3803
+ "dynamodb:GetItem",
3804
+ "dynamodb:Scan",
3805
+ "dynamodb:ConditionCheckItem",
3806
+ "dynamodb:BatchWriteItem",
3807
+ "dynamodb:PutItem",
3808
+ "dynamodb:UpdateItem",
3809
+ "dynamodb:DeleteItem",
3810
+ "dynamodb:DescribeTable",
3811
+ ],
3812
+ "Effect": "Allow",
3813
+ "Resource": Array [
3814
+ Object {
3815
+ "Fn::GetAtt": Array [
3816
+ "CommentTable",
3817
+ "Arn",
3818
+ ],
3819
+ },
3820
+ Object {
3821
+ "Ref": "AWS::NoValue",
3822
+ },
3823
+ ],
3824
+ },
3825
+ ],
3826
+ "Version": "2012-10-17",
3827
+ },
3828
+ "PolicyName": "CommentIAMRoleDefaultPolicyA8D6F6B5",
3829
+ "Roles": Array [
3830
+ Object {
3831
+ "Ref": "CommentIAMRoleD5EC5F51",
3832
+ },
3833
+ ],
3834
+ },
3835
+ "Type": "AWS::IAM::Policy",
3836
+ },
3837
+ "CommentTable": Object {
3838
+ "DeletionPolicy": "Delete",
3839
+ "Properties": Object {
3840
+ "AttributeDefinitions": Array [
3841
+ Object {
3842
+ "AttributeName": "id",
3843
+ "AttributeType": "S",
3844
+ },
3845
+ ],
3846
+ "BillingMode": "PROVISIONED",
3847
+ "KeySchema": Array [
3848
+ Object {
3849
+ "AttributeName": "id",
3850
+ "KeyType": "HASH",
3851
+ },
3852
+ ],
3853
+ "PointInTimeRecoverySpecification": Object {
3854
+ "Fn::If": Array [
3855
+ "ShouldUsePointInTimeRecovery",
3856
+ Object {
3857
+ "PointInTimeRecoveryEnabled": true,
3858
+ },
3859
+ Object {
3860
+ "Ref": "AWS::NoValue",
3861
+ },
3862
+ ],
3863
+ },
3864
+ "ProvisionedThroughput": Object {
3865
+ "Fn::If": Array [
3866
+ "ShouldUsePayPerRequestBilling",
3867
+ Object {
3868
+ "Ref": "AWS::NoValue",
3869
+ },
3870
+ Object {
3871
+ "ReadCapacityUnits": Object {
3872
+ "Ref": "DynamoDBModelTableReadIOPS",
3873
+ },
3874
+ "WriteCapacityUnits": Object {
3875
+ "Ref": "DynamoDBModelTableWriteIOPS",
3876
+ },
3877
+ },
3878
+ ],
3879
+ },
3880
+ "SSESpecification": Object {
3881
+ "SSEEnabled": Object {
3882
+ "Fn::If": Array [
3883
+ "ShouldUseServerSideEncryption",
3884
+ true,
3885
+ false,
3886
+ ],
3887
+ },
3888
+ },
3889
+ "StreamSpecification": Object {
3890
+ "StreamViewType": "NEW_AND_OLD_IMAGES",
3891
+ },
3892
+ "TableName": Object {
3893
+ "Fn::Join": Array [
3894
+ "",
3895
+ Array [
3896
+ "Comment-",
3897
+ Object {
3898
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3899
+ },
3900
+ "-",
3901
+ Object {
3902
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
3903
+ },
3904
+ ],
3905
+ ],
3906
+ },
3907
+ },
3908
+ "Type": "AWS::DynamoDB::Table",
3909
+ "UpdateReplacePolicy": "Delete",
3910
+ },
3911
+ "CreateCommentResolver": Object {
3912
+ "Properties": Object {
3913
+ "ApiId": Object {
3914
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3915
+ },
3916
+ "FieldName": "createComment",
3917
+ "Kind": "PIPELINE",
3918
+ "PipelineConfig": Object {
3919
+ "Functions": Array [
3920
+ Object {
3921
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostMutationcreatePostinit0FunctionMutationcreatePostinit0FunctionAppSyncFunctionB82DB57BFunctionId",
3922
+ },
3923
+ Object {
3924
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
3925
+ },
3926
+ Object {
3927
+ "Fn::GetAtt": Array [
3928
+ "MutationCreateCommentDataResolverFnMutationCreateCommentDataResolverFnAppSyncFunctionD019FFE0",
3929
+ "FunctionId",
3930
+ ],
3931
+ },
3932
+ ],
3933
+ },
3934
+ "RequestMappingTemplate": Object {
3935
+ "Fn::Join": Array [
3936
+ "",
3937
+ Array [
3938
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
3939
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"createComment\\"))
3940
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
3941
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
3942
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
3943
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
3944
+ Object {
3945
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3946
+ },
3947
+ "\\"))
3948
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
3949
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
3950
+ Object {
3951
+ "Ref": "CommentTable",
3952
+ },
3953
+ "\\"))
3954
+ $util.toJson({})",
3955
+ ],
3956
+ ],
3957
+ },
3958
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
3959
+ "TypeName": "Mutation",
3960
+ },
3961
+ "Type": "AWS::AppSync::Resolver",
3962
+ },
3963
+ "DeleteCommentResolver": Object {
3964
+ "Properties": Object {
3965
+ "ApiId": Object {
3966
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3967
+ },
3968
+ "FieldName": "deleteComment",
3969
+ "Kind": "PIPELINE",
3970
+ "PipelineConfig": Object {
3971
+ "Functions": Array [
3972
+ Object {
3973
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
3974
+ },
3975
+ Object {
3976
+ "Fn::GetAtt": Array [
3977
+ "MutationDeleteCommentDataResolverFnMutationDeleteCommentDataResolverFnAppSyncFunctionD661C8CB",
3978
+ "FunctionId",
3979
+ ],
3980
+ },
3981
+ ],
3982
+ },
3983
+ "RequestMappingTemplate": Object {
3984
+ "Fn::Join": Array [
3985
+ "",
3986
+ Array [
3987
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
3988
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"deleteComment\\"))
3989
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
3990
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
3991
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
3992
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
3993
+ Object {
3994
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
3995
+ },
3996
+ "\\"))
3997
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
3998
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
3999
+ Object {
4000
+ "Ref": "CommentTable",
4001
+ },
4002
+ "\\"))
4003
+ $util.toJson({})",
4004
+ ],
4005
+ ],
4006
+ },
4007
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
4008
+ "TypeName": "Mutation",
4009
+ },
4010
+ "Type": "AWS::AppSync::Resolver",
4011
+ },
4012
+ "DynamoDBAccess71ABE5AE": Object {
4013
+ "Properties": Object {
4014
+ "PolicyDocument": Object {
4015
+ "Statement": Array [
4016
+ Object {
4017
+ "Action": Array [
4018
+ "dynamodb:BatchGetItem",
4019
+ "dynamodb:BatchWriteItem",
4020
+ "dynamodb:PutItem",
4021
+ "dynamodb:DeleteItem",
4022
+ "dynamodb:GetItem",
4023
+ "dynamodb:Scan",
4024
+ "dynamodb:Query",
4025
+ "dynamodb:UpdateItem",
4026
+ ],
4027
+ "Effect": "Allow",
4028
+ "Resource": Array [
4029
+ Object {
4030
+ "Fn::Sub": Array [
4031
+ "arn:aws:dynamodb:\${AWS::Region}:\${AWS::AccountId}:table/\${tablename}",
4032
+ Object {
4033
+ "tablename": Object {
4034
+ "Fn::Join": Array [
4035
+ "",
4036
+ Array [
4037
+ "Comment-",
4038
+ Object {
4039
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4040
+ },
4041
+ "-",
4042
+ Object {
4043
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
4044
+ },
4045
+ ],
4046
+ ],
4047
+ },
4048
+ },
4049
+ ],
4050
+ },
4051
+ Object {
4052
+ "Fn::Sub": Array [
4053
+ "arn:aws:dynamodb:\${AWS::Region}:\${AWS::AccountId}:table/\${tablename}/*",
4054
+ Object {
4055
+ "tablename": Object {
4056
+ "Fn::Join": Array [
4057
+ "",
4058
+ Array [
4059
+ "Comment-",
4060
+ Object {
4061
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4062
+ },
4063
+ "-",
4064
+ Object {
4065
+ "Ref": "referencetotransformerrootstackenv10C5A902Ref",
4066
+ },
4067
+ ],
4068
+ ],
4069
+ },
4070
+ },
4071
+ ],
4072
+ },
4073
+ ],
4074
+ },
4075
+ ],
4076
+ "Version": "2012-10-17",
4077
+ },
4078
+ "PolicyName": "DynamoDBAccess71ABE5AE",
4079
+ "Roles": Array [
4080
+ Object {
4081
+ "Ref": "CommentIAMRoleD5EC5F51",
4082
+ },
4083
+ ],
4084
+ },
4085
+ "Type": "AWS::IAM::Policy",
4086
+ },
4087
+ "GetCommentResolver": Object {
4088
+ "Properties": Object {
4089
+ "ApiId": Object {
4090
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4091
+ },
4092
+ "FieldName": "getComment",
4093
+ "Kind": "PIPELINE",
4094
+ "PipelineConfig": Object {
4095
+ "Functions": Array [
4096
+ Object {
4097
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
4098
+ },
4099
+ Object {
4100
+ "Fn::GetAtt": Array [
4101
+ "QueryGetCommentDataResolverFnQueryGetCommentDataResolverFnAppSyncFunction8473E2B0",
4102
+ "FunctionId",
4103
+ ],
4104
+ },
4105
+ ],
4106
+ },
4107
+ "RequestMappingTemplate": Object {
4108
+ "Fn::Join": Array [
4109
+ "",
4110
+ Array [
4111
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Query\\"))
4112
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"getComment\\"))
4113
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
4114
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
4115
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
4116
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
4117
+ Object {
4118
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4119
+ },
4120
+ "\\"))
4121
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
4122
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
4123
+ Object {
4124
+ "Ref": "CommentTable",
4125
+ },
4126
+ "\\"))
4127
+ $util.toJson({})",
4128
+ ],
4129
+ ],
4130
+ },
4131
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
4132
+ "TypeName": "Query",
4133
+ },
4134
+ "Type": "AWS::AppSync::Resolver",
4135
+ },
4136
+ "ListCommentResolver": Object {
4137
+ "Properties": Object {
4138
+ "ApiId": Object {
4139
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4140
+ },
4141
+ "FieldName": "listComments",
4142
+ "Kind": "PIPELINE",
4143
+ "PipelineConfig": Object {
4144
+ "Functions": Array [
4145
+ Object {
4146
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
4147
+ },
4148
+ Object {
4149
+ "Fn::GetAtt": Array [
4150
+ "QueryListCommentsDataResolverFnQueryListCommentsDataResolverFnAppSyncFunction474D4A91",
4151
+ "FunctionId",
4152
+ ],
4153
+ },
4154
+ ],
4155
+ },
4156
+ "RequestMappingTemplate": Object {
4157
+ "Fn::Join": Array [
4158
+ "",
4159
+ Array [
4160
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Query\\"))
4161
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"listComments\\"))
4162
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
4163
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
4164
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
4165
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
4166
+ Object {
4167
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4168
+ },
4169
+ "\\"))
4170
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
4171
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
4172
+ Object {
4173
+ "Ref": "CommentTable",
4174
+ },
4175
+ "\\"))
4176
+ $util.toJson({})",
4177
+ ],
4178
+ ],
4179
+ },
4180
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
4181
+ "TypeName": "Query",
4182
+ },
4183
+ "Type": "AWS::AppSync::Resolver",
4184
+ },
4185
+ "MutationCreateCommentDataResolverFnMutationCreateCommentDataResolverFnAppSyncFunctionD019FFE0": Object {
4186
+ "DependsOn": Array [
4187
+ "CommentDataSource",
4188
+ ],
4189
+ "Properties": Object {
4190
+ "ApiId": Object {
4191
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4192
+ },
4193
+ "DataSourceName": Object {
4194
+ "Fn::GetAtt": Array [
4195
+ "CommentDataSource",
4196
+ "Name",
4197
+ ],
4198
+ },
4199
+ "FunctionVersion": "2018-05-29",
4200
+ "Name": "MutationCreateCommentDataResolverFn",
4201
+ "RequestMappingTemplateS3Location": Object {
4202
+ "Fn::Join": Array [
4203
+ "",
4204
+ Array [
4205
+ "s3://",
4206
+ Object {
4207
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4208
+ },
4209
+ "/",
4210
+ Object {
4211
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4212
+ },
4213
+ "/resolvers/Mutation.createComment.req.vtl",
4214
+ ],
4215
+ ],
4216
+ },
4217
+ "ResponseMappingTemplateS3Location": Object {
4218
+ "Fn::Join": Array [
4219
+ "",
4220
+ Array [
4221
+ "s3://",
4222
+ Object {
4223
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4224
+ },
4225
+ "/",
4226
+ Object {
4227
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4228
+ },
4229
+ "/resolvers/Mutation.createComment.res.vtl",
4230
+ ],
4231
+ ],
4232
+ },
4233
+ },
4234
+ "Type": "AWS::AppSync::FunctionConfiguration",
4235
+ },
4236
+ "MutationDeleteCommentDataResolverFnMutationDeleteCommentDataResolverFnAppSyncFunctionD661C8CB": Object {
4237
+ "DependsOn": Array [
4238
+ "CommentDataSource",
4239
+ ],
4240
+ "Properties": Object {
4241
+ "ApiId": Object {
4242
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4243
+ },
4244
+ "DataSourceName": Object {
4245
+ "Fn::GetAtt": Array [
4246
+ "CommentDataSource",
4247
+ "Name",
4248
+ ],
4249
+ },
4250
+ "FunctionVersion": "2018-05-29",
4251
+ "Name": "MutationDeleteCommentDataResolverFn",
4252
+ "RequestMappingTemplateS3Location": Object {
4253
+ "Fn::Join": Array [
4254
+ "",
4255
+ Array [
4256
+ "s3://",
4257
+ Object {
4258
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4259
+ },
4260
+ "/",
4261
+ Object {
4262
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4263
+ },
4264
+ "/resolvers/Mutation.deleteComment.req.vtl",
4265
+ ],
4266
+ ],
4267
+ },
4268
+ "ResponseMappingTemplateS3Location": Object {
4269
+ "Fn::Join": Array [
4270
+ "",
4271
+ Array [
4272
+ "s3://",
4273
+ Object {
4274
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4275
+ },
4276
+ "/",
4277
+ Object {
4278
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4279
+ },
4280
+ "/resolvers/Mutation.deleteComment.res.vtl",
4281
+ ],
4282
+ ],
4283
+ },
4284
+ },
4285
+ "Type": "AWS::AppSync::FunctionConfiguration",
4286
+ },
4287
+ "MutationUpdateCommentDataResolverFnMutationUpdateCommentDataResolverFnAppSyncFunctionB47372B5": Object {
4288
+ "DependsOn": Array [
4289
+ "CommentDataSource",
4290
+ ],
4291
+ "Properties": Object {
4292
+ "ApiId": Object {
4293
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4294
+ },
4295
+ "DataSourceName": Object {
4296
+ "Fn::GetAtt": Array [
4297
+ "CommentDataSource",
4298
+ "Name",
4299
+ ],
4300
+ },
4301
+ "FunctionVersion": "2018-05-29",
4302
+ "Name": "MutationUpdateCommentDataResolverFn",
4303
+ "RequestMappingTemplateS3Location": Object {
4304
+ "Fn::Join": Array [
4305
+ "",
4306
+ Array [
4307
+ "s3://",
4308
+ Object {
4309
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4310
+ },
4311
+ "/",
4312
+ Object {
4313
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4314
+ },
4315
+ "/resolvers/Mutation.updateComment.req.vtl",
4316
+ ],
4317
+ ],
4318
+ },
4319
+ "ResponseMappingTemplateS3Location": Object {
4320
+ "Fn::Join": Array [
4321
+ "",
4322
+ Array [
4323
+ "s3://",
4324
+ Object {
4325
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4326
+ },
4327
+ "/",
4328
+ Object {
4329
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4330
+ },
4331
+ "/resolvers/Mutation.updateComment.res.vtl",
4332
+ ],
4333
+ ],
4334
+ },
4335
+ },
4336
+ "Type": "AWS::AppSync::FunctionConfiguration",
4337
+ },
4338
+ "QueryGetCommentDataResolverFnQueryGetCommentDataResolverFnAppSyncFunction8473E2B0": Object {
4339
+ "DependsOn": Array [
4340
+ "CommentDataSource",
4341
+ ],
4342
+ "Properties": Object {
4343
+ "ApiId": Object {
4344
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4345
+ },
4346
+ "DataSourceName": Object {
4347
+ "Fn::GetAtt": Array [
4348
+ "CommentDataSource",
4349
+ "Name",
4350
+ ],
4351
+ },
4352
+ "FunctionVersion": "2018-05-29",
4353
+ "Name": "QueryGetCommentDataResolverFn",
4354
+ "RequestMappingTemplateS3Location": Object {
4355
+ "Fn::Join": Array [
4356
+ "",
4357
+ Array [
4358
+ "s3://",
4359
+ Object {
4360
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4361
+ },
4362
+ "/",
4363
+ Object {
4364
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4365
+ },
4366
+ "/resolvers/Query.getComment.req.vtl",
4367
+ ],
4368
+ ],
4369
+ },
4370
+ "ResponseMappingTemplateS3Location": Object {
4371
+ "Fn::Join": Array [
4372
+ "",
4373
+ Array [
4374
+ "s3://",
4375
+ Object {
4376
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4377
+ },
4378
+ "/",
4379
+ Object {
4380
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4381
+ },
4382
+ "/resolvers/Query.getComment.res.vtl",
4383
+ ],
4384
+ ],
4385
+ },
4386
+ },
4387
+ "Type": "AWS::AppSync::FunctionConfiguration",
4388
+ },
4389
+ "QueryListCommentsDataResolverFnQueryListCommentsDataResolverFnAppSyncFunction474D4A91": Object {
4390
+ "DependsOn": Array [
4391
+ "CommentDataSource",
4392
+ ],
4393
+ "Properties": Object {
4394
+ "ApiId": Object {
4395
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4396
+ },
4397
+ "DataSourceName": Object {
4398
+ "Fn::GetAtt": Array [
4399
+ "CommentDataSource",
4400
+ "Name",
4401
+ ],
4402
+ },
4403
+ "FunctionVersion": "2018-05-29",
4404
+ "Name": "QueryListCommentsDataResolverFn",
4405
+ "RequestMappingTemplateS3Location": Object {
4406
+ "Fn::Join": Array [
4407
+ "",
4408
+ Array [
4409
+ "s3://",
4410
+ Object {
4411
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4412
+ },
4413
+ "/",
4414
+ Object {
4415
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4416
+ },
4417
+ "/resolvers/Query.listComments.req.vtl",
4418
+ ],
4419
+ ],
4420
+ },
4421
+ "ResponseMappingTemplateS3Location": Object {
4422
+ "Fn::Join": Array [
4423
+ "",
4424
+ Array [
4425
+ "s3://",
4426
+ Object {
4427
+ "Ref": "referencetotransformerrootstackS3DeploymentBucket7592718ARef",
4428
+ },
4429
+ "/",
4430
+ Object {
4431
+ "Ref": "referencetotransformerrootstackS3DeploymentRootKeyA71EA735Ref",
4432
+ },
4433
+ "/resolvers/Query.listComments.res.vtl",
4434
+ ],
4435
+ ],
4436
+ },
4437
+ },
4438
+ "Type": "AWS::AppSync::FunctionConfiguration",
4439
+ },
4440
+ "SubscriptiononCreateCommentResolver": Object {
4441
+ "Properties": Object {
4442
+ "ApiId": Object {
4443
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4444
+ },
4445
+ "FieldName": "onCreateComment",
4446
+ "Kind": "PIPELINE",
4447
+ "PipelineConfig": Object {
4448
+ "Functions": Array [
4449
+ Object {
4450
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
4451
+ },
4452
+ Object {
4453
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId",
4454
+ },
4455
+ ],
4456
+ },
4457
+ "RequestMappingTemplate": Object {
4458
+ "Fn::Join": Array [
4459
+ "",
4460
+ Array [
4461
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
4462
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onCreateComment\\"))
4463
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
4464
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
4465
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
4466
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
4467
+ Object {
4468
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4469
+ },
4470
+ "\\"))
4471
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
4472
+
4473
+ $util.toJson({})",
4474
+ ],
4475
+ ],
4476
+ },
4477
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
4478
+ "TypeName": "Subscription",
4479
+ },
4480
+ "Type": "AWS::AppSync::Resolver",
4481
+ },
4482
+ "SubscriptiononDeleteCommentResolver": Object {
4483
+ "Properties": Object {
4484
+ "ApiId": Object {
4485
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4486
+ },
4487
+ "FieldName": "onDeleteComment",
4488
+ "Kind": "PIPELINE",
4489
+ "PipelineConfig": Object {
4490
+ "Functions": Array [
4491
+ Object {
4492
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
4493
+ },
4494
+ Object {
4495
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId",
4496
+ },
4497
+ ],
4498
+ },
4499
+ "RequestMappingTemplate": Object {
4500
+ "Fn::Join": Array [
4501
+ "",
4502
+ Array [
4503
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
4504
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onDeleteComment\\"))
4505
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
4506
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
4507
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
4508
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
4509
+ Object {
4510
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4511
+ },
4512
+ "\\"))
4513
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
4514
+
4515
+ $util.toJson({})",
4516
+ ],
4517
+ ],
4518
+ },
4519
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
4520
+ "TypeName": "Subscription",
4521
+ },
4522
+ "Type": "AWS::AppSync::Resolver",
4523
+ },
4524
+ "SubscriptiononUpdateCommentResolver": Object {
4525
+ "Properties": Object {
4526
+ "ApiId": Object {
4527
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4528
+ },
4529
+ "FieldName": "onUpdateComment",
4530
+ "Kind": "PIPELINE",
4531
+ "PipelineConfig": Object {
4532
+ "Functions": Array [
4533
+ Object {
4534
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
4535
+ },
4536
+ Object {
4537
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostSubscriptionOnCreatePostDataResolverFnSubscriptionOnCreatePostDataResolverFnAppSyncFunctionAE3ECF1FFunctionId",
4538
+ },
4539
+ ],
4540
+ },
4541
+ "RequestMappingTemplate": Object {
4542
+ "Fn::Join": Array [
4543
+ "",
4544
+ Array [
4545
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Subscription\\"))
4546
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"onUpdateComment\\"))
4547
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
4548
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
4549
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"NONE\\"))
4550
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
4551
+ Object {
4552
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4553
+ },
4554
+ "\\"))
4555
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
4556
+
4557
+ $util.toJson({})",
4558
+ ],
4559
+ ],
4560
+ },
4561
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
4562
+ "TypeName": "Subscription",
4563
+ },
4564
+ "Type": "AWS::AppSync::Resolver",
4565
+ },
4566
+ "UpdateCommentResolver": Object {
4567
+ "Properties": Object {
4568
+ "ApiId": Object {
4569
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4570
+ },
4571
+ "FieldName": "updateComment",
4572
+ "Kind": "PIPELINE",
4573
+ "PipelineConfig": Object {
4574
+ "Functions": Array [
4575
+ Object {
4576
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostMutationupdatePostinit0FunctionMutationupdatePostinit0FunctionAppSyncFunction148F70DDFunctionId",
4577
+ },
4578
+ Object {
4579
+ "Ref": "referencetotransformerrootstackPostNestedStackPostNestedStackResource45FCAC5EOutputstransformerrootstackPostQuerygetPostpostAuth0FunctionQuerygetPostpostAuth0FunctionAppSyncFunction052A79B2FunctionId",
4580
+ },
4581
+ Object {
4582
+ "Fn::GetAtt": Array [
4583
+ "MutationUpdateCommentDataResolverFnMutationUpdateCommentDataResolverFnAppSyncFunctionB47372B5",
4584
+ "FunctionId",
4585
+ ],
4586
+ },
4587
+ ],
4588
+ },
4589
+ "RequestMappingTemplate": Object {
4590
+ "Fn::Join": Array [
4591
+ "",
4592
+ Array [
4593
+ "$util.qr($ctx.stash.put(\\"typeName\\", \\"Mutation\\"))
4594
+ $util.qr($ctx.stash.put(\\"fieldName\\", \\"updateComment\\"))
4595
+ $util.qr($ctx.stash.put(\\"conditions\\", []))
4596
+ $util.qr($ctx.stash.put(\\"metadata\\", {}))
4597
+ $util.qr($ctx.stash.metadata.put(\\"dataSourceType\\", \\"AMAZON_DYNAMODB\\"))
4598
+ $util.qr($ctx.stash.metadata.put(\\"apiId\\", \\"",
4599
+ Object {
4600
+ "Ref": "referencetotransformerrootstackGraphQLAPI20497F53ApiId",
4601
+ },
4602
+ "\\"))
4603
+ $util.qr($ctx.stash.put(\\"connectionAttributes\\", {}))
4604
+ $util.qr($ctx.stash.put(\\"tableName\\", \\"",
4605
+ Object {
4606
+ "Ref": "CommentTable",
4607
+ },
4608
+ "\\"))
4609
+ $util.toJson({})",
4610
+ ],
4611
+ ],
4612
+ },
4613
+ "ResponseMappingTemplate": "$util.toJson($ctx.prev.result)",
4614
+ "TypeName": "Mutation",
4615
+ },
4616
+ "Type": "AWS::AppSync::Resolver",
4617
+ },
4618
+ },
4619
+ }
4620
+ `;