@djangocfg/api 2.1.289 → 2.1.291

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.mjs CHANGED
@@ -11,6 +11,7 @@ var Auth = class {
11
11
  static {
12
12
  __name(this, "Auth");
13
13
  }
14
+ client;
14
15
  constructor(client) {
15
16
  this.client = client;
16
17
  }
@@ -28,6 +29,7 @@ var Oauth = class {
28
29
  static {
29
30
  __name(this, "Oauth");
30
31
  }
32
+ client;
31
33
  constructor(client) {
32
34
  this.client = client;
33
35
  }
@@ -85,6 +87,7 @@ var UserProfile = class {
85
87
  static {
86
88
  __name(this, "UserProfile");
87
89
  }
90
+ client;
88
91
  constructor(client) {
89
92
  this.client = client;
90
93
  }
@@ -167,6 +170,7 @@ var Accounts = class {
167
170
  static {
168
171
  __name(this, "Accounts");
169
172
  }
173
+ client;
170
174
  constructor(client) {
171
175
  this.client = client;
172
176
  }
@@ -360,6 +364,8 @@ var APILogger = class {
360
364
  static {
361
365
  __name(this, "APILogger");
362
366
  }
367
+ config;
368
+ consola;
363
369
  constructor(config = {}) {
364
370
  this.config = { ...DEFAULT_CONFIG, ...config };
365
371
  this.consola = config.consola || createConsola({
@@ -555,10 +561,20 @@ __name(withRetry, "withRetry");
555
561
 
556
562
  // src/_api/generated/cfg_accounts/client.ts
557
563
  var APIClient = class {
564
+ static {
565
+ __name(this, "APIClient");
566
+ }
567
+ baseUrl;
568
+ httpClient;
569
+ logger = null;
570
+ retryConfig = null;
571
+ tokenGetter = null;
572
+ // Sub-clients
573
+ auth;
574
+ oauth;
575
+ user_profile;
576
+ accounts;
558
577
  constructor(baseUrl, options) {
559
- this.logger = null;
560
- this.retryConfig = null;
561
- this.tokenGetter = null;
562
578
  this.baseUrl = baseUrl.replace(/\/$/, "");
563
579
  this.httpClient = options?.httpClient || new FetchAdapter();
564
580
  this.tokenGetter = options?.tokenGetter || null;
@@ -573,9 +589,6 @@ var APIClient = class {
573
589
  this.user_profile = new UserProfile(this);
574
590
  this.accounts = new Accounts(this);
575
591
  }
576
- static {
577
- __name(this, "APIClient");
578
- }
579
592
  /**
580
593
  * Get CSRF token from cookies (for SessionAuthentication).
581
594
  *
@@ -782,6 +795,7 @@ var LocalStorageAdapter = class {
782
795
  static {
783
796
  __name(this, "LocalStorageAdapter");
784
797
  }
798
+ logger;
785
799
  constructor(logger) {
786
800
  this.logger = logger;
787
801
  }
@@ -1688,10 +1702,22 @@ function detectLocale() {
1688
1702
  }
1689
1703
  __name(detectLocale, "detectLocale");
1690
1704
  var API = class {
1705
+ static {
1706
+ __name(this, "API");
1707
+ }
1708
+ baseUrl;
1709
+ _client;
1710
+ _token = null;
1711
+ _refreshToken = null;
1712
+ _locale = null;
1713
+ storage;
1714
+ options;
1715
+ // Sub-clients
1716
+ auth;
1717
+ oauth;
1718
+ user_profile;
1719
+ accounts;
1691
1720
  constructor(baseUrl, options) {
1692
- this._token = null;
1693
- this._refreshToken = null;
1694
- this._locale = null;
1695
1721
  this.baseUrl = baseUrl;
1696
1722
  this.options = options;
1697
1723
  const logger = options?.loggerConfig ? new APILogger(options.loggerConfig) : void 0;
@@ -1710,9 +1736,6 @@ var API = class {
1710
1736
  this.user_profile = this._client.user_profile;
1711
1737
  this.accounts = this._client.accounts;
1712
1738
  }
1713
- static {
1714
- __name(this, "API");
1715
- }
1716
1739
  _loadTokensFromStorage() {
1717
1740
  this._token = this.storage.getItem(TOKEN_KEY);
1718
1741
  this._refreshToken = this.storage.getItem(REFRESH_TOKEN_KEY);
@@ -1837,6 +1860,7 @@ var CentrifugoAuth = class {
1837
1860
  static {
1838
1861
  __name(this, "CentrifugoAuth");
1839
1862
  }
1863
+ client;
1840
1864
  constructor(client) {
1841
1865
  this.client = client;
1842
1866
  }
@@ -2024,6 +2048,8 @@ var APILogger2 = class {
2024
2048
  static {
2025
2049
  __name(this, "APILogger");
2026
2050
  }
2051
+ config;
2052
+ consola;
2027
2053
  constructor(config = {}) {
2028
2054
  this.config = { ...DEFAULT_CONFIG2, ...config };
2029
2055
  this.consola = config.consola || createConsola2({
@@ -2219,10 +2245,17 @@ __name(withRetry2, "withRetry");
2219
2245
 
2220
2246
  // src/_api/generated/cfg_centrifugo/client.ts
2221
2247
  var APIClient2 = class {
2248
+ static {
2249
+ __name(this, "APIClient");
2250
+ }
2251
+ baseUrl;
2252
+ httpClient;
2253
+ logger = null;
2254
+ retryConfig = null;
2255
+ tokenGetter = null;
2256
+ // Sub-clients
2257
+ centrifugo_auth;
2222
2258
  constructor(baseUrl, options) {
2223
- this.logger = null;
2224
- this.retryConfig = null;
2225
- this.tokenGetter = null;
2226
2259
  this.baseUrl = baseUrl.replace(/\/$/, "");
2227
2260
  this.httpClient = options?.httpClient || new FetchAdapter2();
2228
2261
  this.tokenGetter = options?.tokenGetter || null;
@@ -2234,9 +2267,6 @@ var APIClient2 = class {
2234
2267
  }
2235
2268
  this.centrifugo_auth = new CentrifugoAuth(this);
2236
2269
  }
2237
- static {
2238
- __name(this, "APIClient");
2239
- }
2240
2270
  /**
2241
2271
  * Get CSRF token from cookies (for SessionAuthentication).
2242
2272
  *
@@ -2443,6 +2473,7 @@ var LocalStorageAdapter2 = class {
2443
2473
  static {
2444
2474
  __name(this, "LocalStorageAdapter");
2445
2475
  }
2476
+ logger;
2446
2477
  constructor(logger) {
2447
2478
  this.logger = logger;
2448
2479
  }
@@ -2597,10 +2628,19 @@ function detectLocale2() {
2597
2628
  }
2598
2629
  __name(detectLocale2, "detectLocale");
2599
2630
  var API2 = class {
2631
+ static {
2632
+ __name(this, "API");
2633
+ }
2634
+ baseUrl;
2635
+ _client;
2636
+ _token = null;
2637
+ _refreshToken = null;
2638
+ _locale = null;
2639
+ storage;
2640
+ options;
2641
+ // Sub-clients
2642
+ centrifugo_auth;
2600
2643
  constructor(baseUrl, options) {
2601
- this._token = null;
2602
- this._refreshToken = null;
2603
- this._locale = null;
2604
2644
  this.baseUrl = baseUrl;
2605
2645
  this.options = options;
2606
2646
  const logger = options?.loggerConfig ? new APILogger2(options.loggerConfig) : void 0;
@@ -2616,9 +2656,6 @@ var API2 = class {
2616
2656
  this._injectAuthHeader();
2617
2657
  this.centrifugo_auth = this._client.centrifugo_auth;
2618
2658
  }
2619
- static {
2620
- __name(this, "API");
2621
- }
2622
2659
  _loadTokensFromStorage() {
2623
2660
  this._token = this.storage.getItem(TOKEN_KEY2);
2624
2661
  this._refreshToken = this.storage.getItem(REFRESH_TOKEN_KEY2);
@@ -2740,6 +2777,7 @@ var BackupCodes = class {
2740
2777
  static {
2741
2778
  __name(this, "BackupCodes");
2742
2779
  }
2780
+ client;
2743
2781
  constructor(client) {
2744
2782
  this.client = client;
2745
2783
  }
@@ -2765,6 +2803,7 @@ var TotpManagement = class {
2765
2803
  static {
2766
2804
  __name(this, "TotpManagement");
2767
2805
  }
2806
+ client;
2768
2807
  constructor(client) {
2769
2808
  this.client = client;
2770
2809
  }
@@ -2789,6 +2828,7 @@ var TotpSetup = class {
2789
2828
  static {
2790
2829
  __name(this, "TotpSetup");
2791
2830
  }
2831
+ client;
2792
2832
  constructor(client) {
2793
2833
  this.client = client;
2794
2834
  }
@@ -2815,6 +2855,7 @@ var TotpVerification = class {
2815
2855
  static {
2816
2856
  __name(this, "TotpVerification");
2817
2857
  }
2858
+ client;
2818
2859
  constructor(client) {
2819
2860
  this.client = client;
2820
2861
  }
@@ -2841,6 +2882,7 @@ var Totp = class {
2841
2882
  static {
2842
2883
  __name(this, "Totp");
2843
2884
  }
2885
+ client;
2844
2886
  constructor(client) {
2845
2887
  this.client = client;
2846
2888
  }
@@ -3025,6 +3067,8 @@ var APILogger3 = class {
3025
3067
  static {
3026
3068
  __name(this, "APILogger");
3027
3069
  }
3070
+ config;
3071
+ consola;
3028
3072
  constructor(config = {}) {
3029
3073
  this.config = { ...DEFAULT_CONFIG3, ...config };
3030
3074
  this.consola = config.consola || createConsola3({
@@ -3220,10 +3264,21 @@ __name(withRetry3, "withRetry");
3220
3264
 
3221
3265
  // src/_api/generated/cfg_totp/client.ts
3222
3266
  var APIClient3 = class {
3267
+ static {
3268
+ __name(this, "APIClient");
3269
+ }
3270
+ baseUrl;
3271
+ httpClient;
3272
+ logger = null;
3273
+ retryConfig = null;
3274
+ tokenGetter = null;
3275
+ // Sub-clients
3276
+ backup_codes;
3277
+ totp_management;
3278
+ totp_setup;
3279
+ totp_verification;
3280
+ totp;
3223
3281
  constructor(baseUrl, options) {
3224
- this.logger = null;
3225
- this.retryConfig = null;
3226
- this.tokenGetter = null;
3227
3282
  this.baseUrl = baseUrl.replace(/\/$/, "");
3228
3283
  this.httpClient = options?.httpClient || new FetchAdapter3();
3229
3284
  this.tokenGetter = options?.tokenGetter || null;
@@ -3239,9 +3294,6 @@ var APIClient3 = class {
3239
3294
  this.totp_verification = new TotpVerification(this);
3240
3295
  this.totp = new Totp(this);
3241
3296
  }
3242
- static {
3243
- __name(this, "APIClient");
3244
- }
3245
3297
  /**
3246
3298
  * Get CSRF token from cookies (for SessionAuthentication).
3247
3299
  *
@@ -3448,6 +3500,7 @@ var LocalStorageAdapter3 = class {
3448
3500
  static {
3449
3501
  __name(this, "LocalStorageAdapter");
3450
3502
  }
3503
+ logger;
3451
3504
  constructor(logger) {
3452
3505
  this.logger = logger;
3453
3506
  }
@@ -4025,10 +4078,23 @@ function detectLocale3() {
4025
4078
  }
4026
4079
  __name(detectLocale3, "detectLocale");
4027
4080
  var API3 = class {
4081
+ static {
4082
+ __name(this, "API");
4083
+ }
4084
+ baseUrl;
4085
+ _client;
4086
+ _token = null;
4087
+ _refreshToken = null;
4088
+ _locale = null;
4089
+ storage;
4090
+ options;
4091
+ // Sub-clients
4092
+ backup_codes;
4093
+ totp_management;
4094
+ totp_setup;
4095
+ totp_verification;
4096
+ totp;
4028
4097
  constructor(baseUrl, options) {
4029
- this._token = null;
4030
- this._refreshToken = null;
4031
- this._locale = null;
4032
4098
  this.baseUrl = baseUrl;
4033
4099
  this.options = options;
4034
4100
  const logger = options?.loggerConfig ? new APILogger3(options.loggerConfig) : void 0;
@@ -4048,9 +4114,6 @@ var API3 = class {
4048
4114
  this.totp_verification = this._client.totp_verification;
4049
4115
  this.totp = this._client.totp;
4050
4116
  }
4051
- static {
4052
- __name(this, "API");
4053
- }
4054
4117
  _loadTokensFromStorage() {
4055
4118
  this._token = this.storage.getItem(TOKEN_KEY3);
4056
4119
  this._refreshToken = this.storage.getItem(REFRESH_TOKEN_KEY3);