![JAR search and dependency download from the Maven repository](/logo.png)
com.pulumi.awsnative.wafv2.kotlin.inputs.WebAclCustomResponseArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.wafv2.kotlin.inputs
import com.pulumi.awsnative.wafv2.inputs.WebAclCustomResponseArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
* Custom response.
* @property customResponseBodyKey Custom response body key.
* @property responseCode The HTTP status code to return to the client.
* For a list of status codes that you can use in your custom responses, see [Supported status codes for custom response](https://docs.aws.amazon.com/waf/latest/developerguide/customizing-the-response-status-codes.html) in the *AWS WAF Developer Guide* .
* @property responseHeaders Collection of HTTP headers.
*/
public data class WebAclCustomResponseArgs(
public val customResponseBodyKey: Output? = null,
public val responseCode: Output,
public val responseHeaders: Output>? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.wafv2.inputs.WebAclCustomResponseArgs =
com.pulumi.awsnative.wafv2.inputs.WebAclCustomResponseArgs.builder()
.customResponseBodyKey(customResponseBodyKey?.applyValue({ args0 -> args0 }))
.responseCode(responseCode.applyValue({ args0 -> args0 }))
.responseHeaders(
responseHeaders?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
})
}),
).build()
}
/**
* Builder for [WebAclCustomResponseArgs].
*/
@PulumiTagMarker
public class WebAclCustomResponseArgsBuilder internal constructor() {
private var customResponseBodyKey: Output? = null
private var responseCode: Output? = null
private var responseHeaders: Output>? = null
/**
* @param value Custom response body key.
*/
@JvmName("rslslyxpffpdbqlu")
public suspend fun customResponseBodyKey(`value`: Output) {
this.customResponseBodyKey = value
}
/**
* @param value The HTTP status code to return to the client.
* For a list of status codes that you can use in your custom responses, see [Supported status codes for custom response](https://docs.aws.amazon.com/waf/latest/developerguide/customizing-the-response-status-codes.html) in the *AWS WAF Developer Guide* .
*/
@JvmName("xntvqtuyccqymuqh")
public suspend fun responseCode(`value`: Output) {
this.responseCode = value
}
/**
* @param value Collection of HTTP headers.
*/
@JvmName("xuohxcsmusjyfscb")
public suspend fun responseHeaders(`value`: Output>) {
this.responseHeaders = value
}
@JvmName("ylvdogbuqrnahwqu")
public suspend fun responseHeaders(vararg values: Output) {
this.responseHeaders = Output.all(values.asList())
}
/**
* @param values Collection of HTTP headers.
*/
@JvmName("sojxlnbyxdyeisbp")
public suspend fun responseHeaders(values: List
© 2015 - 2025 Weber Informatics LLC | Privacy Policy