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 Changed
---

##### `GET` /stages/user_write/{stage_uuid}/

###### Return Type:

Changed response : **200 OK**

* Changed content type : `application/json`

    * Added property `user_type` (string)
        > * `internal` - Internal
        > * `external` - External
        > * `service_account` - Service Account
        > * `internal_service_account` - Internal Service Account

        Enum values:

        * `internal`
        * `external`
        * `service_account`
        * `internal_service_account`
##### `PUT` /stages/user_write/{stage_uuid}/

###### Request:

Changed content type : `application/json`

* Added property `user_type` (string)
    > * `internal` - Internal
    > * `external` - External
    > * `service_account` - Service Account
    > * `internal_service_account` - Internal Service Account

###### Return Type:

Changed response : **200 OK**

* Changed content type : `application/json`

    * Added property `user_type` (string)
        > * `internal` - Internal
        > * `external` - External
        > * `service_account` - Service Account
        > * `internal_service_account` - Internal Service Account

##### `PATCH` /stages/user_write/{stage_uuid}/

###### Request:

Changed content type : `application/json`

* Added property `user_type` (string)
    > * `internal` - Internal
    > * `external` - External
    > * `service_account` - Service Account
    > * `internal_service_account` - Internal Service Account

###### Return Type:

Changed response : **200 OK**

* Changed content type : `application/json`

    * Added property `user_type` (string)
        > * `internal` - Internal
        > * `external` - External
        > * `service_account` - Service Account
        > * `internal_service_account` - Internal Service Account

##### `POST` /stages/user_write/

###### Request:

Changed content type : `application/json`

* Added property `user_type` (string)
    > * `internal` - Internal
    > * `external` - External
    > * `service_account` - Service Account
    > * `internal_service_account` - Internal Service Account

###### Return Type:

Changed response : **201 Created**

* Changed content type : `application/json`

    * Added property `user_type` (string)
        > * `internal` - Internal
        > * `external` - External
        > * `service_account` - Service Account
        > * `internal_service_account` - Internal Service Account

##### `GET` /stages/user_write/

###### Parameters:

Added: `user_type` in `query`
> * `internal` - Internal
> * `external` - External
> * `service_account` - Service Account
> * `internal_service_account` - Internal Service Account

###### Return Type:

Changed response : **200 OK**

* Changed content type : `application/json`

    * Changed property `results` (array)

        Changed items (object):
            > UserWriteStage Serializer

        * Added property `user_type` (string)
            > * `internal` - Internal
            > * `external` - External
            > * `service_account` - Service Account
            > * `internal_service_account` - Internal Service Account
  • Loading branch information
authentik-automation[bot] committed Oct 26, 2023
1 parent 53a73b7 commit 106bd5e
Show file tree
Hide file tree
Showing 9 changed files with 63 additions and 7 deletions.
1 change: 1 addition & 0 deletions docs/PatchedUserWriteStageRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Name | Type | Description | Notes
**userCreationMode** | [**UserCreationModeEnum**](UserCreationModeEnum.md) | | [optional]
**createUsersAsInactive** | **kotlin.Boolean** | When set, newly created users are inactive and cannot login. | [optional]
**createUsersGroup** | [**java.util.UUID**](java.util.UUID.md) | Optionally add newly created users to this group. | [optional]
**userType** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional]
**userPathTemplate** | **kotlin.String** | | [optional]


Expand Down
6 changes: 4 additions & 2 deletions docs/StagesApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -8189,7 +8189,7 @@ Configure authentik:

<a name="stagesUserWriteList"></a>
# **stagesUserWriteList**
> PaginatedUserWriteStageList stagesUserWriteList(createUsersAsInactive, createUsersGroup, name, ordering, page, pageSize, search, stageUuid, userCreationMode, userPathTemplate)
> PaginatedUserWriteStageList stagesUserWriteList(createUsersAsInactive, createUsersGroup, name, ordering, page, pageSize, search, stageUuid, userCreationMode, userPathTemplate, userType)


Expand All @@ -8212,8 +8212,9 @@ val search : kotlin.String = search_example // kotlin.String | A search term.
val stageUuid : java.util.UUID = 38400000-8cf0-11bd-b23e-10b96e4ef00d // java.util.UUID |
val userCreationMode : kotlin.String = userCreationMode_example // kotlin.String | * `never_create` - Never Create * `create_when_required` - Create When Required * `always_create` - Always Create
val userPathTemplate : kotlin.String = userPathTemplate_example // kotlin.String |
val userType : kotlin.String = userType_example // kotlin.String | * `internal` - Internal * `external` - External * `service_account` - Service Account * `internal_service_account` - Internal Service Account
try {
val result : PaginatedUserWriteStageList = apiInstance.stagesUserWriteList(createUsersAsInactive, createUsersGroup, name, ordering, page, pageSize, search, stageUuid, userCreationMode, userPathTemplate)
val result : PaginatedUserWriteStageList = apiInstance.stagesUserWriteList(createUsersAsInactive, createUsersGroup, name, ordering, page, pageSize, search, stageUuid, userCreationMode, userPathTemplate, userType)
println(result)
} catch (e: ClientException) {
println("4xx response calling StagesApi#stagesUserWriteList")
Expand All @@ -8238,6 +8239,7 @@ Name | Type | Description | Notes
**stageUuid** | **java.util.UUID**| | [optional]
**userCreationMode** | **kotlin.String**| * &#x60;never_create&#x60; - Never Create * &#x60;create_when_required&#x60; - Create When Required * &#x60;always_create&#x60; - Always Create | [optional] [enum: always_create, create_when_required, never_create]
**userPathTemplate** | **kotlin.String**| | [optional]
**userType** | **kotlin.String**| * &#x60;internal&#x60; - Internal * &#x60;external&#x60; - External * &#x60;service_account&#x60; - Service Account * &#x60;internal_service_account&#x60; - Internal Service Account | [optional] [enum: external, internal, internal_service_account, service_account]

### Return type

Expand Down
1 change: 1 addition & 0 deletions docs/UserWriteStage.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ Name | Type | Description | Notes
**userCreationMode** | [**UserCreationModeEnum**](UserCreationModeEnum.md) | | [optional]
**createUsersAsInactive** | **kotlin.Boolean** | When set, newly created users are inactive and cannot login. | [optional]
**createUsersGroup** | [**java.util.UUID**](java.util.UUID.md) | Optionally add newly created users to this group. | [optional]
**userType** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional]
**userPathTemplate** | **kotlin.String** | | [optional]


Expand Down
1 change: 1 addition & 0 deletions docs/UserWriteStageRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Name | Type | Description | Notes
**userCreationMode** | [**UserCreationModeEnum**](UserCreationModeEnum.md) | | [optional]
**createUsersAsInactive** | **kotlin.Boolean** | When set, newly created users are inactive and cannot login. | [optional]
**createUsersGroup** | [**java.util.UUID**](java.util.UUID.md) | Optionally add newly created users to this group. | [optional]
**userType** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional]
**userPathTemplate** | **kotlin.String** | | [optional]


Expand Down
20 changes: 20 additions & 0 deletions schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27494,6 +27494,20 @@ paths:
name: user_path_template
schema:
type: string
- in: query
name: user_type
schema:
type: string
enum:
- external
- internal
- internal_service_account
- service_account
description: |-
* `internal` - Internal
* `external` - External
* `service_account` - Service Account
* `internal_service_account` - Internal Service Account
tags:
- stages
security:
Expand Down Expand Up @@ -38052,6 +38066,8 @@ components:
format: uuid
nullable: true
description: Optionally add newly created users to this group.
user_type:
$ref: '#/components/schemas/UserTypeEnum'
user_path_template:
type: string
PatchedWebAuthnDeviceRequest:
Expand Down Expand Up @@ -42422,6 +42438,8 @@ components:
format: uuid
nullable: true
description: Optionally add newly created users to this group.
user_type:
$ref: '#/components/schemas/UserTypeEnum'
user_path_template:
type: string
required:
Expand Down Expand Up @@ -42452,6 +42470,8 @@ components:
format: uuid
nullable: true
description: Optionally add newly created users to this group.
user_type:
$ref: '#/components/schemas/UserTypeEnum'
user_path_template:
type: string
required:
Expand Down
26 changes: 21 additions & 5 deletions src/main/kotlin/io/goauthentik/api/apis/StagesApi.kt
Original file line number Diff line number Diff line change
Expand Up @@ -12169,6 +12169,16 @@ class StagesApi(basePath: kotlin.String = defaultBasePath, client: OkHttpClient
@Json(name = "never_create") neverCreate("never_create"),
}

/**
* enum for parameter userType
*/
enum class UserType_stagesUserWriteList(val value: kotlin.String) {
@Json(name = "external") `external`("external"),
@Json(name = "internal") `internal`("internal"),
@Json(name = "internal_service_account") internalServiceAccount("internal_service_account"),
@Json(name = "service_account") serviceAccount("service_account"),
}

