@proconnect-gouv/proconnect.identite 16.0.0 → 17.1.0
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/CHANGELOG.md +24 -0
- package/dist/connectors/index.d.ts +7 -71
- package/dist/connectors/index.d.ts.map +1 -1
- package/dist/connectors/index.js +5 -14
- package/dist/managers/certification/process-certification-dirigeant.d.ts.map +1 -1
- package/dist/managers/organization/get-organization-info.d.ts.map +1 -1
- package/dist/repositories/authenticator/index.d.ts +1 -1
- package/dist/repositories/authenticator/index.js +1 -1
- package/dist/repositories/authenticator/rename-authenticator.d.ts +3 -0
- package/dist/repositories/authenticator/rename-authenticator.d.ts.map +1 -0
- package/dist/repositories/authenticator/rename-authenticator.js +14 -0
- package/dist/repositories/moderation/index.d.ts +0 -2
- package/dist/repositories/moderation/index.d.ts.map +1 -1
- package/dist/repositories/moderation/index.js +0 -2
- package/dist/repositories/organization/index.d.ts +0 -2
- package/dist/repositories/organization/index.d.ts.map +1 -1
- package/dist/repositories/organization/index.js +0 -2
- package/dist/repositories/user/create.d.ts +1 -0
- package/dist/repositories/user/create.d.ts.map +1 -1
- package/dist/repositories/user/find-by-email.d.ts +1 -0
- package/dist/repositories/user/find-by-email.d.ts.map +1 -1
- package/dist/repositories/user/find-by-id.d.ts +1 -0
- package/dist/repositories/user/find-by-id.d.ts.map +1 -1
- package/dist/repositories/user/find-by-magic-link-token.d.ts +1 -0
- package/dist/repositories/user/find-by-magic-link-token.d.ts.map +1 -1
- package/dist/repositories/user/get-by-id.d.ts +1 -0
- package/dist/repositories/user/get-by-id.d.ts.map +1 -1
- package/dist/repositories/user/index.d.ts +0 -1
- package/dist/repositories/user/index.d.ts.map +1 -1
- package/dist/repositories/user/index.js +0 -1
- package/dist/repositories/user/update.d.ts +1 -0
- package/dist/repositories/user/update.d.ts.map +1 -1
- package/dist/types/authenticator.d.ts.map +1 -1
- package/dist/types/user.d.ts +1 -0
- package/dist/types/user.d.ts.map +1 -1
- package/dist/types/user.js +1 -0
- package/package.json +2 -2
- package/src/connectors/index.ts +2 -17
- package/src/managers/certification/process-certification-dirigeant.ts +1 -2
- package/src/managers/organization/get-organization-info.ts +1 -2
- package/src/repositories/authenticator/index.ts +1 -1
- package/src/repositories/authenticator/rename-authenticator.test.ts +53 -0
- package/src/repositories/authenticator/rename-authenticator.ts +26 -0
- package/src/repositories/moderation/index.ts +0 -2
- package/src/repositories/organization/index.ts +0 -2
- package/src/repositories/user/create.test.ts +1 -0
- package/src/repositories/user/find-by-email.test.ts +1 -0
- package/src/repositories/user/find-by-id.test.ts +1 -0
- package/src/repositories/user/get-by-id.test.ts +1 -0
- package/src/repositories/user/index.ts +0 -1
- package/src/types/authenticator.ts +1 -7
- package/src/types/user.ts +1 -0
- package/testing/index.ts +2 -1
- package/dist/repositories/authenticator/update-authenticator.d.ts +0 -3
- package/dist/repositories/authenticator/update-authenticator.d.ts.map +0 -1
- package/dist/repositories/authenticator/update-authenticator.js +0 -13
- package/dist/repositories/email-deliverability-whitelist/find-email-in-deliverability-white-list.d.ts +0 -3
- package/dist/repositories/email-deliverability-whitelist/find-email-in-deliverability-white-list.d.ts.map +0 -1
- package/dist/repositories/email-deliverability-whitelist/find-email-in-deliverability-white-list.js +0 -15
- package/dist/repositories/email-deliverability-whitelist/index.d.ts +0 -2
- package/dist/repositories/email-deliverability-whitelist/index.d.ts.map +0 -1
- package/dist/repositories/email-deliverability-whitelist/index.js +0 -2
- package/dist/repositories/moderation/find-pending-moderation.d.ts +0 -20
- package/dist/repositories/moderation/find-pending-moderation.d.ts.map +0 -1
- package/dist/repositories/moderation/find-pending-moderation.js +0 -16
- package/dist/repositories/moderation/find-rejected-moderation.d.ts +0 -20
- package/dist/repositories/moderation/find-rejected-moderation.d.ts.map +0 -1
- package/dist/repositories/moderation/find-rejected-moderation.js +0 -17
- package/dist/repositories/organization/find-by-siret.d.ts +0 -3
- package/dist/repositories/organization/find-by-siret.d.ts.map +0 -1
- package/dist/repositories/organization/find-by-siret.js +0 -13
- package/dist/repositories/organization/find-pending-by-user-id.d.ts +0 -6
- package/dist/repositories/organization/find-pending-by-user-id.d.ts.map +0 -1
- package/dist/repositories/organization/find-pending-by-user-id.js +0 -18
- package/dist/repositories/user/find-by-reset-password-token.d.ts +0 -29
- package/dist/repositories/user/find-by-reset-password-token.d.ts.map +0 -1
- package/dist/repositories/user/find-by-reset-password-token.js +0 -12
- package/src/repositories/authenticator/update-authenticator.test.ts +0 -41
- package/src/repositories/authenticator/update-authenticator.ts +0 -29
- package/src/repositories/email-deliverability-whitelist/find-email-in-deliverability-white-list.test.ts +0 -45
- package/src/repositories/email-deliverability-whitelist/find-email-in-deliverability-white-list.ts +0 -24
- package/src/repositories/email-deliverability-whitelist/index.ts +0 -3
- package/src/repositories/moderation/find-pending-moderation.test.ts +0 -57
- package/src/repositories/moderation/find-pending-moderation.ts +0 -35
- package/src/repositories/moderation/find-rejected-moderation.test.ts +0 -57
- package/src/repositories/moderation/find-rejected-moderation.ts +0 -37
- package/src/repositories/organization/find-by-siret.test.ts +0 -35
- package/src/repositories/organization/find-by-siret.ts +0 -21
- package/src/repositories/organization/find-pending-by-user-id.test.ts +0 -51
- package/src/repositories/organization/find-pending-by-user-id.ts +0 -27
- package/src/repositories/user/find-by-reset-password-token.test.ts +0 -37
- package/src/repositories/user/find-by-reset-password-token.ts +0 -20
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# @proconnect-gouv/proconnect.identite
|
|
2
2
|
|
|
3
|
+
## 17.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#2424](https://github.com/proconnect-gouv/proconnect-identite/pull/2424) [`97bfc2c`](https://github.com/proconnect-gouv/proconnect-identite/commit/97bfc2ca795440d853f8e295f26f2be7a5048b67) Thanks [@rebeccadumazert](https://github.com/rebeccadumazert)! - Ajoute la colonne `users.totp_display_name`, le champ `totp_display_name` à `UserSchema` (`null` par défaut) et `authenticators.rename`, qui renomme une clé d'accès sans toucher à ses compteurs. La réinitialisation de la double authentification remet aussi ce nom à `null`.
|
|
8
|
+
|
|
9
|
+
## 17.0.0
|
|
10
|
+
|
|
11
|
+
### Major Changes
|
|
12
|
+
|
|
13
|
+
- [#2414](https://github.com/proconnect-gouv/proconnect-identite/pull/2414) [`1b8f27b`](https://github.com/proconnect-gouv/proconnect-identite/commit/1b8f27b1ebba511ae4fda064460e7f9d38d5fa88) Thanks [@douglasduteil](https://github.com/douglasduteil)! - Retire `findEmailInDeliverabilityWhiteListFactory` (`repositories/email-deliverability-whitelist`) et l'entrée `email_deliverability_whitelist` de `connectors` : la vérification de délivrabilité lit maintenant la base en Drizzle depuis l'application.
|
|
14
|
+
|
|
15
|
+
- [#2416](https://github.com/proconnect-gouv/proconnect-identite/pull/2416) [`34cded0`](https://github.com/proconnect-gouv/proconnect-identite/commit/34cded02cb672ca85f29718379f2a7dd54175fc3) Thanks [@douglasduteil](https://github.com/douglasduteil)! - Retire `findByResetPasswordTokenFactory` (`repositories/user`) et l'entrée `users.findByResetPasswordToken` de `connectors` : la réinitialisation de mot de passe lit maintenant la base en Drizzle depuis l'application.
|
|
16
|
+
|
|
17
|
+
- [#2419](https://github.com/proconnect-gouv/proconnect-identite/pull/2419) [`d60638e`](https://github.com/proconnect-gouv/proconnect-identite/commit/d60638e523dfd4018aa7b33367001c9181bad961) Thanks [@douglasduteil](https://github.com/douglasduteil)! - Retire `findBySiretFactory` (`repositories/organization`) et l'entrée `organizations.findBySiret` de `connectors` : la garde de navigation lit maintenant la base en Drizzle depuis l'application.
|
|
18
|
+
|
|
19
|
+
- [#2420](https://github.com/proconnect-gouv/proconnect-identite/pull/2420) [`3e728cb`](https://github.com/proconnect-gouv/proconnect-identite/commit/3e728cb5acd3254e3fef5665f32ac57dd45e2291) Thanks [@douglasduteil](https://github.com/douglasduteil)! - Retire `findPendingByUserIdFactory` (`repositories/organization`) et l'entrée `organizations.findPendingByUserId` de `connectors` : la page des organisations lit maintenant la base en Drizzle depuis l'application.
|
|
20
|
+
|
|
21
|
+
- [#2417](https://github.com/proconnect-gouv/proconnect-identite/pull/2417) [`678828a`](https://github.com/proconnect-gouv/proconnect-identite/commit/678828a72299c2b41f421aa048981c9fd6b73ad3) Thanks [@douglasduteil](https://github.com/douglasduteil)! - Retire `findPendingModerationFactory` (`repositories/moderation`) et l'entrée `moderations.findPending` de `connectors` : la décision d'adhésion lit maintenant la base en Drizzle depuis l'application.
|
|
22
|
+
|
|
23
|
+
- [#2418](https://github.com/proconnect-gouv/proconnect-identite/pull/2418) [`8577ae3`](https://github.com/proconnect-gouv/proconnect-identite/commit/8577ae3f1fe900d0a242e04d97755a7b4c96fc7d) Thanks [@douglasduteil](https://github.com/douglasduteil)! - Retire `findRejectedModerationFactory` (`repositories/moderation`) et l'entrée `moderations.findRejected` de `connectors` : la décision d'adhésion lit maintenant la base en Drizzle depuis l'application.
|
|
24
|
+
|
|
25
|
+
- [#2535](https://github.com/proconnect-gouv/proconnect-identite/pull/2535) [`83f822e`](https://github.com/proconnect-gouv/proconnect-identite/commit/83f822e5ff3f5b82071491b4baf16e36aab2cf81) Thanks [@douglasduteil](https://github.com/douglasduteil)! - Retire `updateAuthenticatorFactory` (`repositories/authenticator`), exposé aussi par `connectors` (`authenticators.update`). L'application identite met à jour le compteur d'une clé d'accès avec Drizzle.
|
|
26
|
+
|
|
3
27
|
## 16.0.0
|
|
4
28
|
|
|
5
29
|
### Major Changes
|
|
@@ -371,10 +371,7 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
371
371
|
deleteAllByUserId: (user_id: number) => Promise<boolean>;
|
|
372
372
|
find: (user_id: number, serialized_credential_id: string) => Promise<import("../types/authenticator.js").Authenticator | undefined>;
|
|
373
373
|
findByUserId: (user_id: number) => Promise<import("../types/authenticator.js").Authenticator[]>;
|
|
374
|
-
|
|
375
|
-
};
|
|
376
|
-
email_deliverability_whitelist: {
|
|
377
|
-
findEmailInDeliverabilityWhiteList: (email: string) => Promise<{} | undefined>;
|
|
374
|
+
rename: (user_id: number, credential_id: string, display_name: string | null) => Promise<import("../types/authenticator.js").Authenticator | undefined>;
|
|
378
375
|
};
|
|
379
376
|
email_domains: {
|
|
380
377
|
addDomain: ({ organization_id, domain, verification_type, }: {
|
|
@@ -418,42 +415,6 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
418
415
|
end_user_reason: string;
|
|
419
416
|
allow_editing: boolean;
|
|
420
417
|
} | undefined>;
|
|
421
|
-
findPending: ({ user_id, organization_id, type, }: {
|
|
422
|
-
user_id: number;
|
|
423
|
-
organization_id: number;
|
|
424
|
-
type: import("../types/moderation.js").ModerationType;
|
|
425
|
-
}) => Promise<{
|
|
426
|
-
id: number;
|
|
427
|
-
user_id: number;
|
|
428
|
-
organization_id: number;
|
|
429
|
-
ticket_id: string | null;
|
|
430
|
-
type: "non_verified_domain" | "organization_join_block";
|
|
431
|
-
created_at: Date;
|
|
432
|
-
moderated_at: Date | null;
|
|
433
|
-
comment: string | null;
|
|
434
|
-
moderated_by: string | null;
|
|
435
|
-
status: "accepted" | "pending" | "rejected" | "reopened" | "unknown";
|
|
436
|
-
end_user_reason: string;
|
|
437
|
-
allow_editing: boolean;
|
|
438
|
-
} | undefined>;
|
|
439
|
-
findRejected: ({ user_id, organization_id, type, }: {
|
|
440
|
-
user_id: number;
|
|
441
|
-
organization_id: number;
|
|
442
|
-
type: import("../types/moderation.js").ModerationType;
|
|
443
|
-
}) => Promise<{
|
|
444
|
-
id: number;
|
|
445
|
-
user_id: number;
|
|
446
|
-
organization_id: number;
|
|
447
|
-
ticket_id: string | null;
|
|
448
|
-
type: "non_verified_domain" | "organization_join_block";
|
|
449
|
-
created_at: Date;
|
|
450
|
-
moderated_at: Date | null;
|
|
451
|
-
comment: string | null;
|
|
452
|
-
moderated_by: string | null;
|
|
453
|
-
status: "accepted" | "pending" | "rejected" | "reopened" | "unknown";
|
|
454
|
-
end_user_reason: string;
|
|
455
|
-
allow_editing: boolean;
|
|
456
|
-
} | undefined>;
|
|
457
418
|
getById: (id: number) => Promise<import("../types/moderation.js").Moderation>;
|
|
458
419
|
reopen: ({ id, userEmail, cause, }: {
|
|
459
420
|
id: number;
|
|
@@ -499,15 +460,11 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
499
460
|
};
|
|
500
461
|
organizations: {
|
|
501
462
|
findById: (id: number) => Promise<import("../types/organization.js").Organization | undefined>;
|
|
502
|
-
findBySiret: (siret: string) => Promise<import("../types/organization.js").Organization | undefined>;
|
|
503
463
|
findByUserId: (userId: number) => Promise<(import("../types/organization.js").Organization & {
|
|
504
464
|
is_external: boolean;
|
|
505
465
|
verification_type: "domain" | "organization_dirigeant" | "code_sent_to_official_contact_email" | "imported_from_coop_mediation_numerique" | "imported_from_inclusion_connect" | "in_liste_dirigeants_rna" | "in_liste_dirigeants_rne" | "official_contact_email" | "ordre_professionnel_domain" | "proof_received" | "verified_by_coop_mediation_numerique" | "bypassed" | "domain_not_verified_yet" | "no_validation_means_available" | "no_verification_means_for_entreprise_unipersonnelle" | "no_verification_means_for_small_association" | "no_verification_means_for_small_organization";
|
|
506
466
|
verified_at: Date | null;
|
|
507
467
|
})[]>;
|
|
508
|
-
findPendingByUserId: (user_id: number) => Promise<(import("../types/organization.js").Organization & {
|
|
509
|
-
moderation_id: number;
|
|
510
|
-
})[]>;
|
|
511
468
|
getById: (id: number) => Promise<import("../types/organization.js").Organization>;
|
|
512
469
|
upsert: ({ siret, organizationInfo, }: {
|
|
513
470
|
siret: string;
|
|
@@ -568,6 +525,7 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
568
525
|
reset_password_sent_at: Date | null;
|
|
569
526
|
reset_password_token: string | null;
|
|
570
527
|
sign_in_count: number;
|
|
528
|
+
totp_display_name: string | null;
|
|
571
529
|
totp_key_verified_at: Date | null;
|
|
572
530
|
updated_at: Date;
|
|
573
531
|
verify_email_sent_at: Date | null;
|
|
@@ -595,6 +553,7 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
595
553
|
reset_password_sent_at: Date | null;
|
|
596
554
|
reset_password_token: string | null;
|
|
597
555
|
sign_in_count: number;
|
|
556
|
+
totp_display_name: string | null;
|
|
598
557
|
totp_key_verified_at: Date | null;
|
|
599
558
|
updated_at: Date;
|
|
600
559
|
verify_email_sent_at: Date | null;
|
|
@@ -622,6 +581,7 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
622
581
|
reset_password_sent_at: Date | null;
|
|
623
582
|
reset_password_token: string | null;
|
|
624
583
|
sign_in_count: number;
|
|
584
|
+
totp_display_name: string | null;
|
|
625
585
|
totp_key_verified_at: Date | null;
|
|
626
586
|
updated_at: Date;
|
|
627
587
|
verify_email_sent_at: Date | null;
|
|
@@ -649,33 +609,7 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
649
609
|
reset_password_sent_at: Date | null;
|
|
650
610
|
reset_password_token: string | null;
|
|
651
611
|
sign_in_count: number;
|
|
652
|
-
|
|
653
|
-
updated_at: Date;
|
|
654
|
-
verify_email_sent_at: Date | null;
|
|
655
|
-
verify_email_token: string | null;
|
|
656
|
-
} | undefined>;
|
|
657
|
-
findByResetPasswordToken: (reset_password_token: string) => Promise<{
|
|
658
|
-
created_at: Date;
|
|
659
|
-
current_challenge: string | null;
|
|
660
|
-
email: string;
|
|
661
|
-
email_verified: boolean;
|
|
662
|
-
email_verified_at: Date | null;
|
|
663
|
-
encrypted_password: string | null;
|
|
664
|
-
encrypted_totp_key: string | null;
|
|
665
|
-
family_name: string | null;
|
|
666
|
-
force_2fa: boolean;
|
|
667
|
-
given_name: string | null;
|
|
668
|
-
id: number;
|
|
669
|
-
job: string | null;
|
|
670
|
-
last_sign_in_at: Date | null;
|
|
671
|
-
magic_link_sent_at: Date | null;
|
|
672
|
-
magic_link_token: string | null;
|
|
673
|
-
needs_inclusionconnect_onboarding_help: boolean;
|
|
674
|
-
needs_inclusionconnect_welcome_page: boolean;
|
|
675
|
-
phone_number: string | null;
|
|
676
|
-
reset_password_sent_at: Date | null;
|
|
677
|
-
reset_password_token: string | null;
|
|
678
|
-
sign_in_count: number;
|
|
612
|
+
totp_display_name: string | null;
|
|
679
613
|
totp_key_verified_at: Date | null;
|
|
680
614
|
updated_at: Date;
|
|
681
615
|
verify_email_sent_at: Date | null;
|
|
@@ -703,6 +637,7 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
703
637
|
reset_password_sent_at: Date | null;
|
|
704
638
|
reset_password_token: string | null;
|
|
705
639
|
sign_in_count: number;
|
|
640
|
+
totp_display_name: string | null;
|
|
706
641
|
totp_key_verified_at: Date | null;
|
|
707
642
|
updated_at: Date;
|
|
708
643
|
verify_email_sent_at: Date | null;
|
|
@@ -730,6 +665,7 @@ export declare function createContext({ api_entreprise_client, api_insee_client,
|
|
|
730
665
|
reset_password_sent_at: Date | null;
|
|
731
666
|
reset_password_token: string | null;
|
|
732
667
|
sign_in_count: number;
|
|
668
|
+
totp_display_name: string | null;
|
|
733
669
|
totp_key_verified_at: Date | null;
|
|
734
670
|
updated_at: Date;
|
|
735
671
|
verify_email_sent_at: Date | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/connectors/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/connectors/index.ts"],"names":[],"mappings":"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"}
|
package/dist/connectors/index.js
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
//
|
|
2
|
-
import { createAuthenticatorFactory, deleteAllAuthenticatorsByUserIdFactory, deleteAuthenticatorFactory, findAuthenticatorFactory, findAuthenticatorsByUserIdFactory,
|
|
3
|
-
import { findEmailInDeliverabilityWhiteListFactory } from "#src/repositories/email-deliverability-whitelist";
|
|
2
|
+
import { createAuthenticatorFactory, deleteAllAuthenticatorsByUserIdFactory, deleteAuthenticatorFactory, findAuthenticatorFactory, findAuthenticatorsByUserIdFactory, renameAuthenticatorFactory, } from "#src/repositories/authenticator";
|
|
4
3
|
import { addDomainFactory, findEmailDomainsByOrganizationIdFactory, } from "#src/repositories/email-domain";
|
|
5
4
|
import { findFranceconnectUserinfoFactory } from "#src/repositories/franceconnect_userinfo";
|
|
6
|
-
import { deleteModerationFactory, findModerationByIdFactory,
|
|
5
|
+
import { deleteModerationFactory, findModerationByIdFactory, getModerationByIdFactory, reopenModerationFactory, } from "#src/repositories/moderation";
|
|
7
6
|
import { deleteOfficialContactEmailVerificationFactory, findOfficialContactEmailVerificationFactory, upsertOfficialContactEmailVerificationFactory, } from "#src/repositories/official-contact-email-verification";
|
|
8
7
|
import { findByClientIdFactory, upsertAuthorizationRequestFactory, } from "#src/repositories/oidc-client";
|
|
9
|
-
import {
|
|
8
|
+
import { findByUserIdFactory, findOrganizationByIdFactory, getOrganizationByIdFactory, upsertFactory, } from "#src/repositories/organization";
|
|
10
9
|
import { createRecoveryWordsFactory, deleteRecoveryWordsByUserIdFactory, findRecoveryWordsByUserIdFactory, } from "#src/repositories/recovery-words";
|
|
11
|
-
import { createUserFactory, findByEmailFactory, findByMagicLinkTokenFactory,
|
|
10
|
+
import { createUserFactory, findByEmailFactory, findByMagicLinkTokenFactory, findByIdFactory as findUserByIdFactory, getByIdFactory, updateUserFactory, } from "#src/repositories/user";
|
|
12
11
|
import { findUserOrganizationFactory, getUserOrganizationFactory, } from "#src/repositories/user_organisation";
|
|
13
12
|
import {} from "pg";
|
|
14
13
|
//
|
|
@@ -26,10 +25,7 @@ export function createContext({ api_entreprise_client, api_insee_client, api_reg
|
|
|
26
25
|
deleteAllByUserId: deleteAllAuthenticatorsByUserIdFactory({ pg }),
|
|
27
26
|
find: findAuthenticatorFactory({ pg }),
|
|
28
27
|
findByUserId: findAuthenticatorsByUserIdFactory({ pg }),
|
|
29
|
-
|
|
30
|
-
},
|
|
31
|
-
email_deliverability_whitelist: {
|
|
32
|
-
findEmailInDeliverabilityWhiteList: findEmailInDeliverabilityWhiteListFactory({ pg }),
|
|
28
|
+
rename: renameAuthenticatorFactory({ pg }),
|
|
33
29
|
},
|
|
34
30
|
email_domains: {
|
|
35
31
|
addDomain: addDomainFactory({ pg }),
|
|
@@ -38,8 +34,6 @@ export function createContext({ api_entreprise_client, api_insee_client, api_reg
|
|
|
38
34
|
moderations: {
|
|
39
35
|
delete: deleteModerationFactory({ pg }),
|
|
40
36
|
findById: findModerationByIdFactory({ pg }),
|
|
41
|
-
findPending: findPendingModerationFactory({ pg }),
|
|
42
|
-
findRejected: findRejectedModerationFactory({ pg }),
|
|
43
37
|
getById: getModerationByIdFactory({ pg }),
|
|
44
38
|
reopen: reopenModerationFactory({ pg }),
|
|
45
39
|
},
|
|
@@ -54,9 +48,7 @@ export function createContext({ api_entreprise_client, api_insee_client, api_reg
|
|
|
54
48
|
},
|
|
55
49
|
organizations: {
|
|
56
50
|
findById: findOrganizationByIdFactory({ pg }),
|
|
57
|
-
findBySiret: findBySiretFactory({ pg }),
|
|
58
51
|
findByUserId: findByUserIdFactory({ pg }),
|
|
59
|
-
findPendingByUserId: findPendingByUserIdFactory({ pg }),
|
|
60
52
|
getById: getOrganizationByIdFactory({ pg }),
|
|
61
53
|
upsert: upsertFactory({ pg }),
|
|
62
54
|
},
|
|
@@ -74,7 +66,6 @@ export function createContext({ api_entreprise_client, api_insee_client, api_reg
|
|
|
74
66
|
findByEmail: findByEmailFactory({ pg }),
|
|
75
67
|
findById: findUserByIdFactory({ pg }),
|
|
76
68
|
findByMagicLinkToken: findByMagicLinkTokenFactory({ pg }),
|
|
77
|
-
findByResetPasswordToken: findByResetPasswordTokenFactory({ pg }),
|
|
78
69
|
getById: getByIdFactory({ pg }),
|
|
79
70
|
update: updateUserFactory({ pg }),
|
|
80
71
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"process-certification-dirigeant.d.ts","sourceRoot":"","sources":["../../../src/managers/certification/process-certification-dirigeant.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE/C,OAAO,EAEL,KAAK,qBAAqB,EAC1B,KAAK,YAAY,EAClB,MAAM,YAAY,CAAC;AAEpB,OAAO,CAAC,MAAM,QAAQ,CAAC;AASvB,eAAO,MAAM,gCAAgC;;;;EAI3C,CAAC;AAEH,MAAM,MAAM,gCAAgC,GAAG,CAAC,CAAC,KAAK,CACpD,OAAO,gCAAgC,CACxC,CAAC;AAWF,wBAAgB,yCAAyC,CACvD,UAAU,EAAE,gCAAgC,UAG7C;AAID,MAAM,MAAM,eAAe,
|
|
1
|
+
{"version":3,"file":"process-certification-dirigeant.d.ts","sourceRoot":"","sources":["../../../src/managers/certification/process-certification-dirigeant.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE/C,OAAO,EAEL,KAAK,qBAAqB,EAC1B,KAAK,YAAY,EAClB,MAAM,YAAY,CAAC;AAEpB,OAAO,CAAC,MAAM,QAAQ,CAAC;AASvB,eAAO,MAAM,gCAAgC;;;;EAI3C,CAAC;AAEH,MAAM,MAAM,gCAAgC,GAAG,CAAC,CAAC,KAAK,CACpD,OAAO,gCAAgC,CACxC,CAAC;AAWF,wBAAgB,yCAAyC,CACvD,UAAU,EAAE,gCAAgC,UAG7C;AAID,MAAM,MAAM,eAAe,GACzB;IAAE,IAAI,EAAE,UAAU,CAAC;IAAC,SAAS,EAAE,OAAO,CAAA;CAAE,GAAG;IAAE,IAAI,EAAE,WAAW,CAAA;CAAE,CAAC;AAqCnE,wBAAgB,oCAAoC,CAAC,OAAO,EAAE,OAAO,IAMjE,cAAc,YAAY,EAC1B,wBAAwB,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4EhD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-organization-info.d.ts","sourceRoot":"","sources":["../../../src/managers/organization/get-organization-info.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,YAAY,CAAC;AACnD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,gDAAgD,CAAC;AAK1F,OAAO,KAAK,EAAE,oCAAoC,EAAE,MAAM,+DAA+D,CAAC;AAM1H,MAAM,MAAM,aAAa,
|
|
1
|
+
{"version":3,"file":"get-organization-info.d.ts","sourceRoot":"","sources":["../../../src/managers/organization/get-organization-info.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,YAAY,CAAC;AACnD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,gDAAgD,CAAC;AAK1F,OAAO,KAAK,EAAE,oCAAoC,EAAE,MAAM,+DAA+D,CAAC;AAM1H,MAAM,MAAM,aAAa,GACvB;IAAE,IAAI,EAAE,UAAU,CAAA;CAAE,GAAG;IAAE,IAAI,EAAE,QAAQ,CAAC;IAAC,SAAS,EAAE,OAAO,CAAA;CAAE,CAAC;AAEhE,MAAM,MAAM,sBAAsB,GAC9B;IAAE,IAAI,EAAE,uBAAuB,CAAC;IAAC,SAAS,EAAE,OAAO,CAAA;CAAE,GACrD;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,iBAAiB,EAAE,gBAAgB,CAAC;IAAC,GAAG,EAAE,aAAa,CAAA;CAAE,GAC1E;IAAE,IAAI,EAAE,eAAe,CAAC;IAAC,SAAS,EAAE,iBAAiB,CAAA;CAAE,GACvD;IAAE,IAAI,EAAE,gBAAgB,CAAA;CAAE,CAAC;AAE/B,wBAAgB,0BAA0B,CACxC,mBAAmB,EAAE,mBAAmB,EACxC,YAAY,EAAE,oCAAoC,IAShD,cAAc,MAAM,KACnB,OAAO,CAAC,sBAAsB,CAAC,CAoDnC;AAED,MAAM,MAAM,0BAA0B,GAAG,UAAU,CACjD,OAAO,0BAA0B,CAClC,CAAC"}
|
|
@@ -3,5 +3,5 @@ export * from "./delete-all-authenticators-by-user-id.js";
|
|
|
3
3
|
export * from "./delete-authenticator.js";
|
|
4
4
|
export * from "./find-authenticator.js";
|
|
5
5
|
export * from "./find-authenticators-by-user-id.js";
|
|
6
|
-
export * from "./
|
|
6
|
+
export * from "./rename-authenticator.js";
|
|
7
7
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -4,4 +4,4 @@ export * from "./delete-all-authenticators-by-user-id.js";
|
|
|
4
4
|
export * from "./delete-authenticator.js";
|
|
5
5
|
export * from "./find-authenticator.js";
|
|
6
6
|
export * from "./find-authenticators-by-user-id.js";
|
|
7
|
-
export * from "./
|
|
7
|
+
export * from "./rename-authenticator.js";
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { Authenticator, DatabaseContext } from "#src/types";
|
|
2
|
+
export declare function renameAuthenticatorFactory({ pg }: DatabaseContext): (user_id: number, credential_id: string, display_name: string | null) => Promise<Authenticator | undefined>;
|
|
3
|
+
//# sourceMappingURL=rename-authenticator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rename-authenticator.d.ts","sourceRoot":"","sources":["../../../src/repositories/authenticator/rename-authenticator.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAKjE,wBAAgB,0BAA0B,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IAE9D,SAAS,MAAM,EACf,eAAe,MAAM,EACrB,cAAc,MAAM,GAAG,IAAI,wCAc9B"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
//
|
|
2
|
+
import {} from "pg";
|
|
3
|
+
//
|
|
4
|
+
export function renameAuthenticatorFactory({ pg }) {
|
|
5
|
+
return async function renameAuthenticator(user_id, credential_id, display_name) {
|
|
6
|
+
const { rows } = await pg.query(`
|
|
7
|
+
UPDATE authenticators
|
|
8
|
+
SET display_name = $3
|
|
9
|
+
WHERE user_id = $1
|
|
10
|
+
AND credential_id = $2
|
|
11
|
+
RETURNING *`, [user_id, credential_id, display_name]);
|
|
12
|
+
return rows.shift();
|
|
13
|
+
};
|
|
14
|
+
}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
export * from "./delete-moderation.js";
|
|
2
2
|
export * from "./find-moderation-by-id.js";
|
|
3
|
-
export * from "./find-pending-moderation.js";
|
|
4
|
-
export * from "./find-rejected-moderation.js";
|
|
5
3
|
export * from "./get-moderation-by-id.js";
|
|
6
4
|
export * from "./reopen-moderation.js";
|
|
7
5
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/repositories/moderation/index.ts"],"names":[],"mappings":"AAEA,cAAc,wBAAwB,CAAC;AACvC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/repositories/moderation/index.ts"],"names":[],"mappings":"AAEA,cAAc,wBAAwB,CAAC;AACvC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,wBAAwB,CAAC"}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
//
|
|
2
2
|
export * from "./delete-moderation.js";
|
|
3
3
|
export * from "./find-moderation-by-id.js";
|
|
4
|
-
export * from "./find-pending-moderation.js";
|
|
5
|
-
export * from "./find-rejected-moderation.js";
|
|
6
4
|
export * from "./get-moderation-by-id.js";
|
|
7
5
|
export * from "./reopen-moderation.js";
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
export * from "./find-by-siret.js";
|
|
2
1
|
export * from "./find-by-user-id.js";
|
|
3
2
|
export * from "./find-organization-by-id.js";
|
|
4
|
-
export * from "./find-pending-by-user-id.js";
|
|
5
3
|
export * from "./get-organization-by-id.js";
|
|
6
4
|
export * from "./upsert.js";
|
|
7
5
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/repositories/organization/index.ts"],"names":[],"mappings":"AAEA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/repositories/organization/index.ts"],"names":[],"mappings":"AAEA,cAAc,sBAAsB,CAAC;AACrC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,aAAa,CAAC"}
|
|
@@ -24,6 +24,7 @@ export declare function createUserFactory({ pg }: DatabaseContext): ({ email, en
|
|
|
24
24
|
reset_password_sent_at: Date | null;
|
|
25
25
|
reset_password_token: string | null;
|
|
26
26
|
sign_in_count: number;
|
|
27
|
+
totp_display_name: string | null;
|
|
27
28
|
totp_key_verified_at: Date | null;
|
|
28
29
|
updated_at: Date;
|
|
29
30
|
verify_email_sent_at: Date | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/create.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAQ,MAAM,YAAY,CAAC;AAKxD,wBAAgB,iBAAiB,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,gCAG9B;IACD,KAAK,EAAE,MAAM,CAAC;IACd,kBAAkB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACpC
|
|
1
|
+
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/create.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAQ,MAAM,YAAY,CAAC;AAKxD,wBAAgB,iBAAiB,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,gCAG9B;IACD,KAAK,EAAE,MAAM,CAAC;IACd,kBAAkB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACpC;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BF;AAED,MAAM,MAAM,iBAAiB,GAAG,UAAU,CAAC,OAAO,iBAAiB,CAAC,CAAC"}
|
|
@@ -21,6 +21,7 @@ export declare function findByEmailFactory({ pg }: DatabaseContext): (email: str
|
|
|
21
21
|
reset_password_sent_at: Date | null;
|
|
22
22
|
reset_password_token: string | null;
|
|
23
23
|
sign_in_count: number;
|
|
24
|
+
totp_display_name: string | null;
|
|
24
25
|
totp_key_verified_at: Date | null;
|
|
25
26
|
updated_at: Date;
|
|
26
27
|
verify_email_sent_at: Date | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-by-email.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/find-by-email.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAQ,MAAM,YAAY,CAAC;AAKxD,wBAAgB,kBAAkB,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,OAAO,MAAM
|
|
1
|
+
{"version":3,"file":"find-by-email.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/find-by-email.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAQ,MAAM,YAAY,CAAC;AAKxD,wBAAgB,kBAAkB,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,OAAO,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;eAWhD;AAED,MAAM,MAAM,kBAAkB,GAAG,UAAU,CAAC,OAAO,kBAAkB,CAAC,CAAC"}
|
|
@@ -21,6 +21,7 @@ export declare function findByIdFactory({ pg }: DatabaseContext): (id: number) =
|
|
|
21
21
|
reset_password_sent_at: Date | null;
|
|
22
22
|
reset_password_token: string | null;
|
|
23
23
|
sign_in_count: number;
|
|
24
|
+
totp_display_name: string | null;
|
|
24
25
|
totp_key_verified_at: Date | null;
|
|
25
26
|
updated_at: Date;
|
|
26
27
|
verify_email_sent_at: Date | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-by-id.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/find-by-id.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAQ,MAAM,YAAY,CAAC;AAKxD,wBAAgB,eAAe,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,IAAI,MAAM
|
|
1
|
+
{"version":3,"file":"find-by-id.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/find-by-id.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAQ,MAAM,YAAY,CAAC;AAKxD,wBAAgB,eAAe,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,IAAI,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;eAY1C;AAED,MAAM,MAAM,eAAe,GAAG,UAAU,CAAC,OAAO,eAAe,CAAC,CAAC"}
|
|
@@ -21,6 +21,7 @@ export declare function findByMagicLinkTokenFactory({ pg }: DatabaseContext): (m
|
|
|
21
21
|
reset_password_sent_at: Date | null;
|
|
22
22
|
reset_password_token: string | null;
|
|
23
23
|
sign_in_count: number;
|
|
24
|
+
totp_display_name: string | null;
|
|
24
25
|
totp_key_verified_at: Date | null;
|
|
25
26
|
updated_at: Date;
|
|
26
27
|
verify_email_sent_at: Date | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-by-magic-link-token.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/find-by-magic-link-token.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAQ,MAAM,YAAY,CAAC;AAKxD,wBAAgB,2BAA2B,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,kBAAkB,MAAM
|
|
1
|
+
{"version":3,"file":"find-by-magic-link-token.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/find-by-magic-link-token.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAQ,MAAM,YAAY,CAAC;AAKxD,wBAAgB,2BAA2B,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,kBAAkB,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;eAWpE"}
|
|
@@ -21,6 +21,7 @@ export declare function getByIdFactory({ pg }: DatabaseContext): (id: number) =>
|
|
|
21
21
|
reset_password_sent_at: Date | null;
|
|
22
22
|
reset_password_token: string | null;
|
|
23
23
|
sign_in_count: number;
|
|
24
|
+
totp_display_name: string | null;
|
|
24
25
|
totp_key_verified_at: Date | null;
|
|
25
26
|
updated_at: Date;
|
|
26
27
|
verify_email_sent_at: Date | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-by-id.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/get-by-id.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAMlD,wBAAgB,cAAc,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IAEtB,IAAI,MAAM
|
|
1
|
+
{"version":3,"file":"get-by-id.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/get-by-id.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAMlD,wBAAgB,cAAc,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IAEtB,IAAI,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;GAOzC;AAED,MAAM,MAAM,cAAc,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC"}
|
|
@@ -2,7 +2,6 @@ export * from "./create.js";
|
|
|
2
2
|
export * from "./find-by-email.js";
|
|
3
3
|
export * from "./find-by-id.js";
|
|
4
4
|
export * from "./find-by-magic-link-token.js";
|
|
5
|
-
export * from "./find-by-reset-password-token.js";
|
|
6
5
|
export * from "./get-by-id.js";
|
|
7
6
|
export * from "./update.js";
|
|
8
7
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/index.ts"],"names":[],"mappings":"AAEA,cAAc,aAAa,CAAC;AAC5B,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/index.ts"],"names":[],"mappings":"AAEA,cAAc,aAAa,CAAC;AAC5B,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CAAC"}
|
|
@@ -21,6 +21,7 @@ export declare function updateUserFactory({ pg }: DatabaseContext): (id: number,
|
|
|
21
21
|
reset_password_sent_at: Date | null;
|
|
22
22
|
reset_password_token: string | null;
|
|
23
23
|
sign_in_count: number;
|
|
24
|
+
totp_display_name: string | null;
|
|
24
25
|
totp_key_verified_at: Date | null;
|
|
25
26
|
updated_at: Date;
|
|
26
27
|
verify_email_sent_at: Date | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"update.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/update.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAKxD,wBAAgB,iBAAiB,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,IAAI,MAAM,EAAE,gBAAgB,OAAO,CAAC,IAAI,CAAC
|
|
1
|
+
{"version":3,"file":"update.d.ts","sourceRoot":"","sources":["../../../src/repositories/user/update.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAKxD,wBAAgB,iBAAiB,CAAC,EAAE,EAAE,EAAE,EAAE,eAAe,IACtB,IAAI,MAAM,EAAE,gBAAgB,OAAO,CAAC,IAAI,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsB3E;AAED,MAAM,MAAM,iBAAiB,GAAG,UAAU,CAAC,OAAO,iBAAiB,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authenticator.d.ts","sourceRoot":"","sources":["../../src/types/authenticator.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC;AACrC,MAAM,MAAM,4BAA4B,
|
|
1
|
+
{"version":3,"file":"authenticator.d.ts","sourceRoot":"","sources":["../../src/types/authenticator.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC;AACrC,MAAM,MAAM,4BAA4B,GACtC,KAAK,GAAG,OAAO,GAAG,QAAQ,GAAG,UAAU,GAAG,KAAK,GAAG,YAAY,GAAG,KAAK,CAAC;AACzE,MAAM,MAAM,oBAAoB,GAAG,cAAc,GAAG,aAAa,CAAC;AAIlE,MAAM,WAAW,iBAAiB;IAChC,aAAa,EAAE,eAAe,CAAC;IAC/B,qBAAqB,EAAE,UAAU,CAAC;IAClC,OAAO,EAAE,MAAM,CAAC;IAChB,sBAAsB,EAAE,oBAAoB,CAAC;IAC7C,oBAAoB,EAAE,OAAO,CAAC;IAC9B,UAAU,CAAC,EAAE,4BAA4B,EAAE,CAAC;IAC5C,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,YAAY,EAAE,IAAI,GAAG,IAAI,CAAC;IAC1B,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,OAAO,CAAC;CACxB;AAED,MAAM,WAAW,aAAc,SAAQ,iBAAiB;IACtD,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,IAAI,CAAC;CAClB"}
|
package/dist/types/user.d.ts
CHANGED
|
@@ -21,6 +21,7 @@ export declare const UserSchema: z.ZodObject<{
|
|
|
21
21
|
reset_password_sent_at: z.ZodNullable<z.ZodDate>;
|
|
22
22
|
reset_password_token: z.ZodNullable<z.ZodString>;
|
|
23
23
|
sign_in_count: z.ZodNumber;
|
|
24
|
+
totp_display_name: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
24
25
|
totp_key_verified_at: z.ZodNullable<z.ZodDate>;
|
|
25
26
|
updated_at: z.ZodDate;
|
|
26
27
|
verify_email_sent_at: z.ZodNullable<z.ZodDate>;
|
package/dist/types/user.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../src/types/user.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,UAAU
|
|
1
|
+
{"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../src/types/user.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA2BrB,CAAC;AAEH,MAAM,MAAM,IAAI,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,UAAU,CAAC,CAAC"}
|
package/dist/types/user.js
CHANGED
|
@@ -23,6 +23,7 @@ export const UserSchema = z.object({
|
|
|
23
23
|
reset_password_sent_at: z.date().nullable(),
|
|
24
24
|
reset_password_token: z.string().nullable(),
|
|
25
25
|
sign_in_count: z.number(),
|
|
26
|
+
totp_display_name: z.string().nullable().default(null),
|
|
26
27
|
totp_key_verified_at: z.date().nullable(),
|
|
27
28
|
updated_at: z.date(),
|
|
28
29
|
verify_email_sent_at: z.date().nullable(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@proconnect-gouv/proconnect.identite",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "17.1.0",
|
|
4
4
|
"homepage": "https://github.com/proconnect-gouv/proconnect-identite/tree/main/packages/identite#readme",
|
|
5
5
|
"bugs": "https://github.com/proconnect-gouv/proconnect-identite/issues",
|
|
6
6
|
"repository": {
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"zod": "^4.6.7"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
|
-
"@electric-sql/pglite": "^0.
|
|
53
|
+
"@electric-sql/pglite": "^0.5.16",
|
|
54
54
|
"@proconnect-gouv/proconnect.annuaire_entreprises": "^3.0.5",
|
|
55
55
|
"@proconnect-gouv/proconnect.api_entreprise": "^2.3.0",
|
|
56
56
|
"@proconnect-gouv/proconnect.core": "^1.1.0",
|
package/src/connectors/index.ts
CHANGED
|
@@ -6,9 +6,8 @@ import {
|
|
|
6
6
|
deleteAuthenticatorFactory,
|
|
7
7
|
findAuthenticatorFactory,
|
|
8
8
|
findAuthenticatorsByUserIdFactory,
|
|
9
|
-
|
|
9
|
+
renameAuthenticatorFactory,
|
|
10
10
|
} from "#src/repositories/authenticator";
|
|
11
|
-
import { findEmailInDeliverabilityWhiteListFactory } from "#src/repositories/email-deliverability-whitelist";
|
|
12
11
|
import {
|
|
13
12
|
addDomainFactory,
|
|
14
13
|
findEmailDomainsByOrganizationIdFactory,
|
|
@@ -17,8 +16,6 @@ import { findFranceconnectUserinfoFactory } from "#src/repositories/franceconnec
|
|
|
17
16
|
import {
|
|
18
17
|
deleteModerationFactory,
|
|
19
18
|
findModerationByIdFactory,
|
|
20
|
-
findPendingModerationFactory,
|
|
21
|
-
findRejectedModerationFactory,
|
|
22
19
|
getModerationByIdFactory,
|
|
23
20
|
reopenModerationFactory,
|
|
24
21
|
} from "#src/repositories/moderation";
|
|
@@ -32,10 +29,8 @@ import {
|
|
|
32
29
|
upsertAuthorizationRequestFactory,
|
|
33
30
|
} from "#src/repositories/oidc-client";
|
|
34
31
|
import {
|
|
35
|
-
findBySiretFactory,
|
|
36
32
|
findByUserIdFactory,
|
|
37
33
|
findOrganizationByIdFactory,
|
|
38
|
-
findPendingByUserIdFactory,
|
|
39
34
|
getOrganizationByIdFactory,
|
|
40
35
|
upsertFactory,
|
|
41
36
|
} from "#src/repositories/organization";
|
|
@@ -48,7 +43,6 @@ import {
|
|
|
48
43
|
createUserFactory,
|
|
49
44
|
findByEmailFactory,
|
|
50
45
|
findByMagicLinkTokenFactory,
|
|
51
|
-
findByResetPasswordTokenFactory,
|
|
52
46
|
findByIdFactory as findUserByIdFactory,
|
|
53
47
|
getByIdFactory,
|
|
54
48
|
updateUserFactory,
|
|
@@ -88,11 +82,7 @@ export function createContext({
|
|
|
88
82
|
deleteAllByUserId: deleteAllAuthenticatorsByUserIdFactory({ pg }),
|
|
89
83
|
find: findAuthenticatorFactory({ pg }),
|
|
90
84
|
findByUserId: findAuthenticatorsByUserIdFactory({ pg }),
|
|
91
|
-
|
|
92
|
-
},
|
|
93
|
-
email_deliverability_whitelist: {
|
|
94
|
-
findEmailInDeliverabilityWhiteList:
|
|
95
|
-
findEmailInDeliverabilityWhiteListFactory({ pg }),
|
|
85
|
+
rename: renameAuthenticatorFactory({ pg }),
|
|
96
86
|
},
|
|
97
87
|
email_domains: {
|
|
98
88
|
addDomain: addDomainFactory({ pg }),
|
|
@@ -102,8 +92,6 @@ export function createContext({
|
|
|
102
92
|
moderations: {
|
|
103
93
|
delete: deleteModerationFactory({ pg }),
|
|
104
94
|
findById: findModerationByIdFactory({ pg }),
|
|
105
|
-
findPending: findPendingModerationFactory({ pg }),
|
|
106
|
-
findRejected: findRejectedModerationFactory({ pg }),
|
|
107
95
|
getById: getModerationByIdFactory({ pg }),
|
|
108
96
|
reopen: reopenModerationFactory({ pg }),
|
|
109
97
|
},
|
|
@@ -118,9 +106,7 @@ export function createContext({
|
|
|
118
106
|
},
|
|
119
107
|
organizations: {
|
|
120
108
|
findById: findOrganizationByIdFactory({ pg }),
|
|
121
|
-
findBySiret: findBySiretFactory({ pg }),
|
|
122
109
|
findByUserId: findByUserIdFactory({ pg }),
|
|
123
|
-
findPendingByUserId: findPendingByUserIdFactory({ pg }),
|
|
124
110
|
getById: getOrganizationByIdFactory({ pg }),
|
|
125
111
|
upsert: upsertFactory({ pg }),
|
|
126
112
|
},
|
|
@@ -138,7 +124,6 @@ export function createContext({
|
|
|
138
124
|
findByEmail: findByEmailFactory({ pg }),
|
|
139
125
|
findById: findUserByIdFactory({ pg }),
|
|
140
126
|
findByMagicLinkToken: findByMagicLinkTokenFactory({ pg }),
|
|
141
|
-
findByResetPasswordToken: findByResetPasswordTokenFactory({ pg }),
|
|
142
127
|
getById: getByIdFactory({ pg }),
|
|
143
128
|
update: updateUserFactory({ pg }),
|
|
144
129
|
},
|
|
@@ -45,8 +45,7 @@ export function getCertificationDirigeantDataSourceLabels(
|
|
|
45
45
|
//
|
|
46
46
|
|
|
47
47
|
export type SourceSelection =
|
|
48
|
-
|
|
49
|
-
| { kind: "preferred" };
|
|
48
|
+
{ kind: "fallback"; exception: unknown } | { kind: "preferred" };
|
|
50
49
|
|
|
51
50
|
async function getMandatairesSociaux(
|
|
52
51
|
{ client: { api_entreprise, rne } }: Context,
|