commonMain.aws.sdk.kotlin.services.bedrockagent.model.CreateAgentAliasRequest.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of bedrockagent-jvm Show documentation
Show all versions of bedrockagent-jvm Show documentation
The AWS SDK for Kotlin client for Bedrock Agent
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.bedrockagent.model
import aws.smithy.kotlin.runtime.SdkDsl
public class CreateAgentAliasRequest private constructor(builder: Builder) {
/**
* The name of the alias.
*/
public val agentAliasName: kotlin.String? = builder.agentAliasName
/**
* The unique identifier of the agent.
*/
public val agentId: kotlin.String? = builder.agentId
/**
* A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see [Ensuring idempotency](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
*/
public val clientToken: kotlin.String? = builder.clientToken
/**
* A description of the alias of the agent.
*/
public val description: kotlin.String? = builder.description
/**
* Contains details about the routing configuration of the alias.
*/
public val routingConfiguration: List? = builder.routingConfiguration
/**
* Any tags that you want to attach to the alias of the agent.
*/
public val tags: Map? = builder.tags
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.bedrockagent.model.CreateAgentAliasRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CreateAgentAliasRequest(")
append("agentAliasName=$agentAliasName,")
append("agentId=$agentId,")
append("clientToken=$clientToken,")
append("description=$description,")
append("routingConfiguration=$routingConfiguration,")
append("tags=$tags")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = agentAliasName?.hashCode() ?: 0
result = 31 * result + (agentId?.hashCode() ?: 0)
result = 31 * result + (clientToken?.hashCode() ?: 0)
result = 31 * result + (description?.hashCode() ?: 0)
result = 31 * result + (routingConfiguration?.hashCode() ?: 0)
result = 31 * result + (tags?.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 CreateAgentAliasRequest
if (agentAliasName != other.agentAliasName) return false
if (agentId != other.agentId) return false
if (clientToken != other.clientToken) return false
if (description != other.description) return false
if (routingConfiguration != other.routingConfiguration) return false
if (tags != other.tags) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.bedrockagent.model.CreateAgentAliasRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The name of the alias.
*/
public var agentAliasName: kotlin.String? = null
/**
* The unique identifier of the agent.
*/
public var agentId: kotlin.String? = null
/**
* A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see [Ensuring idempotency](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
*/
public var clientToken: kotlin.String? = null
/**
* A description of the alias of the agent.
*/
public var description: kotlin.String? = null
/**
* Contains details about the routing configuration of the alias.
*/
public var routingConfiguration: List? = null
/**
* Any tags that you want to attach to the alias of the agent.
*/
public var tags: Map? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.bedrockagent.model.CreateAgentAliasRequest) : this() {
this.agentAliasName = x.agentAliasName
this.agentId = x.agentId
this.clientToken = x.clientToken
this.description = x.description
this.routingConfiguration = x.routingConfiguration
this.tags = x.tags
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.bedrockagent.model.CreateAgentAliasRequest = CreateAgentAliasRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}