Skip to content
This repository has been archived by the owner on Apr 17, 2024. It is now read-only.

Commit

Permalink
Update API Client
Browse files Browse the repository at this point in the history
#### What's New
---

##### `GET` /events/events/volume/
  • Loading branch information
authentik-automation[bot] committed Dec 6, 2023
1 parent 768b627 commit 1e4dd1d
Show file tree
Hide file tree
Showing 4 changed files with 280 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ Class | Method | HTTP request | Description
*EventsApi* | [**eventsEventsRetrieve**](docs/EventsApi.md#eventseventsretrieve) | **GET** /events/events/{event_uuid}/ |
*EventsApi* | [**eventsEventsTopPerUserList**](docs/EventsApi.md#eventseventstopperuserlist) | **GET** /events/events/top_per_user/ |
*EventsApi* | [**eventsEventsUpdate**](docs/EventsApi.md#eventseventsupdate) | **PUT** /events/events/{event_uuid}/ |
*EventsApi* | [**eventsEventsVolumeList**](docs/EventsApi.md#eventseventsvolumelist) | **GET** /events/events/volume/ |
*EventsApi* | [**eventsNotificationsDestroy**](docs/EventsApi.md#eventsnotificationsdestroy) | **DELETE** /events/notifications/{uuid}/ |
*EventsApi* | [**eventsNotificationsList**](docs/EventsApi.md#eventsnotificationslist) | **GET** /events/notifications/ |
*EventsApi* | [**eventsNotificationsMarkAllSeenCreate**](docs/EventsApi.md#eventsnotificationsmarkallseencreate) | **POST** /events/notifications/mark_all_seen/ |
Expand Down
69 changes: 69 additions & 0 deletions docs/EventsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Method | HTTP request | Description
[**eventsEventsRetrieve**](EventsApi.md#eventsEventsRetrieve) | **GET** /events/events/{event_uuid}/ |
[**eventsEventsTopPerUserList**](EventsApi.md#eventsEventsTopPerUserList) | **GET** /events/events/top_per_user/ |
[**eventsEventsUpdate**](EventsApi.md#eventsEventsUpdate) | **PUT** /events/events/{event_uuid}/ |
[**eventsEventsVolumeList**](EventsApi.md#eventsEventsVolumeList) | **GET** /events/events/volume/ |
[**eventsNotificationsDestroy**](EventsApi.md#eventsNotificationsDestroy) | **DELETE** /events/notifications/{uuid}/ |
[**eventsNotificationsList**](EventsApi.md#eventsNotificationsList) | **GET** /events/notifications/ |
[**eventsNotificationsMarkAllSeenCreate**](EventsApi.md#eventsNotificationsMarkAllSeenCreate) | **POST** /events/notifications/mark_all_seen/ |
Expand Down Expand Up @@ -512,6 +513,74 @@ Configure authentik:
- **Content-Type**: application/json
- **Accept**: application/json

<a id="eventsEventsVolumeList"></a>
# **eventsEventsVolumeList**
> kotlin.collections.List&lt;Coordinate&gt; eventsEventsVolumeList(action, clientIp, contextAuthorizedApp, contextModelApp, contextModelName, contextModelPk, ordering, search, tenantName, username)


Get event volume for specified filters and timeframe

### Example
```kotlin
// Import classes:
//import io.goauthentik.api.infrastructure.*
//import io.goauthentik.api.models.*

val apiInstance = EventsApi()
val action : kotlin.String = action_example // kotlin.String |
val clientIp : kotlin.String = clientIp_example // kotlin.String |
val contextAuthorizedApp : kotlin.String = contextAuthorizedApp_example // kotlin.String | Context Authorized application
val contextModelApp : kotlin.String = contextModelApp_example // kotlin.String | Context Model App
val contextModelName : kotlin.String = contextModelName_example // kotlin.String | Context Model Name
val contextModelPk : kotlin.String = contextModelPk_example // kotlin.String | Context Model Primary Key
val ordering : kotlin.String = ordering_example // kotlin.String | Which field to use when ordering the results.
val search : kotlin.String = search_example // kotlin.String | A search term.
val tenantName : kotlin.String = tenantName_example // kotlin.String | Tenant name
val username : kotlin.String = username_example // kotlin.String | Username
try {
val result : kotlin.collections.List<Coordinate> = apiInstance.eventsEventsVolumeList(action, clientIp, contextAuthorizedApp, contextModelApp, contextModelName, contextModelPk, ordering, search, tenantName, username)
println(result)
} catch (e: ClientException) {
println("4xx response calling EventsApi#eventsEventsVolumeList")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling EventsApi#eventsEventsVolumeList")
e.printStackTrace()
}
```

### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**action** | **kotlin.String**| | [optional]
**clientIp** | **kotlin.String**| | [optional]
**contextAuthorizedApp** | **kotlin.String**| Context Authorized application | [optional]
**contextModelApp** | **kotlin.String**| Context Model App | [optional]
**contextModelName** | **kotlin.String**| Context Model Name | [optional]
**contextModelPk** | **kotlin.String**| Context Model Primary Key | [optional]
**ordering** | **kotlin.String**| Which field to use when ordering the results. | [optional]
**search** | **kotlin.String**| A search term. | [optional]
**tenantName** | **kotlin.String**| Tenant name | [optional]
**username** | **kotlin.String**| Username | [optional]

### Return type

[**kotlin.collections.List&lt;Coordinate&gt;**](Coordinate.md)

### Authorization


Configure authentik:
ApiClient.apiKey["Authorization"] = ""
ApiClient.apiKeyPrefix["Authorization"] = ""

### HTTP request headers

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

<a id="eventsNotificationsDestroy"></a>
# **eventsNotificationsDestroy**
> eventsNotificationsDestroy(uuid)
Expand Down
80 changes: 80 additions & 0 deletions schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6276,6 +6276,86 @@ paths:
schema:
$ref: '#/components/schemas/GenericError'
description: ''
/events/events/volume/:
get:
operationId: events_events_volume_list
description: Get event volume for specified filters and timeframe
parameters:
- in: query
name: action
schema:
type: string
- in: query
name: client_ip
schema:
type: string
- in: query
name: context_authorized_app
schema:
type: string
description: Context Authorized application
- in: query
name: context_model_app
schema:
type: string
description: Context Model App
- in: query
name: context_model_name
schema:
type: string
description: Context Model Name
- in: query
name: context_model_pk
schema:
type: string
description: Context Model Primary Key
- name: ordering
required: false
in: query
description: Which field to use when ordering the results.
schema:
type: string
- name: search
required: false
in: query
description: A search term.
schema:
type: string
- in: query
name: tenant_name
schema:
type: string
description: Tenant name
- in: query
name: username
schema:
type: string
description: Username
tags:
- events
security:
- authentik: []
responses:
'200':
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Coordinate'
description: ''
'400':
content:
application/json:
schema:
$ref: '#/components/schemas/ValidationError'
description: ''
'403':
content:
application/json:
schema:
$ref: '#/components/schemas/GenericError'
description: ''
/events/notifications/:
get:
operationId: events_notifications_list
Expand Down
130 changes: 130 additions & 0 deletions src/main/kotlin/io/goauthentik/api/apis/EventsApi.kt
Original file line number Diff line number Diff line change
Expand Up @@ -803,6 +803,136 @@ class EventsApi(basePath: kotlin.String = defaultBasePath, client: OkHttpClient
)
}

/**
*
* Get event volume for specified filters and timeframe
* @param action (optional)
* @param clientIp (optional)
* @param contextAuthorizedApp Context Authorized application (optional)
* @param contextModelApp Context Model App (optional)
* @param contextModelName Context Model Name (optional)
* @param contextModelPk Context Model Primary Key (optional)
* @param ordering Which field to use when ordering the results. (optional)
* @param search A search term. (optional)
* @param tenantName Tenant name (optional)
* @param username Username (optional)
* @return kotlin.collections.List<Coordinate>
* @throws IllegalStateException If the request is not correctly configured
* @throws IOException Rethrows the OkHttp execute method exception
* @throws UnsupportedOperationException If the API returns an informational or redirection response
* @throws ClientException If the API returns a client error response
* @throws ServerException If the API returns a server error response
*/
@Suppress("UNCHECKED_CAST")
@Throws(IllegalStateException::class, IOException::class, UnsupportedOperationException::class, ClientException::class, ServerException::class)
fun eventsEventsVolumeList(action: kotlin.String? = null, clientIp: kotlin.String? = null, contextAuthorizedApp: kotlin.String? = null, contextModelApp: kotlin.String? = null, contextModelName: kotlin.String? = null, contextModelPk: kotlin.String? = null, ordering: kotlin.String? = null, search: kotlin.String? = null, tenantName: kotlin.String? = null, username: kotlin.String? = null) : kotlin.collections.List<Coordinate> {
val localVarResponse = eventsEventsVolumeListWithHttpInfo(action = action, clientIp = clientIp, contextAuthorizedApp = contextAuthorizedApp, contextModelApp = contextModelApp, contextModelName = contextModelName, contextModelPk = contextModelPk, ordering = ordering, search = search, tenantName = tenantName, username = username)

return when (localVarResponse.responseType) {
ResponseType.Success -> (localVarResponse as Success<*>).data as kotlin.collections.List<Coordinate>
ResponseType.Informational -> throw UnsupportedOperationException("Client does not support Informational responses.")
ResponseType.Redirection -> throw UnsupportedOperationException("Client does not support Redirection responses.")
ResponseType.ClientError -> {
val localVarError = localVarResponse as ClientError<*>
throw ClientException("Client error : ${localVarError.statusCode} ${localVarError.message.orEmpty()}", localVarError.statusCode, localVarResponse)
}
ResponseType.ServerError -> {
val localVarError = localVarResponse as ServerError<*>
throw ServerException("Server error : ${localVarError.statusCode} ${localVarError.message.orEmpty()} ${localVarError.body}", localVarError.statusCode, localVarResponse)
}
}
}

/**
*
* Get event volume for specified filters and timeframe
* @param action (optional)
* @param clientIp (optional)
* @param contextAuthorizedApp Context Authorized application (optional)
* @param contextModelApp Context Model App (optional)
* @param contextModelName Context Model Name (optional)
* @param contextModelPk Context Model Primary Key (optional)
* @param ordering Which field to use when ordering the results. (optional)
* @param search A search term. (optional)
* @param tenantName Tenant name (optional)
* @param username Username (optional)
* @return ApiResponse<kotlin.collections.List<Coordinate>?>
* @throws IllegalStateException If the request is not correctly configured
* @throws IOException Rethrows the OkHttp execute method exception
*/
@Suppress("UNCHECKED_CAST")
@Throws(IllegalStateException::class, IOException::class)
fun eventsEventsVolumeListWithHttpInfo(action: kotlin.String?, clientIp: kotlin.String?, contextAuthorizedApp: kotlin.String?, contextModelApp: kotlin.String?, contextModelName: kotlin.String?, contextModelPk: kotlin.String?, ordering: kotlin.String?, search: kotlin.String?, tenantName: kotlin.String?, username: kotlin.String?) : ApiResponse<kotlin.collections.List<Coordinate>?> {
val localVariableConfig = eventsEventsVolumeListRequestConfig(action = action, clientIp = clientIp, contextAuthorizedApp = contextAuthorizedApp, contextModelApp = contextModelApp, contextModelName = contextModelName, contextModelPk = contextModelPk, ordering = ordering, search = search, tenantName = tenantName, username = username)

return request<Unit, kotlin.collections.List<Coordinate>>(
localVariableConfig
)
}

/**
* To obtain the request config of the operation eventsEventsVolumeList
*
* @param action (optional)
* @param clientIp (optional)
* @param contextAuthorizedApp Context Authorized application (optional)
* @param contextModelApp Context Model App (optional)
* @param contextModelName Context Model Name (optional)
* @param contextModelPk Context Model Primary Key (optional)
* @param ordering Which field to use when ordering the results. (optional)
* @param search A search term. (optional)
* @param tenantName Tenant name (optional)
* @param username Username (optional)
* @return RequestConfig
*/
fun eventsEventsVolumeListRequestConfig(action: kotlin.String?, clientIp: kotlin.String?, contextAuthorizedApp: kotlin.String?, contextModelApp: kotlin.String?, contextModelName: kotlin.String?, contextModelPk: kotlin.String?, ordering: kotlin.String?, search: kotlin.String?, tenantName: kotlin.String?, username: kotlin.String?) : RequestConfig<Unit> {
val localVariableBody = null
val localVariableQuery: MultiValueMap = mutableMapOf<kotlin.String, kotlin.collections.List<kotlin.String>>()
.apply {
if (action != null) {
put("action", listOf(action.toString()))
}
if (clientIp != null) {
put("client_ip", listOf(clientIp.toString()))
}
if (contextAuthorizedApp != null) {
put("context_authorized_app", listOf(contextAuthorizedApp.toString()))
}
if (contextModelApp != null) {
put("context_model_app", listOf(contextModelApp.toString()))
}
if (contextModelName != null) {
put("context_model_name", listOf(contextModelName.toString()))
}
if (contextModelPk != null) {
put("context_model_pk", listOf(contextModelPk.toString()))
}
if (ordering != null) {
put("ordering", listOf(ordering.toString()))
}
if (search != null) {
put("search", listOf(search.toString()))
}
if (tenantName != null) {
put("tenant_name", listOf(tenantName.toString()))
}
if (username != null) {
put("username", listOf(username.toString()))
}
}
val localVariableHeaders: MutableMap<String, String> = mutableMapOf()
localVariableHeaders["Accept"] = "application/json"

return RequestConfig(
method = RequestMethod.GET,
path = "/events/events/volume/",
query = localVariableQuery,
headers = localVariableHeaders,
requiresAuthentication = true,
body = localVariableBody
)
}

/**
*
* Notification Viewset
Expand Down

0 comments on commit 1e4dd1d

Please sign in to comment.