Class: Aws::WAFV2::Types::CustomResponseBody
- Inherits:
-
Struct
- Object
- Struct
- Aws::WAFV2::Types::CustomResponseBody
- Includes:
- Structure
- Defined in:
- lib/aws-sdk-wafv2/types.rb
Overview
When making an API call, you may pass CustomResponseBody data as a hash:
{
content_type: "TEXT_PLAIN", # required, accepts TEXT_PLAIN, TEXT_HTML, APPLICATION_JSON
content: "ResponseContent", # required
}
The response body to use in a custom response to a web request. This is referenced by key from CustomResponse `CustomResponseBodyKey`.
Constant Summary collapse
- SENSITIVE =
[]
Instance Attribute Summary collapse
-
#content ⇒ String
The payload of the custom response.
-
#content_type ⇒ String
The type of content in the payload that you are defining in the `Content` string.
Instance Attribute Details
#content ⇒ String
The payload of the custom response.
You can use JSON escape strings in JSON content. To do this, you must specify JSON content in the `ContentType` setting.
For information about the limits on count and size for custom request and response settings, see [WAF quotas] in the [WAF Developer Guide].
[1]: docs.aws.amazon.com/waf/latest/developerguide/limits.html [2]: docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html
3438 3439 3440 3441 3442 3443 |
# File 'lib/aws-sdk-wafv2/types.rb', line 3438 class CustomResponseBody < Struct.new( :content_type, :content) SENSITIVE = [] include Aws::Structure end |
#content_type ⇒ String
The type of content in the payload that you are defining in the `Content` string.
3438 3439 3440 3441 3442 3443 |
# File 'lib/aws-sdk-wafv2/types.rb', line 3438 class CustomResponseBody < Struct.new( :content_type, :content) SENSITIVE = [] include Aws::Structure end |