All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.aws.sdk.kotlin.services.finspacedata.model.CreateUserRequest.kt Maven / Gradle / Ivy

There is a newer version: 1.3.99
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.finspacedata.model

import aws.smithy.kotlin.runtime.SdkDsl

public class CreateUserRequest private constructor(builder: Builder) {
    /**
     * The option to indicate whether the user can use the `GetProgrammaticAccessCredentials` API to obtain credentials that can then be used to access other FinSpace Data API operations.
     * + `ENABLED` – The user has permissions to use the APIs.
     * + `DISABLED` – The user does not have permissions to use any APIs.
     */
    public val apiAccess: aws.sdk.kotlin.services.finspacedata.model.ApiAccess? = builder.apiAccess
    /**
     * The ARN identifier of an AWS user or role that is allowed to call the `GetProgrammaticAccessCredentials` API to obtain a credentials token for a specific FinSpace user. This must be an IAM role within your FinSpace account.
     */
    public val apiAccessPrincipalArn: kotlin.String? = builder.apiAccessPrincipalArn
    /**
     * A token that ensures idempotency. This token expires in 10 minutes.
     */
    public val clientToken: kotlin.String? = builder.clientToken
    /**
     * The email address of the user that you want to register. The email address serves as a uniquer identifier for each user and cannot be changed after it's created.
     */
    public val emailAddress: kotlin.String? = builder.emailAddress
    /**
     * The first name of the user that you want to register.
     */
    public val firstName: kotlin.String? = builder.firstName
    /**
     * The last name of the user that you want to register.
     */
    public val lastName: kotlin.String? = builder.lastName
    /**
     * The option to indicate the type of user. Use one of the following options to specify this parameter:
     * + `SUPER_USER` – A user with permission to all the functionality and data in FinSpace.
     * + `APP_USER` – A user with specific permissions in FinSpace. The users are assigned permissions by adding them to a permission group.
     */
    public val type: aws.sdk.kotlin.services.finspacedata.model.UserType? = builder.type

    public companion object {
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.finspacedata.model.CreateUserRequest = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("CreateUserRequest(")
        append("apiAccess=$apiAccess,")
        append("apiAccessPrincipalArn=$apiAccessPrincipalArn,")
        append("clientToken=$clientToken,")
        append("emailAddress=*** Sensitive Data Redacted ***,")
        append("firstName=*** Sensitive Data Redacted ***,")
        append("lastName=*** Sensitive Data Redacted ***,")
        append("type=$type")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = apiAccess?.hashCode() ?: 0
        result = 31 * result + (apiAccessPrincipalArn?.hashCode() ?: 0)
        result = 31 * result + (clientToken?.hashCode() ?: 0)
        result = 31 * result + (emailAddress?.hashCode() ?: 0)
        result = 31 * result + (firstName?.hashCode() ?: 0)
        result = 31 * result + (lastName?.hashCode() ?: 0)
        result = 31 * result + (type?.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 CreateUserRequest

        if (apiAccess != other.apiAccess) return false
        if (apiAccessPrincipalArn != other.apiAccessPrincipalArn) return false
        if (clientToken != other.clientToken) return false
        if (emailAddress != other.emailAddress) return false
        if (firstName != other.firstName) return false
        if (lastName != other.lastName) return false
        if (type != other.type) return false

        return true
    }

    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.finspacedata.model.CreateUserRequest = Builder(this).apply(block).build()

    @SdkDsl
    public class Builder {
        /**
         * The option to indicate whether the user can use the `GetProgrammaticAccessCredentials` API to obtain credentials that can then be used to access other FinSpace Data API operations.
         * + `ENABLED` – The user has permissions to use the APIs.
         * + `DISABLED` – The user does not have permissions to use any APIs.
         */
        public var apiAccess: aws.sdk.kotlin.services.finspacedata.model.ApiAccess? = null
        /**
         * The ARN identifier of an AWS user or role that is allowed to call the `GetProgrammaticAccessCredentials` API to obtain a credentials token for a specific FinSpace user. This must be an IAM role within your FinSpace account.
         */
        public var apiAccessPrincipalArn: kotlin.String? = null
        /**
         * A token that ensures idempotency. This token expires in 10 minutes.
         */
        public var clientToken: kotlin.String? = null
        /**
         * The email address of the user that you want to register. The email address serves as a uniquer identifier for each user and cannot be changed after it's created.
         */
        public var emailAddress: kotlin.String? = null
        /**
         * The first name of the user that you want to register.
         */
        public var firstName: kotlin.String? = null
        /**
         * The last name of the user that you want to register.
         */
        public var lastName: kotlin.String? = null
        /**
         * The option to indicate the type of user. Use one of the following options to specify this parameter:
         * + `SUPER_USER` – A user with permission to all the functionality and data in FinSpace.
         * + `APP_USER` – A user with specific permissions in FinSpace. The users are assigned permissions by adding them to a permission group.
         */
        public var type: aws.sdk.kotlin.services.finspacedata.model.UserType? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.finspacedata.model.CreateUserRequest) : this() {
            this.apiAccess = x.apiAccess
            this.apiAccessPrincipalArn = x.apiAccessPrincipalArn
            this.clientToken = x.clientToken
            this.emailAddress = x.emailAddress
            this.firstName = x.firstName
            this.lastName = x.lastName
            this.type = x.type
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.finspacedata.model.CreateUserRequest = CreateUserRequest(this)

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy