hh-contracts 0.0.117 → 0.0.118

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 (31) hide show
  1. package/build/auth/auth.api.d.ts +8 -0
  2. package/build/auth/auth.api.d.ts.map +1 -1
  3. package/build/auth/auth.api.js +4 -0
  4. package/build/auth/auth.models.d.ts +30 -3
  5. package/build/auth/auth.models.d.ts.map +1 -1
  6. package/build/auth/auth.models.js +17 -1
  7. package/build/auth/contracts/ability.contract.d.ts +12 -10
  8. package/build/auth/contracts/ability.contract.d.ts.map +1 -1
  9. package/build/auth/contracts/index.d.ts +4 -0
  10. package/build/auth/contracts/index.d.ts.map +1 -1
  11. package/build/auth/contracts/index.js +4 -0
  12. package/build/auth/contracts/password-change.contract.d.ts +2 -0
  13. package/build/auth/contracts/password-change.contract.d.ts.map +1 -1
  14. package/build/auth/contracts/password-reset.contract.d.ts +2 -0
  15. package/build/auth/contracts/password-reset.contract.d.ts.map +1 -1
  16. package/build/auth/contracts/session-revoke.contract.d.ts +11 -0
  17. package/build/auth/contracts/session-revoke.contract.d.ts.map +1 -0
  18. package/build/auth/contracts/session-revoke.contract.js +46 -0
  19. package/build/auth/contracts/sessions-revoke-all.contract.d.ts +9 -0
  20. package/build/auth/contracts/sessions-revoke-all.contract.d.ts.map +1 -0
  21. package/build/auth/contracts/sessions-revoke-all.contract.js +46 -0
  22. package/build/auth/contracts/sessions.contract.d.ts +23 -0
  23. package/build/auth/contracts/sessions.contract.d.ts.map +1 -0
  24. package/build/auth/contracts/sessions.contract.js +13 -0
  25. package/build/auth/contracts/user-sessions-revoke-all.contract.d.ts +11 -0
  26. package/build/auth/contracts/user-sessions-revoke-all.contract.d.ts.map +1 -0
  27. package/build/auth/contracts/user-sessions-revoke-all.contract.js +46 -0
  28. package/build/common/constants/app-errors.constant.d.ts +25 -0
  29. package/build/common/constants/app-errors.constant.d.ts.map +1 -1
  30. package/build/common/constants/app-errors.constant.js +25 -0
  31. package/package.json +1 -1
@@ -8,6 +8,10 @@ export declare const AUTH_CONTROLLER: {
8
8
  readonly ability: "ability";
9
9
  readonly password: "password";
10
10
  readonly userPassword: "users/:userId/password";
11
+ readonly sessions: "sessions";
12
+ readonly sessionsRevokeAll: "sessions/revoke-all";
13
+ readonly sessionRevoke: "sessions/:sessionId/revoke";
14
+ readonly userSessionsRevokeAll: "users/:userId/sessions/revoke-all";
11
15
  };
12
16
  };
13
17
  export declare const AUTH_API: import("../common/utils").TApi<{
@@ -20,6 +24,10 @@ export declare const AUTH_API: import("../common/utils").TApi<{
20
24
  readonly ability: "ability";
21
25
  readonly password: "password";
22
26
  readonly userPassword: "users/:userId/password";
27
+ readonly sessions: "sessions";
28
+ readonly sessionsRevokeAll: "sessions/revoke-all";
29
+ readonly sessionRevoke: "sessions/:sessionId/revoke";
30
+ readonly userSessionsRevokeAll: "users/:userId/sessions/revoke-all";
23
31
  };
24
32
  }>;
25
33
  //# sourceMappingURL=auth.api.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"auth.api.d.ts","sourceRoot":"","sources":["../../auth/auth.api.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe;;;;;;;;;;;CAWI,CAAC;AAEjC,eAAO,MAAM,QAAQ;;;;;;;;;;;EAA6B,CAAC"}
1
+ {"version":3,"file":"auth.api.d.ts","sourceRoot":"","sources":["../../auth/auth.api.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;CAeI,CAAC;AAEjC,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;EAA6B,CAAC"}
@@ -12,6 +12,10 @@ exports.AUTH_CONTROLLER = {
12
12
  ability: 'ability',
13
13
  password: 'password',
14
14
  userPassword: 'users/:userId/password',
15
+ sessions: 'sessions',
16
+ sessionsRevokeAll: 'sessions/revoke-all',
17
+ sessionRevoke: 'sessions/:sessionId/revoke',
18
+ userSessionsRevokeAll: 'users/:userId/sessions/revoke-all',
15
19
  },
16
20
  };
17
21
  exports.AUTH_API = (0, utils_1.createApi)(exports.AUTH_CONTROLLER);
@@ -9,11 +9,9 @@ export type TAuthEmailLogin = z.infer<typeof AuthEmailLoginSchema>;
9
9
  export declare const AuthLoginResponseSchema: z.ZodObject<{
10
10
  accessToken: z.ZodString;
11
11
  }, z.core.$strip>;
12
- export type TAuthLoginResponse = z.infer<typeof AuthLoginResponseSchema>;
13
12
  export declare const AuthRefreshResponseSchema: z.ZodObject<{
14
13
  accessToken: z.ZodString;
15
14
  }, z.core.$strip>;
16
- export type TAuthRefreshResponse = z.infer<typeof AuthRefreshResponseSchema>;
17
15
  export declare const AuthPasswordChangeSchema: z.ZodObject<{
18
16
  currentPassword: z.ZodString;
19
17
  newPassword: z.ZodString;
@@ -53,6 +51,7 @@ export declare const AuthAbilityRuleSchema: z.ZodObject<{
53
51
  userId: z.ZodOptional<z.ZodOptional<z.ZodUUID>>;
54
52
  }, z.core.$strip>>;
55
53
  }, z.core.$strip>;
54
+ export type TAuthAbilityRule = z.infer<typeof AuthAbilityRuleSchema>;
56
55
  export declare const AuthAbilityResponseSchema: z.ZodObject<{
57
56
  rules: z.ZodArray<z.ZodObject<{
58
57
  action: z.ZodEnum<{
@@ -80,5 +79,33 @@ export declare const AuthAbilityResponseSchema: z.ZodObject<{
80
79
  }, z.core.$strip>>;
81
80
  }, z.core.$strip>>;
82
81
  }, z.core.$strip>;
83
- export type TAuthAbilityResponse = z.infer<typeof AuthAbilityResponseSchema>;
82
+ export declare const AuthSessionSchema: z.ZodObject<{
83
+ id: z.ZodUUID;
84
+ createdAt: z.ZodDate;
85
+ lastUsedAt: z.ZodNullable<z.ZodDate>;
86
+ expiresAt: z.ZodDate;
87
+ revokedAt: z.ZodNullable<z.ZodDate>;
88
+ deviceName: z.ZodNullable<z.ZodString>;
89
+ userAgent: z.ZodNullable<z.ZodString>;
90
+ lastUserAgent: z.ZodNullable<z.ZodString>;
91
+ ip: z.ZodNullable<z.ZodString>;
92
+ lastIp: z.ZodNullable<z.ZodString>;
93
+ isCurrent: z.ZodOptional<z.ZodBoolean>;
94
+ }, z.core.$strip>;
95
+ export type TAuthSession = z.infer<typeof AuthSessionSchema>;
96
+ export declare const AuthSessionsResponseSchema: z.ZodObject<{
97
+ sessions: z.ZodArray<z.ZodObject<{
98
+ id: z.ZodUUID;
99
+ createdAt: z.ZodDate;
100
+ lastUsedAt: z.ZodNullable<z.ZodDate>;
101
+ expiresAt: z.ZodDate;
102
+ revokedAt: z.ZodNullable<z.ZodDate>;
103
+ deviceName: z.ZodNullable<z.ZodString>;
104
+ userAgent: z.ZodNullable<z.ZodString>;
105
+ lastUserAgent: z.ZodNullable<z.ZodString>;
106
+ ip: z.ZodNullable<z.ZodString>;
107
+ lastIp: z.ZodNullable<z.ZodString>;
108
+ isCurrent: z.ZodOptional<z.ZodBoolean>;
109
+ }, z.core.$strip>>;
110
+ }, z.core.$strip>;
84
111
  //# sourceMappingURL=auth.models.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"auth.models.d.ts","sourceRoot":"","sources":["../../auth/auth.models.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAGzB,eAAO,MAAM,cAAc,aAAoB,CAAC;AAChD,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAEvD,eAAO,MAAM,oBAAoB;;;iBAG/B,CAAC;AACH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAEnE,eAAO,MAAM,uBAAuB;;iBAElC,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAEzE,eAAO,MAAM,yBAAyB;;iBAEpC,CAAC;AACH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC;AAE7E,eAAO,MAAM,wBAAwB;;;iBAGnC,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAE3E,eAAO,MAAM,uBAAuB;;iBAElC,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAEzE,eAAO,MAAM,0BAA0B;;;iBAK3B,CAAC;AACb,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAE/E,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;iBAIhC,CAAC;AACH,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;iBAEpC,CAAC;AACH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC"}
1
+ {"version":3,"file":"auth.models.d.ts","sourceRoot":"","sources":["../../auth/auth.models.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAGzB,eAAO,MAAM,cAAc,aAAoB,CAAC;AAChD,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAEvD,eAAO,MAAM,oBAAoB;;;iBAG/B,CAAC;AACH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAEnE,eAAO,MAAM,uBAAuB;;iBAElC,CAAC;AAEH,eAAO,MAAM,yBAAyB;;iBAEpC,CAAC;AAEH,eAAO,MAAM,wBAAwB;;;iBAGnC,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAE3E,eAAO,MAAM,uBAAuB;;iBAElC,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAEzE,eAAO,MAAM,0BAA0B;;;iBAK3B,CAAC;AACb,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAE/E,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;iBAIhC,CAAC;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAErE,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;iBAEpC,CAAC;AAEH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;iBAY5B,CAAC;AACH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAE7D,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;iBAErC,CAAC"}
@@ -33,7 +33,7 @@ var __importStar = (this && this.__importStar) || (function () {
33
33
  };
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.AuthAbilityResponseSchema = exports.AuthAbilityRuleSchema = exports.AuthAbilityConditionSchema = exports.AuthPasswordResetSchema = exports.AuthPasswordChangeSchema = exports.AuthRefreshResponseSchema = exports.AuthLoginResponseSchema = exports.AuthEmailLoginSchema = exports.JwtTokenSchema = void 0;
36
+ exports.AuthSessionsResponseSchema = exports.AuthSessionSchema = exports.AuthAbilityResponseSchema = exports.AuthAbilityRuleSchema = exports.AuthAbilityConditionSchema = exports.AuthPasswordResetSchema = exports.AuthPasswordChangeSchema = exports.AuthRefreshResponseSchema = exports.AuthLoginResponseSchema = exports.AuthEmailLoginSchema = exports.JwtTokenSchema = void 0;
37
37
  const z = __importStar(require("zod"));
38
38
  const common_1 = require("../common");
39
39
  exports.JwtTokenSchema = z.string().min(1);
@@ -68,3 +68,19 @@ exports.AuthAbilityRuleSchema = z.object({
68
68
  exports.AuthAbilityResponseSchema = z.object({
69
69
  rules: z.array(exports.AuthAbilityRuleSchema),
70
70
  });
71
+ exports.AuthSessionSchema = z.object({
72
+ id: common_1.UuidSchema,
73
+ createdAt: z.date(),
74
+ lastUsedAt: z.date().nullable(),
75
+ expiresAt: z.date(),
76
+ revokedAt: z.date().nullable(),
77
+ deviceName: z.string().nullable(),
78
+ userAgent: z.string().nullable(),
79
+ lastUserAgent: z.string().nullable(),
80
+ ip: z.string().nullable(),
81
+ lastIp: z.string().nullable(),
82
+ isCurrent: z.boolean().optional(),
83
+ });
84
+ exports.AuthSessionsResponseSchema = z.object({
85
+ sessions: z.array(exports.AuthSessionSchema),
86
+ });
@@ -1,10 +1,11 @@
1
+ import * as z from 'zod';
1
2
  export declare namespace AuthAbilityContract {
2
3
  const getUrl: (params?: {} | undefined) => string;
3
4
  const endpoint: "ability";
4
5
  const httpMethod: "GET";
5
- const ResponseSchema: import("zod").ZodObject<{
6
- rules: import("zod").ZodArray<import("zod").ZodObject<{
7
- action: import("zod").ZodEnum<{
6
+ const ResponseSchema: z.ZodObject<{
7
+ rules: z.ZodArray<z.ZodObject<{
8
+ action: z.ZodEnum<{
8
9
  manage: "manage";
9
10
  create: "create";
10
11
  read: "read";
@@ -12,7 +13,7 @@ export declare namespace AuthAbilityContract {
12
13
  delete: "delete";
13
14
  hotelClientMessaging: "hotelClientMessaging";
14
15
  }>;
15
- subject: import("zod").ZodEnum<{
16
+ subject: z.ZodEnum<{
16
17
  userPassword: "userPassword";
17
18
  user: "user";
18
19
  role: "role";
@@ -23,11 +24,12 @@ export declare namespace AuthAbilityContract {
23
24
  hotelClient: "hotelClient";
24
25
  all: "all";
25
26
  }>;
26
- conditions: import("zod").ZodOptional<import("zod").ZodObject<{
27
- hotelId: import("zod").ZodOptional<import("zod").ZodOptional<import("zod").ZodUUID>>;
28
- userId: import("zod").ZodOptional<import("zod").ZodOptional<import("zod").ZodUUID>>;
29
- }, import("zod/v4/core").$strip>>;
30
- }, import("zod/v4/core").$strip>>;
31
- }, import("zod/v4/core").$strip>;
27
+ conditions: z.ZodOptional<z.ZodObject<{
28
+ hotelId: z.ZodOptional<z.ZodOptional<z.ZodUUID>>;
29
+ userId: z.ZodOptional<z.ZodOptional<z.ZodUUID>>;
30
+ }, z.core.$strip>>;
31
+ }, z.core.$strip>>;
32
+ }, z.core.$strip>;
33
+ type TResponse = z.infer<typeof ResponseSchema>;
32
34
  }
33
35
  //# sourceMappingURL=ability.contract.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ability.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/ability.contract.ts"],"names":[],"mappings":"AAIA,yBAAiB,mBAAmB,CAAC;IAC5B,MAAM,MAAM,qCAAmB,CAAC;IAChC,MAAM,QAAQ,WAAoC,CAAC;IACnD,MAAM,UAAU,OAAmB,CAAC;IACpC,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;oCAA4B,CAAC;CACzD"}
1
+ {"version":3,"file":"ability.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/ability.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAKzB,yBAAiB,mBAAmB,CAAC;IAC5B,MAAM,MAAM,qCAAmB,CAAC;IAChC,MAAM,QAAQ,WAAoC,CAAC;IACnD,MAAM,UAAU,OAAmB,CAAC;IAEpC,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;qBAA4B,CAAC;IACxD,KAAY,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACxD"}
@@ -5,4 +5,8 @@ export * from './me.contract';
5
5
  export * from './password-change.contract';
6
6
  export * from './password-reset.contract';
7
7
  export * from './ability.contract';
8
+ export * from './user-sessions-revoke-all.contract';
9
+ export * from './session-revoke.contract';
10
+ export * from './sessions-revoke-all.contract';
11
+ export * from './sessions.contract';
8
12
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../auth/contracts/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,oBAAoB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../auth/contracts/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,oBAAoB,CAAC;AACnC,cAAc,qCAAqC,CAAC;AACpD,cAAc,2BAA2B,CAAC;AAC1C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,qBAAqB,CAAC"}
@@ -21,3 +21,7 @@ __exportStar(require("./me.contract"), exports);
21
21
  __exportStar(require("./password-change.contract"), exports);
22
22
  __exportStar(require("./password-reset.contract"), exports);
23
23
  __exportStar(require("./ability.contract"), exports);
24
+ __exportStar(require("./user-sessions-revoke-all.contract"), exports);
25
+ __exportStar(require("./session-revoke.contract"), exports);
26
+ __exportStar(require("./sessions-revoke-all.contract"), exports);
27
+ __exportStar(require("./sessions.contract"), exports);
@@ -7,6 +7,8 @@ export declare namespace AuthPasswordChangeContract {
7
7
  currentPassword: z.ZodString;
8
8
  newPassword: z.ZodString;
9
9
  }, z.core.$strip>;
10
+ type TRequest = z.infer<typeof RequestSchema>;
10
11
  const ResponseSchema: z.ZodVoid;
12
+ type TResponse = z.infer<typeof ResponseSchema>;
11
13
  }
12
14
  //# sourceMappingURL=password-change.contract.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"password-change.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/password-change.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAKzB,yBAAiB,0BAA0B,CAAC;IACnC,MAAM,MAAM,qCAAoB,CAAC;IACjC,MAAM,QAAQ,YAAqC,CAAC;IACpD,MAAM,UAAU,QAAoB,CAAC;IACrC,MAAM,aAAa;;;qBAA2B,CAAC;IAC/C,MAAM,cAAc,WAAW,CAAC;CACxC"}
1
+ {"version":3,"file":"password-change.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/password-change.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAKzB,yBAAiB,0BAA0B,CAAC;IACnC,MAAM,MAAM,qCAAoB,CAAC;IACjC,MAAM,QAAQ,YAAqC,CAAC;IACpD,MAAM,UAAU,QAAoB,CAAC;IAErC,MAAM,aAAa;;;qBAA2B,CAAC;IACtD,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE9C,MAAM,cAAc,WAAW,CAAC;IACvC,KAAY,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACxD"}
@@ -8,6 +8,8 @@ export declare namespace AuthPasswordResetContract {
8
8
  const RequestSchema: z.ZodObject<{
9
9
  newPassword: z.ZodString;
10
10
  }, z.core.$strip>;
11
+ type TRequest = z.infer<typeof RequestSchema>;
11
12
  const ResponseSchema: z.ZodVoid;
13
+ type TResponse = z.infer<typeof ResponseSchema>;
12
14
  }
13
15
  //# sourceMappingURL=password-reset.contract.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"password-reset.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/password-reset.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAKzB,yBAAiB,yBAAyB,CAAC;IAClC,MAAM,MAAM;;gBAAwB,CAAC;IACrC,MAAM,QAAQ,0BAAyC,CAAC;IACxD,MAAM,UAAU,QAAoB,CAAC;IACrC,MAAM,aAAa;;qBAA0B,CAAC;IAC9C,MAAM,cAAc,WAAW,CAAC;CACxC"}
1
+ {"version":3,"file":"password-reset.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/password-reset.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAKzB,yBAAiB,yBAAyB,CAAC;IAClC,MAAM,MAAM;;gBAAwB,CAAC;IACrC,MAAM,QAAQ,0BAAyC,CAAC;IACxD,MAAM,UAAU,QAAoB,CAAC;IAErC,MAAM,aAAa;;qBAA0B,CAAC;IACrD,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE9C,MAAM,cAAc,WAAW,CAAC;IACvC,KAAY,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACxD"}
@@ -0,0 +1,11 @@
1
+ import * as z from 'zod';
2
+ export declare namespace AuthSessionRevokeContract {
3
+ const getUrl: (params: {
4
+ sessionId: string | number;
5
+ }) => string;
6
+ const endpoint: "sessions/:sessionId/revoke";
7
+ const httpMethod: "POST";
8
+ const ResponseSchema: z.ZodVoid;
9
+ type TResponse = z.infer<typeof ResponseSchema>;
10
+ }
11
+ //# sourceMappingURL=session-revoke.contract.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"session-revoke.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/session-revoke.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAIzB,yBAAiB,yBAAyB,CAAC;IAClC,MAAM,MAAM;;gBAAyB,CAAC;IACtC,MAAM,QAAQ,8BAA0C,CAAC;IACzD,MAAM,UAAU,QAAoB,CAAC;IAErC,MAAM,cAAc,WAAW,CAAC;IACvC,KAAY,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACxD"}
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.AuthSessionRevokeContract = void 0;
37
+ const z = __importStar(require("zod"));
38
+ const common_1 = require("../../common");
39
+ const auth_api_1 = require("../auth.api");
40
+ var AuthSessionRevokeContract;
41
+ (function (AuthSessionRevokeContract) {
42
+ AuthSessionRevokeContract.getUrl = auth_api_1.AUTH_API.sessionRevoke;
43
+ AuthSessionRevokeContract.endpoint = auth_api_1.AUTH_CONTROLLER.endpoints.sessionRevoke;
44
+ AuthSessionRevokeContract.httpMethod = common_1.HTTP_METHODS.post;
45
+ AuthSessionRevokeContract.ResponseSchema = z.void();
46
+ })(AuthSessionRevokeContract || (exports.AuthSessionRevokeContract = AuthSessionRevokeContract = {}));
@@ -0,0 +1,9 @@
1
+ import * as z from 'zod';
2
+ export declare namespace AuthSessionsRevokeAllContract {
3
+ const getUrl: (params?: {} | undefined) => string;
4
+ const endpoint: "sessions/revoke-all";
5
+ const httpMethod: "POST";
6
+ const ResponseSchema: z.ZodVoid;
7
+ type TResponse = z.infer<typeof ResponseSchema>;
8
+ }
9
+ //# sourceMappingURL=sessions-revoke-all.contract.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sessions-revoke-all.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/sessions-revoke-all.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAIzB,yBAAiB,6BAA6B,CAAC;IACtC,MAAM,MAAM,qCAA6B,CAAC;IAC1C,MAAM,QAAQ,uBAA8C,CAAC;IAC7D,MAAM,UAAU,QAAoB,CAAC;IAErC,MAAM,cAAc,WAAW,CAAC;IACvC,KAAY,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACxD"}
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.AuthSessionsRevokeAllContract = void 0;
37
+ const z = __importStar(require("zod"));
38
+ const common_1 = require("../../common");
39
+ const auth_api_1 = require("../auth.api");
40
+ var AuthSessionsRevokeAllContract;
41
+ (function (AuthSessionsRevokeAllContract) {
42
+ AuthSessionsRevokeAllContract.getUrl = auth_api_1.AUTH_API.sessionsRevokeAll;
43
+ AuthSessionsRevokeAllContract.endpoint = auth_api_1.AUTH_CONTROLLER.endpoints.sessionsRevokeAll;
44
+ AuthSessionsRevokeAllContract.httpMethod = common_1.HTTP_METHODS.post;
45
+ AuthSessionsRevokeAllContract.ResponseSchema = z.void();
46
+ })(AuthSessionsRevokeAllContract || (exports.AuthSessionsRevokeAllContract = AuthSessionsRevokeAllContract = {}));
@@ -0,0 +1,23 @@
1
+ import * as z from 'zod';
2
+ export declare namespace AuthSessionsContract {
3
+ const getUrl: (params?: {} | undefined) => string;
4
+ const endpoint: "sessions";
5
+ const httpMethod: "GET";
6
+ const ResponseSchema: z.ZodObject<{
7
+ sessions: z.ZodArray<z.ZodObject<{
8
+ id: z.ZodUUID;
9
+ createdAt: z.ZodDate;
10
+ lastUsedAt: z.ZodNullable<z.ZodDate>;
11
+ expiresAt: z.ZodDate;
12
+ revokedAt: z.ZodNullable<z.ZodDate>;
13
+ deviceName: z.ZodNullable<z.ZodString>;
14
+ userAgent: z.ZodNullable<z.ZodString>;
15
+ lastUserAgent: z.ZodNullable<z.ZodString>;
16
+ ip: z.ZodNullable<z.ZodString>;
17
+ lastIp: z.ZodNullable<z.ZodString>;
18
+ isCurrent: z.ZodOptional<z.ZodBoolean>;
19
+ }, z.core.$strip>>;
20
+ }, z.core.$strip>;
21
+ type TResponse = z.infer<typeof ResponseSchema>;
22
+ }
23
+ //# sourceMappingURL=sessions.contract.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sessions.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/sessions.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAKzB,yBAAiB,oBAAoB,CAAC;IAC7B,MAAM,MAAM,qCAAoB,CAAC;IACjC,MAAM,QAAQ,YAAqC,CAAC;IACpD,MAAM,UAAU,OAAmB,CAAC;IAEpC,MAAM,cAAc;;;;;;;;;;;;;;qBAA6B,CAAC;IACzD,KAAY,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACxD"}
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.AuthSessionsContract = void 0;
4
+ const common_1 = require("../../common");
5
+ const auth_api_1 = require("../auth.api");
6
+ const auth_models_1 = require("../auth.models");
7
+ var AuthSessionsContract;
8
+ (function (AuthSessionsContract) {
9
+ AuthSessionsContract.getUrl = auth_api_1.AUTH_API.sessions;
10
+ AuthSessionsContract.endpoint = auth_api_1.AUTH_CONTROLLER.endpoints.sessions;
11
+ AuthSessionsContract.httpMethod = common_1.HTTP_METHODS.get;
12
+ AuthSessionsContract.ResponseSchema = auth_models_1.AuthSessionsResponseSchema;
13
+ })(AuthSessionsContract || (exports.AuthSessionsContract = AuthSessionsContract = {}));
@@ -0,0 +1,11 @@
1
+ import * as z from 'zod';
2
+ export declare namespace AuthUserSessionsRevokeAllContract {
3
+ const getUrl: (params: {
4
+ userId: string | number;
5
+ }) => string;
6
+ const endpoint: "users/:userId/sessions/revoke-all";
7
+ const httpMethod: "POST";
8
+ const ResponseSchema: z.ZodVoid;
9
+ type TResponse = z.infer<typeof ResponseSchema>;
10
+ }
11
+ //# sourceMappingURL=user-sessions-revoke-all.contract.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"user-sessions-revoke-all.contract.d.ts","sourceRoot":"","sources":["../../../auth/contracts/user-sessions-revoke-all.contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAIzB,yBAAiB,iCAAiC,CAAC;IAC1C,MAAM,MAAM;;gBAAiC,CAAC;IAC9C,MAAM,QAAQ,qCAAkD,CAAC;IACjE,MAAM,UAAU,QAAoB,CAAC;IAErC,MAAM,cAAc,WAAW,CAAC;IACvC,KAAY,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACxD"}
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.AuthUserSessionsRevokeAllContract = void 0;
37
+ const z = __importStar(require("zod"));
38
+ const common_1 = require("../../common");
39
+ const auth_api_1 = require("../auth.api");
40
+ var AuthUserSessionsRevokeAllContract;
41
+ (function (AuthUserSessionsRevokeAllContract) {
42
+ AuthUserSessionsRevokeAllContract.getUrl = auth_api_1.AUTH_API.userSessionsRevokeAll;
43
+ AuthUserSessionsRevokeAllContract.endpoint = auth_api_1.AUTH_CONTROLLER.endpoints.userSessionsRevokeAll;
44
+ AuthUserSessionsRevokeAllContract.httpMethod = common_1.HTTP_METHODS.post;
45
+ AuthUserSessionsRevokeAllContract.ResponseSchema = z.void();
46
+ })(AuthUserSessionsRevokeAllContract || (exports.AuthUserSessionsRevokeAllContract = AuthUserSessionsRevokeAllContract = {}));
@@ -37,6 +37,31 @@ export declare const APP_ERRORS: {
37
37
  readonly code: "AUTH-01";
38
38
  readonly messageKey: "errors.auth.wrongCredentials";
39
39
  };
40
+ readonly passwordChangeForbidden: {
41
+ readonly statusCode: 403;
42
+ readonly code: "AUTH-02";
43
+ readonly messageKey: "errors.auth.passwordChangeForbidden";
44
+ };
45
+ readonly passwordResetForbidden: {
46
+ readonly statusCode: 403;
47
+ readonly code: "AUTH-03";
48
+ readonly messageKey: "errors.auth.passwordResetForbidden";
49
+ };
50
+ readonly sessionNotFound: {
51
+ readonly statusCode: 404;
52
+ readonly code: "AUTH-04";
53
+ readonly messageKey: "errors.auth.sessionNotFound";
54
+ };
55
+ readonly sessionRevoked: {
56
+ readonly statusCode: 401;
57
+ readonly code: "AUTH-05";
58
+ readonly messageKey: "errors.auth.sessionRevoked";
59
+ };
60
+ readonly refreshReuse: {
61
+ readonly statusCode: 401;
62
+ readonly code: "AUTH-06";
63
+ readonly messageKey: "errors.auth.refreshReuse";
64
+ };
40
65
  };
41
66
  readonly translation: {
42
67
  readonly alreadyExists: {
@@ -1 +1 @@
1
- {"version":3,"file":"app-errors.constant.d.ts","sourceRoot":"","sources":["../../../common/constants/app-errors.constant.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwMb,CAAC;AAEX,UAAU,MAAM;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI;KAC5D,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAChD,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,GACjB,CAAC,CAAC,CAAC,CAAC,GACJ,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GACrB,KAAK;CACV,CAAC,MAAM,CAAC,CAAC,CAAC;AACX,MAAM,MAAM,SAAS,GAAG,aAAa,CAAC,OAAO,UAAU,CAAC,CAAC;AACzD,MAAM,MAAM,aAAa,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC;AAC9C,MAAM,MAAM,mBAAmB,GAAG,SAAS,CAAC,YAAY,CAAC,CAAC;AAE1D,MAAM,WAAW,iBAAiB;IAChC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAClC;AAED,MAAM,WAAW,aAAc,SAAQ,iBAAiB;IACtD,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,aAAa,GAAG,aAAa,EAAE,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC;CAC/F;AACD,MAAM,MAAM,gBAAgB,GAAG,MAAM,CAAC,MAAM,EAAE,aAAa,GAAG,aAAa,EAAE,CAAC,CAAC;AAE/E,MAAM,MAAM,oBAAoB,GAAG,SAAS,GAAG;IAC7C,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,gBAAgB,CAAC;CAC5B,CAAC"}
1
+ {"version":3,"file":"app-errors.constant.d.ts","sourceRoot":"","sources":["../../../common/constants/app-errors.constant.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiOb,CAAC;AAEX,UAAU,MAAM;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI;KAC5D,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAChD,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,GACjB,CAAC,CAAC,CAAC,CAAC,GACJ,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GACrB,KAAK;CACV,CAAC,MAAM,CAAC,CAAC,CAAC;AACX,MAAM,MAAM,SAAS,GAAG,aAAa,CAAC,OAAO,UAAU,CAAC,CAAC;AACzD,MAAM,MAAM,aAAa,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC;AAC9C,MAAM,MAAM,mBAAmB,GAAG,SAAS,CAAC,YAAY,CAAC,CAAC;AAE1D,MAAM,WAAW,iBAAiB;IAChC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAClC;AAED,MAAM,WAAW,aAAc,SAAQ,iBAAiB;IACtD,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,aAAa,GAAG,aAAa,EAAE,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC;CAC/F;AACD,MAAM,MAAM,gBAAgB,GAAG,MAAM,CAAC,MAAM,EAAE,aAAa,GAAG,aAAa,EAAE,CAAC,CAAC;AAE/E,MAAM,MAAM,oBAAoB,GAAG,SAAS,GAAG;IAC7C,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,gBAAgB,CAAC;CAC5B,CAAC"}
@@ -51,6 +51,31 @@ exports.APP_ERRORS = {
51
51
  code: 'AUTH-01',
52
52
  messageKey: 'errors.auth.wrongCredentials',
53
53
  },
54
+ passwordChangeForbidden: {
55
+ statusCode: 403, // HttpStatus.FORBIDDEN,
56
+ code: 'AUTH-02',
57
+ messageKey: 'errors.auth.passwordChangeForbidden',
58
+ },
59
+ passwordResetForbidden: {
60
+ statusCode: 403, // HttpStatus.FORBIDDEN,
61
+ code: 'AUTH-03',
62
+ messageKey: 'errors.auth.passwordResetForbidden',
63
+ },
64
+ sessionNotFound: {
65
+ statusCode: 404, // HttpStatus.NOT_FOUND,
66
+ code: 'AUTH-04',
67
+ messageKey: 'errors.auth.sessionNotFound',
68
+ },
69
+ sessionRevoked: {
70
+ statusCode: 401, // HttpStatus.UNAUTHORIZED,
71
+ code: 'AUTH-05',
72
+ messageKey: 'errors.auth.sessionRevoked',
73
+ },
74
+ refreshReuse: {
75
+ statusCode: 401, // HttpStatus.UNAUTHORIZED,
76
+ code: 'AUTH-06',
77
+ messageKey: 'errors.auth.refreshReuse',
78
+ },
54
79
  },
55
80
  translation: {
56
81
  alreadyExists: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hh-contracts",
3
- "version": "0.0.117",
3
+ "version": "0.0.118",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",