
commonMain.aws.sdk.kotlin.services.sso.model.GetRoleCredentialsRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.sso.model
import aws.smithy.kotlin.runtime.SdkDsl
public class GetRoleCredentialsRequest private constructor(builder: Builder) {
/**
* The token issued by the `CreateToken` API call. For more information, see [CreateToken](https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html) in the *IAM Identity Center OIDC API Reference Guide*.
*/
public val accessToken: kotlin.String? = builder.accessToken
/**
* The identifier for the AWS account that is assigned to the user.
*/
public val accountId: kotlin.String? = builder.accountId
/**
* The friendly name of the role that is assigned to the user.
*/
public val roleName: kotlin.String? = builder.roleName
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.sso.model.GetRoleCredentialsRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetRoleCredentialsRequest(")
append("accessToken=*** Sensitive Data Redacted ***,")
append("accountId=$accountId,")
append("roleName=$roleName")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = accessToken?.hashCode() ?: 0
result = 31 * result + (accountId?.hashCode() ?: 0)
result = 31 * result + (roleName?.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 GetRoleCredentialsRequest
if (accessToken != other.accessToken) return false
if (accountId != other.accountId) return false
if (roleName != other.roleName) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.sso.model.GetRoleCredentialsRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The token issued by the `CreateToken` API call. For more information, see [CreateToken](https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html) in the *IAM Identity Center OIDC API Reference Guide*.
*/
public var accessToken: kotlin.String? = null
/**
* The identifier for the AWS account that is assigned to the user.
*/
public var accountId: kotlin.String? = null
/**
* The friendly name of the role that is assigned to the user.
*/
public var roleName: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.sso.model.GetRoleCredentialsRequest) : this() {
this.accessToken = x.accessToken
this.accountId = x.accountId
this.roleName = x.roleName
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.sso.model.GetRoleCredentialsRequest = GetRoleCredentialsRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy