Skip to content

Commit a6d46d6

Browse files
Update API Client
#### What's New --- ##### `GET` /tasks/tasks/status/ #### What's Changed --- ##### `GET` /policies/geoip/{policy_uuid}/ ###### Return Type: Changed response : **200 OK** * Changed content type : `application/json` * Changed property `countries` (array) ##### `PUT` /policies/geoip/{policy_uuid}/ ###### Request: Changed content type : `application/json` * Changed property `countries` (array) ###### Return Type: Changed response : **200 OK** * Changed content type : `application/json` * Changed property `countries` (array) ##### `PATCH` /policies/geoip/{policy_uuid}/ ###### Request: Changed content type : `application/json` * Changed property `countries` (array) ###### Return Type: Changed response : **200 OK** * Changed content type : `application/json` * Changed property `countries` (array) ##### `POST` /policies/geoip/ ###### Request: Changed content type : `application/json` * Changed property `countries` (array) ###### Return Type: Changed response : **201 Created** * Changed content type : `application/json` * Changed property `countries` (array) ##### `GET` /policies/geoip/ ###### Return Type: Changed response : **200 OK** * Changed content type : `application/json` * Changed property `results` (array) Changed items (object): > GeoIP Policy Serializer * Changed property `countries` (array)
1 parent 6829901 commit a6d46d6

File tree

7 files changed

+242
-0
lines changed

7 files changed

+242
-0
lines changed

.openapi-generator/FILES

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,7 @@ Sources/authentikClient/Models/GenericError.swift
204204
Sources/authentikClient/Models/GeoIPPolicy.swift
205205
Sources/authentikClient/Models/GeoIPPolicyRequest.swift
206206
Sources/authentikClient/Models/GeoipBindingEnum.swift
207+
Sources/authentikClient/Models/GlobalTaskStatus.swift
207208
Sources/authentikClient/Models/GoogleWorkspaceProvider.swift
208209
Sources/authentikClient/Models/GoogleWorkspaceProviderGroup.swift
209210
Sources/authentikClient/Models/GoogleWorkspaceProviderGroupRequest.swift
@@ -979,6 +980,7 @@ docs/GenericError.md
979980
docs/GeoIPPolicy.md
980981
docs/GeoIPPolicyRequest.md
981982
docs/GeoipBindingEnum.md
983+
docs/GlobalTaskStatus.md
982984
docs/GoogleWorkspaceProvider.md
983985
docs/GoogleWorkspaceProviderGroup.md
984986
docs/GoogleWorkspaceProviderGroupRequest.md

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1043,6 +1043,7 @@ Class | Method | HTTP request | Description
10431043
*TasksAPI* | [**tasksTasksList**](docs/TasksAPI.md#taskstaskslist) | **GET** /tasks/tasks/ |
10441044
*TasksAPI* | [**tasksTasksRetrieve**](docs/TasksAPI.md#taskstasksretrieve) | **GET** /tasks/tasks/{message_id}/ |
10451045
*TasksAPI* | [**tasksTasksRetryCreate**](docs/TasksAPI.md#taskstasksretrycreate) | **POST** /tasks/tasks/{message_id}/retry/ |
1046+
*TasksAPI* | [**tasksTasksStatusRetrieve**](docs/TasksAPI.md#taskstasksstatusretrieve) | **GET** /tasks/tasks/status/ |
10461047
*TasksAPI* | [**tasksWorkersList**](docs/TasksAPI.md#tasksworkerslist) | **GET** /tasks/workers |
10471048
*TenantsAPI* | [**tenantsDomainsCreate**](docs/TenantsAPI.md#tenantsdomainscreate) | **POST** /tenants/domains/ |
10481049
*TenantsAPI* | [**tenantsDomainsDestroy**](docs/TenantsAPI.md#tenantsdomainsdestroy) | **DELETE** /tenants/domains/{id}/ |
@@ -1229,6 +1230,7 @@ Class | Method | HTTP request | Description
12291230
- [GeoIPPolicy](docs/GeoIPPolicy.md)
12301231
- [GeoIPPolicyRequest](docs/GeoIPPolicyRequest.md)
12311232
- [GeoipBindingEnum](docs/GeoipBindingEnum.md)
1233+
- [GlobalTaskStatus](docs/GlobalTaskStatus.md)
12321234
- [GoogleWorkspaceProvider](docs/GoogleWorkspaceProvider.md)
12331235
- [GoogleWorkspaceProviderGroup](docs/GoogleWorkspaceProviderGroup.md)
12341236
- [GoogleWorkspaceProviderGroupRequest](docs/GoogleWorkspaceProviderGroupRequest.md)

Sources/authentikClient/APIs/TasksAPI.swift

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -432,6 +432,43 @@ open class TasksAPI {
432432
return localVariableRequestBuilder.init(method: "POST", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
433433
}
434434

435+
/**
436+
437+
- parameter apiConfiguration: The configuration for the http request.
438+
- returns: GlobalTaskStatus
439+
*/
440+
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
441+
open class func tasksTasksStatusRetrieve(apiConfiguration: authentikClientAPIConfiguration = authentikClientAPIConfiguration.shared) async throws(ErrorResponse) -> GlobalTaskStatus {
442+
return try await tasksTasksStatusRetrieveWithRequestBuilder(apiConfiguration: apiConfiguration).execute().body
443+
}
444+
445+
/**
446+
- GET /tasks/tasks/status/
447+
- Global status summary for all tasks
448+
- Bearer Token:
449+
- type: http
450+
- name: authentik
451+
- parameter apiConfiguration: The configuration for the http request.
452+
- returns: RequestBuilder<GlobalTaskStatus>
453+
*/
454+
open class func tasksTasksStatusRetrieveWithRequestBuilder(apiConfiguration: authentikClientAPIConfiguration = authentikClientAPIConfiguration.shared) -> RequestBuilder<GlobalTaskStatus> {
455+
let localVariablePath = "/tasks/tasks/status/"
456+
let localVariableURLString = apiConfiguration.basePath + localVariablePath
457+
let localVariableParameters: [String: any Sendable]? = nil
458+
459+
let localVariableUrlComponents = URLComponents(string: localVariableURLString)
460+
461+
let localVariableNillableHeaders: [String: (any Sendable)?] = [
462+
:
463+
]
464+
465+
let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders)
466+
467+
let localVariableRequestBuilder: RequestBuilder<GlobalTaskStatus>.Type = apiConfiguration.requestBuilderFactory.getBuilder()
468+
469+
return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true, apiConfiguration: apiConfiguration)
470+
}
471+
435472
/**
436473

437474
- parameter apiConfiguration: The configuration for the http request.
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
//
2+
// GlobalTaskStatus.swift
3+
//
4+
// Generated by openapi-generator
5+
// https://openapi-generator.tech
6+
//
7+
8+
import Foundation
9+
10+
public struct GlobalTaskStatus: Sendable, Codable, ParameterConvertible, Hashable {
11+
12+
public var queued: Int
13+
public var consumed: Int
14+
public var preprocess: Int
15+
public var running: Int
16+
public var postprocess: Int
17+
public var rejected: Int
18+
public var done: Int
19+
public var info: Int
20+
public var warning: Int
21+
public var error: Int
22+
23+
public init(queued: Int, consumed: Int, preprocess: Int, running: Int, postprocess: Int, rejected: Int, done: Int, info: Int, warning: Int, error: Int) {
24+
self.queued = queued
25+
self.consumed = consumed
26+
self.preprocess = preprocess
27+
self.running = running
28+
self.postprocess = postprocess
29+
self.rejected = rejected
30+
self.done = done
31+
self.info = info
32+
self.warning = warning
33+
self.error = error
34+
}
35+
36+
public enum CodingKeys: String, CodingKey, CaseIterable {
37+
case queued
38+
case consumed
39+
case preprocess
40+
case running
41+
case postprocess
42+
case rejected
43+
case done
44+
case info
45+
case warning
46+
case error
47+
}
48+
49+
// Encodable protocol methods
50+
51+
public func encode(to encoder: Encoder) throws {
52+
var container = encoder.container(keyedBy: CodingKeys.self)
53+
try container.encode(queued, forKey: .queued)
54+
try container.encode(consumed, forKey: .consumed)
55+
try container.encode(preprocess, forKey: .preprocess)
56+
try container.encode(running, forKey: .running)
57+
try container.encode(postprocess, forKey: .postprocess)
58+
try container.encode(rejected, forKey: .rejected)
59+
try container.encode(done, forKey: .done)
60+
try container.encode(info, forKey: .info)
61+
try container.encode(warning, forKey: .warning)
62+
try container.encode(error, forKey: .error)
63+
}
64+
}
65+

docs/GlobalTaskStatus.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# GlobalTaskStatus
2+
3+
## Properties
4+
Name | Type | Description | Notes
5+
------------ | ------------- | ------------- | -------------
6+
**queued** | **Int** | | [readonly]
7+
**consumed** | **Int** | | [readonly]
8+
**preprocess** | **Int** | | [readonly]
9+
**running** | **Int** | | [readonly]
10+
**postprocess** | **Int** | | [readonly]
11+
**rejected** | **Int** | | [readonly]
12+
**done** | **Int** | | [readonly]
13+
**info** | **Int** | | [readonly]
14+
**warning** | **Int** | | [readonly]
15+
**error** | **Int** | | [readonly]
16+
17+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
18+
19+

docs/TasksAPI.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ Method | HTTP request | Description
1212
[**tasksTasksList**](TasksAPI.md#taskstaskslist) | **GET** /tasks/tasks/ |
1313
[**tasksTasksRetrieve**](TasksAPI.md#taskstasksretrieve) | **GET** /tasks/tasks/{message_id}/ |
1414
[**tasksTasksRetryCreate**](TasksAPI.md#taskstasksretrycreate) | **POST** /tasks/tasks/{message_id}/retry/ |
15+
[**tasksTasksStatusRetrieve**](TasksAPI.md#taskstasksstatusretrieve) | **GET** /tasks/tasks/status/ |
1516
[**tasksWorkersList**](TasksAPI.md#tasksworkerslist) | **GET** /tasks/workers |
1617

1718

@@ -439,6 +440,51 @@ Void (empty response body)
439440

440441
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
441442

443+
# **tasksTasksStatusRetrieve**
444+
```swift
445+
open class func tasksTasksStatusRetrieve(completion: @escaping (_ data: GlobalTaskStatus?, _ error: Error?) -> Void)
446+
```
447+
448+
449+
450+
Global status summary for all tasks
451+
452+
### Example
453+
```swift
454+
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
455+
import authentikClient
456+
457+
458+
TasksAPI.tasksTasksStatusRetrieve() { (response, error) in
459+
guard error == nil else {
460+
print(error)
461+
return
462+
}
463+
464+
if (response) {
465+
dump(response)
466+
}
467+
}
468+
```
469+
470+
### Parameters
471+
This endpoint does not need any parameter.
472+
473+
### Return type
474+
475+
[**GlobalTaskStatus**](GlobalTaskStatus.md)
476+
477+
### Authorization
478+
479+
[authentik](../README.md#authentik)
480+
481+
### HTTP request headers
482+
483+
- **Content-Type**: Not defined
484+
- **Accept**: application/json
485+
486+
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
487+
442488
# **tasksWorkersList**
443489
```swift
444490
open class func tasksWorkersList(completion: @escaping (_ data: [Worker]?, _ error: Error?) -> Void)

schema.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39053,6 +39053,33 @@ paths:
3905339053
schema:
3905439054
$ref: '#/components/schemas/GenericError'
3905539055
description: ''
39056+
/tasks/tasks/status/:
39057+
get:
39058+
operationId: tasks_tasks_status_retrieve
39059+
description: Global status summary for all tasks
39060+
tags:
39061+
- tasks
39062+
security:
39063+
- authentik: []
39064+
responses:
39065+
'200':
39066+
content:
39067+
application/json:
39068+
schema:
39069+
$ref: '#/components/schemas/GlobalTaskStatus'
39070+
description: ''
39071+
'400':
39072+
content:
39073+
application/json:
39074+
schema:
39075+
$ref: '#/components/schemas/ValidationError'
39076+
description: ''
39077+
'403':
39078+
content:
39079+
application/json:
39080+
schema:
39081+
$ref: '#/components/schemas/GenericError'
39082+
description: ''
3905639083
/tasks/workers:
3905739084
get:
3905839085
operationId: tasks_workers_list
@@ -44348,6 +44375,50 @@ components:
4434844375
- bind_continent_country
4434944376
- bind_continent_country_city
4435044377
type: string
44378+
GlobalTaskStatus:
44379+
type: object
44380+
properties:
44381+
queued:
44382+
type: integer
44383+
readOnly: true
44384+
consumed:
44385+
type: integer
44386+
readOnly: true
44387+
preprocess:
44388+
type: integer
44389+
readOnly: true
44390+
running:
44391+
type: integer
44392+
readOnly: true
44393+
postprocess:
44394+
type: integer
44395+
readOnly: true
44396+
rejected:
44397+
type: integer
44398+
readOnly: true
44399+
done:
44400+
type: integer
44401+
readOnly: true
44402+
info:
44403+
type: integer
44404+
readOnly: true
44405+
warning:
44406+
type: integer
44407+
readOnly: true
44408+
error:
44409+
type: integer
44410+
readOnly: true
44411+
required:
44412+
- consumed
44413+
- done
44414+
- error
44415+
- info
44416+
- postprocess
44417+
- preprocess
44418+
- queued
44419+
- rejected
44420+
- running
44421+
- warning
4435144422
GoogleWorkspaceProvider:
4435244423
type: object
4435344424
description: GoogleWorkspaceProvider Serializer

0 commit comments

Comments
 (0)