Files
sdk/docs/IdentityAuthApi.md
zeekayandHanzo Dev b55332704a feat: Hanzo Cloud SDK for Kotlin (generated from OpenAPI v8.0.0)
Coroutine-native client covering the full Hanzo /v1 cloud surface, for JVM and
Android. Generated with openapi-generator kotlin (library=jvm-okhttp4,
useCoroutines=true). Coordinate: ai.hanzo:sdk. Base URL: https://api.hanzo.ai.

Co-authored-by: Hanzo Dev <[email protected]>
2026-07-25 07:10:32 -07:00

8.1 KiB

IdentityAuthApi

All URIs are relative to https://api.hanzo.ai

Method HTTP request Description
kmsAttachUniversalAuth POST /v1/kms/auth/universal-auth/identities/{identityId} Attach Universal Auth to an identity
kmsCreateIdentityToken POST /v1/kms/auth/token-auth/identities/{identityId}/tokens Create an identity token
kmsCreateUniversalAuthClientSecret POST /v1/kms/auth/universal-auth/identities/{identityId}/client-secrets Create a client secret for Universal Auth
kmsGetUniversalAuth GET /v1/kms/auth/universal-auth/identities/{identityId} Get Universal Auth configuration for an identity
kmsUniversalAuthLogin POST /v1/kms/auth/universal-auth/login Login with Universal Auth

kmsAttachUniversalAuth

KmsUniversalAuthConfig kmsAttachUniversalAuth(identityId, kmsAttachUniversalAuthRequest)

Attach Universal Auth to an identity

Example

// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*

val apiInstance = IdentityAuthApi()
val identityId : java.util.UUID = 38400000-8cf0-11bd-b23e-10b96e4ef00d // java.util.UUID | 
val kmsAttachUniversalAuthRequest : KmsAttachUniversalAuthRequest =  // KmsAttachUniversalAuthRequest | 
try {
    val result : KmsUniversalAuthConfig = apiInstance.kmsAttachUniversalAuth(identityId, kmsAttachUniversalAuthRequest)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling IdentityAuthApi#kmsAttachUniversalAuth")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling IdentityAuthApi#kmsAttachUniversalAuth")
    e.printStackTrace()
}

Parameters

| identityId | java.util.UUID| | |

Name Type Description Notes
kmsAttachUniversalAuthRequest KmsAttachUniversalAuthRequest

Return type

KmsUniversalAuthConfig

Authorization

Configure bearerAuth statically:

ApiClient.accessToken = ""

Configure bearerAuth dynamically:

apiInstance.accessTokenProvider = { "" }

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

kmsCreateIdentityToken

KmsTokenResponse kmsCreateIdentityToken(identityId)

Create an identity token

Example

// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*

val apiInstance = IdentityAuthApi()
val identityId : java.util.UUID = 38400000-8cf0-11bd-b23e-10b96e4ef00d // java.util.UUID | 
try {
    val result : KmsTokenResponse = apiInstance.kmsCreateIdentityToken(identityId)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling IdentityAuthApi#kmsCreateIdentityToken")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling IdentityAuthApi#kmsCreateIdentityToken")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
identityId java.util.UUID

Return type

KmsTokenResponse

Authorization

Configure bearerAuth statically:

ApiClient.accessToken = ""

Configure bearerAuth dynamically:

apiInstance.accessTokenProvider = { "" }

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

kmsCreateUniversalAuthClientSecret

KmsCreateClientSecretResponse kmsCreateUniversalAuthClientSecret(identityId, kmsCreateUniversalAuthClientSecretRequest)

Create a client secret for Universal Auth

Example

// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*

val apiInstance = IdentityAuthApi()
val identityId : java.util.UUID = 38400000-8cf0-11bd-b23e-10b96e4ef00d // java.util.UUID | 
val kmsCreateUniversalAuthClientSecretRequest : KmsCreateUniversalAuthClientSecretRequest =  // KmsCreateUniversalAuthClientSecretRequest | 
try {
    val result : KmsCreateClientSecretResponse = apiInstance.kmsCreateUniversalAuthClientSecret(identityId, kmsCreateUniversalAuthClientSecretRequest)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling IdentityAuthApi#kmsCreateUniversalAuthClientSecret")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling IdentityAuthApi#kmsCreateUniversalAuthClientSecret")
    e.printStackTrace()
}

Parameters

| identityId | java.util.UUID| | |

Name Type Description Notes
kmsCreateUniversalAuthClientSecretRequest KmsCreateUniversalAuthClientSecretRequest

Return type

KmsCreateClientSecretResponse

Authorization

Configure bearerAuth statically:

ApiClient.accessToken = ""

Configure bearerAuth dynamically:

apiInstance.accessTokenProvider = { "" }

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

kmsGetUniversalAuth

KmsUniversalAuthConfig kmsGetUniversalAuth(identityId)

Get Universal Auth configuration for an identity

Example

// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*

val apiInstance = IdentityAuthApi()
val identityId : java.util.UUID = 38400000-8cf0-11bd-b23e-10b96e4ef00d // java.util.UUID | 
try {
    val result : KmsUniversalAuthConfig = apiInstance.kmsGetUniversalAuth(identityId)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling IdentityAuthApi#kmsGetUniversalAuth")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling IdentityAuthApi#kmsGetUniversalAuth")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
identityId java.util.UUID

Return type

KmsUniversalAuthConfig

Authorization

Configure bearerAuth statically:

ApiClient.accessToken = ""

Configure bearerAuth dynamically:

apiInstance.accessTokenProvider = { "" }

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

kmsUniversalAuthLogin

KmsTokenResponse kmsUniversalAuthLogin(kmsUniversalAuthLoginRequest)

Login with Universal Auth

Exchange clientId and clientSecret for an access token.

Example

// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*

val apiInstance = IdentityAuthApi()
val kmsUniversalAuthLoginRequest : KmsUniversalAuthLoginRequest =  // KmsUniversalAuthLoginRequest | 
try {
    val result : KmsTokenResponse = apiInstance.kmsUniversalAuthLogin(kmsUniversalAuthLoginRequest)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling IdentityAuthApi#kmsUniversalAuthLogin")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling IdentityAuthApi#kmsUniversalAuthLogin")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
kmsUniversalAuthLoginRequest KmsUniversalAuthLoginRequest

Return type

KmsTokenResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json