cdk-appsync-typescript-resolver 0.0.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.
- package/.gitattributes +23 -0
- package/.jsii +3591 -0
- package/.projenrc.ts +26 -0
- package/API.md +782 -0
- package/LICENSE +202 -0
- package/README.md +40 -0
- package/lib/AppsyncTypescriptFunction.d.ts +22 -0
- package/lib/AppsyncTypescriptFunction.js +28 -0
- package/lib/TSExpressPipelineResolver.d.ts +15 -0
- package/lib/TSExpressPipelineResolver.js +33 -0
- package/lib/bundler.d.ts +9 -0
- package/lib/bundler.js +28 -0
- package/lib/index.d.ts +2 -0
- package/lib/index.js +19 -0
- package/node_modules/@esbuild/linux-x64/README.md +3 -0
- package/node_modules/@esbuild/linux-x64/bin/esbuild +0 -0
- package/node_modules/@esbuild/linux-x64/package.json +17 -0
- package/node_modules/esbuild/LICENSE.md +21 -0
- package/node_modules/esbuild/README.md +3 -0
- package/node_modules/esbuild/bin/esbuild +221 -0
- package/node_modules/esbuild/install.js +287 -0
- package/node_modules/esbuild/lib/main.d.ts +657 -0
- package/node_modules/esbuild/lib/main.js +2392 -0
- package/node_modules/esbuild/package.json +42 -0
- package/package.json +134 -0
package/API.md
ADDED
|
@@ -0,0 +1,782 @@
|
|
|
1
|
+
# cdk-appsync-typescript-resolver
|
|
2
|
+
|
|
3
|
+
[](https://github.com/sudokar/nx-serverless/blob/master/LICENSE)
|
|
4
|
+
[](https://github.com/sudokar/nx-serverless)
|
|
5
|
+

|
|
6
|
+
|
|
7
|
+
Constructs to transpile and bundle Typescript to valid AWS Appsync's JS resolvers
|
|
8
|
+
|
|
9
|
+
# ✨ Highlights
|
|
10
|
+
|
|
11
|
+
- [AppsyncTypescriptFunction](src%2Flib%2FAppsyncTypescriptFunction.ts) - CDK construct to transpile and bundle Typescript
|
|
12
|
+
- [TSExpressPipelineResolver](src%2Flib%2FJSExpressPipelineResolver.ts) - CDK construct to use AppsyncTypescriptFunction with boilerplate code
|
|
13
|
+
|
|
14
|
+
# 🚀 Usage
|
|
15
|
+
|
|
16
|
+
- AppsyncTypescriptFunction
|
|
17
|
+
```typescript
|
|
18
|
+
import { AppsyncTypescriptFunction } from 'cdk-appsync-typescript-resolver'
|
|
19
|
+
...
|
|
20
|
+
const appsyncFunction = new AppsyncTypescriptFunction(stack, "TSDemoFunction", {
|
|
21
|
+
name: "TSDemoFunction",
|
|
22
|
+
api: new appsync.GraphqlApi(...),
|
|
23
|
+
path: path.join(__dirname, "path", "to", "file.ts"),
|
|
24
|
+
dataSource: new appsync.DynamoDbDataSource(...),
|
|
25
|
+
sourceMap,
|
|
26
|
+
});
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
- TSExpressPipelineResolver
|
|
30
|
+
|
|
31
|
+
```typescript
|
|
32
|
+
import { TSExpressPipelineResolver } from 'cdk-appsync-typescript-resolver'
|
|
33
|
+
...
|
|
34
|
+
const resolver = new TSExpressPipelineResolver(testStack, "DemoResolver", {
|
|
35
|
+
api: new appsync.GraphqlApi(...),
|
|
36
|
+
typeName: "Query",
|
|
37
|
+
fieldName: "hello",
|
|
38
|
+
typescriptFunction: new AppsyncTypescriptFunction(...),
|
|
39
|
+
});
|
|
40
|
+
```
|
|
41
|
+
# API Reference <a name="API Reference" id="api-reference"></a>
|
|
42
|
+
|
|
43
|
+
## Constructs <a name="Constructs" id="Constructs"></a>
|
|
44
|
+
|
|
45
|
+
### AppsyncTypescriptFunction <a name="AppsyncTypescriptFunction" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction"></a>
|
|
46
|
+
|
|
47
|
+
Transpile and bundle Typescript to AWS Appsync JS function.
|
|
48
|
+
|
|
49
|
+
#### Initializers <a name="Initializers" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.Initializer"></a>
|
|
50
|
+
|
|
51
|
+
```typescript
|
|
52
|
+
import { AppsyncTypescriptFunction } from 'cdk-appsync-typescript-resolver'
|
|
53
|
+
|
|
54
|
+
new AppsyncTypescriptFunction(scope: IConstruct, id: string, props: AppsyncTypescriptFunctionProps)
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
| **Name** | **Type** | **Description** |
|
|
58
|
+
| --- | --- | --- |
|
|
59
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.Initializer.parameter.scope">scope</a></code> | <code>constructs.IConstruct</code> | *No description.* |
|
|
60
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.Initializer.parameter.id">id</a></code> | <code>string</code> | *No description.* |
|
|
61
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.Initializer.parameter.props">props</a></code> | <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps">AppsyncTypescriptFunctionProps</a></code> | *No description.* |
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
##### `scope`<sup>Required</sup> <a name="scope" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.Initializer.parameter.scope"></a>
|
|
66
|
+
|
|
67
|
+
- *Type:* constructs.IConstruct
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
##### `id`<sup>Required</sup> <a name="id" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.Initializer.parameter.id"></a>
|
|
72
|
+
|
|
73
|
+
- *Type:* string
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
##### `props`<sup>Required</sup> <a name="props" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.Initializer.parameter.props"></a>
|
|
78
|
+
|
|
79
|
+
- *Type:* <a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps">AppsyncTypescriptFunctionProps</a>
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
#### Methods <a name="Methods" id="Methods"></a>
|
|
84
|
+
|
|
85
|
+
| **Name** | **Description** |
|
|
86
|
+
| --- | --- |
|
|
87
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.toString">toString</a></code> | Returns a string representation of this construct. |
|
|
88
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.applyRemovalPolicy">applyRemovalPolicy</a></code> | Apply the given removal policy to this resource. |
|
|
89
|
+
|
|
90
|
+
---
|
|
91
|
+
|
|
92
|
+
##### `toString` <a name="toString" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.toString"></a>
|
|
93
|
+
|
|
94
|
+
```typescript
|
|
95
|
+
public toString(): string
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Returns a string representation of this construct.
|
|
99
|
+
|
|
100
|
+
##### `applyRemovalPolicy` <a name="applyRemovalPolicy" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.applyRemovalPolicy"></a>
|
|
101
|
+
|
|
102
|
+
```typescript
|
|
103
|
+
public applyRemovalPolicy(policy: RemovalPolicy): void
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
Apply the given removal policy to this resource.
|
|
107
|
+
|
|
108
|
+
The Removal Policy controls what happens to this resource when it stops
|
|
109
|
+
being managed by CloudFormation, either because you've removed it from the
|
|
110
|
+
CDK application or because you've made a change that requires the resource
|
|
111
|
+
to be replaced.
|
|
112
|
+
|
|
113
|
+
The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
|
|
114
|
+
account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
|
|
115
|
+
|
|
116
|
+
###### `policy`<sup>Required</sup> <a name="policy" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.applyRemovalPolicy.parameter.policy"></a>
|
|
117
|
+
|
|
118
|
+
- *Type:* aws-cdk-lib.RemovalPolicy
|
|
119
|
+
|
|
120
|
+
---
|
|
121
|
+
|
|
122
|
+
#### Static Functions <a name="Static Functions" id="Static Functions"></a>
|
|
123
|
+
|
|
124
|
+
| **Name** | **Description** |
|
|
125
|
+
| --- | --- |
|
|
126
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isConstruct">isConstruct</a></code> | Checks if `x` is a construct. |
|
|
127
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isOwnedResource">isOwnedResource</a></code> | Returns true if the construct was created by CDK, and false otherwise. |
|
|
128
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isResource">isResource</a></code> | Check whether the given construct is a Resource. |
|
|
129
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.fromAppsyncFunctionAttributes">fromAppsyncFunctionAttributes</a></code> | Import Appsync Function from arn. |
|
|
130
|
+
|
|
131
|
+
---
|
|
132
|
+
|
|
133
|
+
##### ~~`isConstruct`~~ <a name="isConstruct" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isConstruct"></a>
|
|
134
|
+
|
|
135
|
+
```typescript
|
|
136
|
+
import { AppsyncTypescriptFunction } from 'cdk-appsync-typescript-resolver'
|
|
137
|
+
|
|
138
|
+
AppsyncTypescriptFunction.isConstruct(x: any)
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
Checks if `x` is a construct.
|
|
142
|
+
|
|
143
|
+
###### `x`<sup>Required</sup> <a name="x" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isConstruct.parameter.x"></a>
|
|
144
|
+
|
|
145
|
+
- *Type:* any
|
|
146
|
+
|
|
147
|
+
Any object.
|
|
148
|
+
|
|
149
|
+
---
|
|
150
|
+
|
|
151
|
+
##### `isOwnedResource` <a name="isOwnedResource" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isOwnedResource"></a>
|
|
152
|
+
|
|
153
|
+
```typescript
|
|
154
|
+
import { AppsyncTypescriptFunction } from 'cdk-appsync-typescript-resolver'
|
|
155
|
+
|
|
156
|
+
AppsyncTypescriptFunction.isOwnedResource(construct: IConstruct)
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
Returns true if the construct was created by CDK, and false otherwise.
|
|
160
|
+
|
|
161
|
+
###### `construct`<sup>Required</sup> <a name="construct" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isOwnedResource.parameter.construct"></a>
|
|
162
|
+
|
|
163
|
+
- *Type:* constructs.IConstruct
|
|
164
|
+
|
|
165
|
+
---
|
|
166
|
+
|
|
167
|
+
##### `isResource` <a name="isResource" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isResource"></a>
|
|
168
|
+
|
|
169
|
+
```typescript
|
|
170
|
+
import { AppsyncTypescriptFunction } from 'cdk-appsync-typescript-resolver'
|
|
171
|
+
|
|
172
|
+
AppsyncTypescriptFunction.isResource(construct: IConstruct)
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
Check whether the given construct is a Resource.
|
|
176
|
+
|
|
177
|
+
###### `construct`<sup>Required</sup> <a name="construct" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.isResource.parameter.construct"></a>
|
|
178
|
+
|
|
179
|
+
- *Type:* constructs.IConstruct
|
|
180
|
+
|
|
181
|
+
---
|
|
182
|
+
|
|
183
|
+
##### `fromAppsyncFunctionAttributes` <a name="fromAppsyncFunctionAttributes" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.fromAppsyncFunctionAttributes"></a>
|
|
184
|
+
|
|
185
|
+
```typescript
|
|
186
|
+
import { AppsyncTypescriptFunction } from 'cdk-appsync-typescript-resolver'
|
|
187
|
+
|
|
188
|
+
AppsyncTypescriptFunction.fromAppsyncFunctionAttributes(scope: Construct, id: string, attrs: AppsyncFunctionAttributes)
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
Import Appsync Function from arn.
|
|
192
|
+
|
|
193
|
+
###### `scope`<sup>Required</sup> <a name="scope" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.fromAppsyncFunctionAttributes.parameter.scope"></a>
|
|
194
|
+
|
|
195
|
+
- *Type:* constructs.Construct
|
|
196
|
+
|
|
197
|
+
---
|
|
198
|
+
|
|
199
|
+
###### `id`<sup>Required</sup> <a name="id" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.fromAppsyncFunctionAttributes.parameter.id"></a>
|
|
200
|
+
|
|
201
|
+
- *Type:* string
|
|
202
|
+
|
|
203
|
+
---
|
|
204
|
+
|
|
205
|
+
###### `attrs`<sup>Required</sup> <a name="attrs" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.fromAppsyncFunctionAttributes.parameter.attrs"></a>
|
|
206
|
+
|
|
207
|
+
- *Type:* aws-cdk-lib.aws_appsync.AppsyncFunctionAttributes
|
|
208
|
+
|
|
209
|
+
---
|
|
210
|
+
|
|
211
|
+
#### Properties <a name="Properties" id="Properties"></a>
|
|
212
|
+
|
|
213
|
+
| **Name** | **Type** | **Description** |
|
|
214
|
+
| --- | --- | --- |
|
|
215
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.node">node</a></code> | <code>constructs.Node</code> | The tree node. |
|
|
216
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.env">env</a></code> | <code>aws-cdk-lib.ResourceEnvironment</code> | The environment this resource belongs to. |
|
|
217
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.stack">stack</a></code> | <code>aws-cdk-lib.Stack</code> | The stack in which this resource is defined. |
|
|
218
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.dataSource">dataSource</a></code> | <code>aws-cdk-lib.aws_appsync.BaseDataSource</code> | the data source of this AppSync Function. |
|
|
219
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.functionArn">functionArn</a></code> | <code>string</code> | the ARN of the AppSync function. |
|
|
220
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.functionId">functionId</a></code> | <code>string</code> | the ID of the AppSync function. |
|
|
221
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.functionName">functionName</a></code> | <code>string</code> | the name of this AppSync Function. |
|
|
222
|
+
|
|
223
|
+
---
|
|
224
|
+
|
|
225
|
+
##### `node`<sup>Required</sup> <a name="node" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.node"></a>
|
|
226
|
+
|
|
227
|
+
```typescript
|
|
228
|
+
public readonly node: Node;
|
|
229
|
+
```
|
|
230
|
+
|
|
231
|
+
- *Type:* constructs.Node
|
|
232
|
+
|
|
233
|
+
The tree node.
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
237
|
+
##### `env`<sup>Required</sup> <a name="env" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.env"></a>
|
|
238
|
+
|
|
239
|
+
```typescript
|
|
240
|
+
public readonly env: ResourceEnvironment;
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
- *Type:* aws-cdk-lib.ResourceEnvironment
|
|
244
|
+
|
|
245
|
+
The environment this resource belongs to.
|
|
246
|
+
|
|
247
|
+
For resources that are created and managed by the CDK
|
|
248
|
+
(generally, those created by creating new class instances like Role, Bucket, etc.),
|
|
249
|
+
this is always the same as the environment of the stack they belong to;
|
|
250
|
+
however, for imported resources
|
|
251
|
+
(those obtained from static methods like fromRoleArn, fromBucketName, etc.),
|
|
252
|
+
that might be different than the stack they were imported into.
|
|
253
|
+
|
|
254
|
+
---
|
|
255
|
+
|
|
256
|
+
##### `stack`<sup>Required</sup> <a name="stack" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.stack"></a>
|
|
257
|
+
|
|
258
|
+
```typescript
|
|
259
|
+
public readonly stack: Stack;
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
- *Type:* aws-cdk-lib.Stack
|
|
263
|
+
|
|
264
|
+
The stack in which this resource is defined.
|
|
265
|
+
|
|
266
|
+
---
|
|
267
|
+
|
|
268
|
+
##### `dataSource`<sup>Required</sup> <a name="dataSource" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.dataSource"></a>
|
|
269
|
+
|
|
270
|
+
```typescript
|
|
271
|
+
public readonly dataSource: BaseDataSource;
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
- *Type:* aws-cdk-lib.aws_appsync.BaseDataSource
|
|
275
|
+
|
|
276
|
+
the data source of this AppSync Function.
|
|
277
|
+
|
|
278
|
+
---
|
|
279
|
+
|
|
280
|
+
##### `functionArn`<sup>Required</sup> <a name="functionArn" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.functionArn"></a>
|
|
281
|
+
|
|
282
|
+
```typescript
|
|
283
|
+
public readonly functionArn: string;
|
|
284
|
+
```
|
|
285
|
+
|
|
286
|
+
- *Type:* string
|
|
287
|
+
|
|
288
|
+
the ARN of the AppSync function.
|
|
289
|
+
|
|
290
|
+
---
|
|
291
|
+
|
|
292
|
+
##### `functionId`<sup>Required</sup> <a name="functionId" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.functionId"></a>
|
|
293
|
+
|
|
294
|
+
```typescript
|
|
295
|
+
public readonly functionId: string;
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
- *Type:* string
|
|
299
|
+
|
|
300
|
+
the ID of the AppSync function.
|
|
301
|
+
|
|
302
|
+
---
|
|
303
|
+
|
|
304
|
+
##### `functionName`<sup>Required</sup> <a name="functionName" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunction.property.functionName"></a>
|
|
305
|
+
|
|
306
|
+
```typescript
|
|
307
|
+
public readonly functionName: string;
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
- *Type:* string
|
|
311
|
+
|
|
312
|
+
the name of this AppSync Function.
|
|
313
|
+
|
|
314
|
+
---
|
|
315
|
+
|
|
316
|
+
|
|
317
|
+
### TSExpressPipelineResolver <a name="TSExpressPipelineResolver" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver"></a>
|
|
318
|
+
|
|
319
|
+
Appsync's JS pipeline resolver with default bolierplate code using AppsyncTypescriptFunction construct.
|
|
320
|
+
|
|
321
|
+
#### Initializers <a name="Initializers" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.Initializer"></a>
|
|
322
|
+
|
|
323
|
+
```typescript
|
|
324
|
+
import { TSExpressPipelineResolver } from 'cdk-appsync-typescript-resolver'
|
|
325
|
+
|
|
326
|
+
new TSExpressPipelineResolver(scope: IConstruct, id: string, props: TSExpressPipelineResolverProps)
|
|
327
|
+
```
|
|
328
|
+
|
|
329
|
+
| **Name** | **Type** | **Description** |
|
|
330
|
+
| --- | --- | --- |
|
|
331
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolver.Initializer.parameter.scope">scope</a></code> | <code>constructs.IConstruct</code> | *No description.* |
|
|
332
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolver.Initializer.parameter.id">id</a></code> | <code>string</code> | *No description.* |
|
|
333
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolver.Initializer.parameter.props">props</a></code> | <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps">TSExpressPipelineResolverProps</a></code> | *No description.* |
|
|
334
|
+
|
|
335
|
+
---
|
|
336
|
+
|
|
337
|
+
##### `scope`<sup>Required</sup> <a name="scope" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.Initializer.parameter.scope"></a>
|
|
338
|
+
|
|
339
|
+
- *Type:* constructs.IConstruct
|
|
340
|
+
|
|
341
|
+
---
|
|
342
|
+
|
|
343
|
+
##### `id`<sup>Required</sup> <a name="id" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.Initializer.parameter.id"></a>
|
|
344
|
+
|
|
345
|
+
- *Type:* string
|
|
346
|
+
|
|
347
|
+
---
|
|
348
|
+
|
|
349
|
+
##### `props`<sup>Required</sup> <a name="props" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.Initializer.parameter.props"></a>
|
|
350
|
+
|
|
351
|
+
- *Type:* <a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps">TSExpressPipelineResolverProps</a>
|
|
352
|
+
|
|
353
|
+
---
|
|
354
|
+
|
|
355
|
+
#### Methods <a name="Methods" id="Methods"></a>
|
|
356
|
+
|
|
357
|
+
| **Name** | **Description** |
|
|
358
|
+
| --- | --- |
|
|
359
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolver.toString">toString</a></code> | Returns a string representation of this construct. |
|
|
360
|
+
|
|
361
|
+
---
|
|
362
|
+
|
|
363
|
+
##### `toString` <a name="toString" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.toString"></a>
|
|
364
|
+
|
|
365
|
+
```typescript
|
|
366
|
+
public toString(): string
|
|
367
|
+
```
|
|
368
|
+
|
|
369
|
+
Returns a string representation of this construct.
|
|
370
|
+
|
|
371
|
+
#### Static Functions <a name="Static Functions" id="Static Functions"></a>
|
|
372
|
+
|
|
373
|
+
| **Name** | **Description** |
|
|
374
|
+
| --- | --- |
|
|
375
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolver.isConstruct">isConstruct</a></code> | Checks if `x` is a construct. |
|
|
376
|
+
|
|
377
|
+
---
|
|
378
|
+
|
|
379
|
+
##### ~~`isConstruct`~~ <a name="isConstruct" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.isConstruct"></a>
|
|
380
|
+
|
|
381
|
+
```typescript
|
|
382
|
+
import { TSExpressPipelineResolver } from 'cdk-appsync-typescript-resolver'
|
|
383
|
+
|
|
384
|
+
TSExpressPipelineResolver.isConstruct(x: any)
|
|
385
|
+
```
|
|
386
|
+
|
|
387
|
+
Checks if `x` is a construct.
|
|
388
|
+
|
|
389
|
+
###### `x`<sup>Required</sup> <a name="x" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.isConstruct.parameter.x"></a>
|
|
390
|
+
|
|
391
|
+
- *Type:* any
|
|
392
|
+
|
|
393
|
+
Any object.
|
|
394
|
+
|
|
395
|
+
---
|
|
396
|
+
|
|
397
|
+
#### Properties <a name="Properties" id="Properties"></a>
|
|
398
|
+
|
|
399
|
+
| **Name** | **Type** | **Description** |
|
|
400
|
+
| --- | --- | --- |
|
|
401
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolver.property.node">node</a></code> | <code>constructs.Node</code> | The tree node. |
|
|
402
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolver.property.arn">arn</a></code> | <code>string</code> | the ARN of the resolver. |
|
|
403
|
+
|
|
404
|
+
---
|
|
405
|
+
|
|
406
|
+
##### `node`<sup>Required</sup> <a name="node" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.property.node"></a>
|
|
407
|
+
|
|
408
|
+
```typescript
|
|
409
|
+
public readonly node: Node;
|
|
410
|
+
```
|
|
411
|
+
|
|
412
|
+
- *Type:* constructs.Node
|
|
413
|
+
|
|
414
|
+
The tree node.
|
|
415
|
+
|
|
416
|
+
---
|
|
417
|
+
|
|
418
|
+
##### `arn`<sup>Required</sup> <a name="arn" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolver.property.arn"></a>
|
|
419
|
+
|
|
420
|
+
```typescript
|
|
421
|
+
public readonly arn: string;
|
|
422
|
+
```
|
|
423
|
+
|
|
424
|
+
- *Type:* string
|
|
425
|
+
|
|
426
|
+
the ARN of the resolver.
|
|
427
|
+
|
|
428
|
+
---
|
|
429
|
+
|
|
430
|
+
|
|
431
|
+
## Structs <a name="Structs" id="Structs"></a>
|
|
432
|
+
|
|
433
|
+
### AppsyncTypescriptFunctionProps <a name="AppsyncTypescriptFunctionProps" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps"></a>
|
|
434
|
+
|
|
435
|
+
#### Initializer <a name="Initializer" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.Initializer"></a>
|
|
436
|
+
|
|
437
|
+
```typescript
|
|
438
|
+
import { AppsyncTypescriptFunctionProps } from 'cdk-appsync-typescript-resolver'
|
|
439
|
+
|
|
440
|
+
const appsyncTypescriptFunctionProps: AppsyncTypescriptFunctionProps = { ... }
|
|
441
|
+
```
|
|
442
|
+
|
|
443
|
+
#### Properties <a name="Properties" id="Properties"></a>
|
|
444
|
+
|
|
445
|
+
| **Name** | **Type** | **Description** |
|
|
446
|
+
| --- | --- | --- |
|
|
447
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.name">name</a></code> | <code>string</code> | the name of the AppSync Function. |
|
|
448
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.code">code</a></code> | <code>aws-cdk-lib.aws_appsync.Code</code> | The function code. |
|
|
449
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.description">description</a></code> | <code>string</code> | the description for this AppSync Function. |
|
|
450
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.requestMappingTemplate">requestMappingTemplate</a></code> | <code>aws-cdk-lib.aws_appsync.MappingTemplate</code> | the request mapping template for the AppSync Function. |
|
|
451
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.responseMappingTemplate">responseMappingTemplate</a></code> | <code>aws-cdk-lib.aws_appsync.MappingTemplate</code> | the response mapping template for the AppSync Function. |
|
|
452
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.runtime">runtime</a></code> | <code>aws-cdk-lib.aws_appsync.FunctionRuntime</code> | The functions runtime. |
|
|
453
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.api">api</a></code> | <code>aws-cdk-lib.aws_appsync.IGraphqlApi</code> | the GraphQL Api linked to this AppSync Function. |
|
|
454
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.dataSource">dataSource</a></code> | <code>aws-cdk-lib.aws_appsync.BaseDataSource</code> | the data source linked to this AppSync Function. |
|
|
455
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.path">path</a></code> | <code>string</code> | Path of typescript file that will be transpiled and bundled. |
|
|
456
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.replaceStrings">replaceStrings</a></code> | <code>{[ key: string ]: string}</code> | A map of replacement strings in the bundled code. |
|
|
457
|
+
| <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.sourceMap">sourceMap</a></code> | <code>boolean</code> | Flag to enable or disable source maps in bundled code, defaulted to false. |
|
|
458
|
+
|
|
459
|
+
---
|
|
460
|
+
|
|
461
|
+
##### `name`<sup>Required</sup> <a name="name" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.name"></a>
|
|
462
|
+
|
|
463
|
+
```typescript
|
|
464
|
+
public readonly name: string;
|
|
465
|
+
```
|
|
466
|
+
|
|
467
|
+
- *Type:* string
|
|
468
|
+
|
|
469
|
+
the name of the AppSync Function.
|
|
470
|
+
|
|
471
|
+
---
|
|
472
|
+
|
|
473
|
+
##### `code`<sup>Optional</sup> <a name="code" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.code"></a>
|
|
474
|
+
|
|
475
|
+
```typescript
|
|
476
|
+
public readonly code: Code;
|
|
477
|
+
```
|
|
478
|
+
|
|
479
|
+
- *Type:* aws-cdk-lib.aws_appsync.Code
|
|
480
|
+
- *Default:* no code is used
|
|
481
|
+
|
|
482
|
+
The function code.
|
|
483
|
+
|
|
484
|
+
---
|
|
485
|
+
|
|
486
|
+
##### `description`<sup>Optional</sup> <a name="description" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.description"></a>
|
|
487
|
+
|
|
488
|
+
```typescript
|
|
489
|
+
public readonly description: string;
|
|
490
|
+
```
|
|
491
|
+
|
|
492
|
+
- *Type:* string
|
|
493
|
+
- *Default:* no description
|
|
494
|
+
|
|
495
|
+
the description for this AppSync Function.
|
|
496
|
+
|
|
497
|
+
---
|
|
498
|
+
|
|
499
|
+
##### `requestMappingTemplate`<sup>Optional</sup> <a name="requestMappingTemplate" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.requestMappingTemplate"></a>
|
|
500
|
+
|
|
501
|
+
```typescript
|
|
502
|
+
public readonly requestMappingTemplate: MappingTemplate;
|
|
503
|
+
```
|
|
504
|
+
|
|
505
|
+
- *Type:* aws-cdk-lib.aws_appsync.MappingTemplate
|
|
506
|
+
- *Default:* no request mapping template
|
|
507
|
+
|
|
508
|
+
the request mapping template for the AppSync Function.
|
|
509
|
+
|
|
510
|
+
---
|
|
511
|
+
|
|
512
|
+
##### `responseMappingTemplate`<sup>Optional</sup> <a name="responseMappingTemplate" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.responseMappingTemplate"></a>
|
|
513
|
+
|
|
514
|
+
```typescript
|
|
515
|
+
public readonly responseMappingTemplate: MappingTemplate;
|
|
516
|
+
```
|
|
517
|
+
|
|
518
|
+
- *Type:* aws-cdk-lib.aws_appsync.MappingTemplate
|
|
519
|
+
- *Default:* no response mapping template
|
|
520
|
+
|
|
521
|
+
the response mapping template for the AppSync Function.
|
|
522
|
+
|
|
523
|
+
---
|
|
524
|
+
|
|
525
|
+
##### `runtime`<sup>Optional</sup> <a name="runtime" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.runtime"></a>
|
|
526
|
+
|
|
527
|
+
```typescript
|
|
528
|
+
public readonly runtime: FunctionRuntime;
|
|
529
|
+
```
|
|
530
|
+
|
|
531
|
+
- *Type:* aws-cdk-lib.aws_appsync.FunctionRuntime
|
|
532
|
+
- *Default:* no function runtime, VTL mapping templates used
|
|
533
|
+
|
|
534
|
+
The functions runtime.
|
|
535
|
+
|
|
536
|
+
---
|
|
537
|
+
|
|
538
|
+
##### `api`<sup>Required</sup> <a name="api" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.api"></a>
|
|
539
|
+
|
|
540
|
+
```typescript
|
|
541
|
+
public readonly api: IGraphqlApi;
|
|
542
|
+
```
|
|
543
|
+
|
|
544
|
+
- *Type:* aws-cdk-lib.aws_appsync.IGraphqlApi
|
|
545
|
+
|
|
546
|
+
the GraphQL Api linked to this AppSync Function.
|
|
547
|
+
|
|
548
|
+
---
|
|
549
|
+
|
|
550
|
+
##### `dataSource`<sup>Required</sup> <a name="dataSource" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.dataSource"></a>
|
|
551
|
+
|
|
552
|
+
```typescript
|
|
553
|
+
public readonly dataSource: BaseDataSource;
|
|
554
|
+
```
|
|
555
|
+
|
|
556
|
+
- *Type:* aws-cdk-lib.aws_appsync.BaseDataSource
|
|
557
|
+
|
|
558
|
+
the data source linked to this AppSync Function.
|
|
559
|
+
|
|
560
|
+
---
|
|
561
|
+
|
|
562
|
+
##### `path`<sup>Required</sup> <a name="path" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.path"></a>
|
|
563
|
+
|
|
564
|
+
```typescript
|
|
565
|
+
public readonly path: string;
|
|
566
|
+
```
|
|
567
|
+
|
|
568
|
+
- *Type:* string
|
|
569
|
+
|
|
570
|
+
Path of typescript file that will be transpiled and bundled.
|
|
571
|
+
|
|
572
|
+
---
|
|
573
|
+
|
|
574
|
+
##### `replaceStrings`<sup>Optional</sup> <a name="replaceStrings" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.replaceStrings"></a>
|
|
575
|
+
|
|
576
|
+
```typescript
|
|
577
|
+
public readonly replaceStrings: {[ key: string ]: string};
|
|
578
|
+
```
|
|
579
|
+
|
|
580
|
+
- *Type:* {[ key: string ]: string}
|
|
581
|
+
|
|
582
|
+
A map of replacement strings in the bundled code.
|
|
583
|
+
|
|
584
|
+
Example: { "ENV", "prod" }
|
|
585
|
+
|
|
586
|
+
---
|
|
587
|
+
|
|
588
|
+
##### `sourceMap`<sup>Optional</sup> <a name="sourceMap" id="cdk-appsync-typescript-resolver.AppsyncTypescriptFunctionProps.property.sourceMap"></a>
|
|
589
|
+
|
|
590
|
+
```typescript
|
|
591
|
+
public readonly sourceMap: boolean;
|
|
592
|
+
```
|
|
593
|
+
|
|
594
|
+
- *Type:* boolean
|
|
595
|
+
|
|
596
|
+
Flag to enable or disable source maps in bundled code, defaulted to false.
|
|
597
|
+
|
|
598
|
+
---
|
|
599
|
+
|
|
600
|
+
### TSExpressPipelineResolverProps <a name="TSExpressPipelineResolverProps" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps"></a>
|
|
601
|
+
|
|
602
|
+
#### Initializer <a name="Initializer" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.Initializer"></a>
|
|
603
|
+
|
|
604
|
+
```typescript
|
|
605
|
+
import { TSExpressPipelineResolverProps } from 'cdk-appsync-typescript-resolver'
|
|
606
|
+
|
|
607
|
+
const tSExpressPipelineResolverProps: TSExpressPipelineResolverProps = { ... }
|
|
608
|
+
```
|
|
609
|
+
|
|
610
|
+
#### Properties <a name="Properties" id="Properties"></a>
|
|
611
|
+
|
|
612
|
+
| **Name** | **Type** | **Description** |
|
|
613
|
+
| --- | --- | --- |
|
|
614
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.fieldName">fieldName</a></code> | <code>string</code> | name of the GraphQL field in the given type this resolver is attached to. |
|
|
615
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.typeName">typeName</a></code> | <code>string</code> | name of the GraphQL type this resolver is attached to. |
|
|
616
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.cachingConfig">cachingConfig</a></code> | <code>aws-cdk-lib.aws_appsync.CachingConfig</code> | The caching configuration for this resolver. |
|
|
617
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.code">code</a></code> | <code>aws-cdk-lib.aws_appsync.Code</code> | The function code. |
|
|
618
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.maxBatchSize">maxBatchSize</a></code> | <code>number</code> | The maximum number of elements per batch, when using batch invoke. |
|
|
619
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.pipelineConfig">pipelineConfig</a></code> | <code>aws-cdk-lib.aws_appsync.IAppsyncFunction[]</code> | configuration of the pipeline resolver. |
|
|
620
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.requestMappingTemplate">requestMappingTemplate</a></code> | <code>aws-cdk-lib.aws_appsync.MappingTemplate</code> | The request mapping template for this resolver. |
|
|
621
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.responseMappingTemplate">responseMappingTemplate</a></code> | <code>aws-cdk-lib.aws_appsync.MappingTemplate</code> | The response mapping template for this resolver. |
|
|
622
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.runtime">runtime</a></code> | <code>aws-cdk-lib.aws_appsync.FunctionRuntime</code> | The functions runtime. |
|
|
623
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.dataSource">dataSource</a></code> | <code>aws-cdk-lib.aws_appsync.BaseDataSource</code> | The data source this resolver is using. |
|
|
624
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.api">api</a></code> | <code>aws-cdk-lib.aws_appsync.IGraphqlApi</code> | The API this resolver is attached to. |
|
|
625
|
+
| <code><a href="#cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.typescriptFunction">typescriptFunction</a></code> | <code><a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction">AppsyncTypescriptFunction</a></code> | Instance of AppsyncTypescriptFunction construct. |
|
|
626
|
+
|
|
627
|
+
---
|
|
628
|
+
|
|
629
|
+
##### `fieldName`<sup>Required</sup> <a name="fieldName" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.fieldName"></a>
|
|
630
|
+
|
|
631
|
+
```typescript
|
|
632
|
+
public readonly fieldName: string;
|
|
633
|
+
```
|
|
634
|
+
|
|
635
|
+
- *Type:* string
|
|
636
|
+
|
|
637
|
+
name of the GraphQL field in the given type this resolver is attached to.
|
|
638
|
+
|
|
639
|
+
---
|
|
640
|
+
|
|
641
|
+
##### `typeName`<sup>Required</sup> <a name="typeName" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.typeName"></a>
|
|
642
|
+
|
|
643
|
+
```typescript
|
|
644
|
+
public readonly typeName: string;
|
|
645
|
+
```
|
|
646
|
+
|
|
647
|
+
- *Type:* string
|
|
648
|
+
|
|
649
|
+
name of the GraphQL type this resolver is attached to.
|
|
650
|
+
|
|
651
|
+
---
|
|
652
|
+
|
|
653
|
+
##### `cachingConfig`<sup>Optional</sup> <a name="cachingConfig" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.cachingConfig"></a>
|
|
654
|
+
|
|
655
|
+
```typescript
|
|
656
|
+
public readonly cachingConfig: CachingConfig;
|
|
657
|
+
```
|
|
658
|
+
|
|
659
|
+
- *Type:* aws-cdk-lib.aws_appsync.CachingConfig
|
|
660
|
+
- *Default:* No caching configuration
|
|
661
|
+
|
|
662
|
+
The caching configuration for this resolver.
|
|
663
|
+
|
|
664
|
+
---
|
|
665
|
+
|
|
666
|
+
##### `code`<sup>Optional</sup> <a name="code" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.code"></a>
|
|
667
|
+
|
|
668
|
+
```typescript
|
|
669
|
+
public readonly code: Code;
|
|
670
|
+
```
|
|
671
|
+
|
|
672
|
+
- *Type:* aws-cdk-lib.aws_appsync.Code
|
|
673
|
+
- *Default:* no code is used
|
|
674
|
+
|
|
675
|
+
The function code.
|
|
676
|
+
|
|
677
|
+
---
|
|
678
|
+
|
|
679
|
+
##### `maxBatchSize`<sup>Optional</sup> <a name="maxBatchSize" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.maxBatchSize"></a>
|
|
680
|
+
|
|
681
|
+
```typescript
|
|
682
|
+
public readonly maxBatchSize: number;
|
|
683
|
+
```
|
|
684
|
+
|
|
685
|
+
- *Type:* number
|
|
686
|
+
- *Default:* No max batch size
|
|
687
|
+
|
|
688
|
+
The maximum number of elements per batch, when using batch invoke.
|
|
689
|
+
|
|
690
|
+
---
|
|
691
|
+
|
|
692
|
+
##### `pipelineConfig`<sup>Optional</sup> <a name="pipelineConfig" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.pipelineConfig"></a>
|
|
693
|
+
|
|
694
|
+
```typescript
|
|
695
|
+
public readonly pipelineConfig: IAppsyncFunction[];
|
|
696
|
+
```
|
|
697
|
+
|
|
698
|
+
- *Type:* aws-cdk-lib.aws_appsync.IAppsyncFunction[]
|
|
699
|
+
- *Default:* no pipeline resolver configuration An empty array | undefined sets resolver to be of kind, unit
|
|
700
|
+
|
|
701
|
+
configuration of the pipeline resolver.
|
|
702
|
+
|
|
703
|
+
---
|
|
704
|
+
|
|
705
|
+
##### `requestMappingTemplate`<sup>Optional</sup> <a name="requestMappingTemplate" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.requestMappingTemplate"></a>
|
|
706
|
+
|
|
707
|
+
```typescript
|
|
708
|
+
public readonly requestMappingTemplate: MappingTemplate;
|
|
709
|
+
```
|
|
710
|
+
|
|
711
|
+
- *Type:* aws-cdk-lib.aws_appsync.MappingTemplate
|
|
712
|
+
- *Default:* No mapping template
|
|
713
|
+
|
|
714
|
+
The request mapping template for this resolver.
|
|
715
|
+
|
|
716
|
+
---
|
|
717
|
+
|
|
718
|
+
##### `responseMappingTemplate`<sup>Optional</sup> <a name="responseMappingTemplate" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.responseMappingTemplate"></a>
|
|
719
|
+
|
|
720
|
+
```typescript
|
|
721
|
+
public readonly responseMappingTemplate: MappingTemplate;
|
|
722
|
+
```
|
|
723
|
+
|
|
724
|
+
- *Type:* aws-cdk-lib.aws_appsync.MappingTemplate
|
|
725
|
+
- *Default:* No mapping template
|
|
726
|
+
|
|
727
|
+
The response mapping template for this resolver.
|
|
728
|
+
|
|
729
|
+
---
|
|
730
|
+
|
|
731
|
+
##### `runtime`<sup>Optional</sup> <a name="runtime" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.runtime"></a>
|
|
732
|
+
|
|
733
|
+
```typescript
|
|
734
|
+
public readonly runtime: FunctionRuntime;
|
|
735
|
+
```
|
|
736
|
+
|
|
737
|
+
- *Type:* aws-cdk-lib.aws_appsync.FunctionRuntime
|
|
738
|
+
- *Default:* no function runtime, VTL mapping templates used
|
|
739
|
+
|
|
740
|
+
The functions runtime.
|
|
741
|
+
|
|
742
|
+
---
|
|
743
|
+
|
|
744
|
+
##### `dataSource`<sup>Optional</sup> <a name="dataSource" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.dataSource"></a>
|
|
745
|
+
|
|
746
|
+
```typescript
|
|
747
|
+
public readonly dataSource: BaseDataSource;
|
|
748
|
+
```
|
|
749
|
+
|
|
750
|
+
- *Type:* aws-cdk-lib.aws_appsync.BaseDataSource
|
|
751
|
+
- *Default:* No datasource
|
|
752
|
+
|
|
753
|
+
The data source this resolver is using.
|
|
754
|
+
|
|
755
|
+
---
|
|
756
|
+
|
|
757
|
+
##### `api`<sup>Required</sup> <a name="api" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.api"></a>
|
|
758
|
+
|
|
759
|
+
```typescript
|
|
760
|
+
public readonly api: IGraphqlApi;
|
|
761
|
+
```
|
|
762
|
+
|
|
763
|
+
- *Type:* aws-cdk-lib.aws_appsync.IGraphqlApi
|
|
764
|
+
|
|
765
|
+
The API this resolver is attached to.
|
|
766
|
+
|
|
767
|
+
---
|
|
768
|
+
|
|
769
|
+
##### `typescriptFunction`<sup>Required</sup> <a name="typescriptFunction" id="cdk-appsync-typescript-resolver.TSExpressPipelineResolverProps.property.typescriptFunction"></a>
|
|
770
|
+
|
|
771
|
+
```typescript
|
|
772
|
+
public readonly typescriptFunction: AppsyncTypescriptFunction;
|
|
773
|
+
```
|
|
774
|
+
|
|
775
|
+
- *Type:* <a href="#cdk-appsync-typescript-resolver.AppsyncTypescriptFunction">AppsyncTypescriptFunction</a>
|
|
776
|
+
|
|
777
|
+
Instance of AppsyncTypescriptFunction construct.
|
|
778
|
+
|
|
779
|
+
---
|
|
780
|
+
|
|
781
|
+
|
|
782
|
+
|