All URIs are relative to http://localhost
Method | HTTP request | Description |
---|---|---|
createApiKey | POST /v2/api-key | Create Api Key |
deleteApiKey | DELETE /v2/api-key/{api_key_id} | Delete Api Key |
getApiKey | GET /v2/api-key/{api_key_id} | Get Api Key |
getApiKeyScope | GET /v2/api-key/scope | Get Api Key Scope |
getEnvironmentApiKey | GET /v2/api-key/{proj_id}/{env_id} | Get Environment Api Key |
listApiKeys | GET /v2/api-key | List Api Keys |
APIKeyRead createApiKey(apIKeyCreate)
Create Api Key
Creates a new api_key under the active organization.
// Import classes:
//import org.openapitools.client.infrastructure.*
//import org.openapitools.client.models.*
val apiInstance = APIKeysApi()
val apIKeyCreate : APIKeyCreate = // APIKeyCreate |
try {
val result : APIKeyRead = apiInstance.createApiKey(apIKeyCreate)
println(result)
} catch (e: ClientException) {
println("4xx response calling APIKeysApi#createApiKey")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling APIKeysApi#createApiKey")
e.printStackTrace()
}
Name | Type | Description | Notes |
---|---|---|---|
apIKeyCreate | APIKeyCreate |
Configure HTTPBearer: ApiClient.accessToken = ""
- Content-Type: application/json
- Accept: application/json
deleteApiKey(apiKeyId)
Delete Api Key
Deletes the api_key and all its related data.
// Import classes:
//import org.openapitools.client.infrastructure.*
//import org.openapitools.client.models.*
val apiInstance = APIKeysApi()
val apiKeyId : kotlin.String = apiKeyId_example // kotlin.String | The unique id of the API key
try {
apiInstance.deleteApiKey(apiKeyId)
} catch (e: ClientException) {
println("4xx response calling APIKeysApi#deleteApiKey")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling APIKeysApi#deleteApiKey")
e.printStackTrace()
}
Name | Type | Description | Notes |
---|---|---|---|
apiKeyId | kotlin.String | The unique id of the API key |
null (empty response body)
Configure HTTPBearer: ApiClient.accessToken = ""
- Content-Type: Not defined
- Accept: application/json
APIKeyRead getApiKey(apiKeyId)
Get Api Key
Gets a single api_key matching the given api_key_id, if such api_key exists.
// Import classes:
//import org.openapitools.client.infrastructure.*
//import org.openapitools.client.models.*
val apiInstance = APIKeysApi()
val apiKeyId : kotlin.String = apiKeyId_example // kotlin.String | The unique id of the API key
try {
val result : APIKeyRead = apiInstance.getApiKey(apiKeyId)
println(result)
} catch (e: ClientException) {
println("4xx response calling APIKeysApi#getApiKey")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling APIKeysApi#getApiKey")
e.printStackTrace()
}
Name | Type | Description | Notes |
---|---|---|---|
apiKeyId | kotlin.String | The unique id of the API key |
Configure HTTPBearer: ApiClient.accessToken = ""
- Content-Type: Not defined
- Accept: application/json
APIKeyScopeRead getApiKeyScope()
Get Api Key Scope
// Import classes:
//import org.openapitools.client.infrastructure.*
//import org.openapitools.client.models.*
val apiInstance = APIKeysApi()
try {
val result : APIKeyScopeRead = apiInstance.getApiKeyScope()
println(result)
} catch (e: ClientException) {
println("4xx response calling APIKeysApi#getApiKeyScope")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling APIKeysApi#getApiKeyScope")
e.printStackTrace()
}
This endpoint does not need any parameter.
Configure HTTPBearer: ApiClient.accessToken = ""
- Content-Type: Not defined
- Accept: application/json
APIKeyRead getEnvironmentApiKey(projId, envId)
Get Environment Api Key
// Import classes:
//import org.openapitools.client.infrastructure.*
//import org.openapitools.client.models.*
val apiInstance = APIKeysApi()
val projId : kotlin.String = projId_example // kotlin.String | Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\").
val envId : kotlin.String = envId_example // kotlin.String | Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\").
try {
val result : APIKeyRead = apiInstance.getEnvironmentApiKey(projId, envId)
println(result)
} catch (e: ClientException) {
println("4xx response calling APIKeysApi#getEnvironmentApiKey")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling APIKeysApi#getEnvironmentApiKey")
e.printStackTrace()
}
Name | Type | Description | Notes |
---|---|---|---|
projId | kotlin.String | Either the unique id of the project, or the URL-friendly key of the project (i.e: the "slug"). | |
envId | kotlin.String | Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the "slug"). |
Configure HTTPBearer: ApiClient.accessToken = ""
- Content-Type: Not defined
- Accept: application/json
PaginatedResultAPIKeyRead listApiKeys(page, perPage)
List Api Keys
Lists all the api_keys under the active organization.
// Import classes:
//import org.openapitools.client.infrastructure.*
//import org.openapitools.client.models.*
val apiInstance = APIKeysApi()
val page : kotlin.Int = 56 // kotlin.Int | Page number of the results to fetch, starting at 1.
val perPage : kotlin.Int = 56 // kotlin.Int | The number of results per page (max 100).
try {
val result : PaginatedResultAPIKeyRead = apiInstance.listApiKeys(page, perPage)
println(result)
} catch (e: ClientException) {
println("4xx response calling APIKeysApi#listApiKeys")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling APIKeysApi#listApiKeys")
e.printStackTrace()
}
Name | Type | Description | Notes |
---|---|---|---|
page | kotlin.Int | Page number of the results to fetch, starting at 1. | [optional] [default to 1] |
perPage | kotlin.Int | The number of results per page (max 100). | [optional] [default to 30] |
Configure HTTPBearer: ApiClient.accessToken = ""
- Content-Type: Not defined
- Accept: application/json