commonMain.aws.sdk.kotlin.services.codepipeline.model.WebhookAuthConfiguration.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of codepipeline-jvm Show documentation
Show all versions of codepipeline-jvm Show documentation
The AWS SDK for Kotlin client for CodePipeline
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.codepipeline.model
/**
* The authentication applied to incoming webhook trigger requests.
*/
public class WebhookAuthConfiguration private constructor(builder: Builder) {
/**
* The property used to configure acceptance of webhooks in an IP address range. For IP, only the `AllowedIPRange` property must be set. This property must be set to a valid CIDR range.
*/
public val allowedIpRange: kotlin.String? = builder.allowedIpRange
/**
* The property used to configure GitHub authentication. For GITHUB_HMAC, only the `SecretToken` property must be set.
*/
public val secretToken: kotlin.String? = builder.secretToken
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.codepipeline.model.WebhookAuthConfiguration = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("WebhookAuthConfiguration(")
append("allowedIpRange=$allowedIpRange,")
append("secretToken=$secretToken")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = allowedIpRange?.hashCode() ?: 0
result = 31 * result + (secretToken?.hashCode() ?: 0)
return result
}
override fun equals(other: kotlin.Any?): kotlin.Boolean {
if (this === other) return true
if (other == null || this::class != other::class) return false
other as WebhookAuthConfiguration
if (allowedIpRange != other.allowedIpRange) return false
if (secretToken != other.secretToken) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.codepipeline.model.WebhookAuthConfiguration = Builder(this).apply(block).build()
public class Builder {
/**
* The property used to configure acceptance of webhooks in an IP address range. For IP, only the `AllowedIPRange` property must be set. This property must be set to a valid CIDR range.
*/
public var allowedIpRange: kotlin.String? = null
/**
* The property used to configure GitHub authentication. For GITHUB_HMAC, only the `SecretToken` property must be set.
*/
public var secretToken: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.codepipeline.model.WebhookAuthConfiguration) : this() {
this.allowedIpRange = x.allowedIpRange
this.secretToken = x.secretToken
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.codepipeline.model.WebhookAuthConfiguration = WebhookAuthConfiguration(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy