@djangocfg/api 2.1.225 → 2.1.226
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 +270 -270
- package/dist/clients.d.ts +270 -270
- package/dist/hooks.d.cts +76 -76
- package/dist/hooks.d.ts +76 -76
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +105 -105
- package/dist/index.d.ts +105 -105
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
- package/src/_api/generated/cfg_accounts/accounts/models.ts +27 -27
- package/src/_api/generated/cfg_accounts/accounts__auth/models.ts +5 -5
- package/src/_api/generated/cfg_accounts/accounts__oauth/models.ts +55 -55
- package/src/_api/generated/cfg_accounts/accounts__user_profile/models.ts +24 -24
- package/src/_api/generated/cfg_centrifugo/centrifugo__centrifugo_admin_api/models.ts +108 -108
- package/src/_api/generated/cfg_centrifugo/centrifugo__centrifugo_monitoring/models.ts +39 -39
- package/src/_api/generated/cfg_centrifugo/centrifugo__centrifugo_testing/models.ts +14 -14
- package/src/_api/generated/cfg_totp/totp__backup_codes/models.ts +10 -10
- package/src/_api/generated/cfg_totp/totp__totp_management/models.ts +10 -10
- package/src/_api/generated/cfg_totp/totp__totp_setup/models.ts +13 -13
- package/src/_api/generated/cfg_totp/totp__totp_verification/models.ts +8 -8
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
|
|
|
@@ -48,48 +48,37 @@ declare enum OTPRequestRequestChannel {
|
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
/**
|
|
51
|
-
* Request to
|
|
51
|
+
* Request to disconnect OAuth provider.
|
|
52
52
|
*
|
|
53
53
|
* Request model (no read-only fields).
|
|
54
54
|
*/
|
|
55
|
-
interface
|
|
56
|
-
/**
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
55
|
+
interface OAuthDisconnectRequestRequest$1 {
|
|
56
|
+
/** OAuth provider to disconnect
|
|
57
|
+
|
|
58
|
+
* `github` - GitHub */
|
|
59
|
+
provider: OAuthConnectionProvider;
|
|
60
60
|
}
|
|
61
61
|
/**
|
|
62
|
-
* Response with
|
|
62
|
+
* Response with OAuth authorization URL.
|
|
63
63
|
*
|
|
64
64
|
* Response model (includes read-only fields).
|
|
65
65
|
*/
|
|
66
|
-
interface
|
|
67
|
-
/**
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* Request to complete OAuth flow (callback handler).
|
|
72
|
-
*
|
|
73
|
-
* Request model (no read-only fields).
|
|
74
|
-
*/
|
|
75
|
-
interface OAuthCallbackRequestRequest$1 {
|
|
76
|
-
/** Authorization code from OAuth provider callback */
|
|
77
|
-
code: string;
|
|
78
|
-
/** State token for CSRF verification (from authorize response) */
|
|
66
|
+
interface OAuthAuthorizeResponse$1 {
|
|
67
|
+
/** Full URL to redirect user to OAuth provider */
|
|
68
|
+
authorization_url: string;
|
|
69
|
+
/** State token for CSRF protection. Store this and verify on callback. */
|
|
79
70
|
state: string;
|
|
80
|
-
/** Same redirect_uri used in authorize request. If not provided, uses config's site_url + callback_path */
|
|
81
|
-
redirect_uri?: string;
|
|
82
71
|
}
|
|
83
72
|
/**
|
|
84
|
-
* Request to
|
|
73
|
+
* Request to start OAuth flow.
|
|
85
74
|
*
|
|
86
75
|
* Request model (no read-only fields).
|
|
87
76
|
*/
|
|
88
|
-
interface
|
|
89
|
-
/** OAuth
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
77
|
+
interface OAuthAuthorizeRequestRequest$1 {
|
|
78
|
+
/** URL to redirect after OAuth authorization. If not provided, uses config's site_url + callback_path */
|
|
79
|
+
redirect_uri?: string;
|
|
80
|
+
/** Optional source URL for registration tracking */
|
|
81
|
+
source_url?: string;
|
|
93
82
|
}
|
|
94
83
|
/**
|
|
95
84
|
* Response with JWT tokens after OAuth authentication. When 2FA is required: -
|
|
@@ -118,15 +107,26 @@ interface OAuthTokenResponse$1 {
|
|
|
118
107
|
should_prompt_2fa?: boolean;
|
|
119
108
|
}
|
|
120
109
|
/**
|
|
121
|
-
* Response with OAuth
|
|
110
|
+
* Response with available OAuth providers.
|
|
122
111
|
*
|
|
123
112
|
* Response model (includes read-only fields).
|
|
124
113
|
*/
|
|
125
|
-
interface
|
|
126
|
-
/**
|
|
127
|
-
|
|
128
|
-
|
|
114
|
+
interface OAuthProvidersResponse {
|
|
115
|
+
/** List of available OAuth providers */
|
|
116
|
+
providers: Array<Record<string, any>>;
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Request to complete OAuth flow (callback handler).
|
|
120
|
+
*
|
|
121
|
+
* Request model (no read-only fields).
|
|
122
|
+
*/
|
|
123
|
+
interface OAuthCallbackRequestRequest$1 {
|
|
124
|
+
/** Authorization code from OAuth provider callback */
|
|
125
|
+
code: string;
|
|
126
|
+
/** State token for CSRF verification (from authorize response) */
|
|
129
127
|
state: string;
|
|
128
|
+
/** Same redirect_uri used in authorize request. If not provided, uses config's site_url + callback_path */
|
|
129
|
+
redirect_uri?: string;
|
|
130
130
|
}
|
|
131
131
|
|
|
132
132
|
/**
|
|
@@ -169,6 +169,27 @@ declare class Oauth {
|
|
|
169
169
|
accountsOauthProvidersRetrieve(): Promise<OAuthProvidersResponse>;
|
|
170
170
|
}
|
|
171
171
|
|
|
172
|
+
/**
|
|
173
|
+
* Serializer for updating user profile.
|
|
174
|
+
*
|
|
175
|
+
* Request model (no read-only fields).
|
|
176
|
+
*/
|
|
177
|
+
interface UserProfileUpdateRequest$1 {
|
|
178
|
+
first_name?: string;
|
|
179
|
+
last_name?: string;
|
|
180
|
+
company?: string;
|
|
181
|
+
phone?: string;
|
|
182
|
+
position?: string;
|
|
183
|
+
language?: string;
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
*
|
|
187
|
+
* Request model (no read-only fields).
|
|
188
|
+
*/
|
|
189
|
+
interface CfgAccountsProfileAvatarCreateRequest$1 {
|
|
190
|
+
/** Avatar image file (JPEG, PNG, GIF, WebP, max 5MB) */
|
|
191
|
+
avatar: File | Blob;
|
|
192
|
+
}
|
|
172
193
|
/**
|
|
173
194
|
* Serializer for user details.
|
|
174
195
|
*
|
|
@@ -204,7 +225,7 @@ interface User$2 {
|
|
|
204
225
|
*
|
|
205
226
|
* Request model (no read-only fields).
|
|
206
227
|
*/
|
|
207
|
-
interface
|
|
228
|
+
interface PatchedUserProfileUpdateRequest$1 {
|
|
208
229
|
first_name?: string;
|
|
209
230
|
last_name?: string;
|
|
210
231
|
company?: string;
|
|
@@ -212,14 +233,6 @@ interface UserProfileUpdateRequest$1 {
|
|
|
212
233
|
position?: string;
|
|
213
234
|
language?: string;
|
|
214
235
|
}
|
|
215
|
-
/**
|
|
216
|
-
*
|
|
217
|
-
* Request model (no read-only fields).
|
|
218
|
-
*/
|
|
219
|
-
interface CfgAccountsProfileAvatarCreateRequest$1 {
|
|
220
|
-
/** Avatar image file (JPEG, PNG, GIF, WebP, max 5MB) */
|
|
221
|
-
avatar: File | Blob;
|
|
222
|
-
}
|
|
223
236
|
/**
|
|
224
237
|
* Response serializer for account deletion.
|
|
225
238
|
*
|
|
@@ -231,19 +244,6 @@ interface AccountDeleteResponse$1 {
|
|
|
231
244
|
/** Human-readable message about the deletion */
|
|
232
245
|
message: string;
|
|
233
246
|
}
|
|
234
|
-
/**
|
|
235
|
-
* Serializer for updating user profile.
|
|
236
|
-
*
|
|
237
|
-
* Request model (no read-only fields).
|
|
238
|
-
*/
|
|
239
|
-
interface PatchedUserProfileUpdateRequest$1 {
|
|
240
|
-
first_name?: string;
|
|
241
|
-
last_name?: string;
|
|
242
|
-
company?: string;
|
|
243
|
-
phone?: string;
|
|
244
|
-
position?: string;
|
|
245
|
-
language?: string;
|
|
246
|
-
}
|
|
247
247
|
/**
|
|
248
248
|
* Nested serializer for Centrifugo WebSocket connection token.
|
|
249
249
|
*
|
|
@@ -317,6 +317,22 @@ declare class UserProfile {
|
|
|
317
317
|
accountsProfileUpdatePartialUpdate(data?: PatchedUserProfileUpdateRequest$1): Promise<User$2>;
|
|
318
318
|
}
|
|
319
319
|
|
|
320
|
+
/**
|
|
321
|
+
* Serializer for OTP request.
|
|
322
|
+
*
|
|
323
|
+
* Request model (no read-only fields).
|
|
324
|
+
*/
|
|
325
|
+
interface OTPRequestRequest$1 {
|
|
326
|
+
/** Email address or phone number for OTP delivery */
|
|
327
|
+
identifier: string;
|
|
328
|
+
/** Delivery channel: 'email' or 'phone'. Auto-detected if not provided.
|
|
329
|
+
|
|
330
|
+
* `email` - Email
|
|
331
|
+
* `phone` - Phone */
|
|
332
|
+
channel?: OTPRequestRequestChannel;
|
|
333
|
+
/** Source URL for tracking registration (e.g., https://my.djangocfg.com) */
|
|
334
|
+
source_url?: string;
|
|
335
|
+
}
|
|
320
336
|
/**
|
|
321
337
|
* OTP verification response. When 2FA is required: - requires_2fa: True -
|
|
322
338
|
* session_id: UUID of 2FA verification session - refresh/access/user: null
|
|
@@ -338,22 +354,6 @@ interface OTPVerifyResponse$1 {
|
|
|
338
354
|
/** Whether user should be prompted to enable 2FA */
|
|
339
355
|
should_prompt_2fa?: boolean;
|
|
340
356
|
}
|
|
341
|
-
/**
|
|
342
|
-
* Serializer for OTP request.
|
|
343
|
-
*
|
|
344
|
-
* Request model (no read-only fields).
|
|
345
|
-
*/
|
|
346
|
-
interface OTPRequestRequest$1 {
|
|
347
|
-
/** Email address or phone number for OTP delivery */
|
|
348
|
-
identifier: string;
|
|
349
|
-
/** Delivery channel: 'email' or 'phone'. Auto-detected if not provided.
|
|
350
|
-
|
|
351
|
-
* `email` - Email
|
|
352
|
-
* `phone` - Phone */
|
|
353
|
-
channel?: OTPRequestRequestChannel;
|
|
354
|
-
/** Source URL for tracking registration (e.g., https://my.djangocfg.com) */
|
|
355
|
-
source_url?: string;
|
|
356
|
-
}
|
|
357
357
|
/**
|
|
358
358
|
* OTP request response.
|
|
359
359
|
*
|
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
|
|
|
@@ -48,48 +48,37 @@ declare enum OTPRequestRequestChannel {
|
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
/**
|
|
51
|
-
* Request to
|
|
51
|
+
* Request to disconnect OAuth provider.
|
|
52
52
|
*
|
|
53
53
|
* Request model (no read-only fields).
|
|
54
54
|
*/
|
|
55
|
-
interface
|
|
56
|
-
/**
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
55
|
+
interface OAuthDisconnectRequestRequest$1 {
|
|
56
|
+
/** OAuth provider to disconnect
|
|
57
|
+
|
|
58
|
+
* `github` - GitHub */
|
|
59
|
+
provider: OAuthConnectionProvider;
|
|
60
60
|
}
|
|
61
61
|
/**
|
|
62
|
-
* Response with
|
|
62
|
+
* Response with OAuth authorization URL.
|
|
63
63
|
*
|
|
64
64
|
* Response model (includes read-only fields).
|
|
65
65
|
*/
|
|
66
|
-
interface
|
|
67
|
-
/**
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* Request to complete OAuth flow (callback handler).
|
|
72
|
-
*
|
|
73
|
-
* Request model (no read-only fields).
|
|
74
|
-
*/
|
|
75
|
-
interface OAuthCallbackRequestRequest$1 {
|
|
76
|
-
/** Authorization code from OAuth provider callback */
|
|
77
|
-
code: string;
|
|
78
|
-
/** State token for CSRF verification (from authorize response) */
|
|
66
|
+
interface OAuthAuthorizeResponse$1 {
|
|
67
|
+
/** Full URL to redirect user to OAuth provider */
|
|
68
|
+
authorization_url: string;
|
|
69
|
+
/** State token for CSRF protection. Store this and verify on callback. */
|
|
79
70
|
state: string;
|
|
80
|
-
/** Same redirect_uri used in authorize request. If not provided, uses config's site_url + callback_path */
|
|
81
|
-
redirect_uri?: string;
|
|
82
71
|
}
|
|
83
72
|
/**
|
|
84
|
-
* Request to
|
|
73
|
+
* Request to start OAuth flow.
|
|
85
74
|
*
|
|
86
75
|
* Request model (no read-only fields).
|
|
87
76
|
*/
|
|
88
|
-
interface
|
|
89
|
-
/** OAuth
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
77
|
+
interface OAuthAuthorizeRequestRequest$1 {
|
|
78
|
+
/** URL to redirect after OAuth authorization. If not provided, uses config's site_url + callback_path */
|
|
79
|
+
redirect_uri?: string;
|
|
80
|
+
/** Optional source URL for registration tracking */
|
|
81
|
+
source_url?: string;
|
|
93
82
|
}
|
|
94
83
|
/**
|
|
95
84
|
* Response with JWT tokens after OAuth authentication. When 2FA is required: -
|
|
@@ -118,15 +107,26 @@ interface OAuthTokenResponse$1 {
|
|
|
118
107
|
should_prompt_2fa?: boolean;
|
|
119
108
|
}
|
|
120
109
|
/**
|
|
121
|
-
* Response with OAuth
|
|
110
|
+
* Response with available OAuth providers.
|
|
122
111
|
*
|
|
123
112
|
* Response model (includes read-only fields).
|
|
124
113
|
*/
|
|
125
|
-
interface
|
|
126
|
-
/**
|
|
127
|
-
|
|
128
|
-
|
|
114
|
+
interface OAuthProvidersResponse {
|
|
115
|
+
/** List of available OAuth providers */
|
|
116
|
+
providers: Array<Record<string, any>>;
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Request to complete OAuth flow (callback handler).
|
|
120
|
+
*
|
|
121
|
+
* Request model (no read-only fields).
|
|
122
|
+
*/
|
|
123
|
+
interface OAuthCallbackRequestRequest$1 {
|
|
124
|
+
/** Authorization code from OAuth provider callback */
|
|
125
|
+
code: string;
|
|
126
|
+
/** State token for CSRF verification (from authorize response) */
|
|
129
127
|
state: string;
|
|
128
|
+
/** Same redirect_uri used in authorize request. If not provided, uses config's site_url + callback_path */
|
|
129
|
+
redirect_uri?: string;
|
|
130
130
|
}
|
|
131
131
|
|
|
132
132
|
/**
|
|
@@ -169,6 +169,27 @@ declare class Oauth {
|
|
|
169
169
|
accountsOauthProvidersRetrieve(): Promise<OAuthProvidersResponse>;
|
|
170
170
|
}
|
|
171
171
|
|
|
172
|
+
/**
|
|
173
|
+
* Serializer for updating user profile.
|
|
174
|
+
*
|
|
175
|
+
* Request model (no read-only fields).
|
|
176
|
+
*/
|
|
177
|
+
interface UserProfileUpdateRequest$1 {
|
|
178
|
+
first_name?: string;
|
|
179
|
+
last_name?: string;
|
|
180
|
+
company?: string;
|
|
181
|
+
phone?: string;
|
|
182
|
+
position?: string;
|
|
183
|
+
language?: string;
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
*
|
|
187
|
+
* Request model (no read-only fields).
|
|
188
|
+
*/
|
|
189
|
+
interface CfgAccountsProfileAvatarCreateRequest$1 {
|
|
190
|
+
/** Avatar image file (JPEG, PNG, GIF, WebP, max 5MB) */
|
|
191
|
+
avatar: File | Blob;
|
|
192
|
+
}
|
|
172
193
|
/**
|
|
173
194
|
* Serializer for user details.
|
|
174
195
|
*
|
|
@@ -204,7 +225,7 @@ interface User$2 {
|
|
|
204
225
|
*
|
|
205
226
|
* Request model (no read-only fields).
|
|
206
227
|
*/
|
|
207
|
-
interface
|
|
228
|
+
interface PatchedUserProfileUpdateRequest$1 {
|
|
208
229
|
first_name?: string;
|
|
209
230
|
last_name?: string;
|
|
210
231
|
company?: string;
|
|
@@ -212,14 +233,6 @@ interface UserProfileUpdateRequest$1 {
|
|
|
212
233
|
position?: string;
|
|
213
234
|
language?: string;
|
|
214
235
|
}
|
|
215
|
-
/**
|
|
216
|
-
*
|
|
217
|
-
* Request model (no read-only fields).
|
|
218
|
-
*/
|
|
219
|
-
interface CfgAccountsProfileAvatarCreateRequest$1 {
|
|
220
|
-
/** Avatar image file (JPEG, PNG, GIF, WebP, max 5MB) */
|
|
221
|
-
avatar: File | Blob;
|
|
222
|
-
}
|
|
223
236
|
/**
|
|
224
237
|
* Response serializer for account deletion.
|
|
225
238
|
*
|
|
@@ -231,19 +244,6 @@ interface AccountDeleteResponse$1 {
|
|
|
231
244
|
/** Human-readable message about the deletion */
|
|
232
245
|
message: string;
|
|
233
246
|
}
|
|
234
|
-
/**
|
|
235
|
-
* Serializer for updating user profile.
|
|
236
|
-
*
|
|
237
|
-
* Request model (no read-only fields).
|
|
238
|
-
*/
|
|
239
|
-
interface PatchedUserProfileUpdateRequest$1 {
|
|
240
|
-
first_name?: string;
|
|
241
|
-
last_name?: string;
|
|
242
|
-
company?: string;
|
|
243
|
-
phone?: string;
|
|
244
|
-
position?: string;
|
|
245
|
-
language?: string;
|
|
246
|
-
}
|
|
247
247
|
/**
|
|
248
248
|
* Nested serializer for Centrifugo WebSocket connection token.
|
|
249
249
|
*
|
|
@@ -317,6 +317,22 @@ declare class UserProfile {
|
|
|
317
317
|
accountsProfileUpdatePartialUpdate(data?: PatchedUserProfileUpdateRequest$1): Promise<User$2>;
|
|
318
318
|
}
|
|
319
319
|
|
|
320
|
+
/**
|
|
321
|
+
* Serializer for OTP request.
|
|
322
|
+
*
|
|
323
|
+
* Request model (no read-only fields).
|
|
324
|
+
*/
|
|
325
|
+
interface OTPRequestRequest$1 {
|
|
326
|
+
/** Email address or phone number for OTP delivery */
|
|
327
|
+
identifier: string;
|
|
328
|
+
/** Delivery channel: 'email' or 'phone'. Auto-detected if not provided.
|
|
329
|
+
|
|
330
|
+
* `email` - Email
|
|
331
|
+
* `phone` - Phone */
|
|
332
|
+
channel?: OTPRequestRequestChannel;
|
|
333
|
+
/** Source URL for tracking registration (e.g., https://my.djangocfg.com) */
|
|
334
|
+
source_url?: string;
|
|
335
|
+
}
|
|
320
336
|
/**
|
|
321
337
|
* OTP verification response. When 2FA is required: - requires_2fa: True -
|
|
322
338
|
* session_id: UUID of 2FA verification session - refresh/access/user: null
|
|
@@ -338,22 +354,6 @@ interface OTPVerifyResponse$1 {
|
|
|
338
354
|
/** Whether user should be prompted to enable 2FA */
|
|
339
355
|
should_prompt_2fa?: boolean;
|
|
340
356
|
}
|
|
341
|
-
/**
|
|
342
|
-
* Serializer for OTP request.
|
|
343
|
-
*
|
|
344
|
-
* Request model (no read-only fields).
|
|
345
|
-
*/
|
|
346
|
-
interface OTPRequestRequest$1 {
|
|
347
|
-
/** Email address or phone number for OTP delivery */
|
|
348
|
-
identifier: string;
|
|
349
|
-
/** Delivery channel: 'email' or 'phone'. Auto-detected if not provided.
|
|
350
|
-
|
|
351
|
-
* `email` - Email
|
|
352
|
-
* `phone` - Phone */
|
|
353
|
-
channel?: OTPRequestRequestChannel;
|
|
354
|
-
/** Source URL for tracking registration (e.g., https://my.djangocfg.com) */
|
|
355
|
-
source_url?: string;
|
|
356
|
-
}
|
|
357
357
|
/**
|
|
358
358
|
* OTP request response.
|
|
359
359
|
*
|