docta-package 1.2.68 → 1.2.70

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.
@@ -4,6 +4,7 @@ import { LanguageInputDto } from "./language";
4
4
  import { FaqInputDto } from "./faq";
5
5
  import { LocationInputDto } from "./location";
6
6
  export declare class CreateDoctorDto {
7
+ fullname: string;
7
8
  title: string;
8
9
  email?: string;
9
10
  professionalEmail: string;
@@ -20,6 +20,12 @@ const location_1 = require("./location");
20
20
  class CreateDoctorDto {
21
21
  }
22
22
  exports.CreateDoctorDto = CreateDoctorDto;
23
+ __decorate([
24
+ (0, class_validator_1.IsString)(),
25
+ (0, class_validator_1.MinLength)(3),
26
+ (0, class_validator_1.MaxLength)(50),
27
+ __metadata("design:type", String)
28
+ ], CreateDoctorDto.prototype, "fullname", void 0);
23
29
  __decorate([
24
30
  (0, class_validator_1.IsString)(),
25
31
  (0, class_validator_1.MinLength)(3),
@@ -1,11 +1,11 @@
1
1
  import { LoggedInUserTokenData } from "../interfaces";
2
2
  export declare class TokenUtils {
3
3
  static createActivationToken(userId: string): string;
4
- static decodeActivationToken(token: string): string | null;
4
+ static verifyActivationToken(token: string): string | null;
5
5
  static createAccessToken(payload: LoggedInUserTokenData): string;
6
6
  static createRefreshToken(payload: LoggedInUserTokenData): string;
7
7
  static verifyRefreshToken(token: string): LoggedInUserTokenData | null;
8
8
  static verifyAccessToken(token: string): LoggedInUserTokenData;
9
9
  static createForgotPasswordToken(userId: string): string;
10
- static decodeForgotPasswordToken(token: string): string | null;
10
+ static verifyForgotPasswordToken(token: string): string | null;
11
11
  }
@@ -8,9 +8,9 @@ const jsonwebtoken_1 = __importDefault(require("jsonwebtoken"));
8
8
  const config_1 = require("../config");
9
9
  class TokenUtils {
10
10
  static createActivationToken(userId) {
11
- return jsonwebtoken_1.default.sign({ userId }, (0, config_1.getGeneralConfig)().accessTokenSecret);
11
+ return jsonwebtoken_1.default.sign({ userId }, (0, config_1.getGeneralConfig)().activationTokenSecret);
12
12
  }
13
- static decodeActivationToken(token) {
13
+ static verifyActivationToken(token) {
14
14
  try {
15
15
  const decoded = jsonwebtoken_1.default.verify(token, (0, config_1.getGeneralConfig)().activationTokenSecret);
16
16
  if (typeof decoded === "string") {
@@ -63,7 +63,7 @@ class TokenUtils {
63
63
  static createForgotPasswordToken(userId) {
64
64
  return jsonwebtoken_1.default.sign({ userId }, (0, config_1.getGeneralConfig)().forgotPasswordTokenSecret);
65
65
  }
66
- static decodeForgotPasswordToken(token) {
66
+ static verifyForgotPasswordToken(token) {
67
67
  try {
68
68
  const decoded = jsonwebtoken_1.default.verify(token, (0, config_1.getGeneralConfig)().forgotPasswordTokenSecret);
69
69
  if (typeof decoded === "string") {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "docta-package",
3
- "version": "1.2.68",
3
+ "version": "1.2.70",
4
4
  "description": "This package will contail all the required files to run the docta micro-service app",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",