@bitwarden/commercial-sdk-internal 0.2.0-main.486 → 0.2.0-main.488

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.
@@ -180,6 +180,10 @@ export interface TokenProvider {
180
180
  get_access_token(): Promise<string | undefined>;
181
181
  }
182
182
 
183
+ export interface IndexedDbConfiguration {
184
+ db_name: string;
185
+ }
186
+
183
187
  export interface Repositories {
184
188
  cipher: Repository<Cipher> | null;
185
189
  folder: Repository<Folder> | null;
@@ -190,22 +194,6 @@ export interface Repositories {
190
194
  */
191
195
  export interface FeatureFlags extends Map<string, boolean> {}
192
196
 
193
- export interface IndexedDbConfiguration {
194
- db_name: string;
195
- }
196
-
197
- /**
198
- * Credentials for sending password secured access requests.
199
- * Clone auto implements the standard lib\'s Clone trait, allowing us to create copies of this
200
- * struct.
201
- */
202
- export interface SendPasswordCredentials {
203
- /**
204
- * A Base64-encoded hash of the password protecting the send.
205
- */
206
- passwordHashB64: string;
207
- }
208
-
209
197
  /**
210
198
  * Credentials for getting a send access token using an email and OTP.
211
199
  */
@@ -220,6 +208,14 @@ export interface SendEmailOtpCredentials {
220
208
  otp: string;
221
209
  }
222
210
 
211
+ /**
212
+ * The credentials used for send access requests.
213
+ */
214
+ export type SendAccessCredentials =
215
+ | SendPasswordCredentials
216
+ | SendEmailOtpCredentials
217
+ | SendEmailCredentials;
218
+
223
219
  /**
224
220
  * Credentials for sending an OTP to the user\'s email address.
225
221
  * This is used when the send requires email verification with an OTP.
@@ -231,6 +227,18 @@ export interface SendEmailCredentials {
231
227
  email: string;
232
228
  }
233
229
 
230
+ /**
231
+ * Credentials for sending password secured access requests.
232
+ * Clone auto implements the standard lib\'s Clone trait, allowing us to create copies of this
233
+ * struct.
234
+ */
235
+ export interface SendPasswordCredentials {
236
+ /**
237
+ * A Base64-encoded hash of the password protecting the send.
238
+ */
239
+ passwordHashB64: string;
240
+ }
241
+
234
242
  /**
235
243
  * A request structure for requesting a send access token from the API.
236
244
  */
@@ -245,14 +253,6 @@ export interface SendAccessTokenRequest {
245
253
  sendAccessCredentials?: SendAccessCredentials;
246
254
  }
247
255
 
248
- /**
249
- * The credentials used for send access requests.
250
- */
251
- export type SendAccessCredentials =
252
- | SendPasswordCredentials
253
- | SendEmailOtpCredentials
254
- | SendEmailCredentials;
255
-
256
256
  /**
257
257
  * Any unexpected error that occurs when making requests to identity. This could be
258
258
  * local/transport/decoding failure from the HTTP client (DNS/TLS/connect/read timeout,
@@ -263,14 +263,6 @@ export type SendAccessCredentials =
263
263
  */
264
264
  export type UnexpectedIdentityError = string;
265
265
 
266
- /**
267
- * Represents errors that can occur when requesting a send access token.
268
- * It includes expected and unexpected API errors.
269
- */
270
- export type SendAccessTokenError =
271
- | { kind: "unexpected"; data: UnexpectedIdentityError }
272
- | { kind: "expected"; data: SendAccessTokenApiErrorResponse };
273
-
274
266
  /**
275
267
  * A send access token which can be used to access a send.
276
268
  */
@@ -285,6 +277,35 @@ export interface SendAccessTokenResponse {
285
277
  expiresAt: number;
286
278
  }
287
279
 
280
+ /**
281
+ * Represents errors that can occur when requesting a send access token.
282
+ * It includes expected and unexpected API errors.
283
+ */
284
+ export type SendAccessTokenError =
285
+ | { kind: "unexpected"; data: UnexpectedIdentityError }
286
+ | { kind: "expected"; data: SendAccessTokenApiErrorResponse };
287
+
288
+ /**
289
+ * Invalid request errors - typically due to missing parameters.
290
+ */
291
+ export type SendAccessTokenInvalidRequestError =
292
+ | "send_id_required"
293
+ | "password_hash_b64_required"
294
+ | "email_required"
295
+ | "email_and_otp_required_otp_sent"
296
+ | "unknown";
297
+
298
+ /**
299
+ * Invalid grant errors - typically due to invalid credentials.
300
+ */
301
+ export type SendAccessTokenInvalidGrantError =
302
+ | "send_id_invalid"
303
+ | "password_hash_b64_invalid"
304
+ | "email_invalid"
305
+ | "otp_invalid"
306
+ | "otp_generation_failed"
307
+ | "unknown";
308
+
288
309
  /**
289
310
  * Represents the possible, expected errors that can occur when requesting a send access token.
290
311
  */
@@ -306,67 +327,41 @@ export type SendAccessTokenApiErrorResponse =
306
327
  | { error: "invalid_target"; error_description?: string };
307
328
 
308
329
  /**
309
- * Invalid grant errors - typically due to invalid credentials.
310
- */
311
- export type SendAccessTokenInvalidGrantError =
312
- | "send_id_invalid"
313
- | "password_hash_b64_invalid"
314
- | "email_invalid"
315
- | "otp_invalid"
316
- | "otp_generation_failed"
317
- | "unknown";
318
-
319
- /**
320
- * Invalid request errors - typically due to missing parameters.
321
- */
322
- export type SendAccessTokenInvalidRequestError =
323
- | "send_id_required"
324
- | "password_hash_b64_required"
325
- | "email_required"
326
- | "email_and_otp_required_otp_sent"
327
- | "unknown";
328
-
329
- /**
330
- * Request parameters for TDE (Trusted Device Encryption) registration.
330
+ * Result of JIT master password registration process.
331
331
  */
332
- export interface TdeRegistrationRequest {
333
- /**
334
- * Organization ID to enroll in
335
- */
336
- org_id: OrganizationId;
337
- /**
338
- * Organization\'s public key for encrypting the reset password key. This should be verified by
339
- * the client and not verifying may compromise the security of the user\'s account.
340
- */
341
- org_public_key: B64;
332
+ export interface JitMasterPasswordRegistrationResponse {
342
333
  /**
343
- * User ID for the account being initialized
334
+ * The account cryptographic state of the user
344
335
  */
345
- user_id: UserId;
336
+ account_cryptographic_state: WrappedAccountCryptographicState;
346
337
  /**
347
- * Device identifier for TDE enrollment
338
+ * The master password unlock data
348
339
  */
349
- device_identifier: string;
340
+ master_password_unlock: MasterPasswordUnlockData;
350
341
  /**
351
- * Whether to trust this device for TDE
342
+ * The decrypted user key.
352
343
  */
353
- trust_device: boolean;
344
+ user_key: B64;
354
345
  }
355
346
 
356
347
  /**
357
- * Result of JIT master password registration process.
348
+ * Result of Key Connector registration process.
358
349
  */
359
- export interface JitMasterPasswordRegistrationResponse {
350
+ export interface KeyConnectorRegistrationResult {
360
351
  /**
361
- * The account cryptographic state of the user
352
+ * The account cryptographic state of the user.
362
353
  */
363
354
  account_cryptographic_state: WrappedAccountCryptographicState;
364
355
  /**
365
- * The master password unlock data
356
+ * The key connector key used for unlocking.
366
357
  */
367
- master_password_unlock: MasterPasswordUnlockData;
358
+ key_connector_key: B64;
368
359
  /**
369
- * The decrypted user key.
360
+ * The encrypted user key, wrapped with the key connector key.
361
+ */
362
+ key_connector_key_wrapped_user_key: EncString;
363
+ /**
364
+ * The decrypted user key. This can be used to get the consuming client to an unlocked state.
370
365
  */
371
366
  user_key: B64;
372
367
  }
@@ -410,53 +405,69 @@ export interface JitMasterPasswordRegistrationRequest {
410
405
  reset_password_enroll: boolean;
411
406
  }
412
407
 
408
+ export interface RegistrationError extends Error {
409
+ name: "RegistrationError";
410
+ variant: "KeyConnectorApi" | "Api" | "Crypto";
411
+ }
412
+
413
+ export function isRegistrationError(error: any): error is RegistrationError;
414
+
413
415
  /**
414
- * Result of TDE registration process.
416
+ * Request parameters for TDE (Trusted Device Encryption) registration.
415
417
  */
416
- export interface TdeRegistrationResponse {
418
+ export interface TdeRegistrationRequest {
417
419
  /**
418
- * The account cryptographic state of the user
420
+ * Organization ID to enroll in
419
421
  */
420
- account_cryptographic_state: WrappedAccountCryptographicState;
422
+ org_id: OrganizationId;
421
423
  /**
422
- * The device key
424
+ * Organization\'s public key for encrypting the reset password key. This should be verified by
425
+ * the client and not verifying may compromise the security of the user\'s account.
423
426
  */
424
- device_key: B64;
427
+ org_public_key: B64;
425
428
  /**
426
- * The decrypted user key. This can be used to get the consuming client to an unlocked state.
429
+ * User ID for the account being initialized
427
430
  */
428
- user_key: B64;
431
+ user_id: UserId;
432
+ /**
433
+ * Device identifier for TDE enrollment
434
+ */
435
+ device_identifier: string;
436
+ /**
437
+ * Whether to trust this device for TDE
438
+ */
439
+ trust_device: boolean;
429
440
  }
430
441
 
431
442
  /**
432
- * Result of Key Connector registration process.
443
+ * Result of TDE registration process.
433
444
  */
434
- export interface KeyConnectorRegistrationResult {
445
+ export interface TdeRegistrationResponse {
435
446
  /**
436
- * The account cryptographic state of the user.
447
+ * The account cryptographic state of the user
437
448
  */
438
449
  account_cryptographic_state: WrappedAccountCryptographicState;
439
450
  /**
440
- * The key connector key used for unlocking.
441
- */
442
- key_connector_key: B64;
443
- /**
444
- * The encrypted user key, wrapped with the key connector key.
451
+ * The device key
445
452
  */
446
- key_connector_key_wrapped_user_key: EncString;
453
+ device_key: B64;
447
454
  /**
448
455
  * The decrypted user key. This can be used to get the consuming client to an unlocked state.
449
456
  */
450
457
  user_key: B64;
451
458
  }
452
459
 
453
- export interface RegistrationError extends Error {
454
- name: "RegistrationError";
455
- variant: "KeyConnectorApi" | "Api" | "Crypto";
460
+ export interface CollectionView {
461
+ id: CollectionId | undefined;
462
+ organizationId: OrganizationId;
463
+ name: string;
464
+ externalId: string | undefined;
465
+ hidePasswords: boolean;
466
+ readOnly: boolean;
467
+ manage: boolean;
468
+ type: CollectionType;
456
469
  }
457
470
 
458
- export function isRegistrationError(error: any): error is RegistrationError;
459
-
460
471
  export interface Collection {
461
472
  id: CollectionId | undefined;
462
473
  organizationId: OrganizationId;
@@ -469,26 +480,15 @@ export interface Collection {
469
480
  type: CollectionType;
470
481
  }
471
482
 
472
- /**
473
- * Type of collection
474
- */
475
- export type CollectionType = "SharedCollection" | "DefaultUserCollection";
476
-
477
483
  /**
478
484
  * NewType wrapper for `CollectionId`
479
485
  */
480
486
  export type CollectionId = Tagged<Uuid, "CollectionId">;
481
487
 
482
- export interface CollectionView {
483
- id: CollectionId | undefined;
484
- organizationId: OrganizationId;
485
- name: string;
486
- externalId: string | undefined;
487
- hidePasswords: boolean;
488
- readOnly: boolean;
489
- manage: boolean;
490
- type: CollectionType;
491
- }
488
+ /**
489
+ * Type of collection
490
+ */
491
+ export type CollectionType = "SharedCollection" | "DefaultUserCollection";
492
492
 
493
493
  export interface CollectionDecryptError extends Error {
494
494
  name: "CollectionDecryptError";
@@ -554,6 +554,13 @@ export function isAccountCryptographyInitializationError(
554
554
  error: any,
555
555
  ): error is AccountCryptographyInitializationError;
556
556
 
557
+ export interface RotateCryptographyStateError extends Error {
558
+ name: "RotateCryptographyStateError";
559
+ variant: "KeyMissing" | "InvalidData";
560
+ }
561
+
562
+ export function isRotateCryptographyStateError(error: any): error is RotateCryptographyStateError;
563
+
557
564
  /**
558
565
  * Any keys / cryptographic protection \"downstream\" from the account symmetric key (user key).
559
566
  * Private keys are protected by the user key.
@@ -569,26 +576,12 @@ export type WrappedAccountCryptographicState =
569
576
  };
570
577
  };
571
578
 
572
- export interface RotateCryptographyStateError extends Error {
573
- name: "RotateCryptographyStateError";
574
- variant: "KeyMissing" | "InvalidData";
575
- }
576
-
577
- export function isRotateCryptographyStateError(error: any): error is RotateCryptographyStateError;
578
-
579
579
  /**
580
- * Response from the `make_update_password` function
580
+ * Auth requests supports multiple initialization methods.
581
581
  */
582
- export interface UpdatePasswordResponse {
583
- /**
584
- * Hash of the new password
585
- */
586
- passwordHash: B64;
587
- /**
588
- * User key, encrypted with the new password
589
- */
590
- newKey: EncString;
591
- }
582
+ export type AuthRequestMethod =
583
+ | { userKey: { protected_user_key: UnsignedSharedKey } }
584
+ | { masterKey: { protected_master_key: UnsignedSharedKey; auth_request_key: EncString } };
592
585
 
593
586
  /**
594
587
  * Request for `verify_asymmetric_keys`.
@@ -609,50 +602,58 @@ export interface VerifyAsymmetricKeysRequest {
609
602
  }
610
603
 
611
604
  /**
612
- * State used for initializing the user cryptographic state.
605
+ * Response for `verify_asymmetric_keys`.
613
606
  */
614
- export interface InitUserCryptoRequest {
615
- /**
616
- * The user\'s ID.
617
- */
618
- userId: UserId | undefined;
619
- /**
620
- * The user\'s KDF parameters, as received from the prelogin request
621
- */
622
- kdfParams: Kdf;
623
- /**
624
- * The user\'s email address
625
- */
626
- email: string;
607
+ export interface VerifyAsymmetricKeysResponse {
627
608
  /**
628
- * The user\'s account cryptographic state, containing their signature and
629
- * public-key-encryption keys, along with the signed security state, protected by the user key
609
+ * Whether the user\'s private key was decryptable by the user key.
630
610
  */
631
- accountCryptographicState: WrappedAccountCryptographicState;
611
+ privateKeyDecryptable: boolean;
632
612
  /**
633
- * The method to decrypt the user\'s account symmetric key (user key)
613
+ * Whether the user\'s private key was a valid RSA key and matched the public key provided.
634
614
  */
635
- method: InitUserCryptoMethod;
615
+ validPrivateKey: boolean;
636
616
  }
637
617
 
618
+ export interface DeriveKeyConnectorError extends Error {
619
+ name: "DeriveKeyConnectorError";
620
+ variant: "WrongPassword" | "Crypto";
621
+ }
622
+
623
+ export function isDeriveKeyConnectorError(error: any): error is DeriveKeyConnectorError;
624
+
638
625
  /**
639
- * Response from the `update_kdf` function
626
+ * Response from the `make_update_password` function
640
627
  */
641
- export interface UpdateKdfResponse {
642
- /**
643
- * The authentication data for the new KDF setting
644
- */
645
- masterPasswordAuthenticationData: MasterPasswordAuthenticationData;
628
+ export interface UpdatePasswordResponse {
646
629
  /**
647
- * The unlock data for the new KDF setting
630
+ * Hash of the new password
648
631
  */
649
- masterPasswordUnlockData: MasterPasswordUnlockData;
632
+ passwordHash: B64;
650
633
  /**
651
- * The authentication data for the KDF setting prior to the change
634
+ * User key, encrypted with the new password
652
635
  */
653
- oldMasterPasswordAuthenticationData: MasterPasswordAuthenticationData;
636
+ newKey: EncString;
637
+ }
638
+
639
+ export interface MakeKeysError extends Error {
640
+ name: "MakeKeysError";
641
+ variant:
642
+ | "AccountCryptographyInitialization"
643
+ | "MasterPasswordDerivation"
644
+ | "RequestModelCreation"
645
+ | "Crypto";
654
646
  }
655
647
 
648
+ export function isMakeKeysError(error: any): error is MakeKeysError;
649
+
650
+ export interface EnrollAdminPasswordResetError extends Error {
651
+ name: "EnrollAdminPasswordResetError";
652
+ variant: "Crypto";
653
+ }
654
+
655
+ export function isEnrollAdminPasswordResetError(error: any): error is EnrollAdminPasswordResetError;
656
+
656
657
  /**
657
658
  * The crypto method used to initialize the user cryptographic state.
658
659
  */
@@ -671,6 +672,41 @@ export type InitUserCryptoMethod =
671
672
  }
672
673
  | { keyConnector: { master_key: B64; user_key: EncString } };
673
674
 
675
+ export interface CryptoClientError extends Error {
676
+ name: "CryptoClientError";
677
+ variant: "NotAuthenticated" | "Crypto" | "InvalidKdfSettings" | "PasswordProtectedKeyEnvelope";
678
+ }
679
+
680
+ export function isCryptoClientError(error: any): error is CryptoClientError;
681
+
682
+ /**
683
+ * Request for deriving a pin protected user key
684
+ */
685
+ export interface DerivePinKeyResponse {
686
+ /**
687
+ * [UserKey] protected by PIN
688
+ */
689
+ pinProtectedUserKey: EncString;
690
+ /**
691
+ * PIN protected by [UserKey]
692
+ */
693
+ encryptedPin: EncString;
694
+ }
695
+
696
+ /**
697
+ * Request for deriving a pin protected user key
698
+ */
699
+ export interface EnrollPinResponse {
700
+ /**
701
+ * [UserKey] protected by PIN
702
+ */
703
+ pinProtectedUserKeyEnvelope: PasswordProtectedKeyEnvelope;
704
+ /**
705
+ * PIN protected by [UserKey]
706
+ */
707
+ userKeyEncryptedPin: EncString;
708
+ }
709
+
674
710
  /**
675
711
  * Response for the `make_keys_for_user_crypto_v2`, containing a set of keys for a user
676
712
  */
@@ -709,46 +745,22 @@ export interface UserCryptoV2KeysResponse {
709
745
  securityVersion: number;
710
746
  }
711
747
 
712
- export interface DeriveKeyConnectorError extends Error {
713
- name: "DeriveKeyConnectorError";
714
- variant: "WrongPassword" | "Crypto";
715
- }
716
-
717
- export function isDeriveKeyConnectorError(error: any): error is DeriveKeyConnectorError;
718
-
719
748
  /**
720
- * Request for deriving a pin protected user key
749
+ * Response from the `update_kdf` function
721
750
  */
722
- export interface DerivePinKeyResponse {
723
- /**
724
- * [UserKey] protected by PIN
725
- */
726
- pinProtectedUserKey: EncString;
751
+ export interface UpdateKdfResponse {
727
752
  /**
728
- * PIN protected by [UserKey]
753
+ * The authentication data for the new KDF setting
729
754
  */
730
- encryptedPin: EncString;
731
- }
732
-
733
- export interface CryptoClientError extends Error {
734
- name: "CryptoClientError";
735
- variant: "NotAuthenticated" | "Crypto" | "InvalidKdfSettings" | "PasswordProtectedKeyEnvelope";
736
- }
737
-
738
- export function isCryptoClientError(error: any): error is CryptoClientError;
739
-
740
- /**
741
- * Request for deriving a pin protected user key
742
- */
743
- export interface EnrollPinResponse {
755
+ masterPasswordAuthenticationData: MasterPasswordAuthenticationData;
744
756
  /**
745
- * [UserKey] protected by PIN
757
+ * The unlock data for the new KDF setting
746
758
  */
747
- pinProtectedUserKeyEnvelope: PasswordProtectedKeyEnvelope;
759
+ masterPasswordUnlockData: MasterPasswordUnlockData;
748
760
  /**
749
- * PIN protected by [UserKey]
761
+ * The authentication data for the KDF setting prior to the change
750
762
  */
751
- userKeyEncryptedPin: EncString;
763
+ oldMasterPasswordAuthenticationData: MasterPasswordAuthenticationData;
752
764
  }
753
765
 
754
766
  /**
@@ -773,45 +785,6 @@ export interface DeriveKeyConnectorRequest {
773
785
  email: string;
774
786
  }
775
787
 
776
- export interface MakeKeysError extends Error {
777
- name: "MakeKeysError";
778
- variant:
779
- | "AccountCryptographyInitialization"
780
- | "MasterPasswordDerivation"
781
- | "RequestModelCreation"
782
- | "Crypto";
783
- }
784
-
785
- export function isMakeKeysError(error: any): error is MakeKeysError;
786
-
787
- /**
788
- * Response for `verify_asymmetric_keys`.
789
- */
790
- export interface VerifyAsymmetricKeysResponse {
791
- /**
792
- * Whether the user\'s private key was decryptable by the user key.
793
- */
794
- privateKeyDecryptable: boolean;
795
- /**
796
- * Whether the user\'s private key was a valid RSA key and matched the public key provided.
797
- */
798
- validPrivateKey: boolean;
799
- }
800
-
801
- export interface EnrollAdminPasswordResetError extends Error {
802
- name: "EnrollAdminPasswordResetError";
803
- variant: "Crypto";
804
- }
805
-
806
- export function isEnrollAdminPasswordResetError(error: any): error is EnrollAdminPasswordResetError;
807
-
808
- /**
809
- * Auth requests supports multiple initialization methods.
810
- */
811
- export type AuthRequestMethod =
812
- | { userKey: { protected_user_key: UnsignedSharedKey } }
813
- | { masterKey: { protected_master_key: UnsignedSharedKey; auth_request_key: EncString } };
814
-
815
788
  /**
816
789
  * Response from the `make_key_pair` function
817
790
  */
@@ -837,15 +810,42 @@ export interface InitOrgCryptoRequest {
837
810
  }
838
811
 
839
812
  /**
840
- * NewType wrapper for `UserId`
813
+ * State used for initializing the user cryptographic state.
841
814
  */
842
- export type UserId = Tagged<Uuid, "UserId">;
815
+ export interface InitUserCryptoRequest {
816
+ /**
817
+ * The user\'s ID.
818
+ */
819
+ userId: UserId | undefined;
820
+ /**
821
+ * The user\'s KDF parameters, as received from the prelogin request
822
+ */
823
+ kdfParams: Kdf;
824
+ /**
825
+ * The user\'s email address
826
+ */
827
+ email: string;
828
+ /**
829
+ * The user\'s account cryptographic state, containing their signature and
830
+ * public-key-encryption keys, along with the signed security state, protected by the user key
831
+ */
832
+ accountCryptographicState: WrappedAccountCryptographicState;
833
+ /**
834
+ * The method to decrypt the user\'s account symmetric key (user key)
835
+ */
836
+ method: InitUserCryptoMethod;
837
+ }
843
838
 
844
839
  /**
845
840
  * NewType wrapper for `OrganizationId`
846
841
  */
847
842
  export type OrganizationId = Tagged<Uuid, "OrganizationId">;
848
843
 
844
+ /**
845
+ * NewType wrapper for `UserId`
846
+ */
847
+ export type UserId = Tagged<Uuid, "UserId">;
848
+
849
849
  export interface StatefulCryptoError extends Error {
850
850
  name: "StatefulCryptoError";
851
851
  variant: "MissingSecurityState" | "WrongAccountCryptoVersion" | "Crypto";
@@ -998,6 +998,8 @@ export interface RotateableKeySet {
998
998
  encryptedDecapsulationKey: EncString;
999
999
  }
1000
1000
 
1001
+ export type PublicKey = Tagged<string, "PublicKey">;
1002
+
1001
1003
  /**
1002
1004
  * Key Derivation Function for Bitwarden Account
1003
1005
  *
@@ -1109,6 +1111,13 @@ export interface PassphraseGeneratorRequest {
1109
1111
  includeNumber: boolean;
1110
1112
  }
1111
1113
 
1114
+ export interface PasswordError extends Error {
1115
+ name: "PasswordError";
1116
+ variant: "NoCharacterSetEnabled" | "InvalidLength";
1117
+ }
1118
+
1119
+ export function isPasswordError(error: any): error is PasswordError;
1120
+
1112
1121
  /**
1113
1122
  * Password generator request options.
1114
1123
  */
@@ -1161,12 +1170,18 @@ export interface PasswordGeneratorRequest {
1161
1170
  minSpecial: number | undefined;
1162
1171
  }
1163
1172
 
1164
- export interface PasswordError extends Error {
1165
- name: "PasswordError";
1166
- variant: "NoCharacterSetEnabled" | "InvalidLength";
1173
+ export interface UsernameError extends Error {
1174
+ name: "UsernameError";
1175
+ variant: "InvalidApiKey" | "Unknown" | "ResponseContent" | "Reqwest";
1167
1176
  }
1168
1177
 
1169
- export function isPasswordError(error: any): error is PasswordError;
1178
+ export function isUsernameError(error: any): error is UsernameError;
1179
+
1180
+ export type UsernameGeneratorRequest =
1181
+ | { word: { capitalize: boolean; include_number: boolean } }
1182
+ | { subaddress: { type: AppendType; email: string } }
1183
+ | { catchall: { type: AppendType; domain: string } }
1184
+ | { forwarded: { service: ForwarderServiceType; website: string | undefined } };
1170
1185
 
1171
1186
  /**
1172
1187
  * Configures the email forwarding service to use.
@@ -1181,21 +1196,8 @@ export type ForwarderServiceType =
1181
1196
  | { forwardEmail: { api_token: string; domain: string } }
1182
1197
  | { simpleLogin: { api_key: string; base_url: string } };
1183
1198
 
1184
- export interface UsernameError extends Error {
1185
- name: "UsernameError";
1186
- variant: "InvalidApiKey" | "Unknown" | "ResponseContent" | "Reqwest";
1187
- }
1188
-
1189
- export function isUsernameError(error: any): error is UsernameError;
1190
-
1191
1199
  export type AppendType = "random" | { websiteName: { website: string } };
1192
1200
 
1193
- export type UsernameGeneratorRequest =
1194
- | { word: { capitalize: boolean; include_number: boolean } }
1195
- | { subaddress: { type: AppendType; email: string } }
1196
- | { catchall: { type: AppendType; domain: string } }
1197
- | { forwarded: { service: ForwarderServiceType; website: string | undefined } };
1198
-
1199
1201
  export interface ReceiveError extends Error {
1200
1202
  name: "ReceiveError";
1201
1203
  variant: "Channel" | "Timeout" | "Cancelled";
@@ -1257,13 +1259,6 @@ export type Endpoint =
1257
1259
  | "DesktopRenderer"
1258
1260
  | "DesktopMain";
1259
1261
 
1260
- export interface KeyGenerationError extends Error {
1261
- name: "KeyGenerationError";
1262
- variant: "KeyGeneration" | "KeyConversion";
1263
- }
1264
-
1265
- export function isKeyGenerationError(error: any): error is KeyGenerationError;
1266
-
1267
1262
  export interface SshKeyExportError extends Error {
1268
1263
  name: "SshKeyExportError";
1269
1264
  variant: "KeyConversion";
@@ -1271,10 +1266,17 @@ export interface SshKeyExportError extends Error {
1271
1266
 
1272
1267
  export function isSshKeyExportError(error: any): error is SshKeyExportError;
1273
1268
 
1274
- export interface SshKeyImportError extends Error {
1275
- name: "SshKeyImportError";
1276
- variant: "Parsing" | "PasswordRequired" | "WrongPassword" | "UnsupportedKeyType";
1277
- }
1269
+ export interface KeyGenerationError extends Error {
1270
+ name: "KeyGenerationError";
1271
+ variant: "KeyGeneration" | "KeyConversion";
1272
+ }
1273
+
1274
+ export function isKeyGenerationError(error: any): error is KeyGenerationError;
1275
+
1276
+ export interface SshKeyImportError extends Error {
1277
+ name: "SshKeyImportError";
1278
+ variant: "Parsing" | "PasswordRequired" | "WrongPassword" | "UnsupportedKeyType";
1279
+ }
1278
1280
 
1279
1281
  export function isSshKeyImportError(error: any): error is SshKeyImportError;
1280
1282
 
@@ -1307,14 +1309,6 @@ export interface CipherRiskError extends Error {
1307
1309
 
1308
1310
  export function isCipherRiskError(error: any): error is CipherRiskError;
1309
1311
 
1310
- /**
1311
- * Result of checking password exposure via HIBP API.
1312
- */
1313
- export type ExposedPasswordResult =
1314
- | { type: "NotChecked" }
1315
- | { type: "Found"; value: number }
1316
- | { type: "Error"; value: string };
1317
-
1318
1312
  /**
1319
1313
  * Password reuse map wrapper for WASM compatibility.
1320
1314
  */
@@ -1386,6 +1380,14 @@ export interface CipherRiskOptions {
1386
1380
  hibpBaseUrl?: string | undefined;
1387
1381
  }
1388
1382
 
1383
+ /**
1384
+ * Result of checking password exposure via HIBP API.
1385
+ */
1386
+ export type ExposedPasswordResult =
1387
+ | { type: "NotChecked" }
1388
+ | { type: "Found"; value: number }
1389
+ | { type: "Error"; value: string };
1390
+
1389
1391
  export interface PasswordHistoryView {
1390
1392
  password: string;
1391
1393
  lastUsedDate: DateTime<Utc>;
@@ -1432,18 +1434,6 @@ export interface DecryptError extends Error {
1432
1434
 
1433
1435
  export function isDecryptError(error: any): error is DecryptError;
1434
1436
 
1435
- export interface Attachment {
1436
- id: string | undefined;
1437
- url: string | undefined;
1438
- size: string | undefined;
1439
- /**
1440
- * Readable size, ex: \"4.2 KB\" or \"1.43 GB\
1441
- */
1442
- sizeName: string | undefined;
1443
- fileName: EncString | undefined;
1444
- key: EncString | undefined;
1445
- }
1446
-
1447
1437
  export interface AttachmentView {
1448
1438
  id: string | undefined;
1449
1439
  url: string | undefined;
@@ -1466,12 +1456,24 @@ export interface AttachmentView {
1466
1456
  decryptedKey: string | undefined;
1467
1457
  }
1468
1458
 
1469
- export interface LocalData {
1459
+ export interface Attachment {
1460
+ id: string | undefined;
1461
+ url: string | undefined;
1462
+ size: string | undefined;
1463
+ /**
1464
+ * Readable size, ex: \"4.2 KB\" or \"1.43 GB\
1465
+ */
1466
+ sizeName: string | undefined;
1467
+ fileName: EncString | undefined;
1468
+ key: EncString | undefined;
1469
+ }
1470
+
1471
+ export interface LocalDataView {
1470
1472
  lastUsedDate: DateTime<Utc> | undefined;
1471
1473
  lastLaunched: DateTime<Utc> | undefined;
1472
1474
  }
1473
1475
 
1474
- export interface LocalDataView {
1476
+ export interface LocalData {
1475
1477
  lastUsedDate: DateTime<Utc> | undefined;
1476
1478
  lastLaunched: DateTime<Utc> | undefined;
1477
1479
  }
@@ -1571,6 +1573,13 @@ export interface RestoreCipherAdminError extends Error {
1571
1573
 
1572
1574
  export function isRestoreCipherAdminError(error: any): error is RestoreCipherAdminError;
1573
1575
 
1576
+ export interface CreateCipherError extends Error {
1577
+ name: "CreateCipherError";
1578
+ variant: "Crypto" | "Api" | "VaultParse" | "MissingField" | "NotAuthenticated" | "Repository";
1579
+ }
1580
+
1581
+ export function isCreateCipherError(error: any): error is CreateCipherError;
1582
+
1574
1583
  /**
1575
1584
  * Request to add a cipher.
1576
1585
  */
@@ -1586,13 +1595,6 @@ export interface CipherCreateRequest {
1586
1595
  fields: FieldView[];
1587
1596
  }
1588
1597
 
1589
- export interface CreateCipherError extends Error {
1590
- name: "CreateCipherError";
1591
- variant: "Crypto" | "Api" | "VaultParse" | "MissingField" | "NotAuthenticated" | "Repository";
1592
- }
1593
-
1594
- export function isCreateCipherError(error: any): error is CreateCipherError;
1595
-
1596
1598
  export interface DeleteCipherError extends Error {
1597
1599
  name: "DeleteCipherError";
1598
1600
  variant: "Api" | "Repository";
@@ -1617,13 +1619,6 @@ export type CipherViewType =
1617
1619
  | { secureNote: SecureNoteView }
1618
1620
  | { sshKey: SshKeyView };
1619
1621
 
1620
- export interface EncryptFileError extends Error {
1621
- name: "EncryptFileError";
1622
- variant: "Encrypt" | "Io";
1623
- }
1624
-
1625
- export function isEncryptFileError(error: any): error is EncryptFileError;
1626
-
1627
1622
  export interface DecryptFileError extends Error {
1628
1623
  name: "DecryptFileError";
1629
1624
  variant: "Decrypt" | "Io";
@@ -1631,18 +1626,25 @@ export interface DecryptFileError extends Error {
1631
1626
 
1632
1627
  export function isDecryptFileError(error: any): error is DecryptFileError;
1633
1628
 
1629
+ export interface EncryptFileError extends Error {
1630
+ name: "EncryptFileError";
1631
+ variant: "Encrypt" | "Io";
1632
+ }
1633
+
1634
+ export function isEncryptFileError(error: any): error is EncryptFileError;
1635
+
1634
1636
  export interface CipherPermissions {
1635
1637
  delete: boolean;
1636
1638
  restore: boolean;
1637
1639
  }
1638
1640
 
1639
- export interface CardView {
1640
- cardholderName: string | undefined;
1641
- expMonth: string | undefined;
1642
- expYear: string | undefined;
1643
- code: string | undefined;
1644
- brand: string | undefined;
1645
- number: string | undefined;
1641
+ export interface Card {
1642
+ cardholderName: EncString | undefined;
1643
+ expMonth: EncString | undefined;
1644
+ expYear: EncString | undefined;
1645
+ code: EncString | undefined;
1646
+ brand: EncString | undefined;
1647
+ number: EncString | undefined;
1646
1648
  }
1647
1649
 
1648
1650
  /**
@@ -1655,13 +1657,20 @@ export interface CardListView {
1655
1657
  brand: string | undefined;
1656
1658
  }
1657
1659
 
1658
- export interface Card {
1659
- cardholderName: EncString | undefined;
1660
- expMonth: EncString | undefined;
1661
- expYear: EncString | undefined;
1662
- code: EncString | undefined;
1663
- brand: EncString | undefined;
1664
- number: EncString | undefined;
1660
+ export interface CardView {
1661
+ cardholderName: string | undefined;
1662
+ expMonth: string | undefined;
1663
+ expYear: string | undefined;
1664
+ code: string | undefined;
1665
+ brand: string | undefined;
1666
+ number: string | undefined;
1667
+ }
1668
+
1669
+ export interface FieldView {
1670
+ name: string | undefined;
1671
+ value: string | undefined;
1672
+ type: FieldType;
1673
+ linkedId: LinkedIdType | undefined;
1665
1674
  }
1666
1675
 
1667
1676
  export interface Field {
@@ -1671,59 +1680,47 @@ export interface Field {
1671
1680
  linkedId: LinkedIdType | undefined;
1672
1681
  }
1673
1682
 
1674
- export interface FieldView {
1675
- name: string | undefined;
1676
- value: string | undefined;
1677
- type: FieldType;
1678
- linkedId: LinkedIdType | undefined;
1683
+ export interface Login {
1684
+ username: EncString | undefined;
1685
+ password: EncString | undefined;
1686
+ passwordRevisionDate: DateTime<Utc> | undefined;
1687
+ uris: LoginUri[] | undefined;
1688
+ totp: EncString | undefined;
1689
+ autofillOnPageLoad: boolean | undefined;
1690
+ fido2Credentials: Fido2Credential[] | undefined;
1679
1691
  }
1680
1692
 
1681
- export interface Fido2CredentialFullView {
1693
+ export interface Fido2CredentialListView {
1682
1694
  credentialId: string;
1683
- keyType: string;
1684
- keyAlgorithm: string;
1685
- keyCurve: string;
1686
- keyValue: string;
1687
1695
  rpId: string;
1688
1696
  userHandle: string | undefined;
1689
1697
  userName: string | undefined;
1690
- counter: string;
1691
- rpName: string | undefined;
1692
1698
  userDisplayName: string | undefined;
1693
- discoverable: string;
1694
- creationDate: DateTime<Utc>;
1699
+ counter: string;
1695
1700
  }
1696
1701
 
1697
- export interface Fido2CredentialNewView {
1702
+ export interface LoginUri {
1703
+ uri: EncString | undefined;
1704
+ match: UriMatchType | undefined;
1705
+ uriChecksum: EncString | undefined;
1706
+ }
1707
+
1708
+ export interface Fido2CredentialView {
1698
1709
  credentialId: string;
1699
1710
  keyType: string;
1700
1711
  keyAlgorithm: string;
1701
1712
  keyCurve: string;
1713
+ keyValue: EncString;
1702
1714
  rpId: string;
1703
1715
  userHandle: string | undefined;
1704
1716
  userName: string | undefined;
1705
1717
  counter: string;
1706
1718
  rpName: string | undefined;
1707
1719
  userDisplayName: string | undefined;
1720
+ discoverable: string;
1708
1721
  creationDate: DateTime<Utc>;
1709
1722
  }
1710
1723
 
1711
- export interface Login {
1712
- username: EncString | undefined;
1713
- password: EncString | undefined;
1714
- passwordRevisionDate: DateTime<Utc> | undefined;
1715
- uris: LoginUri[] | undefined;
1716
- totp: EncString | undefined;
1717
- autofillOnPageLoad: boolean | undefined;
1718
- fido2Credentials: Fido2Credential[] | undefined;
1719
- }
1720
-
1721
- export interface LoginUriView {
1722
- uri: string | undefined;
1723
- match: UriMatchType | undefined;
1724
- uriChecksum: string | undefined;
1725
- }
1726
-
1727
1724
  export interface LoginView {
1728
1725
  username: string | undefined;
1729
1726
  password: string | undefined;
@@ -1734,46 +1731,40 @@ export interface LoginView {
1734
1731
  fido2Credentials: Fido2Credential[] | undefined;
1735
1732
  }
1736
1733
 
1737
- export interface LoginListView {
1738
- fido2Credentials: Fido2CredentialListView[] | undefined;
1739
- hasFido2: boolean;
1740
- username: string | undefined;
1741
- /**
1742
- * The TOTP key is not decrypted. Useable as is with [`crate::generate_totp_cipher_view`].
1743
- */
1744
- totp: EncString | undefined;
1745
- uris: LoginUriView[] | undefined;
1746
- }
1747
-
1748
- export interface Fido2CredentialView {
1734
+ export interface Fido2CredentialNewView {
1749
1735
  credentialId: string;
1750
1736
  keyType: string;
1751
1737
  keyAlgorithm: string;
1752
1738
  keyCurve: string;
1753
- keyValue: EncString;
1754
1739
  rpId: string;
1755
1740
  userHandle: string | undefined;
1756
1741
  userName: string | undefined;
1757
1742
  counter: string;
1758
1743
  rpName: string | undefined;
1759
1744
  userDisplayName: string | undefined;
1760
- discoverable: string;
1761
1745
  creationDate: DateTime<Utc>;
1762
1746
  }
1763
1747
 
1764
- export interface LoginUri {
1765
- uri: EncString | undefined;
1748
+ export interface LoginUriView {
1749
+ uri: string | undefined;
1766
1750
  match: UriMatchType | undefined;
1767
- uriChecksum: EncString | undefined;
1751
+ uriChecksum: string | undefined;
1768
1752
  }
1769
1753
 
1770
- export interface Fido2CredentialListView {
1754
+ export interface Fido2CredentialFullView {
1771
1755
  credentialId: string;
1756
+ keyType: string;
1757
+ keyAlgorithm: string;
1758
+ keyCurve: string;
1759
+ keyValue: string;
1772
1760
  rpId: string;
1773
1761
  userHandle: string | undefined;
1774
1762
  userName: string | undefined;
1775
- userDisplayName: string | undefined;
1776
1763
  counter: string;
1764
+ rpName: string | undefined;
1765
+ userDisplayName: string | undefined;
1766
+ discoverable: string;
1767
+ creationDate: DateTime<Utc>;
1777
1768
  }
1778
1769
 
1779
1770
  export interface Fido2Credential {
@@ -1792,6 +1783,39 @@ export interface Fido2Credential {
1792
1783
  creationDate: DateTime<Utc>;
1793
1784
  }
1794
1785
 
1786
+ export interface LoginListView {
1787
+ fido2Credentials: Fido2CredentialListView[] | undefined;
1788
+ hasFido2: boolean;
1789
+ username: string | undefined;
1790
+ /**
1791
+ * The TOTP key is not decrypted. Useable as is with [`crate::generate_totp_cipher_view`].
1792
+ */
1793
+ totp: EncString | undefined;
1794
+ uris: LoginUriView[] | undefined;
1795
+ }
1796
+
1797
+ export interface CipherError extends Error {
1798
+ name: "CipherError";
1799
+ variant:
1800
+ | "MissingField"
1801
+ | "Crypto"
1802
+ | "Decrypt"
1803
+ | "Encrypt"
1804
+ | "AttachmentsWithoutKeys"
1805
+ | "OrganizationAlreadySet"
1806
+ | "Repository"
1807
+ | "Chrono"
1808
+ | "SerdeJson"
1809
+ | "Api";
1810
+ }
1811
+
1812
+ export function isCipherError(error: any): error is CipherError;
1813
+
1814
+ /**
1815
+ * NewType wrapper for `CipherId`
1816
+ */
1817
+ export type CipherId = Tagged<Uuid, "CipherId">;
1818
+
1795
1819
  export interface Cipher {
1796
1820
  id: CipherId | undefined;
1797
1821
  organizationId: OrganizationId | undefined;
@@ -1827,78 +1851,6 @@ export interface Cipher {
1827
1851
  data: string | undefined;
1828
1852
  }
1829
1853
 
1830
- /**
1831
- * Represents the result of decrypting a list of ciphers.
1832
- *
1833
- * This struct contains two vectors: `successes` and `failures`.
1834
- * `successes` contains the decrypted `CipherListView` objects,
1835
- * while `failures` contains the original `Cipher` objects that failed to decrypt.
1836
- */
1837
- export interface DecryptCipherListResult {
1838
- /**
1839
- * The decrypted `CipherListView` objects.
1840
- */
1841
- successes: CipherListView[];
1842
- /**
1843
- * The original `Cipher` objects that failed to decrypt.
1844
- */
1845
- failures: Cipher[];
1846
- }
1847
-
1848
- export interface CipherError extends Error {
1849
- name: "CipherError";
1850
- variant:
1851
- | "MissingField"
1852
- | "Crypto"
1853
- | "Decrypt"
1854
- | "Encrypt"
1855
- | "AttachmentsWithoutKeys"
1856
- | "OrganizationAlreadySet"
1857
- | "Repository"
1858
- | "Chrono"
1859
- | "SerdeJson"
1860
- | "Api";
1861
- }
1862
-
1863
- export function isCipherError(error: any): error is CipherError;
1864
-
1865
- /**
1866
- * NewType wrapper for `CipherId`
1867
- */
1868
- export type CipherId = Tagged<Uuid, "CipherId">;
1869
-
1870
- /**
1871
- * Available fields on a cipher and can be copied from a the list view in the UI.
1872
- */
1873
- export type CopyableCipherFields =
1874
- | "LoginUsername"
1875
- | "LoginPassword"
1876
- | "LoginTotp"
1877
- | "CardNumber"
1878
- | "CardSecurityCode"
1879
- | "IdentityUsername"
1880
- | "IdentityEmail"
1881
- | "IdentityPhone"
1882
- | "IdentityAddress"
1883
- | "SshKey"
1884
- | "SecureNotes";
1885
-
1886
- export interface EncryptionContext {
1887
- /**
1888
- * The Id of the user that encrypted the cipher. It should always represent a UserId, even for
1889
- * Organization-owned ciphers
1890
- */
1891
- encryptedFor: UserId;
1892
- cipher: Cipher;
1893
- }
1894
-
1895
- export type CipherListViewType =
1896
- | { login: LoginListView }
1897
- | "secureNote"
1898
- | { card: CardListView }
1899
- | "identity"
1900
- | "sshKey";
1901
-
1902
1854
  export interface CipherView {
1903
1855
  id: CipherId | undefined;
1904
1856
  organizationId: OrganizationId | undefined;
@@ -1932,6 +1884,31 @@ export interface CipherView {
1932
1884
  archivedDate: DateTime<Utc> | undefined;
1933
1885
  }
1934
1886
 
1887
+ /**
1888
+ * Available fields on a cipher and can be copied from a the list view in the UI.
1889
+ */
1890
+ export type CopyableCipherFields =
1891
+ | "LoginUsername"
1892
+ | "LoginPassword"
1893
+ | "LoginTotp"
1894
+ | "CardNumber"
1895
+ | "CardSecurityCode"
1896
+ | "IdentityUsername"
1897
+ | "IdentityEmail"
1898
+ | "IdentityPhone"
1899
+ | "IdentityAddress"
1900
+ | "SshKey"
1901
+ | "SecureNotes";
1902
+
1903
+ export interface EncryptionContext {
1904
+ /**
1905
+ * The Id of the user that encrypted the cipher. It should always represent a UserId, even for
1906
+ * Organization-owned ciphers
1907
+ */
1908
+ encryptedFor: UserId;
1909
+ cipher: Cipher;
1910
+ }
1911
+
1935
1912
  export interface CipherListView {
1936
1913
  id: CipherId | undefined;
1937
1914
  organizationId: OrganizationId | undefined;
@@ -1969,21 +1946,31 @@ export interface CipherListView {
1969
1946
  localData: LocalDataView | undefined;
1970
1947
  }
1971
1948
 
1972
- export interface SshKeyView {
1973
- /**
1974
- * SSH private key (ed25519/rsa) in unencrypted openssh private key format [OpenSSH private key](https://github.com/openssh/openssh-portable/blob/master/PROTOCOL.key)
1975
- */
1976
- privateKey: string;
1949
+ /**
1950
+ * Represents the result of decrypting a list of ciphers.
1951
+ *
1952
+ * This struct contains two vectors: `successes` and `failures`.
1953
+ * `successes` contains the decrypted `CipherListView` objects,
1954
+ * while `failures` contains the original `Cipher` objects that failed to decrypt.
1955
+ */
1956
+ export interface DecryptCipherListResult {
1977
1957
  /**
1978
- * SSH public key (ed25519/rsa) according to [RFC4253](https://datatracker.ietf.org/doc/html/rfc4253#section-6.6)
1958
+ * The decrypted `CipherListView` objects.
1979
1959
  */
1980
- publicKey: string;
1960
+ successes: CipherListView[];
1981
1961
  /**
1982
- * SSH fingerprint using SHA256 in the format: `SHA256:BASE64_ENCODED_FINGERPRINT`
1962
+ * The original `Cipher` objects that failed to decrypt.
1983
1963
  */
1984
- fingerprint: string;
1964
+ failures: Cipher[];
1985
1965
  }
1986
1966
 
1967
+ export type CipherListViewType =
1968
+ | { login: LoginListView }
1969
+ | "secureNote"
1970
+ | { card: CardListView }
1971
+ | "identity"
1972
+ | "sshKey";
1973
+
1987
1974
  export interface SshKey {
1988
1975
  /**
1989
1976
  * SSH private key (ed25519/rsa) in unencrypted openssh private key format [OpenSSH private key](https://github.com/openssh/openssh-portable/blob/master/PROTOCOL.key)
@@ -1999,25 +1986,19 @@ export interface SshKey {
1999
1986
  fingerprint: EncString;
2000
1987
  }
2001
1988
 
2002
- export interface IdentityView {
2003
- title: string | undefined;
2004
- firstName: string | undefined;
2005
- middleName: string | undefined;
2006
- lastName: string | undefined;
2007
- address1: string | undefined;
2008
- address2: string | undefined;
2009
- address3: string | undefined;
2010
- city: string | undefined;
2011
- state: string | undefined;
2012
- postalCode: string | undefined;
2013
- country: string | undefined;
2014
- company: string | undefined;
2015
- email: string | undefined;
2016
- phone: string | undefined;
2017
- ssn: string | undefined;
2018
- username: string | undefined;
2019
- passportNumber: string | undefined;
2020
- licenseNumber: string | undefined;
1989
+ export interface SshKeyView {
1990
+ /**
1991
+ * SSH private key (ed25519/rsa) in unencrypted openssh private key format [OpenSSH private key](https://github.com/openssh/openssh-portable/blob/master/PROTOCOL.key)
1992
+ */
1993
+ privateKey: string;
1994
+ /**
1995
+ * SSH public key (ed25519/rsa) according to [RFC4253](https://datatracker.ietf.org/doc/html/rfc4253#section-6.6)
1996
+ */
1997
+ publicKey: string;
1998
+ /**
1999
+ * SSH fingerprint using SHA256 in the format: `SHA256:BASE64_ENCODED_FINGERPRINT`
2000
+ */
2001
+ fingerprint: string;
2021
2002
  }
2022
2003
 
2023
2004
  export interface Identity {
@@ -2041,25 +2022,46 @@ export interface Identity {
2041
2022
  licenseNumber: EncString | undefined;
2042
2023
  }
2043
2024
 
2044
- export type LinkedIdType = LoginLinkedIdType | CardLinkedIdType | IdentityLinkedIdType;
2025
+ export interface IdentityView {
2026
+ title: string | undefined;
2027
+ firstName: string | undefined;
2028
+ middleName: string | undefined;
2029
+ lastName: string | undefined;
2030
+ address1: string | undefined;
2031
+ address2: string | undefined;
2032
+ address3: string | undefined;
2033
+ city: string | undefined;
2034
+ state: string | undefined;
2035
+ postalCode: string | undefined;
2036
+ country: string | undefined;
2037
+ company: string | undefined;
2038
+ email: string | undefined;
2039
+ phone: string | undefined;
2040
+ ssn: string | undefined;
2041
+ username: string | undefined;
2042
+ passportNumber: string | undefined;
2043
+ licenseNumber: string | undefined;
2044
+ }
2045
2045
 
2046
- /**
2047
- * NewType wrapper for `FolderId`
2048
- */
2049
- export type FolderId = Tagged<Uuid, "FolderId">;
2046
+ export type LinkedIdType = LoginLinkedIdType | CardLinkedIdType | IdentityLinkedIdType;
2050
2047
 
2051
- export interface FolderView {
2048
+ export interface Folder {
2052
2049
  id: FolderId | undefined;
2053
- name: string;
2050
+ name: EncString;
2054
2051
  revisionDate: DateTime<Utc>;
2055
2052
  }
2056
2053
 
2057
- export interface Folder {
2054
+ export interface FolderView {
2058
2055
  id: FolderId | undefined;
2059
- name: EncString;
2056
+ name: string;
2060
2057
  revisionDate: DateTime<Utc>;
2061
2058
  }
2062
2059
 
2060
+ /**
2061
+ * NewType wrapper for `FolderId`
2062
+ */
2063
+ export type FolderId = Tagged<Uuid, "FolderId">;
2064
+
2063
2065
  export interface EditFolderError extends Error {
2064
2066
  name: "EditFolderError";
2065
2067
  variant: