commonMain.aws.sdk.kotlin.services.pinpointsmsvoicev2.model.DisassociateOriginationIdentityRequest.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pinpointsmsvoicev2-jvm Show documentation
Show all versions of pinpointsmsvoicev2-jvm Show documentation
The AWS SDK for Kotlin client for Pinpoint SMS Voice V2
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.pinpointsmsvoicev2.model
import aws.smithy.kotlin.runtime.SdkDsl
public class DisassociateOriginationIdentityRequest private constructor(builder: Builder) {
/**
* Unique, case-sensitive identifier you provide to ensure the idempotency of the request. If you don't specify a client token, a randomly generated token is used for the request to ensure idempotency.
*/
public val clientToken: kotlin.String? = builder.clientToken
/**
* The two-character code, in ISO 3166-1 alpha-2 format, for the country or region.
*/
public val isoCountryCode: kotlin.String? = builder.isoCountryCode
/**
* The origination identity to use such as a PhoneNumberId, PhoneNumberArn, SenderId or SenderIdArn. You can use DescribePhoneNumbers find the values for PhoneNumberId and PhoneNumberArn, or use DescribeSenderIds to get the values for SenderId and SenderIdArn.
*
* If you are using a shared AWS End User Messaging SMS and Voice resource then you must use the full Amazon Resource Name(ARN).
*/
public val originationIdentity: kotlin.String? = builder.originationIdentity
/**
* The unique identifier for the pool to disassociate with the origination identity. This value can be either the PoolId or PoolArn.
*
* If you are using a shared AWS End User Messaging SMS and Voice resource then you must use the full Amazon Resource Name(ARN).
*/
public val poolId: kotlin.String? = builder.poolId
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.pinpointsmsvoicev2.model.DisassociateOriginationIdentityRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("DisassociateOriginationIdentityRequest(")
append("clientToken=$clientToken,")
append("isoCountryCode=$isoCountryCode,")
append("originationIdentity=$originationIdentity,")
append("poolId=$poolId")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = clientToken?.hashCode() ?: 0
result = 31 * result + (isoCountryCode?.hashCode() ?: 0)
result = 31 * result + (originationIdentity?.hashCode() ?: 0)
result = 31 * result + (poolId?.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 DisassociateOriginationIdentityRequest
if (clientToken != other.clientToken) return false
if (isoCountryCode != other.isoCountryCode) return false
if (originationIdentity != other.originationIdentity) return false
if (poolId != other.poolId) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.pinpointsmsvoicev2.model.DisassociateOriginationIdentityRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Unique, case-sensitive identifier you provide to ensure the idempotency of the request. If you don't specify a client token, a randomly generated token is used for the request to ensure idempotency.
*/
public var clientToken: kotlin.String? = null
/**
* The two-character code, in ISO 3166-1 alpha-2 format, for the country or region.
*/
public var isoCountryCode: kotlin.String? = null
/**
* The origination identity to use such as a PhoneNumberId, PhoneNumberArn, SenderId or SenderIdArn. You can use DescribePhoneNumbers find the values for PhoneNumberId and PhoneNumberArn, or use DescribeSenderIds to get the values for SenderId and SenderIdArn.
*
* If you are using a shared AWS End User Messaging SMS and Voice resource then you must use the full Amazon Resource Name(ARN).
*/
public var originationIdentity: kotlin.String? = null
/**
* The unique identifier for the pool to disassociate with the origination identity. This value can be either the PoolId or PoolArn.
*
* If you are using a shared AWS End User Messaging SMS and Voice resource then you must use the full Amazon Resource Name(ARN).
*/
public var poolId: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.pinpointsmsvoicev2.model.DisassociateOriginationIdentityRequest) : this() {
this.clientToken = x.clientToken
this.isoCountryCode = x.isoCountryCode
this.originationIdentity = x.originationIdentity
this.poolId = x.poolId
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.pinpointsmsvoicev2.model.DisassociateOriginationIdentityRequest = DisassociateOriginationIdentityRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}