aws-cdk-lib 2.148.0__py3-none-any.whl → 2.149.0__py3-none-any.whl

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.

Potentially problematic release.


This version of aws-cdk-lib might be problematic. Click here for more details.

Files changed (31) hide show
  1. aws_cdk/_jsii/__init__.py +1 -1
  2. aws_cdk/_jsii/{aws-cdk-lib@2.148.0.jsii.tgz → aws-cdk-lib@2.149.0.jsii.tgz} +0 -0
  3. aws_cdk/aws_applicationautoscaling/__init__.py +16 -12
  4. aws_cdk/aws_bedrock/__init__.py +30 -2
  5. aws_cdk/aws_codebuild/__init__.py +57 -5
  6. aws_cdk/aws_codecommit/__init__.py +103 -0
  7. aws_cdk/aws_codedeploy/__init__.py +251 -5
  8. aws_cdk/aws_codepipeline/__init__.py +69 -0
  9. aws_cdk/aws_codestarnotifications/__init__.py +90 -4
  10. aws_cdk/aws_deadline/__init__.py +9 -15
  11. aws_cdk/aws_dms/__init__.py +10 -10
  12. aws_cdk/aws_ec2/__init__.py +4 -0
  13. aws_cdk/aws_emr/__init__.py +8 -8
  14. aws_cdk/aws_events/__init__.py +1 -13
  15. aws_cdk/aws_kinesisanalytics/__init__.py +11 -11
  16. aws_cdk/aws_kinesisanalyticsv2/__init__.py +11 -11
  17. aws_cdk/aws_rds/__init__.py +3 -3
  18. aws_cdk/aws_rolesanywhere/__init__.py +22 -13
  19. aws_cdk/aws_route53profiles/__init__.py +4 -4
  20. aws_cdk/aws_s3/__init__.py +15 -117
  21. aws_cdk/aws_ses/__init__.py +119 -102
  22. aws_cdk/aws_stepfunctions_tasks/__init__.py +209 -16
  23. aws_cdk/aws_verifiedpermissions/__init__.py +7 -9
  24. aws_cdk/aws_wafv2/__init__.py +10 -16
  25. aws_cdk/aws_workspaces/__init__.py +86 -56
  26. {aws_cdk_lib-2.148.0.dist-info → aws_cdk_lib-2.149.0.dist-info}/METADATA +1 -1
  27. {aws_cdk_lib-2.148.0.dist-info → aws_cdk_lib-2.149.0.dist-info}/RECORD +31 -31
  28. {aws_cdk_lib-2.148.0.dist-info → aws_cdk_lib-2.149.0.dist-info}/LICENSE +0 -0
  29. {aws_cdk_lib-2.148.0.dist-info → aws_cdk_lib-2.149.0.dist-info}/NOTICE +0 -0
  30. {aws_cdk_lib-2.148.0.dist-info → aws_cdk_lib-2.149.0.dist-info}/WHEEL +0 -0
  31. {aws_cdk_lib-2.148.0.dist-info → aws_cdk_lib-2.149.0.dist-info}/top_level.txt +0 -0
@@ -316,6 +316,28 @@ start_query_execution_job = tasks.AthenaStartQueryExecution(self, "Start Athena
316
316
  )
317
317
  ```
318
318
 
319
+ You can reuse the query results by setting the `resultReuseConfigurationMaxAge` property.
320
+
321
+ ```python
322
+ start_query_execution_job = tasks.AthenaStartQueryExecution(self, "Start Athena Query",
323
+ query_string=sfn.JsonPath.string_at("$.queryString"),
324
+ query_execution_context=tasks.QueryExecutionContext(
325
+ database_name="mydatabase"
326
+ ),
327
+ result_configuration=tasks.ResultConfiguration(
328
+ encryption_configuration=tasks.EncryptionConfiguration(
329
+ encryption_option=tasks.EncryptionOption.S3_MANAGED
330
+ ),
331
+ output_location=s3.Location(
332
+ bucket_name="query-results-bucket",
333
+ object_key="folder"
334
+ )
335
+ ),
336
+ execution_parameters=["param1", "param2"],
337
+ result_reuse_configuration_max_age=Duration.minutes(100)
338
+ )
339
+ ```
340
+
319
341
  ### GetQueryExecution
320
342
 
321
343
  The [GetQueryExecution](https://docs.aws.amazon.com/athena/latest/APIReference/API_GetQueryExecution.html) API gets information about a single execution of a query.
@@ -398,6 +420,30 @@ task = tasks.BedrockInvokeModel(self, "Prompt Model",
398
420
  )
399
421
  ```
400
422
 
423
+ You can apply a guardrail to the invocation by setting `guardrail`.
424
+
425
+ ```python
426
+ import aws_cdk.aws_bedrock as bedrock
427
+
428
+
429
+ model = bedrock.FoundationModel.from_foundation_model_id(self, "Model", bedrock.FoundationModelIdentifier.AMAZON_TITAN_TEXT_G1_EXPRESS_V1)
430
+
431
+ task = tasks.BedrockInvokeModel(self, "Prompt Model with guardrail",
432
+ model=model,
433
+ body=sfn.TaskInput.from_object({
434
+ "input_text": "Generate a list of five first names.",
435
+ "text_generation_config": {
436
+ "max_token_count": 100,
437
+ "temperature": 1
438
+ }
439
+ }),
440
+ guardrail=tasks.Guardrail.enable("guardrailId", 1),
441
+ result_selector={
442
+ "names": sfn.JsonPath.string_at("$.Body.results[0].outputText")
443
+ }
444
+ )
445
+ ```
446
+
401
447
  ## CodeBuild
402
448
 
403
449
  Step Functions supports [CodeBuild](https://docs.aws.amazon.com/step-functions/latest/dg/connect-codebuild.html) through the service integration pattern.
@@ -3018,6 +3064,7 @@ class AthenaStartQueryExecution(
3018
3064
  execution_parameters: typing.Optional[typing.Sequence[builtins.str]] = None,
3019
3065
  query_execution_context: typing.Optional[typing.Union["QueryExecutionContext", typing.Dict[builtins.str, typing.Any]]] = None,
3020
3066
  result_configuration: typing.Optional[typing.Union["ResultConfiguration", typing.Dict[builtins.str, typing.Any]]] = None,
3067
+ result_reuse_configuration_max_age: typing.Optional[_Duration_4839e8c3] = None,
3021
3068
  work_group: typing.Optional[builtins.str] = None,
3022
3069
  comment: typing.Optional[builtins.str] = None,
3023
3070
  credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
@@ -3040,6 +3087,7 @@ class AthenaStartQueryExecution(
3040
3087
  :param execution_parameters: A list of values for the parameters in a query. The values are applied sequentially to the parameters in the query in the order in which the parameters occur. Default: - No parameters
3041
3088
  :param query_execution_context: Database within which query executes. Default: - No query execution context
3042
3089
  :param result_configuration: Configuration on how and where to save query. Default: - No result configuration
3090
+ :param result_reuse_configuration_max_age: Specifies, in minutes, the maximum age of a previous query result that Athena should consider for reuse. Default: - Query results are not reused
3043
3091
  :param work_group: Configuration on how and where to save query. Default: - No work group
3044
3092
  :param comment: An optional description for this state. Default: - No comment
3045
3093
  :param credentials: Credentials for an IAM Role that the State Machine assumes for executing the task. This enables cross-account resource invocations. Default: - None (Task is executed using the State Machine's execution role)
@@ -3064,6 +3112,7 @@ class AthenaStartQueryExecution(
3064
3112
  execution_parameters=execution_parameters,
3065
3113
  query_execution_context=query_execution_context,
3066
3114
  result_configuration=result_configuration,
3115
+ result_reuse_configuration_max_age=result_reuse_configuration_max_age,
3067
3116
  work_group=work_group,
3068
3117
  comment=comment,
3069
3118
  credentials=credentials,
@@ -3113,6 +3162,7 @@ class AthenaStartQueryExecution(
3113
3162
  "execution_parameters": "executionParameters",
3114
3163
  "query_execution_context": "queryExecutionContext",
3115
3164
  "result_configuration": "resultConfiguration",
3165
+ "result_reuse_configuration_max_age": "resultReuseConfigurationMaxAge",
3116
3166
  "work_group": "workGroup",
3117
3167
  },
3118
3168
  )
@@ -3137,6 +3187,7 @@ class AthenaStartQueryExecutionProps(_TaskStateBaseProps_3a62b6d0):
3137
3187
  execution_parameters: typing.Optional[typing.Sequence[builtins.str]] = None,
3138
3188
  query_execution_context: typing.Optional[typing.Union["QueryExecutionContext", typing.Dict[builtins.str, typing.Any]]] = None,
3139
3189
  result_configuration: typing.Optional[typing.Union["ResultConfiguration", typing.Dict[builtins.str, typing.Any]]] = None,
3190
+ result_reuse_configuration_max_age: typing.Optional[_Duration_4839e8c3] = None,
3140
3191
  work_group: typing.Optional[builtins.str] = None,
3141
3192
  ) -> None:
3142
3193
  '''Properties for starting a Query Execution.
@@ -3158,6 +3209,7 @@ class AthenaStartQueryExecutionProps(_TaskStateBaseProps_3a62b6d0):
3158
3209
  :param execution_parameters: A list of values for the parameters in a query. The values are applied sequentially to the parameters in the query in the order in which the parameters occur. Default: - No parameters
3159
3210
  :param query_execution_context: Database within which query executes. Default: - No query execution context
3160
3211
  :param result_configuration: Configuration on how and where to save query. Default: - No result configuration
3212
+ :param result_reuse_configuration_max_age: Specifies, in minutes, the maximum age of a previous query result that Athena should consider for reuse. Default: - Query results are not reused
3161
3213
  :param work_group: Configuration on how and where to save query. Default: - No work group
3162
3214
 
3163
3215
  :exampleMetadata: infused
@@ -3206,6 +3258,7 @@ class AthenaStartQueryExecutionProps(_TaskStateBaseProps_3a62b6d0):
3206
3258
  check_type(argname="argument execution_parameters", value=execution_parameters, expected_type=type_hints["execution_parameters"])
3207
3259
  check_type(argname="argument query_execution_context", value=query_execution_context, expected_type=type_hints["query_execution_context"])
3208
3260
  check_type(argname="argument result_configuration", value=result_configuration, expected_type=type_hints["result_configuration"])
3261
+ check_type(argname="argument result_reuse_configuration_max_age", value=result_reuse_configuration_max_age, expected_type=type_hints["result_reuse_configuration_max_age"])
3209
3262
  check_type(argname="argument work_group", value=work_group, expected_type=type_hints["work_group"])
3210
3263
  self._values: typing.Dict[builtins.str, typing.Any] = {
3211
3264
  "query_string": query_string,
@@ -3242,6 +3295,8 @@ class AthenaStartQueryExecutionProps(_TaskStateBaseProps_3a62b6d0):
3242
3295
  self._values["query_execution_context"] = query_execution_context
3243
3296
  if result_configuration is not None:
3244
3297
  self._values["result_configuration"] = result_configuration
3298
+ if result_reuse_configuration_max_age is not None:
3299
+ self._values["result_reuse_configuration_max_age"] = result_reuse_configuration_max_age
3245
3300
  if work_group is not None:
3246
3301
  self._values["work_group"] = work_group
3247
3302
 
@@ -3446,6 +3501,15 @@ class AthenaStartQueryExecutionProps(_TaskStateBaseProps_3a62b6d0):
3446
3501
  result = self._values.get("result_configuration")
3447
3502
  return typing.cast(typing.Optional["ResultConfiguration"], result)
3448
3503
 
3504
+ @builtins.property
3505
+ def result_reuse_configuration_max_age(self) -> typing.Optional[_Duration_4839e8c3]:
3506
+ '''Specifies, in minutes, the maximum age of a previous query result that Athena should consider for reuse.
3507
+
3508
+ :default: - Query results are not reused
3509
+ '''
3510
+ result = self._values.get("result_reuse_configuration_max_age")
3511
+ return typing.cast(typing.Optional[_Duration_4839e8c3], result)
3512
+
3449
3513
  @builtins.property
3450
3514
  def work_group(self) -> typing.Optional[builtins.str]:
3451
3515
  '''Configuration on how and where to save query.
@@ -4660,8 +4724,10 @@ class BedrockInvokeModel(
4660
4724
  accept: typing.Optional[builtins.str] = None,
4661
4725
  body: typing.Optional[_TaskInput_91b91b91] = None,
4662
4726
  content_type: typing.Optional[builtins.str] = None,
4727
+ guardrail: typing.Optional["Guardrail"] = None,
4663
4728
  input: typing.Optional[typing.Union["BedrockInvokeModelInputProps", typing.Dict[builtins.str, typing.Any]]] = None,
4664
4729
  output: typing.Optional[typing.Union["BedrockInvokeModelOutputProps", typing.Dict[builtins.str, typing.Any]]] = None,
4730
+ trace_enabled: typing.Optional[builtins.bool] = None,
4665
4731
  comment: typing.Optional[builtins.str] = None,
4666
4732
  credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
4667
4733
  heartbeat: typing.Optional[_Duration_4839e8c3] = None,
@@ -4680,10 +4746,12 @@ class BedrockInvokeModel(
4680
4746
  :param id: Descriptive identifier for this chainable.
4681
4747
  :param model: The Bedrock model that the task will invoke.
4682
4748
  :param accept: The desired MIME type of the inference body in the response. Default: 'application/json'
4683
- :param body: The input data for the Bedrock model invocation. The inference parameters contained in the body depend on the Bedrock model being used. The body must be in the format specified in the ``contentType`` field. For example, if the content type is ``application/json``, the body must be JSON formatted. The body must be up to 256 KB in size. For input data that exceeds 256 KB, use ``input`` instead to retrieve the input data from S3. You must specify either the ``body`` or the ``input`` field, but not both. Default: Input data is retrieved from the location specified in the ``input`` field
4684
- :param content_type: The MIME type of the input data in the request. Default: 'application/json'
4685
- :param input: The source location to retrieve the input data from. Default: Input data is retrieved from the ``body`` field
4686
- :param output: The destination location where the API response is written. If you specify this field, the API response body is replaced with a reference to the output location. Default: The API response body is returned in the result.
4749
+ :param body: The input data for the Bedrock model invocation. The inference parameters contained in the body depend on the Bedrock model being used. The body must be in the format specified in the ``contentType`` field. For example, if the content type is ``application/json``, the body must be JSON formatted. The body must be up to 256 KB in size. For input data that exceeds 256 KB, use ``input`` instead to retrieve the input data from S3. You must specify either the ``body`` or the ``input`` field, but not both. Default: - Input data is retrieved from the location specified in the ``input`` field
4750
+ :param content_type: (deprecated) The MIME type of the input data in the request. Default: 'application/json'
4751
+ :param guardrail: The guardrail is applied to the invocation. Default: - No guardrail is applied to the invocation.
4752
+ :param input: The source location to retrieve the input data from. Default: - Input data is retrieved from the ``body`` field
4753
+ :param output: The destination location where the API response is written. If you specify this field, the API response body is replaced with a reference to the output location. Default: - The API response body is returned in the result.
4754
+ :param trace_enabled: Specifies whether to enable or disable the Bedrock trace. Default: - Trace is not enabled for the invocation.
4687
4755
  :param comment: An optional description for this state. Default: - No comment
4688
4756
  :param credentials: Credentials for an IAM Role that the State Machine assumes for executing the task. This enables cross-account resource invocations. Default: - None (Task is executed using the State Machine's execution role)
4689
4757
  :param heartbeat: (deprecated) Timeout for the heartbeat. Default: - None
@@ -4706,8 +4774,10 @@ class BedrockInvokeModel(
4706
4774
  accept=accept,
4707
4775
  body=body,
4708
4776
  content_type=content_type,
4777
+ guardrail=guardrail,
4709
4778
  input=input,
4710
4779
  output=output,
4780
+ trace_enabled=trace_enabled,
4711
4781
  comment=comment,
4712
4782
  credentials=credentials,
4713
4783
  heartbeat=heartbeat,
@@ -4748,7 +4818,7 @@ class BedrockInvokeModelInputProps:
4748
4818
  ) -> None:
4749
4819
  '''Location to retrieve the input data, prior to calling Bedrock InvokeModel.
4750
4820
 
4751
- :param s3_location: S3 object to retrieve the input data from. If the S3 location is not set, then the Body must be set. Default: Input data is retrieved from the ``body`` field
4821
+ :param s3_location: S3 object to retrieve the input data from. If the S3 location is not set, then the Body must be set. Default: - Input data is retrieved from the ``body`` field
4752
4822
 
4753
4823
  :see: https://docs.aws.amazon.com/step-functions/latest/dg/connect-bedrock.html
4754
4824
  :exampleMetadata: fixture=_generated
@@ -4784,7 +4854,7 @@ class BedrockInvokeModelInputProps:
4784
4854
 
4785
4855
  If the S3 location is not set, then the Body must be set.
4786
4856
 
4787
- :default: Input data is retrieved from the ``body`` field
4857
+ :default: - Input data is retrieved from the ``body`` field
4788
4858
  '''
4789
4859
  result = self._values.get("s3_location")
4790
4860
  return typing.cast(typing.Optional[_Location_0948fa7f], result)
@@ -4814,7 +4884,7 @@ class BedrockInvokeModelOutputProps:
4814
4884
  ) -> None:
4815
4885
  '''Location where the Bedrock InvokeModel API response is written.
4816
4886
 
4817
- :param s3_location: S3 object where the Bedrock InvokeModel API response is written. If you specify this field, the API response body is replaced with a reference to the Amazon S3 location of the original output. Default: Response body is returned in the task result
4887
+ :param s3_location: S3 object where the Bedrock InvokeModel API response is written. If you specify this field, the API response body is replaced with a reference to the Amazon S3 location of the original output. Default: - Response body is returned in the task result
4818
4888
 
4819
4889
  :see: https://docs.aws.amazon.com/step-functions/latest/dg/connect-bedrock.html
4820
4890
  :exampleMetadata: fixture=_generated
@@ -4851,7 +4921,7 @@ class BedrockInvokeModelOutputProps:
4851
4921
  If you specify this field, the API response body is replaced with
4852
4922
  a reference to the Amazon S3 location of the original output.
4853
4923
 
4854
- :default: Response body is returned in the task result
4924
+ :default: - Response body is returned in the task result
4855
4925
  '''
4856
4926
  result = self._values.get("s3_location")
4857
4927
  return typing.cast(typing.Optional[_Location_0948fa7f], result)
@@ -4888,8 +4958,10 @@ class BedrockInvokeModelOutputProps:
4888
4958
  "accept": "accept",
4889
4959
  "body": "body",
4890
4960
  "content_type": "contentType",
4961
+ "guardrail": "guardrail",
4891
4962
  "input": "input",
4892
4963
  "output": "output",
4964
+ "trace_enabled": "traceEnabled",
4893
4965
  },
4894
4966
  )
4895
4967
  class BedrockInvokeModelProps(_TaskStateBaseProps_3a62b6d0):
@@ -4912,8 +4984,10 @@ class BedrockInvokeModelProps(_TaskStateBaseProps_3a62b6d0):
4912
4984
  accept: typing.Optional[builtins.str] = None,
4913
4985
  body: typing.Optional[_TaskInput_91b91b91] = None,
4914
4986
  content_type: typing.Optional[builtins.str] = None,
4987
+ guardrail: typing.Optional["Guardrail"] = None,
4915
4988
  input: typing.Optional[typing.Union[BedrockInvokeModelInputProps, typing.Dict[builtins.str, typing.Any]]] = None,
4916
4989
  output: typing.Optional[typing.Union[BedrockInvokeModelOutputProps, typing.Dict[builtins.str, typing.Any]]] = None,
4990
+ trace_enabled: typing.Optional[builtins.bool] = None,
4917
4991
  ) -> None:
4918
4992
  '''Properties for invoking a Bedrock Model.
4919
4993
 
@@ -4931,10 +5005,12 @@ class BedrockInvokeModelProps(_TaskStateBaseProps_3a62b6d0):
4931
5005
  :param timeout: (deprecated) Timeout for the task. Default: - None
4932
5006
  :param model: The Bedrock model that the task will invoke.
4933
5007
  :param accept: The desired MIME type of the inference body in the response. Default: 'application/json'
4934
- :param body: The input data for the Bedrock model invocation. The inference parameters contained in the body depend on the Bedrock model being used. The body must be in the format specified in the ``contentType`` field. For example, if the content type is ``application/json``, the body must be JSON formatted. The body must be up to 256 KB in size. For input data that exceeds 256 KB, use ``input`` instead to retrieve the input data from S3. You must specify either the ``body`` or the ``input`` field, but not both. Default: Input data is retrieved from the location specified in the ``input`` field
4935
- :param content_type: The MIME type of the input data in the request. Default: 'application/json'
4936
- :param input: The source location to retrieve the input data from. Default: Input data is retrieved from the ``body`` field
4937
- :param output: The destination location where the API response is written. If you specify this field, the API response body is replaced with a reference to the output location. Default: The API response body is returned in the result.
5008
+ :param body: The input data for the Bedrock model invocation. The inference parameters contained in the body depend on the Bedrock model being used. The body must be in the format specified in the ``contentType`` field. For example, if the content type is ``application/json``, the body must be JSON formatted. The body must be up to 256 KB in size. For input data that exceeds 256 KB, use ``input`` instead to retrieve the input data from S3. You must specify either the ``body`` or the ``input`` field, but not both. Default: - Input data is retrieved from the location specified in the ``input`` field
5009
+ :param content_type: (deprecated) The MIME type of the input data in the request. Default: 'application/json'
5010
+ :param guardrail: The guardrail is applied to the invocation. Default: - No guardrail is applied to the invocation.
5011
+ :param input: The source location to retrieve the input data from. Default: - Input data is retrieved from the ``body`` field
5012
+ :param output: The destination location where the API response is written. If you specify this field, the API response body is replaced with a reference to the output location. Default: - The API response body is returned in the result.
5013
+ :param trace_enabled: Specifies whether to enable or disable the Bedrock trace. Default: - Trace is not enabled for the invocation.
4938
5014
 
4939
5015
  :exampleMetadata: infused
4940
5016
 
@@ -4983,8 +5059,10 @@ class BedrockInvokeModelProps(_TaskStateBaseProps_3a62b6d0):
4983
5059
  check_type(argname="argument accept", value=accept, expected_type=type_hints["accept"])
4984
5060
  check_type(argname="argument body", value=body, expected_type=type_hints["body"])
4985
5061
  check_type(argname="argument content_type", value=content_type, expected_type=type_hints["content_type"])
5062
+ check_type(argname="argument guardrail", value=guardrail, expected_type=type_hints["guardrail"])
4986
5063
  check_type(argname="argument input", value=input, expected_type=type_hints["input"])
4987
5064
  check_type(argname="argument output", value=output, expected_type=type_hints["output"])
5065
+ check_type(argname="argument trace_enabled", value=trace_enabled, expected_type=type_hints["trace_enabled"])
4988
5066
  self._values: typing.Dict[builtins.str, typing.Any] = {
4989
5067
  "model": model,
4990
5068
  }
@@ -5018,10 +5096,14 @@ class BedrockInvokeModelProps(_TaskStateBaseProps_3a62b6d0):
5018
5096
  self._values["body"] = body
5019
5097
  if content_type is not None:
5020
5098
  self._values["content_type"] = content_type
5099
+ if guardrail is not None:
5100
+ self._values["guardrail"] = guardrail
5021
5101
  if input is not None:
5022
5102
  self._values["input"] = input
5023
5103
  if output is not None:
5024
5104
  self._values["output"] = output
5105
+ if trace_enabled is not None:
5106
+ self._values["trace_enabled"] = trace_enabled
5025
5107
 
5026
5108
  @builtins.property
5027
5109
  def comment(self) -> typing.Optional[builtins.str]:
@@ -5214,7 +5296,7 @@ class BedrockInvokeModelProps(_TaskStateBaseProps_3a62b6d0):
5214
5296
 
5215
5297
  You must specify either the ``body`` or the ``input`` field, but not both.
5216
5298
 
5217
- :default: Input data is retrieved from the location specified in the ``input`` field
5299
+ :default: - Input data is retrieved from the location specified in the ``input`` field
5218
5300
 
5219
5301
  :see: https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html
5220
5302
  '''
@@ -5223,20 +5305,32 @@ class BedrockInvokeModelProps(_TaskStateBaseProps_3a62b6d0):
5223
5305
 
5224
5306
  @builtins.property
5225
5307
  def content_type(self) -> typing.Optional[builtins.str]:
5226
- '''The MIME type of the input data in the request.
5308
+ '''(deprecated) The MIME type of the input data in the request.
5227
5309
 
5228
5310
  :default: 'application/json'
5229
5311
 
5312
+ :deprecated: This property does not require configuration because the only acceptable value is 'application/json'.
5313
+
5230
5314
  :see: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_InvokeModel.html
5315
+ :stability: deprecated
5231
5316
  '''
5232
5317
  result = self._values.get("content_type")
5233
5318
  return typing.cast(typing.Optional[builtins.str], result)
5234
5319
 
5320
+ @builtins.property
5321
+ def guardrail(self) -> typing.Optional["Guardrail"]:
5322
+ '''The guardrail is applied to the invocation.
5323
+
5324
+ :default: - No guardrail is applied to the invocation.
5325
+ '''
5326
+ result = self._values.get("guardrail")
5327
+ return typing.cast(typing.Optional["Guardrail"], result)
5328
+
5235
5329
  @builtins.property
5236
5330
  def input(self) -> typing.Optional[BedrockInvokeModelInputProps]:
5237
5331
  '''The source location to retrieve the input data from.
5238
5332
 
5239
- :default: Input data is retrieved from the ``body`` field
5333
+ :default: - Input data is retrieved from the ``body`` field
5240
5334
  '''
5241
5335
  result = self._values.get("input")
5242
5336
  return typing.cast(typing.Optional[BedrockInvokeModelInputProps], result)
@@ -5248,11 +5342,20 @@ class BedrockInvokeModelProps(_TaskStateBaseProps_3a62b6d0):
5248
5342
  If you specify this field, the API response body is replaced with a reference to the
5249
5343
  output location.
5250
5344
 
5251
- :default: The API response body is returned in the result.
5345
+ :default: - The API response body is returned in the result.
5252
5346
  '''
5253
5347
  result = self._values.get("output")
5254
5348
  return typing.cast(typing.Optional[BedrockInvokeModelOutputProps], result)
5255
5349
 
5350
+ @builtins.property
5351
+ def trace_enabled(self) -> typing.Optional[builtins.bool]:
5352
+ '''Specifies whether to enable or disable the Bedrock trace.
5353
+
5354
+ :default: - Trace is not enabled for the invocation.
5355
+ '''
5356
+ result = self._values.get("trace_enabled")
5357
+ return typing.cast(typing.Optional[builtins.bool], result)
5358
+
5256
5359
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
5257
5360
  return isinstance(rhs, self.__class__) and rhs._values == self._values
5258
5361
 
@@ -24254,6 +24357,76 @@ class GlueStartJobRunProps(_TaskStateBaseProps_3a62b6d0):
24254
24357
  )
24255
24358
 
24256
24359
 
24360
+ class Guardrail(
24361
+ metaclass=jsii.JSIIMeta,
24362
+ jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.Guardrail",
24363
+ ):
24364
+ '''Guradrail settings for BedrockInvokeModel.
24365
+
24366
+ :exampleMetadata: infused
24367
+
24368
+ Example::
24369
+
24370
+ import aws_cdk.aws_bedrock as bedrock
24371
+
24372
+
24373
+ model = bedrock.FoundationModel.from_foundation_model_id(self, "Model", bedrock.FoundationModelIdentifier.AMAZON_TITAN_TEXT_G1_EXPRESS_V1)
24374
+
24375
+ task = tasks.BedrockInvokeModel(self, "Prompt Model with guardrail",
24376
+ model=model,
24377
+ body=sfn.TaskInput.from_object({
24378
+ "input_text": "Generate a list of five first names.",
24379
+ "text_generation_config": {
24380
+ "max_token_count": 100,
24381
+ "temperature": 1
24382
+ }
24383
+ }),
24384
+ guardrail=tasks.Guardrail.enable("guardrailId", 1),
24385
+ result_selector={
24386
+ "names": sfn.JsonPath.string_at("$.Body.results[0].outputText")
24387
+ }
24388
+ )
24389
+ '''
24390
+
24391
+ @jsii.member(jsii_name="enable")
24392
+ @builtins.classmethod
24393
+ def enable(cls, identifier: builtins.str, version: jsii.Number) -> "Guardrail":
24394
+ '''Enable guardrail.
24395
+
24396
+ :param identifier: The id or arn of the guardrail.
24397
+ :param version: The version of the guardrail.
24398
+ '''
24399
+ if __debug__:
24400
+ type_hints = typing.get_type_hints(_typecheckingstub__5fa6ebe8b4dbacaaab9ce1d7f96201628e8429b6f1e9480ecaf651f59e53f917)
24401
+ check_type(argname="argument identifier", value=identifier, expected_type=type_hints["identifier"])
24402
+ check_type(argname="argument version", value=version, expected_type=type_hints["version"])
24403
+ return typing.cast("Guardrail", jsii.sinvoke(cls, "enable", [identifier, version]))
24404
+
24405
+ @jsii.member(jsii_name="enableDraft")
24406
+ @builtins.classmethod
24407
+ def enable_draft(cls, identifier: builtins.str) -> "Guardrail":
24408
+ '''Enable guardrail with DRAFT version.
24409
+
24410
+ :param identifier: The identifier of the guardrail. Must be between 1 and 2048 characters in length.
24411
+ '''
24412
+ if __debug__:
24413
+ type_hints = typing.get_type_hints(_typecheckingstub__7303b9390112fa7a595653a20262a8472e6088014bf04484e53c9069efdff499)
24414
+ check_type(argname="argument identifier", value=identifier, expected_type=type_hints["identifier"])
24415
+ return typing.cast("Guardrail", jsii.sinvoke(cls, "enableDraft", [identifier]))
24416
+
24417
+ @builtins.property
24418
+ @jsii.member(jsii_name="guardrailIdentifier")
24419
+ def guardrail_identifier(self) -> builtins.str:
24420
+ '''The identitifier of guardrail.'''
24421
+ return typing.cast(builtins.str, jsii.get(self, "guardrailIdentifier"))
24422
+
24423
+ @builtins.property
24424
+ @jsii.member(jsii_name="guardrailVersion")
24425
+ def guardrail_version(self) -> builtins.str:
24426
+ '''The version of guardrail.'''
24427
+ return typing.cast(builtins.str, jsii.get(self, "guardrailVersion"))
24428
+
24429
+
24257
24430
  class HttpInvoke(
24258
24431
  _TaskStateBase_b5c0a816,
24259
24432
  metaclass=jsii.JSIIMeta,
@@ -34100,6 +34273,7 @@ __all__ = [
34100
34273
  "GlueStartCrawlerRunProps",
34101
34274
  "GlueStartJobRun",
34102
34275
  "GlueStartJobRunProps",
34276
+ "Guardrail",
34103
34277
  "HttpInvoke",
34104
34278
  "HttpInvokeProps",
34105
34279
  "HttpMethod",
@@ -34305,6 +34479,7 @@ def _typecheckingstub__74ee21cd0bad6760da4cd18a6c4cd846a24d69d25b7bac8eb004edf64
34305
34479
  execution_parameters: typing.Optional[typing.Sequence[builtins.str]] = None,
34306
34480
  query_execution_context: typing.Optional[typing.Union[QueryExecutionContext, typing.Dict[builtins.str, typing.Any]]] = None,
34307
34481
  result_configuration: typing.Optional[typing.Union[ResultConfiguration, typing.Dict[builtins.str, typing.Any]]] = None,
34482
+ result_reuse_configuration_max_age: typing.Optional[_Duration_4839e8c3] = None,
34308
34483
  work_group: typing.Optional[builtins.str] = None,
34309
34484
  comment: typing.Optional[builtins.str] = None,
34310
34485
  credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
@@ -34341,6 +34516,7 @@ def _typecheckingstub__d2b6c9868cc3485b4ed4a4ef1f89308086ff873bc4d86413aa4b420c9
34341
34516
  execution_parameters: typing.Optional[typing.Sequence[builtins.str]] = None,
34342
34517
  query_execution_context: typing.Optional[typing.Union[QueryExecutionContext, typing.Dict[builtins.str, typing.Any]]] = None,
34343
34518
  result_configuration: typing.Optional[typing.Union[ResultConfiguration, typing.Dict[builtins.str, typing.Any]]] = None,
34519
+ result_reuse_configuration_max_age: typing.Optional[_Duration_4839e8c3] = None,
34344
34520
  work_group: typing.Optional[builtins.str] = None,
34345
34521
  ) -> None:
34346
34522
  """Type checking stubs"""
@@ -34470,8 +34646,10 @@ def _typecheckingstub__3b20c515efa874adacf78d373dbda10fc59e519a3bd1b280ecbf56409
34470
34646
  accept: typing.Optional[builtins.str] = None,
34471
34647
  body: typing.Optional[_TaskInput_91b91b91] = None,
34472
34648
  content_type: typing.Optional[builtins.str] = None,
34649
+ guardrail: typing.Optional[Guardrail] = None,
34473
34650
  input: typing.Optional[typing.Union[BedrockInvokeModelInputProps, typing.Dict[builtins.str, typing.Any]]] = None,
34474
34651
  output: typing.Optional[typing.Union[BedrockInvokeModelOutputProps, typing.Dict[builtins.str, typing.Any]]] = None,
34652
+ trace_enabled: typing.Optional[builtins.bool] = None,
34475
34653
  comment: typing.Optional[builtins.str] = None,
34476
34654
  credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
34477
34655
  heartbeat: typing.Optional[_Duration_4839e8c3] = None,
@@ -34520,8 +34698,10 @@ def _typecheckingstub__a9bf54cbc3850dd1a65ada3b96e97b5e68b7027badd90592dbcc79a35
34520
34698
  accept: typing.Optional[builtins.str] = None,
34521
34699
  body: typing.Optional[_TaskInput_91b91b91] = None,
34522
34700
  content_type: typing.Optional[builtins.str] = None,
34701
+ guardrail: typing.Optional[Guardrail] = None,
34523
34702
  input: typing.Optional[typing.Union[BedrockInvokeModelInputProps, typing.Dict[builtins.str, typing.Any]]] = None,
34524
34703
  output: typing.Optional[typing.Union[BedrockInvokeModelOutputProps, typing.Dict[builtins.str, typing.Any]]] = None,
34704
+ trace_enabled: typing.Optional[builtins.bool] = None,
34525
34705
  ) -> None:
34526
34706
  """Type checking stubs"""
34527
34707
  pass
@@ -36424,6 +36604,19 @@ def _typecheckingstub__6a5a6a067402f20efc3f218ecff8d7cae8c7206cf0bfb73907469d47f
36424
36604
  """Type checking stubs"""
36425
36605
  pass
36426
36606
 
36607
+ def _typecheckingstub__5fa6ebe8b4dbacaaab9ce1d7f96201628e8429b6f1e9480ecaf651f59e53f917(
36608
+ identifier: builtins.str,
36609
+ version: jsii.Number,
36610
+ ) -> None:
36611
+ """Type checking stubs"""
36612
+ pass
36613
+
36614
+ def _typecheckingstub__7303b9390112fa7a595653a20262a8472e6088014bf04484e53c9069efdff499(
36615
+ identifier: builtins.str,
36616
+ ) -> None:
36617
+ """Type checking stubs"""
36618
+ pass
36619
+
36427
36620
  def _typecheckingstub__380dcb304dd02d709d798634fa365c757bcaa7593ab7542271009736c47d0329(
36428
36621
  scope: _constructs_77d1e7e8.Construct,
36429
36622
  id: builtins.str,
@@ -143,7 +143,7 @@ class CfnIdentitySource(
143
143
  '''
144
144
  :param scope: Scope in which this resource is defined.
145
145
  :param id: Construct identifier for this resource (unique in its scope).
146
- :param configuration: Contains configuration information about an identity source.
146
+ :param configuration: Contains configuration information used when creating a new identity source.
147
147
  :param policy_store_id: Specifies the ID of the policy store in which you want to store this identity source. Only policies and requests made using this policy store can reference identities from the identity provider configured in the new identity source.
148
148
  :param principal_entity_type: Specifies the namespace and data type of the principals generated for identities authenticated by the new identity source.
149
149
  '''
@@ -248,7 +248,7 @@ class CfnIdentitySource(
248
248
  def configuration(
249
249
  self,
250
250
  ) -> typing.Union[_IResolvable_da3f097b, "CfnIdentitySource.IdentitySourceConfigurationProperty"]:
251
- '''Contains configuration information about an identity source.'''
251
+ '''Contains configuration information used when creating a new identity source.'''
252
252
  return typing.cast(typing.Union[_IResolvable_da3f097b, "CfnIdentitySource.IdentitySourceConfigurationProperty"], jsii.get(self, "configuration"))
253
253
 
254
254
  @configuration.setter
@@ -296,8 +296,6 @@ class CfnIdentitySource(
296
296
  def __init__(self, *, group_entity_type: builtins.str) -> None:
297
297
  '''The type of entity that a policy store maps to groups from an Amazon Cognito user pool identity source.
298
298
 
299
- This data type is part of a `CognitoUserPoolConfiguration <https://docs.aws.amazon.com/verifiedpermissions/latest/apireference/API_CognitoUserPoolConfiguration.html>`_ structure and is a request parameter in `CreateIdentitySource <https://docs.aws.amazon.com/verifiedpermissions/latest/apireference/API_CreateIdentitySource.html>`_ .
300
-
301
299
  :param group_entity_type: The name of the schema entity type that's mapped to the user pool group. Defaults to ``AWS::CognitoGroup`` .
302
300
 
303
301
  :see: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-verifiedpermissions-identitysource-cognitogroupconfiguration.html
@@ -1145,7 +1143,7 @@ class CfnIdentitySourceProps:
1145
1143
  ) -> None:
1146
1144
  '''Properties for defining a ``CfnIdentitySource``.
1147
1145
 
1148
- :param configuration: Contains configuration information about an identity source.
1146
+ :param configuration: Contains configuration information used when creating a new identity source.
1149
1147
  :param policy_store_id: Specifies the ID of the policy store in which you want to store this identity source. Only policies and requests made using this policy store can reference identities from the identity provider configured in the new identity source.
1150
1148
  :param principal_entity_type: Specifies the namespace and data type of the principals generated for identities authenticated by the new identity source.
1151
1149
 
@@ -1212,7 +1210,7 @@ class CfnIdentitySourceProps:
1212
1210
  def configuration(
1213
1211
  self,
1214
1212
  ) -> typing.Union[_IResolvable_da3f097b, CfnIdentitySource.IdentitySourceConfigurationProperty]:
1215
- '''Contains configuration information about an identity source.
1213
+ '''Contains configuration information used when creating a new identity source.
1216
1214
 
1217
1215
  :see: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-verifiedpermissions-identitysource.html#cfn-verifiedpermissions-identitysource-configuration
1218
1216
  '''
@@ -1263,7 +1261,7 @@ class CfnPolicy(
1263
1261
 
1264
1262
  You can create either a static policy or a policy linked to a policy template.
1265
1263
 
1266
- You can directly update only static policies. To update a template-linked policy, you must update it's linked policy template instead.
1264
+ You can directly update only static policies. To update a template-linked policy, you must update its linked policy template instead.
1267
1265
 
1268
1266
  - To create a static policy, in the ``Definition`` include a ``Static`` element that includes the Cedar policy text in the ``Statement`` element.
1269
1267
  - To create a policy that is dynamically linked to a policy template, in the ``Definition`` include a ``Templatelinked`` element that specifies the policy template ID and the principal and resource to associate with this policy. If the policy template is ever updated, any policies linked to the policy template automatically use the updated template.
@@ -2056,7 +2054,7 @@ class CfnPolicyStore(
2056
2054
 
2057
2055
  If the validation mode for the policy store is set to ``STRICT`` , then policies that can't be validated by this schema are rejected by Verified Permissions and can't be stored in the policy store.
2058
2056
 
2059
- :param cedar_json: A JSON string representation of the schema supported by applications that use this policy store. For more information, see `Policy store schema <https://docs.aws.amazon.com/verifiedpermissions/latest/userguide/schema.html>`_ in the *Amazon Verified Permissions User Guide* .
2057
+ :param cedar_json: A JSON string representation of the schema supported by applications that use this policy store. For more information, see `Policy store schema <https://docs.aws.amazon.com/verifiedpermissions/latest/userguide/schema.html>`_ in the AVP User Guide.
2060
2058
 
2061
2059
  :see: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-verifiedpermissions-policystore-schemadefinition.html
2062
2060
  :exampleMetadata: fixture=_generated
@@ -2082,7 +2080,7 @@ class CfnPolicyStore(
2082
2080
  def cedar_json(self) -> typing.Optional[builtins.str]:
2083
2081
  '''A JSON string representation of the schema supported by applications that use this policy store.
2084
2082
 
2085
- For more information, see `Policy store schema <https://docs.aws.amazon.com/verifiedpermissions/latest/userguide/schema.html>`_ in the *Amazon Verified Permissions User Guide* .
2083
+ For more information, see `Policy store schema <https://docs.aws.amazon.com/verifiedpermissions/latest/userguide/schema.html>`_ in the AVP User Guide.
2086
2084
 
2087
2085
  :see: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-verifiedpermissions-policystore-schemadefinition.html#cfn-verifiedpermissions-policystore-schemadefinition-cedarjson
2088
2086
  '''
@@ -5476,9 +5476,11 @@ class CfnRuleGroup(
5476
5476
 
5477
5477
  Example JSON: ``"JsonBody": { "MatchPattern": { "All": {} }, "MatchScope": "ALL" }``
5478
5478
 
5479
+ For additional information about this request component option, see `JSON body <https://docs.aws.amazon.com/waf/latest/developerguide/waf-rule-statement-fields-list.html#waf-rule-statement-request-component-json-body>`_ in the *AWS WAF Developer Guide* .
5480
+
5479
5481
  :param match_pattern: The patterns to look for in the JSON body. AWS WAF inspects the results of these pattern matches against the rule inspection criteria.
5480
5482
  :param match_scope: The parts of the JSON to match against using the ``MatchPattern`` . If you specify ``ALL`` , AWS WAF matches against keys and values. ``All`` does not require a match to be found in the keys and a match to be found in the values. It requires a match to be found in the keys or the values or both. To require a match in the keys and in the values, use a logical ``AND`` statement to combine two match rules, one that inspects the keys and another that inspects the values.
5481
- :param invalid_fallback_behavior: What AWS WAF should do if it fails to completely parse the JSON body. The options are the following:. - ``EVALUATE_AS_STRING`` - Inspect the body as plain text. AWS WAF applies the text transformations and inspection criteria that you defined for the JSON inspection to the body text string. - ``MATCH`` - Treat the web request as matching the rule statement. AWS WAF applies the rule action to the request. - ``NO_MATCH`` - Treat the web request as not matching the rule statement. If you don't provide this setting, AWS WAF parses and evaluates the content only up to the first parsing failure that it encounters. AWS WAF does its best to parse the entire JSON body, but might be forced to stop for reasons such as invalid characters, duplicate keys, truncation, and any content whose root node isn't an object or an array. AWS WAF parses the JSON in the following examples as two valid key, value pairs: - Missing comma: ``{"key1":"value1""key2":"value2"}`` - Missing colon: ``{"key1":"value1","key2""value2"}`` - Extra colons: ``{"key1"::"value1","key2""value2"}``
5483
+ :param invalid_fallback_behavior: What AWS WAF should do if it fails to completely parse the JSON body. The options are the following:. - ``EVALUATE_AS_STRING`` - Inspect the body as plain text. AWS WAF applies the text transformations and inspection criteria that you defined for the JSON inspection to the body text string. - ``MATCH`` - Treat the web request as matching the rule statement. AWS WAF applies the rule action to the request. - ``NO_MATCH`` - Treat the web request as not matching the rule statement. If you don't provide this setting, AWS WAF parses and evaluates the content only up to the first parsing failure that it encounters. .. epigraph:: AWS WAF parsing doesn't fully validate the input JSON string, so parsing can succeed even for invalid JSON. When parsing succeeds, AWS WAF doesn't apply the fallback behavior. For more information, see `JSON body <https://docs.aws.amazon.com/waf/latest/developerguide/waf-rule-statement-fields-list.html#waf-rule-statement-request-component-json-body>`_ in the *AWS WAF Developer Guide* .
5482
5484
  :param oversize_handling: What AWS WAF should do if the body is larger than AWS WAF can inspect. AWS WAF does not support inspecting the entire contents of the web request body if the body exceeds the limit for the resource type. When a web request body is larger than the limit, the underlying host service only forwards the contents that are within the limit to AWS WAF for inspection. - For Application Load Balancer and AWS AppSync , the limit is fixed at 8 KB (8,192 bytes). - For CloudFront, API Gateway, Amazon Cognito, App Runner, and Verified Access, the default limit is 16 KB (16,384 bytes), and you can increase the limit for each resource type in the web ACL ``AssociationConfig`` , for additional processing fees. The options for oversize handling are the following: - ``CONTINUE`` - Inspect the available body contents normally, according to the rule inspection criteria. - ``MATCH`` - Treat the web request as matching the rule statement. AWS WAF applies the rule action to the request. - ``NO_MATCH`` - Treat the web request as not matching the rule statement. You can combine the ``MATCH`` or ``NO_MATCH`` settings for oversize handling with your rule and web ACL action settings, so that you block any request whose body is over the limit. Default: ``CONTINUE``
5483
5485
 
5484
5486
  :see: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wafv2-rulegroup-jsonbody.html
@@ -5556,14 +5558,9 @@ class CfnRuleGroup(
5556
5558
  - ``NO_MATCH`` - Treat the web request as not matching the rule statement.
5557
5559
 
5558
5560
  If you don't provide this setting, AWS WAF parses and evaluates the content only up to the first parsing failure that it encounters.
5561
+ .. epigraph::
5559
5562
 
5560
- AWS WAF does its best to parse the entire JSON body, but might be forced to stop for reasons such as invalid characters, duplicate keys, truncation, and any content whose root node isn't an object or an array.
5561
-
5562
- AWS WAF parses the JSON in the following examples as two valid key, value pairs:
5563
-
5564
- - Missing comma: ``{"key1":"value1""key2":"value2"}``
5565
- - Missing colon: ``{"key1":"value1","key2""value2"}``
5566
- - Extra colons: ``{"key1"::"value1","key2""value2"}``
5563
+ AWS WAF parsing doesn't fully validate the input JSON string, so parsing can succeed even for invalid JSON. When parsing succeeds, AWS WAF doesn't apply the fallback behavior. For more information, see `JSON body <https://docs.aws.amazon.com/waf/latest/developerguide/waf-rule-statement-fields-list.html#waf-rule-statement-request-component-json-body>`_ in the *AWS WAF Developer Guide* .
5567
5564
 
5568
5565
  :see: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wafv2-rulegroup-jsonbody.html#cfn-wafv2-rulegroup-jsonbody-invalidfallbackbehavior
5569
5566
  '''
@@ -14956,9 +14953,11 @@ class CfnWebACL(
14956
14953
 
14957
14954
  Example JSON: ``"JsonBody": { "MatchPattern": { "All": {} }, "MatchScope": "ALL" }``
14958
14955
 
14956
+ For additional information about this request component option, see `JSON body <https://docs.aws.amazon.com/waf/latest/developerguide/waf-rule-statement-fields-list.html#waf-rule-statement-request-component-json-body>`_ in the *AWS WAF Developer Guide* .
14957
+
14959
14958
  :param match_pattern: The patterns to look for in the JSON body. AWS WAF inspects the results of these pattern matches against the rule inspection criteria.
14960
14959
  :param match_scope: The parts of the JSON to match against using the ``MatchPattern`` . If you specify ``ALL`` , AWS WAF matches against keys and values. ``All`` does not require a match to be found in the keys and a match to be found in the values. It requires a match to be found in the keys or the values or both. To require a match in the keys and in the values, use a logical ``AND`` statement to combine two match rules, one that inspects the keys and another that inspects the values.
14961
- :param invalid_fallback_behavior: What AWS WAF should do if it fails to completely parse the JSON body. The options are the following:. - ``EVALUATE_AS_STRING`` - Inspect the body as plain text. AWS WAF applies the text transformations and inspection criteria that you defined for the JSON inspection to the body text string. - ``MATCH`` - Treat the web request as matching the rule statement. AWS WAF applies the rule action to the request. - ``NO_MATCH`` - Treat the web request as not matching the rule statement. If you don't provide this setting, AWS WAF parses and evaluates the content only up to the first parsing failure that it encounters. AWS WAF does its best to parse the entire JSON body, but might be forced to stop for reasons such as invalid characters, duplicate keys, truncation, and any content whose root node isn't an object or an array. AWS WAF parses the JSON in the following examples as two valid key, value pairs: - Missing comma: ``{"key1":"value1""key2":"value2"}`` - Missing colon: ``{"key1":"value1","key2""value2"}`` - Extra colons: ``{"key1"::"value1","key2""value2"}``
14960
+ :param invalid_fallback_behavior: What AWS WAF should do if it fails to completely parse the JSON body. The options are the following:. - ``EVALUATE_AS_STRING`` - Inspect the body as plain text. AWS WAF applies the text transformations and inspection criteria that you defined for the JSON inspection to the body text string. - ``MATCH`` - Treat the web request as matching the rule statement. AWS WAF applies the rule action to the request. - ``NO_MATCH`` - Treat the web request as not matching the rule statement. If you don't provide this setting, AWS WAF parses and evaluates the content only up to the first parsing failure that it encounters. .. epigraph:: AWS WAF parsing doesn't fully validate the input JSON string, so parsing can succeed even for invalid JSON. When parsing succeeds, AWS WAF doesn't apply the fallback behavior. For more information, see `JSON body <https://docs.aws.amazon.com/waf/latest/developerguide/waf-rule-statement-fields-list.html#waf-rule-statement-request-component-json-body>`_ in the *AWS WAF Developer Guide* .
14962
14961
  :param oversize_handling: What AWS WAF should do if the body is larger than AWS WAF can inspect. AWS WAF does not support inspecting the entire contents of the web request body if the body exceeds the limit for the resource type. When a web request body is larger than the limit, the underlying host service only forwards the contents that are within the limit to AWS WAF for inspection. - For Application Load Balancer and AWS AppSync , the limit is fixed at 8 KB (8,192 bytes). - For CloudFront, API Gateway, Amazon Cognito, App Runner, and Verified Access, the default limit is 16 KB (16,384 bytes), and you can increase the limit for each resource type in the web ACL ``AssociationConfig`` , for additional processing fees. The options for oversize handling are the following: - ``CONTINUE`` - Inspect the available body contents normally, according to the rule inspection criteria. - ``MATCH`` - Treat the web request as matching the rule statement. AWS WAF applies the rule action to the request. - ``NO_MATCH`` - Treat the web request as not matching the rule statement. You can combine the ``MATCH`` or ``NO_MATCH`` settings for oversize handling with your rule and web ACL action settings, so that you block any request whose body is over the limit. Default: ``CONTINUE``
14963
14962
 
14964
14963
  :see: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wafv2-webacl-jsonbody.html
@@ -15036,14 +15035,9 @@ class CfnWebACL(
15036
15035
  - ``NO_MATCH`` - Treat the web request as not matching the rule statement.
15037
15036
 
15038
15037
  If you don't provide this setting, AWS WAF parses and evaluates the content only up to the first parsing failure that it encounters.
15038
+ .. epigraph::
15039
15039
 
15040
- AWS WAF does its best to parse the entire JSON body, but might be forced to stop for reasons such as invalid characters, duplicate keys, truncation, and any content whose root node isn't an object or an array.
15041
-
15042
- AWS WAF parses the JSON in the following examples as two valid key, value pairs:
15043
-
15044
- - Missing comma: ``{"key1":"value1""key2":"value2"}``
15045
- - Missing colon: ``{"key1":"value1","key2""value2"}``
15046
- - Extra colons: ``{"key1"::"value1","key2""value2"}``
15040
+ AWS WAF parsing doesn't fully validate the input JSON string, so parsing can succeed even for invalid JSON. When parsing succeeds, AWS WAF doesn't apply the fallback behavior. For more information, see `JSON body <https://docs.aws.amazon.com/waf/latest/developerguide/waf-rule-statement-fields-list.html#waf-rule-statement-request-component-json-body>`_ in the *AWS WAF Developer Guide* .
15047
15041
 
15048
15042
  :see: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wafv2-webacl-jsonbody.html#cfn-wafv2-webacl-jsonbody-invalidfallbackbehavior
15049
15043
  '''