KoryAuth

sealed interface KoryAuth

Authentication strategies for KoryHttpClient.

  • None — No authentication.

  • Bearer — Bearer token in the Authorization header.

  • ApiKeyHeader — Custom header with an API key.

  • Custom — Arbitrary headers.

Inheritors

Types

Link copied to clipboard
data class ApiKeyHeader(val headerName: String, val key: String) : KoryAuth

API key in a custom header.

Link copied to clipboard
data class Bearer(val token: String) : KoryAuth

Bearer token authentication.

Link copied to clipboard
data class Custom(val headers: Map<String, String>, val value: String) : KoryAuth

Custom headers for authentication.

Link copied to clipboard
data object None : KoryAuth

No authentication.