-
Notifications
You must be signed in to change notification settings - Fork 16
/
api_gateway.aws.txt
2906 lines (2409 loc) · 154 KB
/
api_gateway.aws.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
API GATEWAY
VERSION ==> #2023-22-06
NOTATION ==> =#: v1
-#: v2 HTTP
~#: v2 WebSocket
SUMMARY ==> #API: v1|v2, HTTP|WebSocket, quick create
#Payloads: compression, binary
#Route: request|response, params|body validation|mapping, test, gateway responses
#Integration: request|response, proxy, HTTP, AWS (Lambda, first-class), mock, timeout, VPC
#AWS integrations: Lambda, first-class (SQS, EventBridge, Kinesis, StepFunctions, AppConfig)
#Authorization: API.policy, none|IAM|Lambda|JWT|Cognito, cache, test, CORS, WAF
#Stage: variables, deployment, auto-deploy, canary
#Monitoring: metrics (detailed), execution logging (level, body), access logging (CloudWatch|Kinesis, format), X-Ray
#Caching: size, TTL, encryption, key, invalidation
#OpenAPI: import|export (merge|overwrite), extensions, DOCPART, SDK
#Domain name: edge|regional|private, certificates, client TLS, server auth, mapping
#Usage plan: throttle, quota, key (import), marketplace
#WebSocket: $connect|$disconnect, push
/=+===============================+=\
/ : : \
)==: VERSIONS :==(
\ :_______________________________: /
\=+===============================+=/
VERSION ==> #There are two versions of the API.
=#v1 (also called "REST")
# - more features, except for a few that v2-only
-~#v2 (also called "HTTP"/"WebSocket")
# - cheaper
# - slightly faster
# - simpler
MIXING ==> #Resources are version-specific, i.e. cannot use v1|v2 together
=-#But HTTP|REST APIs can be mixed under same domain name by using MAPPINGs
MISSING FEATURES PER VERSION ==> =#Auto-deploy
-#Binary, request|response body mapping, request params|body validation, mock INTEGRATION, execution logging
~#HTTP, path variables, OpenAPI custom fields, VPCLINK, AUTHORIZER cache
UNIQUE FEATURES PER VERSION ==> =#Edge, caching, compression, canary, X-Ray, USAGEPLAN, private API
=#OpenAPI 2.0, API.cloneFrom, ROUTE|AUTHORIZER testing, GRESP, Cognito, API.policy, WAF, Kinesis logging, merge IMPORT, DOCPART, SDK, CCERTIFICATE
-#First-class INTEGRATION, JWT, CORS, API quick create
~#WebSocket
CONCLUSION ==> #If needs WebSocket, use v2
#Otherwise, if just needs routing and no v1-unique features, use v1 HTTP
#Otherwise, use v1 REST
/=+===============================+=\
/ : : \
)==: API :==(
\ :_______________________________: /
\=+===============================+=/
SERVICE_DOMAIN #apigateway.amazonaws.com
FORMAT ==> #JSON REST
REQ_ID #x-amzn-requestid [S]
#Extended REQ_ID: x-amz-apigw-id [S]
x-amzn-ErrorType: ERROR_TYPE [S] #Automatically set on 4**|5**
PAGINATION ==> #Uses:
=# - REQ.limit NUM (def 25, max 500), REQ|RES.position STR
-~# - REQ.maxResults NUM (def 25, max 500), REQ|RES.nextToken STR
#No pagination:
# - GetTags()
=# - GetStages()
# - with SDK:
=# - GetAuthorizers(), GetDocumentation*(), GetGatewayResponses(), GetRequestValidators(), GetSdkTypes()
-~# - all ACTIONs
-~# - with CLI: GetApiMappings()
THROTTLING ==> #Per ACCOUNT:
# - 10/s: total for all ACTIONs (burst of 40) (for API ACTIONs, not client requests)
# - 5/s: Create|DeleteApiKey, Create|DeleteResource
# - 1/s: PutRestApi
# - 5/2s: GetResources
# - 1/5s: CreateDeployment 1 request every 5 seconds per account No
# - 1/15s: CreateVpcLink
# - 1/20s: CreateDocumentationVersion, UpdateAccount, UpdateUsagePlan
# - 1/30s: Create|Update|DeleteDomainName, ImportDocumentationParts, DeleteRestApi, DeleteVpcLink
# - 1/3s (ENDPOINT.types 'EDGE'), 1/30s (ENDPOINT.types 'REGIONAL|PRIVATE'): CreateRestApi, ImportRestApi
PRICING ==> #Requests:
=# - 3.5$/1e6 requests
# - 20% cheaper after 3e8 requests, 32% after 1e9, 57% after 2e10
# - also pay EC2 egress cost on responses (e.g. 1$/11GB)
# - free for first 12 months: 1e6 requests/month
-# - 1$/1e6 requests
# - 10% cheaper after 3e8 requests
# - no egress cost, but big responses multiplied by their size % 512KB
# - free for first 12 months: 1e6 requests/month
~# - 1$/1e6 requests or responses (push message)
# - 20% cheaper after 1e9 requests
# - no igress|egress cost, but big requests|responses multiplied by their size % 32KB
# - free for first 12 months: 1e6 requests/month
~#Connections: 1$/1e6 connections
# - for 4 minutes connections, proportional to duration otherwise
# - free for first 12 months: 7.5e5 connections/month
=#Caching:
# - depending on STAGE.cacheClusterSize:
# - 0.5 GB: 15$, 1.6GB: 27$, 6.1GB: 146$, 13.5GB: 182$, 28.4GB: 365$, 58.2GB: 730$, 118GB: 1400$, 237GB: 2800$
# - those are monthly prices, but this is charged hourly
=-# - AUTHORIZER cache: free
AmazonAPIGatewayAdministrator #AWS managed POLICY that allows PACTION apigateway:*
AWSServiceRoleForAPIGateway #SERVER_LINKED_ROLE automatically created when using:
# - ROUTE_SETTINGS.loggingLevel
# - STAGE.accessLogSettings
# - STAGE.tracingEnabled
# - [D]DNAME.[ownershipVerification]certificateArn
# - VPC
#Can only be assumed by SERVICE_DOMAIN 'ops.apigateway.amazonaws.com'
APIGatewayServiceRolePolicy #POLICY of APIGatewayServiceRole allowing PACTIONs:
# - logs:*LogDelivery
# - firehose:PutRecord[Batch]|DescribeDeliveryStream on STREAM 'amazon-apigateway-*'
# - xray:PutTraceSegments|PutTelemetryRecords|GetSamplingTargets|GetSamplingRules
# - acm:Describe|GetCertificate
# - elasticloadbalancing:*Listener*|DescribeLoadBalancers
# - ec2:*NetworkInterface*|*PrivateIpAddresses|DescribeAvailabilityZones
# |DescribeVpcs|DescribeSubnets|DescribeRouteTables|DescribeSecurityGroups
# - servicediscovery:DiscoverInstances|GetNamespace|GetService
/=+===============================+=\
/ : : \
)==: EXECUTE :==(
\ :_______________________________: /
\=+===============================+=/
EXECUTE API ==> #Separate API, also called "data plane API"
#Used only by INVOKE_URI and by *Connection()
SERVICE_DOMAIN #execute-api.amazonaws.com
INVOKE_URI =-#https://API_MID.execute-api.REGION.amazonaws.com
~#wss://API_MID.execute-api.REGION.amazonaws.com
#URI for clients to call the API
#Online documentation calls "app developer" the client, as opposed to "API developer".
/=+===============================+=\
/ : : \
)==: PATCH :==(
\ :_______________________________: /
\=+===============================+=/
PATCH METHODS ==> =#All Update*() request payload is different from other SERVICEs
#Instead, it is { patchOperations: PATCH_OP_ARR }
PATCH_OP.op =#STR, among the following
PATCH_OP.op 'replace' =#Set value. Unless documented otherwise, always available
PATCH_OP.op 'add|remove' =#Add|remove ARR item. Unless documented otherwise, always available if property is ARR
#Also for properties that are 'VAL,...', or dynamic OBJs (where keys are user-defined)
PATCH_OP.op 'copy' =#Set value using another property's value
#Only with STAGE.deploymentId, with PATCH_OP.from '/canarySettings/deploymentId'
PATCH_OP.op 'move' =#Like 'copy' but deletes original value
PATCH_OP.op 'test' =#Like 'replace' but dry run
PATCH_OP.path =#JSON pointer to property, e.g. /VAR/VAR2
#Excluding - (ARR append), but including ~0|~1 escaping
#Only for mutable attributes
#OBJ: unless documented otherwise:
# - dynamic OBJs: only OBJ itself, not OBJ.* (but can use op 'add|remove')
# - non-dynamic OBJs: only for OBJ.*, not OBJ itself
#OBJ_ARR: use an OBJ id, not the ARR index
#Other ARR: only for ARR itself, not ARR.*
PATCH_OP.value =#STR. Only with PATCH_OP 'replace|add|test'
PATCH_OP.from =#JSON pointer to property containing the value to set
#Only with PATCH_OP 'copy|move'
/=+===============================+=\
/ : : \
)==: REST API :==(
\ :_______________________________: /
\=+===============================+=/
POST /restapis =#Req: API
# - no id, rootResourceId, createdDate, warnings
# - only one with cloneFrom
CreateRestApi() #Res: API
PATCH /restapis/API_MID =#Req: API
# - no id, rootResourceId, createdDate, version, warnings, tags
UpdateRestApi() #Res: API
GET /restapis =#Req: empty
GetRestApis() #Res: item API_ARR
GET /restapis/API_MID =#Req: empty
GetRestApi() #Res: API
DELETE /restapis/API_MID =#Req: empty
DeleteRestApi() #Res: empty
POST /v2/apis -~#Req: API
CreateApi() # - no apiId, warnings, importInfo, apiEndpoint, apiGatewayManaged, createdDate
# - only ones with target|credentialsArn|routeKey
#Res: API
PATCH /v2/apis/API_MID -~#Req: API
UpdateApi() # - no apiId, warnings, importInfo, apiEndpoint, apiGatewayManaged, createdDate
# - no protocolType, tags
# - only ones with target|credentialsArn|routeKey
#Res: API
GET /v2/apis -~#Req: empty
GetApis() #Res: items API_ARR
GET /v2/apis/API_MID -~#Req: empty
GetApi() #Res: API
DELETE /v2/apis/API_MID -~#Req: empty
DeleteApi() #Res: empty
API #API gateway, i.e. sets of endpoints that perform validation and authorization then forward to a backend
#Max 120 (if ENDPOINT.types 'EDGE') or 600 (if ENDPOINT.types 'REGIONAL|PRIVATE') per ACCOUNT
API_ARN =#arn:aws:apigateway:REGION::/restapis[/API_MID]
API_ARN -~#arn:aws:apigateway:REGION::/apis[/API_MID]
API.id =
API.apiId -~#API_MID
API.name #'API'
COND_KEY ApiName #'API', on Create|Update|Delete[Rest]Api()
API.description #STR
API.createdDate =#DATE_NUM
-~#'DATE'
API.protocolType -~#Protocol used, either 'HTTP' or 'WEBSOCKET'
API.tags #TAGS
=#Inherited by children (ABAC-only): RESOURCE, ROUTE, ROUTESETTINGS, INTEGRATION, GRESP, MODEL,
#AUTHORIZER, STAGE, DEPLOYMENT, DOCPART, DOCVERS
pulumi-aws-apigateway ##Package with an API REZ simplifying setting:
## - Lambda INTEGRATION|AUTHORIZER, with inline FUNC
## - S3 INTEGRATION, uploading local files then serving them
##Does not allow using every API Gateway features
##Version 2.1.0
##Not fully documented yet
/=+===============================+=\
/ : : \
)==: QUICK CREATE :==(
\ :_______________________________: /
\=+===============================+=/
API.cloneFrom =#API_MID to copy from
API.target -#STR. Automatically create:
# - '$default' STAGE
# - '$default' ROUTE
# - INTEGRATION, depending on STR:
# - 'URL': integrationType 'HTTP_PROXY'
# - Lambda FUNC_ARN: integrationType 'AWS_PROXY'
#All readonly, except INTEGRATION can be updated, and API deleted
API.credentialsArn -#INTEGRATION.credentialsArn, when using API.target FUNC_ARN
API.routeKey -#'ROUTE' (def: '$default') when using API.target FUNC_ARN
API.apiGatewayManaged
STAGE.apiGatewayManaged
ROUTE.apiGatewayManaged -#BOOL. Whether created through API.target
INTEGRATION.apiGatewayManaged ##With CloudFormation, can set them using AWS::ApiGatewayV2::ApiGatewayManagedOverrides
/=+===============================+=\
/ : : \
)==: PAYLOADS :==(
\ :_______________________________: /
\=+===============================+=/
API.minimumCompressionSize =#NUM (def: disabled, max: 10MB). When set:
OSPEC.x-amazon-apigateway- # - allow compressed request body
minimum-compression-size # - if Content-Encoding: ALGO [C] (only first ALGO)
# - produce compressed response body
# - if Accept-Encoding: ALGO [C] (only first ALGO) and no Content-Encoding [S]
#Only for gzip|deflate
#Only when body >=NUM bytes.
API.binaryMediaTypes
OSPEC.x-amazon-apigateway- =#Binary 'MIME|*'_ARR allowed
binary-media-types #By default, only non-binary allowed, i.e. UTF8
INTEGRATION|IRESP.contentHandling=
INTEGRATION|IRESP ~#STR. Whether request|response body should be:
.contentHandlingStrategy # - default: keep as is
# - CONVERT_TO_BINARY: base64 decode
# - only if non-binary MIME request|response
# - CONVERT_TO_TEXT: base64 encode
# - only if binary MIME request|response
~#Backend request|response must be base64'd, if binary
MIME #Based on Content-Type [C] and Accept: MIME [S] (only first MIME)
#Def: application/json
#SDK forces Accept: application/json [S]
#Can use wildcard *
#Can be '$default' as a catch-all
/=+===============================+=\
/ : : \
)==: RESOURCE :==(
\ :_______________________________: /
\=+===============================+=/
POST /restapis/API_MID =#Req: RESOURCE
/resources/PARENT_RESOURCE_MID # - no id, path, resourceMethods
CreateResource() # - parentId is in URL path
#Res: RESOURCE
PATCH /restapis/API_MID =#Req: RESOURCE
/resources/RESOURCE_MID # - no id, path, resourceMethods
UpdateResource() #Res: RESOURCE
GET /restapis/API_MID/resources =#Req:
GetResources() # - only embed 'methods', to return RESOURCE.resourceMethods
#Res: item RESOURCE_ARR
GET /restapis/API_MID
/resources/RESOURCE_MID =#Req: only embed 'methods'
GetResource() #Res: RESOURCE
DELETE /restapis/API_MID
/resources/RESOURCE_MID =#Req: empty
DeleteResource() #Res: empty
RESOURCE =#Endpoints sharing same /PATH (but different HTTP_METHODs)
#Max 300 per API (soft)
RESOURCE_ARN =#arn:aws:apigateway:REGION::/restapis/API_MID/resources[/RESOURCE_MID]
RESOURCE.id =#RESOURCE_MID
RESOURCE.path =#'/PATH'
RESOURCE.pathPart =#Last part of '/PATH'. Can include 1|n slashes
RESOURCE.parentId =#PARENT_RESOURCE_MID, i.e. same '/PATH' without last part
API.rootResourceId =#Root RESOURCE_MID
/=+===============================+=\
/ : : \
)==: ROUTE REQUEST :==(
\ :_______________________________: /
\=+===============================+=/
PUT /restapis/API_MID
/resources/RESOURCE_MID =#Req: ROUTE
/methods/HTTP_METHOD # - no httpMethod, methodIntegration, methodResponses
PutMethod() #Res: ROUTE
PATCH /restapis/API_MID =#Req: ROUTE
/resources/RESOURCE_MID # - no httpMethod, methodIntegration, methodResponses
/methods/HTTP_METHOD # - op:add|remove, not op:replace: authorizationScopes
UpdateMethod() #Res: ROUTE
GET /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD =#Req: empty
GetMethod() #Res: ROUTE
DELETE /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD =#Req: empty
DeleteMethod() #Res: empty
POST /v2/apis/API_MID/routes -~#Req: ROUTE
CreateRoute() # - no routeId, apiGatewayManaged
#Res: ROUTE
PATCH /v2/apis/API_MID -~#Req: ROUTE
/routes/ROUTE_MID # - no routeId, apiGatewayManaged
UpdateRoute() #Res: ROUTE
GET /v2/apis/API_MID/routes -~#Req: empty
GetRoutes() #Res: items ROUTE_ARR
GET /v2/apis/API_MID
/routes/ROUTE_MID -~#Req: empty
GetRoute() #Res: ROUTE
DELETE /v2/apis/API_MID
/routes/ROUTE_MID -~#Req: empty
DeleteRoute() #Res: empty
DELETE /v2/apis/API_MID
/routes/ROUTE_MID -~#Req: empty
/requestparameters/EXPR #Res: empty
DeleteRouteRequestParameter() #Delete ROUTE.requestParameters
ROUTE #Endpoint, i.e. /PATH + HTTP_METHOD
#Max 300 per API (soft)
ROUTE_ARN =#arn:aws:apigateway:REGION::/restapis/API_MID/integrations/resources/RESOURCE_MID/methods/HTTP_METHOD
ROUTE_ARN -~#arn:aws:apigateway:REGION::/apis/API_MID/routes[/ROUTE_MID]
ROUTE.routeId -~#ROUTE_MID
ROUTE.routeKey -~#'ROUTE', as:
-# - 'HTTP_METHOD /PATH'
~# - any STR
#Can be '$default' as a catch-all
~# - including on non-JSON request bodies
# - def: returns { message: 'Not Found' }
#/PATH: [[:alnum:]_-.,:{}] cannot be /[s]ping
RESOURCE
.resourceMethods.HTTP_METHOD =#ROUTE
ROUTE.httpMethod =#'HTTP_METHOD'
API.routeSelectionExpression ~#'ROUTE_$EXPR' used by each request
OOPERATION.isDefaultRoute =-#BOOL. ROUTE '$default'
#Must be under OPATHDEF.x-amazon-apigateway-any-method
ROUTE.requestParameters.EXPR =~#BOOL (requiredness). Allowed request non-body parameters from client
#EXPR: only non-body 'request.*'
#Max size of URI: 8KB
#Max size of URI + headers: 10KB
PARAM_ARN ~#arn:aws:apigateway:REGION::/apis/API_MID/routes/ROUTE_MID/requestparameters/PARAM
ROUTE.requestModels.MIME =#'MODEL'. Allowed request body parameters from client
#Max request body size: 10MB
ROUTE.requestModels.ROUTE_MODEL ~#Same but using a name
#Max request body size: 128KB, with max frame size 32KB
#ROUTE_MODEL can be '$default' as a catch-all
ROUTE.modelSelectionExpression ~#'ROUTE_MODEL_$EXPR'
/=+===============================+=\
/ : : \
)==: ROUTE PARAMETERS :==(
\ :_______________________________: /
\=+===============================+=/
HTTP_METHOD #'GET|HEAD|POST|PUT|PATCH|DELETE|OPTIONS' or 'ANY'
OPATHDEF.x-amazon-apigateway-
any-method =-#OOPERATION but with HTTP_METHOD 'ANY'
X-HTTP-Method-Override: METHOD [C]#Handled.
#Removed to INTEGRATION request, unless explicitely mapped with INTEGRATION.requestParameters
PATHVAR ==> =-#/PATH can include '{PATHVAR[+]}'
#Can use /{PATHVAR} but not /...{PATHVAR}...
#Can resolve to empty
#If +:
# - does not stop at next /
# - called "proxy parameter"
# - PATHVAR often named `proxy`
QUERY STRING ==> #Cannot use ; |
HEADERS FORWARDING ==> #Request|response header names are capitalized
#Cookies are sorted by name
#Creates Content-Length [C] if missing
#Sets Host [C] to match INTEGRATION
#Removes:
# - Content-MD5 [C], Expect [C|S], Host [S], Max-Forwards [C], Server [C],
# TE [C|S], Transfer-Encoding [C|S], Trailer [C|S], Upgrade [C|S]
# - Proxy-Authenticate [C|S], WWW-Authenticate [C]
# - Authorization [C] if it contains AWS signature
# - only with integrationType:
# - 'HTTP': Accept [S]
# - 'HTTP_PROXY': Content-Encoding [C]
# - 'HTTP[_PROXY]': Via [C]
# - 'AWS_PROXY': Connection [C]
# - '*_PROXY': Via [S]
#Renames HEADER to X-Amzn-Remapped-HEADER:
# - Authorization [S], Connection [S], Date [S], Max-Forwards [S],
# Server [S], User-Agent [S], WWW-Authenticate [S]
RESERVED HEADERS ==> #Many well-known HTTP headers cannot be set in request|response
#Nor x-amz[n]-* [C|S]
#I.e. mostly meant for custom headers
/=+===============================+=\
/ : : \
)==: ROUTE RESPONSE :==(
\ :_______________________________: /
\=+===============================+=/
PUT /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD =#Req: RRESP
/responses/STATUS_NUM # - no statusCode
PutMethodResponse() #Res: RRESP
PATCH /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD =#Req: RRESP
/responses/STATUS_NUM # - no statusCode
UpdateMethodResponse() #Res: RRESP
GET /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD
/responses/STATUS_NUM =#Req: empty
GetMethodResponse() #Res: RRESP
DELETE /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD
/responses/STATUS_NUM =#Req: empty
DeleteMethodResponse() #Res: empty
POST /v2/apis/API_MID
/routes/ROUTE_MID ~#Req: RRESP
/routeresponses # - no routeResponseId
CreateRouteResponse() #Res: RRESP
PATCH /v2/apis/API_MID
/routes/ROUTE_MID ~#Req: RRESP
/routeresponses/RRESP_MID # - no routeResponseId
UpdateRouteResponse() #Res: RRESP
GET /v2/apis/API_MID
/routes/ROUTE_MID
/routeresponses ~#Req: empty
GetRouteResponses() #Res: RRESP
GET /v2/apis/API_MID
/routes/ROUTE_MID
/routeresponses/RRESP_MID ~#Req: empty
GetRouteResponse() #Res: items RRESP_ARR
DELETE /v2/apis/API_MID
/routes/ROUTE_MID
/routeresponses/RRESP_MID ~#Req: empty
DeleteRouteResponse() #Res: empty
RRESP =~#ROUTE's response status|headers|body
~#Def: no response
#Not with integrationType '*_PROXY'
RRESP_ARN =#arn:aws:apigateway:REGION::/restapis/API_MID/integrations/resources/RESOURCE_MID/methods/HTTP_METHOD/responses/STATUS_NUM
RRESP_ARN ~#arn:aws:apigateway:REGION::/apis/API_MID/routes/ROUTE_MID/routeresponses[/RRESP_MID]
RRESP.routeReponseId ~#RRESP_MID
RRESP.routeReponseKey ~#'RRESP'. Can only be '$default', i.e. only one RRESP per ROUTE
ROUTE.methodResponses.STATUS_NUM =#RRESP
ROUTE.routeResponse
SelectionExpression ~#Always '\$default'
RRESP.statusCode =#'STATUS_NUM'
RRESP.responseParameters.EXPR =~#BOOL (requiredness). Response headers to send to client
#EXPR: only 'response.header.*'
RRESP.responseModels.MIME =#'MODEL'. Response body to send to client
RRESP.responseModels.RRESP_MODEL ~#Same but as a name
RRESP.modelSelectionExpression ~#'RRESP_MODEL_$EXPR'. Currently not supported
ACONTEXT.status #STATUS_NUM of RRESP
CONTEXT.error.message =-#'ERROR' message of RRESP
CONTEXT.error.messageString #Like CONTEXT.error.message but "-quoted
ACONTEXT.responseLatency =-#Duration NUM (in ms) of RRESP
AWS/ApiGateway/Latency =-#CloudWatch METRIC with duration NUM (in ms) of RRESP
ACONTEXT.responseLength =-#RRESP Content-Length [S]
CONTEXT.dataProcessed -#NUM of bytes processed
AWS/ApiGateway/DataProcessed -#CloudWatch METRIC with NUM of bytes processed
/=+===============================+=\
/ : : \
)==: ROUTE TEST :==(
\ :_______________________________: /
\=+===============================+=/
POST /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD =#Req: INVOKE_ROUTE_REQ
TestInvokeMethod() #Res: INVOKE_ROUTE_RES
INVOKE_ROUTE_REQ =#Like calling INVOKE_URI, but programmatically, for debugging
#Not logged by CloudTrail
INVOKE_ROUTE_REQ
.pathWithQueryString =#'/PATH?QUERY'. Request path
INVOKE_ROUTE_REQ.headers.HEADER =#'VAL'. Request headers
INVOKE_ROUTE_REQ
.multiValueHeaders.HEADER =#Same as 'VAL'_ARR
INVOKE_ROUTE_REQ.body =#STR. Request body. Must be JSON
INVOKE_ROUTE_REQ
.stageVariables.STAGE_VAR =#'VAL'
INVOKE_ROUTE_RES.status =#STATUS_NUM of response
INVOKE_ROUTE_RES.headers.HEADER =#'VAL'. Response headers
INVOKE_ROUTE_RES
.multiValueHeaders.HEADER =#Same as 'VAL'_ARR
INVOKE_ROUTE_RES.body =#STR. Response body
INVOKE_ROUTE_RES.latency =#NUM (in ms). Duration
INVOKE_ROUTE_RES.log =#STR. From execution logging
/=+===============================+=\
/ : : \
)==: INTEGRATION REQUEST :==(
\ :_______________________________: /
\=+===============================+=/
PUT /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD =#Req: INTEGRATION
/integration # - no integrationResponses
PutIntegration() #Res: INTEGRATION
PATCH /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD =#Req: INTEGRATION
/integration # - no credentials, integrationResponses
UpdateIntegration() #Res: INTEGRATION
GET /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD
/integration =#Req: empty
GetIntegration() #Res: INTEGRATION
DELETE /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD
/integration =#Req: empty
DeleteIntegration() #Res: empty
POST /v2/apis/API_MID -~#Req: INTEGRATION
/integrations # - no integrationId, integrationResponseSelectionExpression, apiGatewayManaged
CreateIntegration() #Res: INTEGRATION
PATCH /v2/apis/API_MID -~#Req: INTEGRATION
/integrations/INTEGRATION_MID # - no integrationId, integrationResponseSelectionExpression, apiGatewayManaged
UpdateIntegration() #Res: INTEGRATION
GET /v2/apis/API_MID
/integrations -~#Req: empty
GetIntegrations() #Res: items INTEGRATION_ARR
GET /v2/apis/API_MID
/integrations/INTEGRATION_MID -~#Req: empty
GetIntegration() #Res: INTEGRATION
DELETE /v2/apis/API_MID
/integrations/INTEGRATION_MID -~#Req: empty
DeleteIntegration() #Res: empty
INTEGRATION #"Backend", i.e. destination to forward client's request, and send back response from
#Max 300 per API (soft)
OOPERATION.x-amazon-apigateway- =-#INTEGRATION.*, except *Id, description, apiGatewayManaged, responseParameters
integration.* #INTEGRATION.responses named integrationResponses instead
#When v1|v2 have different names, uses v1's
OCOMPONENTS
.x-amazon-apigateway-integrations
.NAME =-#OOPERATION.x-amazon-apigateway-integration
INTEGRATION_ARN =#arn:aws:apigateway:REGION::/restapis/API_MID/integrations/resources/RESOURCE_MID/methods/HTTP_METHOD/integration
INTEGRATION_ARN -~#arn:aws:apigateway:REGION::/apis/API_MID/integrations[/INTEGRATION_MID]
INTEGRATION.integrationId -~#INTEGRATION_MID
INTEGRATION.description -~#STR
ROUTE.methodIntegration =#INTEGRATION
ROUTE.target -~#'integrations/INTEGRATION_MID'
INTEGRATION.type =
INTEGRATION.integrationType -~#STR. "Backend" to forward to:
# - HTTP[_PROXY]: a new HTTP request
# - initial port must be 80|443|1024-65535
# - AWS[_PROXY]: a call to an AWS SERVICE
=~# - MOCK: nothing
#Difference between:
# - HTTP_PROXY: pass initial request as is
=-# - AWS_PROXY:
# - Lambda: pass initial request as a REQ with its parameters|body|context
-# - "first-class": like integrationType AWS (including mapping parameters) except:
# - only specific SERVICEs|ACTIONs
# - INTEGRATION.requestParameters keys are PARAMs, i.e. simpler
=~# - HTTP|AWS ("custom"):
# - must map parameters|body|context to a body OBJ
# - if no mapping specified, pass initial request body as is
# - AWS: any SERVICEs|ACTIONs
INTEGRATION.integrationSubtype -#'SERVICE-ACTION' among:
# - SQS-SendMessage|ReceiveMessage|DeleteMessage|PurgeQueue
# - EventBridge-PutEvents (for a single EVENT)
# - Kinesis-PutRecord
# - StepFunctions-Start[Sync]Execution|StopExecution
# - AppConfig-GetConfiguration
#Only with integrationType 'AWS_PROXY' ("first-class")
INTEGRATION.uri =
INTEGRATION.integrationUri -~#Depending on type:
# - 'HTTP[_PROXY]': 'URI' to call
# - 'AWS[_PROXY]':
# - 'SERVICE_ARN:action/ACTION[?QUERY]': any SERVICEs (including REST)
# - 'SERVICE_ARN:path//PATH[?QUERY]': REST SERVICEs only
# - SERVICE_ARN: 'arn:aws:apigateway:REGION:SERVICE'
# - QUERY: ?PARAM=VAL&..., only for URL paths and query parameters
=~# - 'MOCK': not allowed
INTEGRATION.httpMethod =
INTEGRATION.integrationMethod -~#'HTTP_METHOD' to call
#Not with type 'MOCK'
INTEGRATION.requestParameters #OBJ. Request parameters to send to backend.
#Non-body parameters (except "first-class")
#Key:
=~# - 'EXPR': only 'integration.request.*'
-# - if "first-class": 'PARAM' among:
# - any parameter of the SERVICE ACTION (PATHVARs, query variables, headers, body)
# - Region
-# - otherwise: 'TEXPR' (PATHVARs, query variables, headers only)
#Value:
=~# - 'EXPR2'
-# - '$EXPR2'
# - [$]EXPR2 is only '[$]request|stagevar|context.*' or static STR
#Not with integrationType '*_PROXY' (except "first-class")
INTEGRATION =~#'TEMPLATE'. Request body to send to backend.
.requestTemplates.MIME #Not with integrationType '*_PROXY'
INTEGRATION.requestTemplates ~#Same but using a name, selected by templateSelectionExpression
.INTEGRATION_TEMPLATE #INTEGRATION_TEMPLATE can be '$default' as a catch-all
#Not with integrationType '*_PROXY'
INTEGRATION
.templateSelectionExpression ~#'INTEGRATION_TEMPLATE_$EXPR'. Can only be 'INTEGRATION_TEMPLATE' or '$request.body.VARR'
INTEGRATION =~#STR. Default behavior when no requestTemplates matches. Can be:
.passthroughBehavior # - NEVER: respond with 415
# - WHEN_NO_MATCH (def): forward request body as is
# - WHEN_NO_TEMPLATES: like NEVER if requestTemplates is defined, as WHEN_NO_MATCH otherwise
INTEGRATION.credentials =
INTEGRATION.credentialsArn -~#STR. Authentication, among:
# - ROLE_ARN: must allow Principal.Service 'apigateway.amazonaws.com' assuming it
# - 'arn:aws:iam::*:user/*': keep current authenticated USER
# - null: none, but can use resource-based POLICY, e.g. Lambda FUNCTION PERMISSION
#Only for integrationType 'AWS[_PROXY]'
INTEGRATION.timeoutInMillis #NUM (in ms, min: 50ms, def|max: 29s). Request timeout
/=+===============================+=\
/ : : \
)==: INTEGRATION RESPONSE :==(
\ :_______________________________: /
\=+===============================+=/
PUT /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD
/integration =#Req: IRESP
/responses/STATUS_NUM # - no statusCode
PutIntegrationResponse() #Res: IRESP
PATCH /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD
/integration =#Req: IRESP
/responses/STATUS_NUM # - no statusCode
UpdateIntegrationResponse() #Res: IRESP
GET /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD
/integration
/responses/STATUS_NUM =#Req: empty
GetIntegrationResponse() #Res: IRESP
DELETE /restapis/API_MID
/resources/RESOURCE_MID
/methods/HTTP_METHOD
/integration
/responses/STATUS_NUM =#Req: empty
DeleteIntegrationResponse() #Res: empty
POST /v2/apis/API_MID
/integrations/INTEGRATION_MID -~#Req: IRESP
/integrationresponses # - no integrationResponseId
CreateIntegrationResponse() #Res: IRESP
PATCH /v2/apis/API_MID
/integrations/INTEGRATION_MID -~#Req: IRESP
/integrationresponses/IRESP_MID # - no integrationResponseId
UpdateIntegrationResponse() #Res: IRESP
GET /v2/apis/API_MID
/integrations/INTEGRATION_MID
/integrationresponses -~#Req: empty
GetIntegrationResponses() #Res: items IRESP_ARR
GET /v2/apis/API_MID
/integrations/INTEGRATION_MID
/integrationresponses
/IRESP_MID -~#Req: empty
GetIntegrationResponse() #Res: IRESP
DELETE /v2/apis/API_MID
/integrations/INTEGRATION_MID
/integrationresponses
/IRESP_MID -~#Req: empty
DeleteIntegrationResponse() #Res: empty
IRESP #Response from backend, sent to RRESP (not client)
#Not with integrationType '*_PROXY'
IRESP_ARN =#arn:aws:apigateway:REGION::/restapis/API_MID/integrations/resources/RESOURCE_MID/methods/HTTP_METHOD/integration/responses/STATUS_NUM
IRESP_ARN -~#arn:aws:apigateway:REGION::/apis/API_MID/integrations[/IRESP_MID]
IRESP.integrationResponseId -~#IRESP_MID
IRESP.selectionPattern =#'REGEXP' whether to use IRESP, matched against STATUS_NUM
#Can be '' (def) as a catch-all
IRESP.integrationResponseKey -~#'/REGEXP/' whether to use IRESP, matched against STATUS_NUM
~#Can be '$default' as a catch-all
INTEGRATION
.integrationResponses.REGEXP =#IRESP
INTEGRATION.integrationResponse ~#'$EXPR' evaluated to IRESP.integrationResponseKey
SelectionExpression #Can only be '$integration.response.statuscode'
IRESP.statusCode =#'STATUS_NUM'
IRESP.responseParameters.EXPR =~#'EXPR2'. Response headers to send to RRESP (not client)
#EXPR: only 'response.header.*'
#EXPR2: only 'integration.response|stageVariables|context.*' or static STR
INTEGRATION -#'$EXPR'. Response headers to send to RRESP (not client)
.responseParameters.TEXPR #TEXPR: only headers or status code
#'$EXPR': only '$integration.response|stageVariables|context.*' or static STR
IRESP.responseTemplates.MIME =#'TEMPLATE'. Response body to send to RRESP (not client)
IRESP.responseTemplate ~#Same but as a name
.IRESP_TEMPLATE #Can be '$default' as a catch-all
IRESP ~#'IRESP_TEMPLATE_$EXPR'. Can be:
.templateSelectionExpression # - 'IRESP_TEMPLATE'
# - '$request.body.VARR'
# - '$integration.response.statuscode'
# - '$integration.response.[multivalue]header.HEADER'
ACONTEXT.integration.status =-
CONTEXT.integrationErrorMessage -
ACONTEXT.integration.error =-
ACONTEXT.integrationLatency =-
ACONTEXT.integration.latency =-#Same as ACONTEXT.authorize.* but for backend response
ACONTEXT[.integration] =-#Like ACONTEXT.integration.status except with Lambda:
.integrationStatus #STATUS_NUM of Invoke() call itself, not MAIN_RES.statusCode
AWS/ApiGateway/IntegrationLatency #CloudWatch METRIC with duration NUM (in ms) of INTEGRATION
/=+===============================+=\
/ : : \
)==: INTEGRATION LAMBDA :==(
\ :_______________________________: /
\=+===============================+=/
INTEGRATION.httpMethod =
INTEGRATION.integrationMethod -~#'POST'
INTEGRATION.uri =#'arn:aws:apigateway:REGION:lambda:path//YYYY-MM-DD/functions/SHORT_FUNC_ARN/invocations[?Qualifier=QUALIFIER]
INTEGRATION.integrationUri -~#Lambda FUNC_ARN
INTEGRATION.requestParameters #Can be used to set X-Amz-InvocationType|ClientContext|LogType [C]
LAMBDA INVOCATIONTYPE ==> #'RequestResponse', but can be changed with X-Amz-InvocationType [C]
PERMISSIONS ==> #Must use FUNCTION PERMISSION or INTEGRATION.credentials[Arn] to allow:
# - PACTION lambda:InvokeFunction
# - Principal.Service 'apigateway.amazonaws.com'
# - COND_KEY aws:SourceArn CALL_ROUTE_ARN
# - COND_KEY aws:SourceAccount|SourceOrg*
ERRORS ==> #Invocation|function errors (but not RES with 4**|5** status codes) are returned as 502 with
#response body { message: 'Internal server error' }
INTEGRATION -~#'X.Y' of the request sent to backend.
.payloadFormatVersion #With Lambda + integrationType 'AWS_PROXY':
-# - either '1.0' or '2.0', documented as REQ*[1|2]
~# - always '1.0', documented as REQ*[0]
#Otherwise, always '1.0'
REQ.version #undefined ('1.0') or '2.0'
REQ #If integrationType 'AWS', request body as is
#If integrationType 'AWS_PROXY', following properties
REQ.requestContext #REQ_CONTEXT
REQ_CONTEXT2.http #REQ_HTTP2
CONTEXT.protocol =-
REQ_CONTEXT1|REQ_HTTP2.protocol #Like FUNC_URL_REQ_CONTEXT_HTTP.protocol
CONTEXT.httpMethod =-
REQ[_CONTEXT]1.httpMethod
REQ_HTTP2.method #Like FUNC_URL_REQ_CONTEXT_HTTP.method
CONTEXT.domainPrefix =-
CONTEXT.apiId
REQ_CONTEXT.domainPrefix|apiId #'API_MID'
[REQ_]CONTEXT.domainName #STR
CONTEXT.path =-
REQ[_CONTEXT]1|REQ_HTTP2.path
REQ2.rawPath #'/PATH'
CONTEXT.resourcePath =
REQ1.resource
REQ_CONTEXT1.resourcePath #Last '/PATH' part
CONTEXT.resourceId =
REQ_CONTEXT1.resourceId #RESOURCE_MID
CONTEXT.routeKey -~
REQ_CONTEXT0|2.routeKey
REQ2.routeKey #'ROUTE'
REQ1|2.pathParameters #OBJ|null of PATHVARs
REQ2.rawQueryString
REQ1.queryStringParameters
REQ.headers
REQ2.cookies #Like FUNC_URL_REQ.*
REQ0|1
.multiValueQueryStringParameters
|multiValueHeaders #Same but, with ARR values (instead of comma-separated) if duplicate name
REQ0|1.body
REQ.isBase64Encoded #Like FUNC_URL_REQ.*
[REQ_]CONTEXT.stage #'STAGE'
REQ.stageVariables #OBJ|null of STAGEVARs
[REQ_]CONTEXT.requestId #REQ_ID of client request
CONTEXT|REQ_CONTEXT0|1
.extendedRequestId #x-amz-id-2 [S] of client request
CONTEXT.awsEndpointRequestId
ACONTEXT.integration.requestId =-#REQ_ID of backend request
CONTEXT.awsEndpointRequestId2 -#x-amz-id-2 [S] of backend request
CONTEXT|REQ_CONTEXT0|1
.requestTime[Epoch]
REQ_CONTEXT2.time[Epoch] #Like FUNC_URL_REQ_CONTEXT.time[Epoch]
REQ_IDENTITY0|1|REQ_HTTP2.sourceIp#Like FUNC_URL_REQ_CONTEXT_HTTP.*
REQ_IDENTITY1|REQ_HTTP2.userAgent #Like FUNC_URL_REQ_CONTEXT_HTTP.*
CONTEXT.accountId =-
REQ_CONTEXT.accountId #ACCOUNT_ID of API
CONTEXT.identity #CONTEXT_IDENTITY
REQ_CONTEXT0|1.identity #REQ_IDENTITY0|1
CONTEXT_IDENTITY.principalOrgId =-
REQ_IDENTITY0|1.principalOrgId
CONTEXT_IDENTITY|REQ_IDENTITY0|1
.accountId
CONTEXT_IDENTITY|REQ_IDENTITY0|1
.userArn
CONTEXT_IDENTITY|REQ_IDENTITY0|1
.user
CONTEXT_IDENTITY|REQ_IDENTITY0|1
.caller #Like FUNC_URL_REQ_IAM.*
REQ_IDENTITY0|1.accessKey #Only when IAM authenticated
RES #One of: MAIN_RES, ERROR_RES, CUSTOM_ERROR_RES
MAIN_RES.statusCode|headers|body #Like FUNC_URL_RES.*
|isBase64Encoded #Must base64 if binary MIME
MAIN_RES.multiValueHeaders #OBJ
ERROR_RES.errorType|errorMessage
|stackTrace|cause #Like Lambda
IRESP.selectionPattern
IRESP.integrationResponseKey #When using ERROR_RES, matches ERROR_RES.errorMessage, not STATUS_NUM
INTEGRATION.integrationResponse
SelectionExpression ~#When using ERROR_REST, must be '$integration.response.body.errorMessage' instead
CUSTOM_ERROR_RES #Is 'OBJ_JSON', not OBJ
CUSTOM_ERROR_RES.errorType #STR. ERROR.name
CUSTOM_ERROR_RES.trace #CUSTOM_ERROR_TRACE
CUSTOM_ERROR_TRACE.file #'FILENAME'
CUSTOM_ERROR_TRACE.function #'FUNC()'
CUSTOM_ERROR_TRACE.line #LINE_NUM
CUSTOM_ERROR_RES.httpStatus #STATUS_NUM
CUSTOM_ERROR_RES.requestId #REQ_ID. Should forward REQ_CONTEXT.requestId
/=+===============================+=\
/ : : \
)==: VPC :==(
\ :_______________________________: /
\=+===============================+=/
POST /vpclinks =#Req: VPCLINK
CreateVpcLink() # - no id, status*
#Res: VPCLINK
PATCH /vpclinks/VPCLINKS_MID =#Req: VPCLINK
UpdateVpcLink() # - no id, status*, targetArns, tags
#Res: VPCLINK
GET /vpclinks =#Req: empty
GetVpcLinks() #Res: item VPCLINK_ARR
GET /vpclinks/VPCLINKS_MID =#Req: empty
GetVpcLink() #Res: VPCLINK
DELETE /vpclinks/VPCLINKS_MID =#Req: empty
DeleteVpcLink() #Res: empty
POST /v2/vpclinks -#Req: VPCLINK
CreateVpcLink() # - no vpcLinkId, createdDate, vpcLinkVersion, vpcLinkStatus*
#Res: VPCLINK
PATCH /v2/vpclinks/VPCLINK_MID -#Req: VPCLINK
UpdateVpcLink() # - no vpcLinkId, createdDate, vpcLinkVersion, vpcLinkStatus*
# - no subnetIds, securityGroupIds, tags
#Res: VPCLINK
GET /v2/vpclinks -#Req: empty
GetVpcLinks() #Res: items VPCLINK_ARR
GET /v2/vpclinks/VPCLINK_MID -#Req: empty
GetVpcLink() #Res: VPCLINK
DELETE
/v2/vpclinks/VPCLINK_MID -#Req: empty
DeleteVpcLink() #Res: empty
VPCLINK =-#Access backend that uses a private VPC
#All resoures must be in same ACCOUNT
=#Max 20 per ACCOUNT + REGION (soft)
-#Max 10 per ACCOUNT + REGION (soft)
VPCLINK_ARN #arn:aws:apigateway:REGION::/vpclinks[/VPCLINK_MID]
VPCLINK.id =
VPCLINK.vpcLinkId -#VPCLINK_MID
VPCLINK.name =-#'VPCLINK'
VPCLINK.description =#STR
VPCLINK.createdDate -#'DATE'
VPCLINK.vpcLinkVersion -#Always 'V2'
INTEGRATION.connectionType =-#Either:
# - 'INTERNET' (def)
# - 'VPC_LINK': use connectionId
INTEGRATION.connectionId =-#VPCLINK_MID. Called "private INTEGRATION"
#Only with integrationType 'HTTP[_PROXY]'
=#Can be an $EXPR (only with STAGEVAR)
VPCLINK.subnetIds -#VPC SUBNET_MID_ARR
#Max 10 (soft)
VPCLINK.securityGroupIds -#VPC SECURITY_GROUP_MID_ARR
VPCLINK.targetArns =#ELB_ARN_ARR
INTEGRATION.uri #Not used for routing, but used to set Host [C] and for SSL verification