@djangocfg/api 2.1.228 → 2.1.229
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/dist/clients.d.cts +260 -260
- package/dist/clients.d.ts +260 -260
- package/dist/hooks.d.cts +73 -73
- package/dist/hooks.d.ts +73 -73
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +86 -86
- package/dist/index.d.ts +86 -86
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
- package/src/_api/generated/cfg_accounts/accounts/models.ts +23 -23
- package/src/_api/generated/cfg_accounts/accounts__auth/models.ts +5 -5
- package/src/_api/generated/cfg_accounts/accounts__oauth/models.ts +44 -44
- package/src/_api/generated/cfg_accounts/accounts__user_profile/models.ts +18 -18
- package/src/_api/generated/cfg_centrifugo/centrifugo__centrifugo_admin_api/models.ts +84 -84
- package/src/_api/generated/cfg_centrifugo/centrifugo__centrifugo_monitoring/models.ts +46 -46
- package/src/_api/generated/cfg_centrifugo/centrifugo__centrifugo_testing/models.ts +20 -20
- package/src/_api/generated/cfg_totp/totp__backup_codes/models.ts +14 -14
- package/src/_api/generated/cfg_totp/totp__totp_management/models.ts +10 -10
- package/src/_api/generated/cfg_totp/totp__totp_setup/models.ts +22 -22
package/dist/hooks.d.cts
CHANGED
|
@@ -4,17 +4,17 @@ import useSWR from 'swr';
|
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
*
|
|
7
|
-
*
|
|
7
|
+
* Response model (includes read-only fields).
|
|
8
8
|
*/
|
|
9
|
-
interface
|
|
9
|
+
interface TokenRefresh$1 {
|
|
10
|
+
access: string;
|
|
10
11
|
refresh: string;
|
|
11
12
|
}
|
|
12
13
|
/**
|
|
13
14
|
*
|
|
14
|
-
*
|
|
15
|
+
* Request model (no read-only fields).
|
|
15
16
|
*/
|
|
16
|
-
interface
|
|
17
|
-
access: string;
|
|
17
|
+
interface TokenRefreshRequest$1 {
|
|
18
18
|
refresh: string;
|
|
19
19
|
}
|
|
20
20
|
|
|
@@ -39,24 +39,41 @@ declare enum OAuthConnectionProvider {
|
|
|
39
39
|
}
|
|
40
40
|
|
|
41
41
|
/**
|
|
42
|
-
* Response with
|
|
42
|
+
* Response with OAuth authorization URL.
|
|
43
43
|
*
|
|
44
44
|
* Response model (includes read-only fields).
|
|
45
45
|
*/
|
|
46
|
-
interface
|
|
47
|
-
/**
|
|
48
|
-
|
|
46
|
+
interface OAuthAuthorizeResponse$1 {
|
|
47
|
+
/** Full URL to redirect user to OAuth provider */
|
|
48
|
+
authorization_url: string;
|
|
49
|
+
/** State token for CSRF protection. Store this and verify on callback. */
|
|
50
|
+
state: string;
|
|
49
51
|
}
|
|
50
52
|
/**
|
|
51
|
-
*
|
|
53
|
+
* Response with JWT tokens after OAuth authentication. When 2FA is required: -
|
|
54
|
+
* requires_2fa: True - session_id: UUID of 2FA verification session -
|
|
55
|
+
* access/refresh/user: null When 2FA is not required: - requires_2fa: False -
|
|
56
|
+
* session_id: null - access/refresh/user: populated
|
|
52
57
|
*
|
|
53
|
-
*
|
|
58
|
+
* Response model (includes read-only fields).
|
|
54
59
|
*/
|
|
55
|
-
interface
|
|
56
|
-
/**
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
+
interface OAuthTokenResponse$1 {
|
|
61
|
+
/** True if 2FA verification is required */
|
|
62
|
+
requires_2fa?: boolean;
|
|
63
|
+
/** 2FA session ID (only when requires_2fa=True) */
|
|
64
|
+
session_id?: string | null;
|
|
65
|
+
/** JWT access token (null when requires_2fa=True) */
|
|
66
|
+
access?: string | null;
|
|
67
|
+
/** JWT refresh token (null when requires_2fa=True) */
|
|
68
|
+
refresh?: string | null;
|
|
69
|
+
/** Authenticated user info (null when requires_2fa=True) */
|
|
70
|
+
user?: Record<string, any> | null;
|
|
71
|
+
/** True if a new user was created during this OAuth flow */
|
|
72
|
+
is_new_user: boolean;
|
|
73
|
+
/** True if a new OAuth connection was created */
|
|
74
|
+
is_new_connection: boolean;
|
|
75
|
+
/** True if user should be prompted to enable 2FA */
|
|
76
|
+
should_prompt_2fa?: boolean;
|
|
60
77
|
}
|
|
61
78
|
/**
|
|
62
79
|
* Request to start OAuth flow.
|
|
@@ -83,41 +100,24 @@ interface OAuthCallbackRequestRequest$1 {
|
|
|
83
100
|
redirect_uri?: string;
|
|
84
101
|
}
|
|
85
102
|
/**
|
|
86
|
-
*
|
|
103
|
+
* Request to disconnect OAuth provider.
|
|
87
104
|
*
|
|
88
|
-
*
|
|
105
|
+
* Request model (no read-only fields).
|
|
89
106
|
*/
|
|
90
|
-
interface
|
|
91
|
-
/**
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
107
|
+
interface OAuthDisconnectRequestRequest$1 {
|
|
108
|
+
/** OAuth provider to disconnect
|
|
109
|
+
|
|
110
|
+
* `github` - GitHub */
|
|
111
|
+
provider: OAuthConnectionProvider;
|
|
95
112
|
}
|
|
96
113
|
/**
|
|
97
|
-
* Response with
|
|
98
|
-
* requires_2fa: True - session_id: UUID of 2FA verification session -
|
|
99
|
-
* access/refresh/user: null When 2FA is not required: - requires_2fa: False -
|
|
100
|
-
* session_id: null - access/refresh/user: populated
|
|
114
|
+
* Response with available OAuth providers.
|
|
101
115
|
*
|
|
102
116
|
* Response model (includes read-only fields).
|
|
103
117
|
*/
|
|
104
|
-
interface
|
|
105
|
-
/**
|
|
106
|
-
|
|
107
|
-
/** 2FA session ID (only when requires_2fa=True) */
|
|
108
|
-
session_id?: string | null;
|
|
109
|
-
/** JWT access token (null when requires_2fa=True) */
|
|
110
|
-
access?: string | null;
|
|
111
|
-
/** JWT refresh token (null when requires_2fa=True) */
|
|
112
|
-
refresh?: string | null;
|
|
113
|
-
/** Authenticated user info (null when requires_2fa=True) */
|
|
114
|
-
user?: Record<string, any> | null;
|
|
115
|
-
/** True if a new user was created during this OAuth flow */
|
|
116
|
-
is_new_user: boolean;
|
|
117
|
-
/** True if a new OAuth connection was created */
|
|
118
|
-
is_new_connection: boolean;
|
|
119
|
-
/** True if user should be prompted to enable 2FA */
|
|
120
|
-
should_prompt_2fa?: boolean;
|
|
118
|
+
interface OAuthProvidersResponse {
|
|
119
|
+
/** List of available OAuth providers */
|
|
120
|
+
providers: Array<Record<string, any>>;
|
|
121
121
|
}
|
|
122
122
|
|
|
123
123
|
/**
|
|
@@ -160,23 +160,12 @@ declare class Oauth {
|
|
|
160
160
|
accountsOauthProvidersRetrieve(): Promise<OAuthProvidersResponse>;
|
|
161
161
|
}
|
|
162
162
|
|
|
163
|
-
/**
|
|
164
|
-
* Response serializer for account deletion.
|
|
165
|
-
*
|
|
166
|
-
* Response model (includes read-only fields).
|
|
167
|
-
*/
|
|
168
|
-
interface AccountDeleteResponse$1 {
|
|
169
|
-
/** Whether the account was successfully deleted */
|
|
170
|
-
success: boolean;
|
|
171
|
-
/** Human-readable message about the deletion */
|
|
172
|
-
message: string;
|
|
173
|
-
}
|
|
174
163
|
/**
|
|
175
164
|
* Serializer for updating user profile.
|
|
176
165
|
*
|
|
177
166
|
* Request model (no read-only fields).
|
|
178
167
|
*/
|
|
179
|
-
interface
|
|
168
|
+
interface PatchedUserProfileUpdateRequest$1 {
|
|
180
169
|
first_name?: string;
|
|
181
170
|
last_name?: string;
|
|
182
171
|
company?: string;
|
|
@@ -184,12 +173,20 @@ interface UserProfileUpdateRequest$1 {
|
|
|
184
173
|
position?: string;
|
|
185
174
|
language?: string;
|
|
186
175
|
}
|
|
176
|
+
/**
|
|
177
|
+
*
|
|
178
|
+
* Request model (no read-only fields).
|
|
179
|
+
*/
|
|
180
|
+
interface CfgAccountsProfileAvatarCreateRequest$1 {
|
|
181
|
+
/** Avatar image file (JPEG, PNG, GIF, WebP, max 5MB) */
|
|
182
|
+
avatar: File | Blob;
|
|
183
|
+
}
|
|
187
184
|
/**
|
|
188
185
|
* Serializer for updating user profile.
|
|
189
186
|
*
|
|
190
187
|
* Request model (no read-only fields).
|
|
191
188
|
*/
|
|
192
|
-
interface
|
|
189
|
+
interface UserProfileUpdateRequest$1 {
|
|
193
190
|
first_name?: string;
|
|
194
191
|
last_name?: string;
|
|
195
192
|
company?: string;
|
|
@@ -228,12 +225,15 @@ interface User$2 {
|
|
|
228
225
|
centrifugo: CentrifugoToken$1 | null;
|
|
229
226
|
}
|
|
230
227
|
/**
|
|
228
|
+
* Response serializer for account deletion.
|
|
231
229
|
*
|
|
232
|
-
*
|
|
230
|
+
* Response model (includes read-only fields).
|
|
233
231
|
*/
|
|
234
|
-
interface
|
|
235
|
-
/**
|
|
236
|
-
|
|
232
|
+
interface AccountDeleteResponse$1 {
|
|
233
|
+
/** Whether the account was successfully deleted */
|
|
234
|
+
success: boolean;
|
|
235
|
+
/** Human-readable message about the deletion */
|
|
236
|
+
message: string;
|
|
237
237
|
}
|
|
238
238
|
/**
|
|
239
239
|
* Nested serializer for Centrifugo WebSocket connection token.
|
|
@@ -319,6 +319,18 @@ interface OTPRequestRequest$1 {
|
|
|
319
319
|
/** Source URL for tracking registration (e.g., https://my.djangocfg.com) */
|
|
320
320
|
source_url?: string;
|
|
321
321
|
}
|
|
322
|
+
/**
|
|
323
|
+
* Serializer for OTP verification.
|
|
324
|
+
*
|
|
325
|
+
* Request model (no read-only fields).
|
|
326
|
+
*/
|
|
327
|
+
interface OTPVerifyRequest$1 {
|
|
328
|
+
/** Email address used for OTP request */
|
|
329
|
+
identifier: string;
|
|
330
|
+
otp: string;
|
|
331
|
+
/** Source URL for tracking login (e.g., https://my.djangocfg.com) */
|
|
332
|
+
source_url?: string;
|
|
333
|
+
}
|
|
322
334
|
/**
|
|
323
335
|
* OTP request response.
|
|
324
336
|
*
|
|
@@ -349,18 +361,6 @@ interface OTPVerifyResponse$1 {
|
|
|
349
361
|
/** Whether user should be prompted to enable 2FA */
|
|
350
362
|
should_prompt_2fa?: boolean;
|
|
351
363
|
}
|
|
352
|
-
/**
|
|
353
|
-
* Serializer for OTP verification.
|
|
354
|
-
*
|
|
355
|
-
* Request model (no read-only fields).
|
|
356
|
-
*/
|
|
357
|
-
interface OTPVerifyRequest$1 {
|
|
358
|
-
/** Email address used for OTP request */
|
|
359
|
-
identifier: string;
|
|
360
|
-
otp: string;
|
|
361
|
-
/** Source URL for tracking login (e.g., https://my.djangocfg.com) */
|
|
362
|
-
source_url?: string;
|
|
363
|
-
}
|
|
364
364
|
/**
|
|
365
365
|
* Serializer for user details.
|
|
366
366
|
*
|
package/dist/hooks.d.ts
CHANGED
|
@@ -4,17 +4,17 @@ import useSWR from 'swr';
|
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
*
|
|
7
|
-
*
|
|
7
|
+
* Response model (includes read-only fields).
|
|
8
8
|
*/
|
|
9
|
-
interface
|
|
9
|
+
interface TokenRefresh$1 {
|
|
10
|
+
access: string;
|
|
10
11
|
refresh: string;
|
|
11
12
|
}
|
|
12
13
|
/**
|
|
13
14
|
*
|
|
14
|
-
*
|
|
15
|
+
* Request model (no read-only fields).
|
|
15
16
|
*/
|
|
16
|
-
interface
|
|
17
|
-
access: string;
|
|
17
|
+
interface TokenRefreshRequest$1 {
|
|
18
18
|
refresh: string;
|
|
19
19
|
}
|
|
20
20
|
|
|
@@ -39,24 +39,41 @@ declare enum OAuthConnectionProvider {
|
|
|
39
39
|
}
|
|
40
40
|
|
|
41
41
|
/**
|
|
42
|
-
* Response with
|
|
42
|
+
* Response with OAuth authorization URL.
|
|
43
43
|
*
|
|
44
44
|
* Response model (includes read-only fields).
|
|
45
45
|
*/
|
|
46
|
-
interface
|
|
47
|
-
/**
|
|
48
|
-
|
|
46
|
+
interface OAuthAuthorizeResponse$1 {
|
|
47
|
+
/** Full URL to redirect user to OAuth provider */
|
|
48
|
+
authorization_url: string;
|
|
49
|
+
/** State token for CSRF protection. Store this and verify on callback. */
|
|
50
|
+
state: string;
|
|
49
51
|
}
|
|
50
52
|
/**
|
|
51
|
-
*
|
|
53
|
+
* Response with JWT tokens after OAuth authentication. When 2FA is required: -
|
|
54
|
+
* requires_2fa: True - session_id: UUID of 2FA verification session -
|
|
55
|
+
* access/refresh/user: null When 2FA is not required: - requires_2fa: False -
|
|
56
|
+
* session_id: null - access/refresh/user: populated
|
|
52
57
|
*
|
|
53
|
-
*
|
|
58
|
+
* Response model (includes read-only fields).
|
|
54
59
|
*/
|
|
55
|
-
interface
|
|
56
|
-
/**
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
+
interface OAuthTokenResponse$1 {
|
|
61
|
+
/** True if 2FA verification is required */
|
|
62
|
+
requires_2fa?: boolean;
|
|
63
|
+
/** 2FA session ID (only when requires_2fa=True) */
|
|
64
|
+
session_id?: string | null;
|
|
65
|
+
/** JWT access token (null when requires_2fa=True) */
|
|
66
|
+
access?: string | null;
|
|
67
|
+
/** JWT refresh token (null when requires_2fa=True) */
|
|
68
|
+
refresh?: string | null;
|
|
69
|
+
/** Authenticated user info (null when requires_2fa=True) */
|
|
70
|
+
user?: Record<string, any> | null;
|
|
71
|
+
/** True if a new user was created during this OAuth flow */
|
|
72
|
+
is_new_user: boolean;
|
|
73
|
+
/** True if a new OAuth connection was created */
|
|
74
|
+
is_new_connection: boolean;
|
|
75
|
+
/** True if user should be prompted to enable 2FA */
|
|
76
|
+
should_prompt_2fa?: boolean;
|
|
60
77
|
}
|
|
61
78
|
/**
|
|
62
79
|
* Request to start OAuth flow.
|
|
@@ -83,41 +100,24 @@ interface OAuthCallbackRequestRequest$1 {
|
|
|
83
100
|
redirect_uri?: string;
|
|
84
101
|
}
|
|
85
102
|
/**
|
|
86
|
-
*
|
|
103
|
+
* Request to disconnect OAuth provider.
|
|
87
104
|
*
|
|
88
|
-
*
|
|
105
|
+
* Request model (no read-only fields).
|
|
89
106
|
*/
|
|
90
|
-
interface
|
|
91
|
-
/**
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
107
|
+
interface OAuthDisconnectRequestRequest$1 {
|
|
108
|
+
/** OAuth provider to disconnect
|
|
109
|
+
|
|
110
|
+
* `github` - GitHub */
|
|
111
|
+
provider: OAuthConnectionProvider;
|
|
95
112
|
}
|
|
96
113
|
/**
|
|
97
|
-
* Response with
|
|
98
|
-
* requires_2fa: True - session_id: UUID of 2FA verification session -
|
|
99
|
-
* access/refresh/user: null When 2FA is not required: - requires_2fa: False -
|
|
100
|
-
* session_id: null - access/refresh/user: populated
|
|
114
|
+
* Response with available OAuth providers.
|
|
101
115
|
*
|
|
102
116
|
* Response model (includes read-only fields).
|
|
103
117
|
*/
|
|
104
|
-
interface
|
|
105
|
-
/**
|
|
106
|
-
|
|
107
|
-
/** 2FA session ID (only when requires_2fa=True) */
|
|
108
|
-
session_id?: string | null;
|
|
109
|
-
/** JWT access token (null when requires_2fa=True) */
|
|
110
|
-
access?: string | null;
|
|
111
|
-
/** JWT refresh token (null when requires_2fa=True) */
|
|
112
|
-
refresh?: string | null;
|
|
113
|
-
/** Authenticated user info (null when requires_2fa=True) */
|
|
114
|
-
user?: Record<string, any> | null;
|
|
115
|
-
/** True if a new user was created during this OAuth flow */
|
|
116
|
-
is_new_user: boolean;
|
|
117
|
-
/** True if a new OAuth connection was created */
|
|
118
|
-
is_new_connection: boolean;
|
|
119
|
-
/** True if user should be prompted to enable 2FA */
|
|
120
|
-
should_prompt_2fa?: boolean;
|
|
118
|
+
interface OAuthProvidersResponse {
|
|
119
|
+
/** List of available OAuth providers */
|
|
120
|
+
providers: Array<Record<string, any>>;
|
|
121
121
|
}
|
|
122
122
|
|
|
123
123
|
/**
|
|
@@ -160,23 +160,12 @@ declare class Oauth {
|
|
|
160
160
|
accountsOauthProvidersRetrieve(): Promise<OAuthProvidersResponse>;
|
|
161
161
|
}
|
|
162
162
|
|
|
163
|
-
/**
|
|
164
|
-
* Response serializer for account deletion.
|
|
165
|
-
*
|
|
166
|
-
* Response model (includes read-only fields).
|
|
167
|
-
*/
|
|
168
|
-
interface AccountDeleteResponse$1 {
|
|
169
|
-
/** Whether the account was successfully deleted */
|
|
170
|
-
success: boolean;
|
|
171
|
-
/** Human-readable message about the deletion */
|
|
172
|
-
message: string;
|
|
173
|
-
}
|
|
174
163
|
/**
|
|
175
164
|
* Serializer for updating user profile.
|
|
176
165
|
*
|
|
177
166
|
* Request model (no read-only fields).
|
|
178
167
|
*/
|
|
179
|
-
interface
|
|
168
|
+
interface PatchedUserProfileUpdateRequest$1 {
|
|
180
169
|
first_name?: string;
|
|
181
170
|
last_name?: string;
|
|
182
171
|
company?: string;
|
|
@@ -184,12 +173,20 @@ interface UserProfileUpdateRequest$1 {
|
|
|
184
173
|
position?: string;
|
|
185
174
|
language?: string;
|
|
186
175
|
}
|
|
176
|
+
/**
|
|
177
|
+
*
|
|
178
|
+
* Request model (no read-only fields).
|
|
179
|
+
*/
|
|
180
|
+
interface CfgAccountsProfileAvatarCreateRequest$1 {
|
|
181
|
+
/** Avatar image file (JPEG, PNG, GIF, WebP, max 5MB) */
|
|
182
|
+
avatar: File | Blob;
|
|
183
|
+
}
|
|
187
184
|
/**
|
|
188
185
|
* Serializer for updating user profile.
|
|
189
186
|
*
|
|
190
187
|
* Request model (no read-only fields).
|
|
191
188
|
*/
|
|
192
|
-
interface
|
|
189
|
+
interface UserProfileUpdateRequest$1 {
|
|
193
190
|
first_name?: string;
|
|
194
191
|
last_name?: string;
|
|
195
192
|
company?: string;
|
|
@@ -228,12 +225,15 @@ interface User$2 {
|
|
|
228
225
|
centrifugo: CentrifugoToken$1 | null;
|
|
229
226
|
}
|
|
230
227
|
/**
|
|
228
|
+
* Response serializer for account deletion.
|
|
231
229
|
*
|
|
232
|
-
*
|
|
230
|
+
* Response model (includes read-only fields).
|
|
233
231
|
*/
|
|
234
|
-
interface
|
|
235
|
-
/**
|
|
236
|
-
|
|
232
|
+
interface AccountDeleteResponse$1 {
|
|
233
|
+
/** Whether the account was successfully deleted */
|
|
234
|
+
success: boolean;
|
|
235
|
+
/** Human-readable message about the deletion */
|
|
236
|
+
message: string;
|
|
237
237
|
}
|
|
238
238
|
/**
|
|
239
239
|
* Nested serializer for Centrifugo WebSocket connection token.
|
|
@@ -319,6 +319,18 @@ interface OTPRequestRequest$1 {
|
|
|
319
319
|
/** Source URL for tracking registration (e.g., https://my.djangocfg.com) */
|
|
320
320
|
source_url?: string;
|
|
321
321
|
}
|
|
322
|
+
/**
|
|
323
|
+
* Serializer for OTP verification.
|
|
324
|
+
*
|
|
325
|
+
* Request model (no read-only fields).
|
|
326
|
+
*/
|
|
327
|
+
interface OTPVerifyRequest$1 {
|
|
328
|
+
/** Email address used for OTP request */
|
|
329
|
+
identifier: string;
|
|
330
|
+
otp: string;
|
|
331
|
+
/** Source URL for tracking login (e.g., https://my.djangocfg.com) */
|
|
332
|
+
source_url?: string;
|
|
333
|
+
}
|
|
322
334
|
/**
|
|
323
335
|
* OTP request response.
|
|
324
336
|
*
|
|
@@ -349,18 +361,6 @@ interface OTPVerifyResponse$1 {
|
|
|
349
361
|
/** Whether user should be prompted to enable 2FA */
|
|
350
362
|
should_prompt_2fa?: boolean;
|
|
351
363
|
}
|
|
352
|
-
/**
|
|
353
|
-
* Serializer for OTP verification.
|
|
354
|
-
*
|
|
355
|
-
* Request model (no read-only fields).
|
|
356
|
-
*/
|
|
357
|
-
interface OTPVerifyRequest$1 {
|
|
358
|
-
/** Email address used for OTP request */
|
|
359
|
-
identifier: string;
|
|
360
|
-
otp: string;
|
|
361
|
-
/** Source URL for tracking login (e.g., https://my.djangocfg.com) */
|
|
362
|
-
source_url?: string;
|
|
363
|
-
}
|
|
364
364
|
/**
|
|
365
365
|
* Serializer for user details.
|
|
366
366
|
*
|