@techtulp/choremanji-types 1.4.0 → 1.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.
@@ -0,0 +1,59 @@
1
+ export declare enum DeletionType {
2
+ ACCOUNT_ONLY = "ACCOUNT_ONLY",
3
+ ACCOUNT_AND_FAMILY = "ACCOUNT_AND_FAMILY"
4
+ }
5
+ export declare enum DeletionStatus {
6
+ PENDING = "PENDING",
7
+ CONFIRMED = "CONFIRMED",
8
+ PROCESSING = "PROCESSING",
9
+ COMPLETED = "COMPLETED",
10
+ CANCELLED = "CANCELLED"
11
+ }
12
+ export interface RequestDeletionDto {
13
+ deletionType: DeletionType;
14
+ reason?: string;
15
+ password: string;
16
+ }
17
+ export interface ConfirmDeletionDto {
18
+ confirmationToken: string;
19
+ }
20
+ export interface CancelDeletionDto {
21
+ deletionRequestId: string;
22
+ }
23
+ export interface AccountDeletion {
24
+ id: string;
25
+ userId: string;
26
+ deletionType: DeletionType;
27
+ status: DeletionStatus;
28
+ requestedAt: string;
29
+ confirmedAt: string | null;
30
+ scheduledDeletionDate: string | null;
31
+ reason?: string | null;
32
+ }
33
+ export interface DeletionPreview {
34
+ user: {
35
+ name: string;
36
+ email: string;
37
+ };
38
+ family: {
39
+ id: string;
40
+ membersCount: number;
41
+ members: {
42
+ name: string;
43
+ role: string;
44
+ }[];
45
+ } | null;
46
+ dataToDelete: {
47
+ tasksCount: number;
48
+ taskTracksCount: number;
49
+ rewardsCount: number;
50
+ redemptionsCount: number;
51
+ pointTracksCount: number;
52
+ };
53
+ }
54
+ export interface DeletionResponse {
55
+ requestId: string;
56
+ status: DeletionStatus;
57
+ message: string;
58
+ scheduledDate?: string;
59
+ }
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DeletionStatus = exports.DeletionType = void 0;
4
+ var DeletionType;
5
+ (function (DeletionType) {
6
+ DeletionType["ACCOUNT_ONLY"] = "ACCOUNT_ONLY";
7
+ DeletionType["ACCOUNT_AND_FAMILY"] = "ACCOUNT_AND_FAMILY";
8
+ })(DeletionType || (exports.DeletionType = DeletionType = {}));
9
+ var DeletionStatus;
10
+ (function (DeletionStatus) {
11
+ DeletionStatus["PENDING"] = "PENDING";
12
+ DeletionStatus["CONFIRMED"] = "CONFIRMED";
13
+ DeletionStatus["PROCESSING"] = "PROCESSING";
14
+ DeletionStatus["COMPLETED"] = "COMPLETED";
15
+ DeletionStatus["CANCELLED"] = "CANCELLED";
16
+ })(DeletionStatus || (exports.DeletionStatus = DeletionStatus = {}));
@@ -27,5 +27,6 @@ export declare enum ErrorType {
27
27
  TaskAlreadyExcused = "Task already excused",
28
28
  AssigneeNotFound = "Assignee not found",
29
29
  RewardNotFound = "Reward not found",
30
- InsufficientPoints = "Insufficient points"
30
+ InsufficientPoints = "Insufficient points",
31
+ EmailSendFailed = "Failed to send email"
31
32
  }
@@ -32,4 +32,5 @@ var ErrorType;
32
32
  ErrorType["AssigneeNotFound"] = "Assignee not found";
33
33
  ErrorType["RewardNotFound"] = "Reward not found";
34
34
  ErrorType["InsufficientPoints"] = "Insufficient points";
35
+ ErrorType["EmailSendFailed"] = "Failed to send email";
35
36
  })(ErrorType || (exports.ErrorType = ErrorType = {}));
package/dist/index.d.ts CHANGED
@@ -16,3 +16,4 @@ export * from './user.type';
16
16
  export * from './redemption.type';
17
17
  export * from './dashboard-data.type';
18
18
  export * from './app-home-data.type';
19
+ export * from './account-deletion.types';
package/dist/index.js CHANGED
@@ -32,3 +32,4 @@ __exportStar(require("./user.type"), exports);
32
32
  __exportStar(require("./redemption.type"), exports);
33
33
  __exportStar(require("./dashboard-data.type"), exports);
34
34
  __exportStar(require("./app-home-data.type"), exports);
35
+ __exportStar(require("./account-deletion.types"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@techtulp/choremanji-types",
3
- "version": "1.4.0",
3
+ "version": "1.4.2",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": ["dist"],