/**
*
* UserWriteStage Viewset
Expand All @@ -12182,6 +12192,7 @@ class StagesApi(basePath: kotlin.String = defaultBasePath, client: OkHttpClient
* @param stageUuid (optional)
* @param userCreationMode * &#x60;never_create&#x60; - Never Create * &#x60;create_when_required&#x60; - Create When Required * &#x60;always_create&#x60; - Always Create (optional)
* @param userPathTemplate (optional)
* @param userType * &#x60;internal&#x60; - Internal * &#x60;external&#x60; - External * &#x60;service_account&#x60; - Service Account * &#x60;internal_service_account&#x60; - Internal Service Account (optional)
* @return PaginatedUserWriteStageList
* @throws IllegalStateException If the request is not correctly configured
* @throws IOException Rethrows the OkHttp execute method exception
Expand All @@ -12191,8 +12202,8 @@ class StagesApi(basePath: kotlin.String = defaultBasePath, client: OkHttpClient
*/
@Suppress("UNCHECKED_CAST")
@Throws(IllegalStateException::class, IOException::class, UnsupportedOperationException::class, ClientException::class, ServerException::class)
fun stagesUserWriteList(createUsersAsInactive: kotlin.Boolean? = null, createUsersGroup: java.util.UUID? = null, name: kotlin.String? = null, ordering: kotlin.String? = null, page: kotlin.Int? = null, pageSize: kotlin.Int? = null, search: kotlin.String? = null, stageUuid: java.util.UUID? = null, userCreationMode: UserCreationMode_stagesUserWriteList? = null, userPathTemplate: kotlin.String? = null) : PaginatedUserWriteStageList {
val localVarResponse = stagesUserWriteListWithHttpInfo(createUsersAsInactive = createUsersAsInactive, createUsersGroup = createUsersGroup, name = name, ordering = ordering, page = page, pageSize = pageSize, search = search, stageUuid = stageUuid, userCreationMode = userCreationMode, userPathTemplate = userPathTemplate)
fun stagesUserWriteList(createUsersAsInactive: kotlin.Boolean? = null, createUsersGroup: java.util.UUID? = null, name: kotlin.String? = null, ordering: kotlin.String? = null, page: kotlin.Int? = null, pageSize: kotlin.Int? = null, search: kotlin.String? = null, stageUuid: java.util.UUID? = null, userCreationMode: UserCreationMode_stagesUserWriteList? = null, userPathTemplate: kotlin.String? = null, userType: UserType_stagesUserWriteList? = null) : PaginatedUserWriteStageList {
val localVarResponse = stagesUserWriteListWithHttpInfo(createUsersAsInactive = createUsersAsInactive, createUsersGroup = createUsersGroup, name = name, ordering = ordering, page = page, pageSize = pageSize, search = search, stageUuid = stageUuid, userCreationMode = userCreationMode, userPathTemplate = userPathTemplate, userType = userType)

return when (localVarResponse.responseType) {
ResponseType.Success -> (localVarResponse as Success<*>).data as PaginatedUserWriteStageList
Expand Down Expand Up @@ -12222,14 +12233,15 @@ class StagesApi(basePath: kotlin.String = defaultBasePath, client: OkHttpClient
* @param stageUuid (optional)
* @param userCreationMode * &#x60;never_create&#x60; - Never Create * &#x60;create_when_required&#x60; - Create When Required * &#x60;always_create&#x60; - Always Create (optional)
* @param userPathTemplate (optional)
* @param userType * &#x60;internal&#x60; - Internal * &#x60;external&#x60; - External * &#x60;service_account&#x60; - Service Account * &#x60;internal_service_account&#x60; - Internal Service Account (optional)
* @return ApiResponse<PaginatedUserWriteStageList?>
* @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 stagesUserWriteListWithHttpInfo(createUsersAsInactive: kotlin.Boolean?, createUsersGroup: java.util.UUID?, name: kotlin.String?, ordering: kotlin.String?, page: kotlin.Int?, pageSize: kotlin.Int?, search: kotlin.String?, stageUuid: java.util.UUID?, userCreationMode: UserCreationMode_stagesUserWriteList?, userPathTemplate: kotlin.String?) : ApiResponse<PaginatedUserWriteStageList?> {
val localVariableConfig = stagesUserWriteListRequestConfig(createUsersAsInactive = createUsersAsInactive, createUsersGroup = createUsersGroup, name = name, ordering = ordering, page = page, pageSize = pageSize, search = search, stageUuid = stageUuid, userCreationMode = userCreationMode, userPathTemplate = userPathTemplate)
fun stagesUserWriteListWithHttpInfo(createUsersAsInactive: kotlin.Boolean?, createUsersGroup: java.util.UUID?, name: kotlin.String?, ordering: kotlin.String?, page: kotlin.Int?, pageSize: kotlin.Int?, search: kotlin.String?, stageUuid: java.util.UUID?, userCreationMode: UserCreationMode_stagesUserWriteList?, userPathTemplate: kotlin.String?, userType: UserType_stagesUserWriteList?) : ApiResponse<PaginatedUserWriteStageList?> {
val localVariableConfig = stagesUserWriteListRequestConfig(createUsersAsInactive = createUsersAsInactive, createUsersGroup = createUsersGroup, name = name, ordering = ordering, page = page, pageSize = pageSize, search = search, stageUuid = stageUuid, userCreationMode = userCreationMode, userPathTemplate = userPathTemplate, userType = userType)

return request<Unit, PaginatedUserWriteStageList>(
localVariableConfig
Expand All @@ -12249,9 +12261,10 @@ class StagesApi(basePath: kotlin.String = defaultBasePath, client: OkHttpClient
* @param stageUuid (optional)
* @param userCreationMode * &#x60;never_create&#x60; - Never Create * &#x60;create_when_required&#x60; - Create When Required * &#x60;always_create&#x60; - Always Create (optional)
* @param userPathTemplate (optional)
* @param userType * &#x60;internal&#x60; - Internal * &#x60;external&#x60; - External * &#x60;service_account&#x60; - Service Account * &#x60;internal_service_account&#x60; - Internal Service Account (optional)
* @return RequestConfig
*/
fun stagesUserWriteListRequestConfig(createUsersAsInactive: kotlin.Boolean?, createUsersGroup: java.util.UUID?, name: kotlin.String?, ordering: kotlin.String?, page: kotlin.Int?, pageSize: kotlin.Int?, search: kotlin.String?, stageUuid: java.util.UUID?, userCreationMode: UserCreationMode_stagesUserWriteList?, userPathTemplate: kotlin.String?) : RequestConfig<Unit> {
fun stagesUserWriteListRequestConfig(createUsersAsInactive: kotlin.Boolean?, createUsersGroup: java.util.UUID?, name: kotlin.String?, ordering: kotlin.String?, page: kotlin.Int?, pageSize: kotlin.Int?, search: kotlin.String?, stageUuid: java.util.UUID?, userCreationMode: UserCreationMode_stagesUserWriteList?, userPathTemplate: kotlin.String?, userType: UserType_stagesUserWriteList?) : RequestConfig<Unit> {
val localVariableBody = null
val localVariableQuery: MultiValueMap = mutableMapOf<kotlin.String, kotlin.collections.List<kotlin.String>>()
.apply {
Expand Down Expand Up @@ -12285,6 +12298,9 @@ class StagesApi(basePath: kotlin.String = defaultBasePath, client: OkHttpClient
if (userPathTemplate != null) {
put("user_path_template", listOf(userPathTemplate.toString()))
}
if (userType != null) {
put("user_type", listOf(userType.toString()))
}
}
val localVariableHeaders: MutableMap<String, String> = mutableMapOf()
localVariableHeaders["Accept"] = "application/json"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ package io.goauthentik.api.models

import io.goauthentik.api.models.FlowSetRequest
import io.goauthentik.api.models.UserCreationModeEnum
import io.goauthentik.api.models.UserTypeEnum

import com.squareup.moshi.Json

Expand All @@ -33,6 +34,7 @@ import com.squareup.moshi.Json
* @param userCreationMode
* @param createUsersAsInactive When set, newly created users are inactive and cannot login.
* @param createUsersGroup Optionally add newly created users to this group.
* @param userType
* @param userPathTemplate
*/

Expand All @@ -55,6 +57,9 @@ data class PatchedUserWriteStageRequest (
@Json(name = "create_users_group")
val createUsersGroup: java.util.UUID? = null,

@Json(name = "user_type")
val userType: UserTypeEnum? = null,

@Json(name = "user_path_template")
val userPathTemplate: kotlin.String? = null

Expand Down
5 changes: 5 additions & 0 deletions src/main/kotlin/io/goauthentik/api/models/UserWriteStage.kt
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ package io.goauthentik.api.models

import io.goauthentik.api.models.FlowSet
import io.goauthentik.api.models.UserCreationModeEnum
import io.goauthentik.api.models.UserTypeEnum

import com.squareup.moshi.Json

Expand All @@ -38,6 +39,7 @@ import com.squareup.moshi.Json
* @param userCreationMode
* @param createUsersAsInactive When set, newly created users are inactive and cannot login.
* @param createUsersGroup Optionally add newly created users to this group.
* @param userType
* @param userPathTemplate
*/

Expand Down Expand Up @@ -79,6 +81,9 @@ data class UserWriteStage (
@Json(name = "create_users_group")
val createUsersGroup: java.util.UUID? = null,

@Json(name = "user_type")
val userType: UserTypeEnum? = null,

@Json(name = "user_path_template")
val userPathTemplate: kotlin.String? = null

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ package io.goauthentik.api.models

import io.goauthentik.api.models.FlowSetRequest
import io.goauthentik.api.models.UserCreationModeEnum
import io.goauthentik.api.models.UserTypeEnum

import com.squareup.moshi.Json

Expand All @@ -33,6 +34,7 @@ import com.squareup.moshi.Json
* @param userCreationMode
* @param createUsersAsInactive When set, newly created users are inactive and cannot login.
* @param createUsersGroup Optionally add newly created users to this group.
* @param userType
* @param userPathTemplate
*/

Expand All @@ -55,6 +57,9 @@ data class UserWriteStageRequest (
@Json(name = "create_users_group")
val createUsersGroup: java.util.UUID? = null,

@Json(name = "user_type")
val userType: UserTypeEnum? = null,

@Json(name = "user_path_template")
val userPathTemplate: kotlin.String? = null

Expand Down

0 comments on commit 106bd5e

Please sign in to comment.