@anarchitects/auth-nest 0.0.1 → 0.4.2

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.
Files changed (40) hide show
  1. package/README.md +181 -16
  2. package/package.json +7 -4
  3. package/src/application/application.module.d.ts +6 -9
  4. package/src/application/application.module.js +17 -21
  5. package/src/application/application.module.js.map +1 -1
  6. package/src/auth.module.d.ts +14 -0
  7. package/src/auth.module.js +44 -0
  8. package/src/auth.module.js.map +1 -0
  9. package/src/index.d.ts +1 -0
  10. package/src/index.js +1 -0
  11. package/src/index.js.map +1 -1
  12. package/src/infrastructure-mailer/adapters/node-mailer.adapter.d.ts +1 -8
  13. package/src/infrastructure-mailer/adapters/node-mailer.adapter.js +2 -19
  14. package/src/infrastructure-mailer/adapters/node-mailer.adapter.js.map +1 -1
  15. package/src/infrastructure-mailer/index.d.ts +0 -1
  16. package/src/infrastructure-mailer/index.js +0 -1
  17. package/src/infrastructure-mailer/index.js.map +1 -1
  18. package/src/infrastructure-mailer/mailer.module.d.ts +1 -1
  19. package/src/infrastructure-mailer/mailer.module.js +9 -15
  20. package/src/infrastructure-mailer/mailer.module.js.map +1 -1
  21. package/src/infrastructure-persistence/index.d.ts +1 -0
  22. package/src/infrastructure-persistence/index.js +1 -0
  23. package/src/infrastructure-persistence/index.js.map +1 -1
  24. package/src/infrastructure-persistence/migrations/{1720200000000-create-invalidated-tokens-cache.table.d.ts → 1720200000000-create-auth-schema.d.ts} +1 -1
  25. package/src/infrastructure-persistence/migrations/1720200000000-create-auth-schema.js +312 -0
  26. package/src/infrastructure-persistence/migrations/1720200000000-create-auth-schema.js.map +1 -0
  27. package/src/infrastructure-persistence/persistence.module.d.ts +1 -3
  28. package/src/infrastructure-persistence/persistence.module.js +12 -18
  29. package/src/infrastructure-persistence/persistence.module.js.map +1 -1
  30. package/src/presentation/controllers/auth.controller.d.ts +9 -27
  31. package/src/presentation/controllers/auth.controller.js +18 -30
  32. package/src/presentation/controllers/auth.controller.js.map +1 -1
  33. package/src/presentation/presentation.module.d.ts +1 -1
  34. package/src/presentation/presentation.module.js +5 -5
  35. package/src/presentation/presentation.module.js.map +1 -1
  36. package/src/infrastructure-mailer/adapters/mailer.adapter.d.ts +0 -4
  37. package/src/infrastructure-mailer/adapters/mailer.adapter.js +0 -7
  38. package/src/infrastructure-mailer/adapters/mailer.adapter.js.map +0 -1
  39. package/src/infrastructure-persistence/migrations/1720200000000-create-invalidated-tokens-cache.table.js +0 -29
  40. package/src/infrastructure-persistence/migrations/1720200000000-create-invalidated-tokens-cache.table.js.map +0 -1
@@ -1,29 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.CreateInvalidatedTokensCacheTable1720200000000 = void 0;
4
- const schema_1 = require("../schema");
5
- class CreateInvalidatedTokensCacheTable1720200000000 {
6
- constructor() {
7
- this.name = 'CreateInvalidatedTokensCacheTable1720200000000';
8
- }
9
- async up(queryRunner) {
10
- await queryRunner.query(`CREATE SCHEMA IF NOT EXISTS "${schema_1.AUTH_SCHEMA}";`);
11
- await queryRunner.query(`
12
- CREATE UNLOGGED TABLE IF NOT EXISTS "${schema_1.AUTH_SCHEMA}"."invalidated_tokens" (
13
- token_id varchar(128) PRIMARY KEY,
14
- user_id uuid NULL,
15
- expires_at timestamptz NOT NULL,
16
- invalidated_at timestamptz NOT NULL DEFAULT CURRENT_TIMESTAMP
17
- );
18
- `);
19
- await queryRunner.query(`
20
- CREATE INDEX IF NOT EXISTS invalidated_tokens_expires_at_idx
21
- ON "${schema_1.AUTH_SCHEMA}"."invalidated_tokens" (expires_at);
22
- `);
23
- }
24
- async down(queryRunner) {
25
- await queryRunner.query(`DROP TABLE IF EXISTS "${schema_1.AUTH_SCHEMA}"."invalidated_tokens";`);
26
- }
27
- }
28
- exports.CreateInvalidatedTokensCacheTable1720200000000 = CreateInvalidatedTokensCacheTable1720200000000;
29
- //# sourceMappingURL=1720200000000-create-invalidated-tokens-cache.table.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"1720200000000-create-invalidated-tokens-cache.table.js","sourceRoot":"","sources":["../../../../../../../libs/auth/nest/src/infrastructure-persistence/migrations/1720200000000-create-invalidated-tokens-cache.table.ts"],"names":[],"mappings":";;;AACA,sCAAwC;AAExC,MAAa,8CAA8C;IAA3D;QAGE,SAAI,GAAG,gDAAgD,CAAC;IAyB1D,CAAC;IAvBQ,KAAK,CAAC,EAAE,CAAC,WAAwB;QACtC,MAAM,WAAW,CAAC,KAAK,CAAC,gCAAgC,oBAAW,IAAI,CAAC,CAAC;QAEzE,MAAM,WAAW,CAAC,KAAK,CAAC;6CACiB,oBAAW;;;;;;KAMnD,CAAC,CAAC;QAEH,MAAM,WAAW,CAAC,KAAK,CAAC;;cAEd,oBAAW;KACpB,CAAC,CAAC;IACL,CAAC;IAEM,KAAK,CAAC,IAAI,CAAC,WAAwB;QACxC,MAAM,WAAW,CAAC,KAAK,CACrB,yBAAyB,oBAAW,yBAAyB,CAC9D,CAAC;IACJ,CAAC;CACF;AA5BD,wGA4BC"}