@goauthentik/api 2022.6.3-1656258767 → 2022.6.3-1656620570
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
## @goauthentik/api
|
|
2
|
+
|
|
3
|
+
This package provides a generated API Client for [authentik](https://goauthentik.io?utm_source=npm-api-package).
|
|
4
|
+
|
|
5
|
+
### Building
|
|
6
|
+
|
|
7
|
+
See https://goauthentik.io/developer-docs/making-schema-changes
|
|
8
|
+
|
|
9
|
+
### Consuming
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
npm install @goauthentik/api --save
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Create a configuration:
|
|
16
|
+
|
|
17
|
+
```typescript
|
|
18
|
+
import { Configuration } from "@goauthentik/api";
|
|
19
|
+
|
|
20
|
+
export const DEFAULT_CONFIG = new Configuration({
|
|
21
|
+
// Configure where the API is located
|
|
22
|
+
// Can be a full host, ensure CORS is configured
|
|
23
|
+
basePath: "",
|
|
24
|
+
// Required for POST/PUT/DELETE requests
|
|
25
|
+
// getCookie function must return the cookie's contents
|
|
26
|
+
headers: {
|
|
27
|
+
"X-authentik-CSRF": getCookie("authentik_csrf"),
|
|
28
|
+
},
|
|
29
|
+
});
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
Then use the API:
|
|
33
|
+
|
|
34
|
+
```typescript
|
|
35
|
+
import { CoreApi } from "@goauthentik/api";
|
|
36
|
+
|
|
37
|
+
const user = await new CoreApi(DEFAULT_CONFIG).coreUsersMeRetrieve();
|
|
38
|
+
```
|
|
@@ -155,7 +155,25 @@ export interface SAMLProvider {
|
|
|
155
155
|
* @type {string}
|
|
156
156
|
* @memberof SAMLProvider
|
|
157
157
|
*/
|
|
158
|
-
readonly
|
|
158
|
+
readonly urlDownloadMetadata: string;
|
|
159
|
+
/**
|
|
160
|
+
*
|
|
161
|
+
* @type {string}
|
|
162
|
+
* @memberof SAMLProvider
|
|
163
|
+
*/
|
|
164
|
+
readonly urlSsoPost: string;
|
|
165
|
+
/**
|
|
166
|
+
*
|
|
167
|
+
* @type {string}
|
|
168
|
+
* @memberof SAMLProvider
|
|
169
|
+
*/
|
|
170
|
+
readonly urlSsoRedirect: string;
|
|
171
|
+
/**
|
|
172
|
+
*
|
|
173
|
+
* @type {string}
|
|
174
|
+
* @memberof SAMLProvider
|
|
175
|
+
*/
|
|
176
|
+
readonly urlSsoInit: string;
|
|
159
177
|
}
|
|
160
178
|
export declare function SAMLProviderFromJSON(json: any): SAMLProvider;
|
|
161
179
|
export declare function SAMLProviderFromJSONTyped(json: any, ignoreDiscriminator: boolean): SAMLProvider;
|
|
@@ -45,7 +45,10 @@ export function SAMLProviderFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
45
45
|
'signingKp': !exists(json, 'signing_kp') ? undefined : json['signing_kp'],
|
|
46
46
|
'verificationKp': !exists(json, 'verification_kp') ? undefined : json['verification_kp'],
|
|
47
47
|
'spBinding': !exists(json, 'sp_binding') ? undefined : SpBindingEnumFromJSON(json['sp_binding']),
|
|
48
|
-
'
|
|
48
|
+
'urlDownloadMetadata': json['url_download_metadata'],
|
|
49
|
+
'urlSsoPost': json['url_sso_post'],
|
|
50
|
+
'urlSsoRedirect': json['url_sso_redirect'],
|
|
51
|
+
'urlSsoInit': json['url_sso_init'],
|
|
49
52
|
};
|
|
50
53
|
}
|
|
51
54
|
export function SAMLProviderToJSON(value) {
|
|
@@ -155,7 +155,25 @@ export interface SAMLProvider {
|
|
|
155
155
|
* @type {string}
|
|
156
156
|
* @memberof SAMLProvider
|
|
157
157
|
*/
|
|
158
|
-
readonly
|
|
158
|
+
readonly urlDownloadMetadata: string;
|
|
159
|
+
/**
|
|
160
|
+
*
|
|
161
|
+
* @type {string}
|
|
162
|
+
* @memberof SAMLProvider
|
|
163
|
+
*/
|
|
164
|
+
readonly urlSsoPost: string;
|
|
165
|
+
/**
|
|
166
|
+
*
|
|
167
|
+
* @type {string}
|
|
168
|
+
* @memberof SAMLProvider
|
|
169
|
+
*/
|
|
170
|
+
readonly urlSsoRedirect: string;
|
|
171
|
+
/**
|
|
172
|
+
*
|
|
173
|
+
* @type {string}
|
|
174
|
+
* @memberof SAMLProvider
|
|
175
|
+
*/
|
|
176
|
+
readonly urlSsoInit: string;
|
|
159
177
|
}
|
|
160
178
|
export declare function SAMLProviderFromJSON(json: any): SAMLProvider;
|
|
161
179
|
export declare function SAMLProviderFromJSONTyped(json: any, ignoreDiscriminator: boolean): SAMLProvider;
|
|
@@ -49,7 +49,10 @@ function SAMLProviderFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
49
49
|
'signingKp': !(0, runtime_1.exists)(json, 'signing_kp') ? undefined : json['signing_kp'],
|
|
50
50
|
'verificationKp': !(0, runtime_1.exists)(json, 'verification_kp') ? undefined : json['verification_kp'],
|
|
51
51
|
'spBinding': !(0, runtime_1.exists)(json, 'sp_binding') ? undefined : (0, SpBindingEnum_1.SpBindingEnumFromJSON)(json['sp_binding']),
|
|
52
|
-
'
|
|
52
|
+
'urlDownloadMetadata': json['url_download_metadata'],
|
|
53
|
+
'urlSsoPost': json['url_sso_post'],
|
|
54
|
+
'urlSsoRedirect': json['url_sso_redirect'],
|
|
55
|
+
'urlSsoInit': json['url_sso_init'],
|
|
53
56
|
};
|
|
54
57
|
}
|
|
55
58
|
exports.SAMLProviderFromJSONTyped = SAMLProviderFromJSONTyped;
|
package/package.json
CHANGED
|
@@ -175,7 +175,25 @@ export interface SAMLProvider {
|
|
|
175
175
|
* @type {string}
|
|
176
176
|
* @memberof SAMLProvider
|
|
177
177
|
*/
|
|
178
|
-
readonly
|
|
178
|
+
readonly urlDownloadMetadata: string;
|
|
179
|
+
/**
|
|
180
|
+
*
|
|
181
|
+
* @type {string}
|
|
182
|
+
* @memberof SAMLProvider
|
|
183
|
+
*/
|
|
184
|
+
readonly urlSsoPost: string;
|
|
185
|
+
/**
|
|
186
|
+
*
|
|
187
|
+
* @type {string}
|
|
188
|
+
* @memberof SAMLProvider
|
|
189
|
+
*/
|
|
190
|
+
readonly urlSsoRedirect: string;
|
|
191
|
+
/**
|
|
192
|
+
*
|
|
193
|
+
* @type {string}
|
|
194
|
+
* @memberof SAMLProvider
|
|
195
|
+
*/
|
|
196
|
+
readonly urlSsoInit: string;
|
|
179
197
|
}
|
|
180
198
|
|
|
181
199
|
export function SAMLProviderFromJSON(json: any): SAMLProvider {
|
|
@@ -210,7 +228,10 @@ export function SAMLProviderFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
|
|
210
228
|
'signingKp': !exists(json, 'signing_kp') ? undefined : json['signing_kp'],
|
|
211
229
|
'verificationKp': !exists(json, 'verification_kp') ? undefined : json['verification_kp'],
|
|
212
230
|
'spBinding': !exists(json, 'sp_binding') ? undefined : SpBindingEnumFromJSON(json['sp_binding']),
|
|
213
|
-
'
|
|
231
|
+
'urlDownloadMetadata': json['url_download_metadata'],
|
|
232
|
+
'urlSsoPost': json['url_sso_post'],
|
|
233
|
+
'urlSsoRedirect': json['url_sso_redirect'],
|
|
234
|
+
'urlSsoInit': json['url_sso_init'],
|
|
214
235
|
};
|
|
215
236
|
}
|
|
216
237
|
|