@abyss-project/main 1.0.67 → 1.0.69
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/dist/api/index.d.ts +2 -0
- package/dist/api/index.js +2 -0
- package/dist/api/short-link.admin.api.d.ts +7 -0
- package/dist/api/short-link.admin.api.js +22 -0
- package/dist/api/short-link.api.d.ts +4 -7
- package/dist/api/short-link.api.js +8 -18
- package/dist/api/short-link.public.api.d.ts +8 -0
- package/dist/api/short-link.public.api.js +32 -0
- package/dist/constants/index.d.ts +1 -0
- package/dist/constants/index.js +1 -0
- package/dist/constants/short-link.constants.d.ts +8 -0
- package/dist/constants/short-link.constants.js +11 -0
- package/dist/server-sent-events/index.d.ts +2 -1
- package/dist/server-sent-events/index.js +1 -0
- package/dist/types/enum/index.d.ts +1 -0
- package/dist/types/enum/index.js +1 -0
- package/dist/types/enum/user-agent.enum.d.ts +22 -0
- package/dist/types/enum/user-agent.enum.js +28 -0
- package/dist/types/interface/api/index.d.ts +2 -0
- package/dist/types/interface/api/index.js +2 -0
- package/dist/types/interface/api/requests/application.admin.request.d.ts +6 -7
- package/dist/types/interface/api/requests/application.request.d.ts +6 -7
- package/dist/types/interface/api/requests/gift-code.admin.request.d.ts +4 -5
- package/dist/types/interface/api/requests/project-access.admin.request.d.ts +10 -11
- package/dist/types/interface/api/requests/project-access.request.d.ts +11 -12
- package/dist/types/interface/api/requests/project.admin.request.d.ts +5 -6
- package/dist/types/interface/api/requests/project.request.d.ts +10 -11
- package/dist/types/interface/api/requests/short-link.admin.request.d.ts +4 -1
- package/dist/types/interface/api/requests/short-link.public.request.d.ts +33 -0
- package/dist/types/interface/api/requests/short-link.public.request.js +2 -0
- package/dist/types/interface/api/requests/short-link.request.d.ts +7 -26
- package/dist/types/interface/api/requests/user-credit-purchase.admin.request.d.ts +5 -6
- package/dist/types/interface/api/requests/user-credit-purchase.request.d.ts +1 -2
- package/dist/types/interface/api/requests/user-notification.admin.request.d.ts +3 -4
- package/dist/types/interface/api/requests/user-notification.request.d.ts +2 -3
- package/dist/types/interface/api/requests/user-ticket.admin.request.d.ts +8 -9
- package/dist/types/interface/api/requests/user-ticket.request.d.ts +6 -7
- package/dist/types/interface/api/requests/user-transaction.admin.request.d.ts +3 -4
- package/dist/types/interface/api/requests/user.admin.request.d.ts +7 -8
- package/dist/types/interface/api/requests/user.request.d.ts +2 -3
- package/dist/types/interface/api/responses/short-link.admin.response.d.ts +2 -0
- package/dist/types/interface/api/responses/short-link.public.response.d.ts +20 -0
- package/dist/types/interface/api/responses/short-link.public.response.js +2 -0
- package/dist/types/interface/api/responses/short-link.response.d.ts +4 -15
- package/dist/types/interface/models/short-link-click.model.d.ts +13 -1
- package/dist/types/interface/models/short-link.model.d.ts +16 -0
- package/dist/utils/index.d.ts +3 -0
- package/dist/utils/index.js +3 -0
- package/dist/utils/string.utils.d.ts +6 -0
- package/dist/utils/string.utils.js +45 -0
- package/dist/utils/tracking.utils.d.ts +11 -0
- package/dist/utils/tracking.utils.js +60 -0
- package/package.json +1 -1
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { QueryPaginate } from '../type-message/base-paginate';
|
|
3
2
|
import { ProjectStatus, SubscriptionLevel, UserTransactionType } from '../../../enum';
|
|
4
|
-
export interface IGetProjectParams
|
|
3
|
+
export interface IGetProjectParams {
|
|
5
4
|
projectId: string;
|
|
6
5
|
}
|
|
7
|
-
export interface IGetMetricsProjectParams
|
|
6
|
+
export interface IGetMetricsProjectParams {
|
|
8
7
|
projectId: string;
|
|
9
8
|
}
|
|
10
9
|
export type IPaginateProjectQuery = {
|
|
11
10
|
name?: string;
|
|
12
11
|
} & QueryPaginate;
|
|
13
|
-
export interface IPaginateTransactionProjectParams
|
|
12
|
+
export interface IPaginateTransactionProjectParams {
|
|
14
13
|
projectId: string;
|
|
15
14
|
}
|
|
16
15
|
export type IPaginateTransactionProjectQuery = {
|
|
@@ -20,14 +19,14 @@ export type ICreateProjectBody = {
|
|
|
20
19
|
name: string;
|
|
21
20
|
description?: string | null;
|
|
22
21
|
};
|
|
23
|
-
export interface IDeleteProjectParams
|
|
22
|
+
export interface IDeleteProjectParams {
|
|
24
23
|
projectId: string;
|
|
25
24
|
}
|
|
26
25
|
export interface IDeleteProjectQuery {
|
|
27
26
|
deleteSpotlightProject?: boolean;
|
|
28
27
|
deleteForm?: boolean;
|
|
29
28
|
}
|
|
30
|
-
export interface IUpdateProjectParams
|
|
29
|
+
export interface IUpdateProjectParams {
|
|
31
30
|
projectId: string;
|
|
32
31
|
}
|
|
33
32
|
export type IUpdateProjectBody = {
|
|
@@ -35,26 +34,26 @@ export type IUpdateProjectBody = {
|
|
|
35
34
|
description?: string | null;
|
|
36
35
|
status?: ProjectStatus;
|
|
37
36
|
};
|
|
38
|
-
export interface ILeaveProjectParams
|
|
37
|
+
export interface ILeaveProjectParams {
|
|
39
38
|
projectId: string;
|
|
40
39
|
}
|
|
41
|
-
export interface ICreateSubscriptionProjectParams
|
|
40
|
+
export interface ICreateSubscriptionProjectParams {
|
|
42
41
|
projectId: string;
|
|
43
42
|
}
|
|
44
43
|
export interface ICreateSubscriptionProjectBody {
|
|
45
44
|
level: SubscriptionLevel;
|
|
46
45
|
isAutoRenewEnabled: boolean;
|
|
47
46
|
}
|
|
48
|
-
export interface IUpdateSubscriptionProjectParams
|
|
47
|
+
export interface IUpdateSubscriptionProjectParams {
|
|
49
48
|
projectId: string;
|
|
50
49
|
}
|
|
51
50
|
export interface IUpdateSubscriptionProjectBody {
|
|
52
51
|
isAutoRenewEnabled?: boolean;
|
|
53
52
|
}
|
|
54
|
-
export interface IRenewSubscriptionProjectParams
|
|
53
|
+
export interface IRenewSubscriptionProjectParams {
|
|
55
54
|
projectId: string;
|
|
56
55
|
}
|
|
57
|
-
export interface ISetOwnershipProjectParams
|
|
56
|
+
export interface ISetOwnershipProjectParams {
|
|
58
57
|
projectId: string;
|
|
59
58
|
}
|
|
60
59
|
export interface ISetOwnershipProjectBody {
|
|
@@ -22,5 +22,8 @@ export type IUpdateShortLinkAdminBody = {
|
|
|
22
22
|
isActive?: boolean;
|
|
23
23
|
expiresAt?: Date | null;
|
|
24
24
|
maxClicks?: number | null;
|
|
25
|
-
password?: string | null;
|
|
26
25
|
};
|
|
26
|
+
export type IGetClicksShortLinkAdminParams = {
|
|
27
|
+
shortLinkId: string;
|
|
28
|
+
};
|
|
29
|
+
export type IGetClicksShortLinkAdminQuery = QueryPaginate;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { QueryPaginate } from '../type-message/base-paginate';
|
|
2
|
+
export type ICreateAnonymousShortLinkPublicBody = {
|
|
3
|
+
originalUrl: string;
|
|
4
|
+
title?: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
};
|
|
7
|
+
export type IRedirectShortLinkPublicParams = {
|
|
8
|
+
slug: string;
|
|
9
|
+
};
|
|
10
|
+
export type IRedirectShortLinkPublicQuery = {
|
|
11
|
+
ref?: string;
|
|
12
|
+
lang?: string;
|
|
13
|
+
utmSource?: string;
|
|
14
|
+
utmMedium?: string;
|
|
15
|
+
utmCampaign?: string;
|
|
16
|
+
utmTerm?: string;
|
|
17
|
+
utmContent?: string;
|
|
18
|
+
};
|
|
19
|
+
export type IGetStatsShortLinkPublicParams = {
|
|
20
|
+
shortLinkId: string;
|
|
21
|
+
};
|
|
22
|
+
export type IGetStatsShortLinkPublicQuery = {
|
|
23
|
+
startDate?: Date;
|
|
24
|
+
endDate?: Date;
|
|
25
|
+
groupBy?: 'day' | 'week' | 'month';
|
|
26
|
+
};
|
|
27
|
+
export type IGetClicksShortLinkPublicParams = {
|
|
28
|
+
shortLinkId: string;
|
|
29
|
+
};
|
|
30
|
+
export type IGetClicksShortLinkPublicQuery = QueryPaginate;
|
|
31
|
+
export type IRenewShortLinkPublicParams = {
|
|
32
|
+
shortLinkId: string;
|
|
33
|
+
};
|
|
@@ -2,37 +2,19 @@ import { QueryPaginate } from '../type-message/base-paginate';
|
|
|
2
2
|
export type IGetShortLinkParams = {
|
|
3
3
|
shortLinkId: string;
|
|
4
4
|
};
|
|
5
|
-
export type IGetShortLinkBySlugParams = {
|
|
6
|
-
slug: string;
|
|
7
|
-
};
|
|
8
|
-
export type IValidateShortLinkPasswordBody = {
|
|
9
|
-
password: string;
|
|
10
|
-
};
|
|
11
5
|
export type IPaginateShortLinkQuery = {
|
|
12
|
-
title?: string;
|
|
13
|
-
userId?: string;
|
|
14
|
-
projectId?: string;
|
|
15
|
-
isActive?: boolean;
|
|
16
|
-
} & QueryPaginate;
|
|
17
|
-
export type IPaginateUserShortLinkQuery = {
|
|
18
6
|
title?: string;
|
|
19
7
|
isActive?: boolean;
|
|
20
8
|
} & QueryPaginate;
|
|
21
9
|
export type IPaginateProjectShortLinkParams = {
|
|
22
10
|
projectId: string;
|
|
23
11
|
};
|
|
24
|
-
export type IPaginateProjectShortLinkQuery = {
|
|
25
|
-
title?: string;
|
|
26
|
-
isActive?: boolean;
|
|
27
|
-
} & QueryPaginate;
|
|
28
12
|
export type ICreateShortLinkBody = {
|
|
29
13
|
originalUrl: string;
|
|
30
|
-
slug?: string;
|
|
31
14
|
title?: string;
|
|
32
15
|
description?: string;
|
|
33
16
|
expiresAt?: Date;
|
|
34
17
|
maxClicks?: number;
|
|
35
|
-
password?: string;
|
|
36
18
|
};
|
|
37
19
|
export type ICreateForProjectShortLinkParams = {
|
|
38
20
|
projectId: string;
|
|
@@ -42,25 +24,24 @@ export type IUpdateShortLinkParams = {
|
|
|
42
24
|
};
|
|
43
25
|
export type IUpdateShortLinkBody = {
|
|
44
26
|
originalUrl?: string;
|
|
45
|
-
slug?: string;
|
|
46
27
|
title?: string;
|
|
47
28
|
description?: string;
|
|
48
29
|
isActive?: boolean;
|
|
49
30
|
expiresAt?: Date | null;
|
|
50
31
|
maxClicks?: number | null;
|
|
51
|
-
password?: string | null;
|
|
52
32
|
};
|
|
53
33
|
export type IDeleteShortLinkParams = {
|
|
54
34
|
shortLinkId: string;
|
|
55
35
|
};
|
|
56
|
-
export type
|
|
36
|
+
export type IGetStatsShortLinkParams = {
|
|
57
37
|
shortLinkId: string;
|
|
58
38
|
};
|
|
59
|
-
export type
|
|
60
|
-
startDate?:
|
|
61
|
-
endDate?:
|
|
39
|
+
export type IGetStatsShortLinkQuery = {
|
|
40
|
+
startDate?: Date;
|
|
41
|
+
endDate?: Date;
|
|
62
42
|
groupBy?: 'day' | 'week' | 'month';
|
|
63
43
|
};
|
|
64
|
-
export type
|
|
65
|
-
|
|
44
|
+
export type IGetClicksShortLinkParams = {
|
|
45
|
+
shortLinkId: string;
|
|
66
46
|
};
|
|
47
|
+
export type IGetClicksShortLinkQuery = QueryPaginate;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { QueryPaginate } from '..';
|
|
3
2
|
import { UserCreditPurchaseCurrency, UserCreditPurchasePaymentMethod, UserCreditPurchasePlatform } from '../../../enum';
|
|
4
3
|
export type IPaginateUserCreditPurchaseAdminQuery = {
|
|
@@ -8,10 +7,10 @@ export type IPaginateUserCreditPurchaseAdminQuery = {
|
|
|
8
7
|
userId?: string[];
|
|
9
8
|
adminId?: string[];
|
|
10
9
|
} & QueryPaginate;
|
|
11
|
-
export interface IGetUserCreditPurchaseAdminParams
|
|
10
|
+
export interface IGetUserCreditPurchaseAdminParams {
|
|
12
11
|
userCreditPurchaseId: string;
|
|
13
12
|
}
|
|
14
|
-
export interface ICreateUserCreditPurchaseAdminParams
|
|
13
|
+
export interface ICreateUserCreditPurchaseAdminParams {
|
|
15
14
|
userId: string;
|
|
16
15
|
}
|
|
17
16
|
export interface ICreateUserCreditPurchaseAdminBody {
|
|
@@ -23,7 +22,7 @@ export interface ICreateUserCreditPurchaseAdminBody {
|
|
|
23
22
|
creditAmount: number;
|
|
24
23
|
externalId?: string | null;
|
|
25
24
|
}
|
|
26
|
-
export interface IUpdateUserCreditPurchaseAdminParams
|
|
25
|
+
export interface IUpdateUserCreditPurchaseAdminParams {
|
|
27
26
|
userCreditPurchaseId: string;
|
|
28
27
|
}
|
|
29
28
|
export interface IUpdateUserCreditPurchaseAdminBody {
|
|
@@ -35,9 +34,9 @@ export interface IUpdateUserCreditPurchaseAdminBody {
|
|
|
35
34
|
creditAmount?: number;
|
|
36
35
|
externalId?: string | null;
|
|
37
36
|
}
|
|
38
|
-
export interface IDeleteUserCreditPurchaseAdminParams
|
|
37
|
+
export interface IDeleteUserCreditPurchaseAdminParams {
|
|
39
38
|
userCreditPurchaseId: string;
|
|
40
39
|
}
|
|
41
|
-
export interface IRefundUserCreditPurchaseAdminParams
|
|
40
|
+
export interface IRefundUserCreditPurchaseAdminParams {
|
|
42
41
|
userCreditPurchaseId: string;
|
|
43
42
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { QueryPaginate } from '..';
|
|
3
2
|
import { UserCreditPurchaseCurrency, UserCreditPurchasePlatform } from '../../../enum';
|
|
4
3
|
export type IPaginateUserCreditPurchaseQuery = {
|
|
5
4
|
method?: UserCreditPurchasePlatform[];
|
|
6
5
|
currency?: UserCreditPurchaseCurrency[];
|
|
7
6
|
} & QueryPaginate;
|
|
8
|
-
export interface IGetUserCreditPurchaseParams
|
|
7
|
+
export interface IGetUserCreditPurchaseParams {
|
|
9
8
|
creditPurchaseId: string;
|
|
10
9
|
}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { AbyssService, UserNotificationType } from '../../../enum';
|
|
3
2
|
import { NotificationDTO } from '../../../utils';
|
|
4
3
|
import { QueryPaginate } from '../type-message/base-paginate';
|
|
5
|
-
export interface IGetUserNotificationAdminParams
|
|
4
|
+
export interface IGetUserNotificationAdminParams {
|
|
6
5
|
userNotificationId: string;
|
|
7
6
|
}
|
|
8
7
|
export type IPaginateUserNotificationAdminQuery = {
|
|
@@ -16,10 +15,10 @@ export type ICreateUserNotificationAdminBody = ({
|
|
|
16
15
|
userId: string;
|
|
17
16
|
type: UserNotificationType;
|
|
18
17
|
} & NotificationDTO)[];
|
|
19
|
-
export interface IDeleteUserNotificationAdminParams
|
|
18
|
+
export interface IDeleteUserNotificationAdminParams {
|
|
20
19
|
userNotificationId: string;
|
|
21
20
|
}
|
|
22
|
-
export interface IUpdateUserNotificationAdminParams
|
|
21
|
+
export interface IUpdateUserNotificationAdminParams {
|
|
23
22
|
userNotificationId: string;
|
|
24
23
|
}
|
|
25
24
|
export type IUpdateUserNotificationAdminBody = Partial<NotificationDTO> & {
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { AbyssService, UserNotificationType } from '../../../enum';
|
|
3
2
|
import { QueryPaginate } from '../type-message/base-paginate';
|
|
4
|
-
export interface IGetUserNotificationParams
|
|
3
|
+
export interface IGetUserNotificationParams {
|
|
5
4
|
userNotificationId: string;
|
|
6
5
|
}
|
|
7
6
|
export type IPaginateUserNotificationQuery = {
|
|
@@ -9,6 +8,6 @@ export type IPaginateUserNotificationQuery = {
|
|
|
9
8
|
service?: AbyssService[];
|
|
10
9
|
shouldGetOnlyNew?: boolean;
|
|
11
10
|
} & QueryPaginate;
|
|
12
|
-
export interface IOpenUserNotificationParams
|
|
11
|
+
export interface IOpenUserNotificationParams {
|
|
13
12
|
userNotificationId: string;
|
|
14
13
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { QueryPaginate } from '..';
|
|
3
2
|
import { AbyssService, UserTicketCategory } from '../../../enum';
|
|
4
|
-
export interface IGetUserTicketAdminParams
|
|
3
|
+
export interface IGetUserTicketAdminParams {
|
|
5
4
|
userTicketId: string;
|
|
6
5
|
}
|
|
7
6
|
export type IPaginateUserTicketAdminQuery = {
|
|
@@ -10,7 +9,7 @@ export type IPaginateUserTicketAdminQuery = {
|
|
|
10
9
|
category?: UserTicketCategory[];
|
|
11
10
|
userId?: string[];
|
|
12
11
|
} & QueryPaginate;
|
|
13
|
-
export interface IUpdateUserTicketAdminParams
|
|
12
|
+
export interface IUpdateUserTicketAdminParams {
|
|
14
13
|
userTicketId: string;
|
|
15
14
|
}
|
|
16
15
|
export interface IUpdateUserTicketAdminBody {
|
|
@@ -24,35 +23,35 @@ export interface ICreateUserTicketAdminBody {
|
|
|
24
23
|
service: AbyssService;
|
|
25
24
|
userId: string;
|
|
26
25
|
}
|
|
27
|
-
export interface ICloseUserTicketAdminParams
|
|
26
|
+
export interface ICloseUserTicketAdminParams {
|
|
28
27
|
userTicketId: string;
|
|
29
28
|
}
|
|
30
|
-
export interface IPaginateMessageUserTicketAdminParams
|
|
29
|
+
export interface IPaginateMessageUserTicketAdminParams {
|
|
31
30
|
userTicketId: string;
|
|
32
31
|
}
|
|
33
32
|
export type IPaginateMessageUserTicketAdminQuery = {
|
|
34
33
|
userTicketId?: string[];
|
|
35
34
|
userId?: string[];
|
|
36
35
|
} & QueryPaginate;
|
|
37
|
-
export interface IUpdateMessageUserTicketAdminParams
|
|
36
|
+
export interface IUpdateMessageUserTicketAdminParams {
|
|
38
37
|
userTicketId: string;
|
|
39
38
|
userTicketMessageId: string;
|
|
40
39
|
}
|
|
41
40
|
export interface IUpdateMessageUserTicketAdminBody {
|
|
42
41
|
content?: string;
|
|
43
42
|
}
|
|
44
|
-
export interface ICreateMessageUserTicketAdminParams
|
|
43
|
+
export interface ICreateMessageUserTicketAdminParams {
|
|
45
44
|
userTicketId: string;
|
|
46
45
|
}
|
|
47
46
|
export interface ICreateMessageUserTicketAdminBody {
|
|
48
47
|
content: string;
|
|
49
48
|
}
|
|
50
|
-
export interface IRemoveAttachmentMessageUserTicketAdminParams
|
|
49
|
+
export interface IRemoveAttachmentMessageUserTicketAdminParams {
|
|
51
50
|
userTicketId: string;
|
|
52
51
|
userTicketMessageId: string;
|
|
53
52
|
userTicketMessageAttachmentId: string;
|
|
54
53
|
}
|
|
55
|
-
export interface IAddAttachmentMessageUserTicketAdminParams
|
|
54
|
+
export interface IAddAttachmentMessageUserTicketAdminParams {
|
|
56
55
|
userTicketId: string;
|
|
57
56
|
userTicketMessageId: string;
|
|
58
57
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { QueryPaginate } from '..';
|
|
3
2
|
import { AbyssService, UserTicketCategory } from '../../../enum';
|
|
4
|
-
export interface IGetUserTicketParams
|
|
3
|
+
export interface IGetUserTicketParams {
|
|
5
4
|
userTicketId: string;
|
|
6
5
|
}
|
|
7
6
|
export type IPaginateUserTicketQuery = {
|
|
@@ -9,7 +8,7 @@ export type IPaginateUserTicketQuery = {
|
|
|
9
8
|
service?: AbyssService[];
|
|
10
9
|
category?: UserTicketCategory[];
|
|
11
10
|
} & QueryPaginate;
|
|
12
|
-
export interface IUpdateUserTicketParams
|
|
11
|
+
export interface IUpdateUserTicketParams {
|
|
13
12
|
userTicketId: string;
|
|
14
13
|
}
|
|
15
14
|
export interface IUpdateUserTicketBody {
|
|
@@ -23,25 +22,25 @@ export interface ICreateUserTicketBody {
|
|
|
23
22
|
export type IPaginateMessageUserTicketQuery = {
|
|
24
23
|
userTicketId?: string[];
|
|
25
24
|
} & QueryPaginate;
|
|
26
|
-
export interface IUpdateMessageUserTicketParams
|
|
25
|
+
export interface IUpdateMessageUserTicketParams {
|
|
27
26
|
userTicketId: string;
|
|
28
27
|
userTicketMessageId: string;
|
|
29
28
|
}
|
|
30
29
|
export interface IUpdateMessageUserTicketBody {
|
|
31
30
|
content?: string;
|
|
32
31
|
}
|
|
33
|
-
export interface ICreateMessageUserTicketParams
|
|
32
|
+
export interface ICreateMessageUserTicketParams {
|
|
34
33
|
userTicketId: string;
|
|
35
34
|
}
|
|
36
35
|
export interface ICreateMessageUserTicketBody {
|
|
37
36
|
content: string;
|
|
38
37
|
}
|
|
39
|
-
export interface IRemoveAttachmentMessageUserTicketParams
|
|
38
|
+
export interface IRemoveAttachmentMessageUserTicketParams {
|
|
40
39
|
userTicketId: string;
|
|
41
40
|
userTicketMessageId: string;
|
|
42
41
|
userTicketMessageAttachmentId: string;
|
|
43
42
|
}
|
|
44
|
-
export interface IAddAttachmentMessageUserTicketParams
|
|
43
|
+
export interface IAddAttachmentMessageUserTicketParams {
|
|
45
44
|
userTicketId: string;
|
|
46
45
|
userTicketMessageId: string;
|
|
47
46
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { UserTransactionType } from '../../../enum';
|
|
3
2
|
import { QueryPaginate } from '../type-message/base-paginate';
|
|
4
3
|
export type IPaginateUserTransactionAdminQuery = {
|
|
@@ -9,7 +8,7 @@ export type IPaginateUserTransactionAdminQuery = {
|
|
|
9
8
|
projectId?: string[];
|
|
10
9
|
userTransactionId?: string[];
|
|
11
10
|
} & QueryPaginate;
|
|
12
|
-
export interface ICreateUserTransactionAdminParams
|
|
11
|
+
export interface ICreateUserTransactionAdminParams {
|
|
13
12
|
userId: string;
|
|
14
13
|
}
|
|
15
14
|
export interface ICreateUserTransactionAdminBody {
|
|
@@ -19,10 +18,10 @@ export interface ICreateUserTransactionAdminBody {
|
|
|
19
18
|
projectId?: string;
|
|
20
19
|
shouldFailOnNegative?: boolean;
|
|
21
20
|
}
|
|
22
|
-
export interface IDeleteUserTransactionAdminParams
|
|
21
|
+
export interface IDeleteUserTransactionAdminParams {
|
|
23
22
|
userTransactionId: string;
|
|
24
23
|
}
|
|
25
|
-
export interface IUpdateUserTransactionAdminParams
|
|
24
|
+
export interface IUpdateUserTransactionAdminParams {
|
|
26
25
|
userTransactionId: string;
|
|
27
26
|
}
|
|
28
27
|
export interface IUpdateUserTransactionAdminBody {
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import * as core from 'express-serve-static-core';
|
|
2
1
|
import { QueryPaginate } from '..';
|
|
3
2
|
import { AbyssService, UserLanguage } from '../../..';
|
|
4
|
-
export interface IGetUserAdminParams
|
|
3
|
+
export interface IGetUserAdminParams {
|
|
5
4
|
userId: string;
|
|
6
5
|
}
|
|
7
6
|
export type IPaginateUserAdminQuery = {
|
|
@@ -11,7 +10,7 @@ export type IPaginateUserAdminQuery = {
|
|
|
11
10
|
id?: string[];
|
|
12
11
|
hasJoinedNewsletter?: boolean;
|
|
13
12
|
} & QueryPaginate;
|
|
14
|
-
export interface IUpdateUserAdminParams
|
|
13
|
+
export interface IUpdateUserAdminParams {
|
|
15
14
|
userId: string;
|
|
16
15
|
}
|
|
17
16
|
export interface IUpdateUserAdminBody {
|
|
@@ -24,25 +23,25 @@ export interface IUpdateUserAdminBody {
|
|
|
24
23
|
alias?: string;
|
|
25
24
|
emailVerifiedAt?: Date | null;
|
|
26
25
|
}
|
|
27
|
-
export interface IActivateServiceUserAdminParams
|
|
26
|
+
export interface IActivateServiceUserAdminParams {
|
|
28
27
|
userId: string;
|
|
29
28
|
}
|
|
30
29
|
export interface IActivateServiceUserAdminQuery {
|
|
31
30
|
service: Omit<AbyssService, AbyssService.ABYSS | AbyssService.ABYSS_MONITOR | AbyssService.ABYSS_STORAGE>;
|
|
32
31
|
}
|
|
33
|
-
export interface IUpdateSettingsUserAdminParams
|
|
32
|
+
export interface IUpdateSettingsUserAdminParams {
|
|
34
33
|
userId: string;
|
|
35
34
|
}
|
|
36
35
|
export interface IUpdateSettingsUserAdminBody {
|
|
37
36
|
language?: UserLanguage;
|
|
38
37
|
}
|
|
39
|
-
export interface IConnectAsAdminUserAdminParams
|
|
38
|
+
export interface IConnectAsAdminUserAdminParams {
|
|
40
39
|
userId: string;
|
|
41
40
|
}
|
|
42
|
-
export interface IJoinNewsletterUserAdminParams
|
|
41
|
+
export interface IJoinNewsletterUserAdminParams {
|
|
43
42
|
userId: string;
|
|
44
43
|
}
|
|
45
|
-
export interface ILeaveNewsletterUserAdminParams
|
|
44
|
+
export interface ILeaveNewsletterUserAdminParams {
|
|
46
45
|
userId: string;
|
|
47
46
|
}
|
|
48
47
|
export interface IUnsubscribeNewsletterUserAdminBody {
|
|
@@ -2,7 +2,6 @@ import { SubscriptionLevel, UserCreditPurchaseCurrency, UserLanguage } from '../
|
|
|
2
2
|
import { TokenHistoryMetadataUserInvitation } from '../../models/token-history.model';
|
|
3
3
|
import { UserOnboardingStatus } from '../../models/user.model';
|
|
4
4
|
import { QueryPaginate } from '../type-message/base-paginate';
|
|
5
|
-
import * as core from 'express-serve-static-core';
|
|
6
5
|
export interface ISponsorUserQuery {
|
|
7
6
|
email: string;
|
|
8
7
|
}
|
|
@@ -41,7 +40,7 @@ export interface IImportProfilePictureFromCollectionUserBody {
|
|
|
41
40
|
source: string;
|
|
42
41
|
elementId: string;
|
|
43
42
|
}
|
|
44
|
-
export interface ICloudSaveUserParams
|
|
43
|
+
export interface ICloudSaveUserParams {
|
|
45
44
|
cloudId: string;
|
|
46
45
|
}
|
|
47
46
|
export type ICloudSaveUserBody = {
|
|
@@ -62,7 +61,7 @@ export type ICloudSaveUserBody = {
|
|
|
62
61
|
applicationFileId: string;
|
|
63
62
|
};
|
|
64
63
|
});
|
|
65
|
-
export interface ICloudImportUserParams
|
|
64
|
+
export interface ICloudImportUserParams {
|
|
66
65
|
cloudId: string;
|
|
67
66
|
}
|
|
68
67
|
export type ICloudImportUserBody = {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { BasePaginate, IResponse } from '..';
|
|
2
2
|
import { IShortLink } from '../../models/short-link.model';
|
|
3
|
+
import { IShortLinkClick } from '../../models/short-link-click.model';
|
|
3
4
|
export type IPaginateShortLinkAdminResponse = IResponse<BasePaginate<IShortLink>>;
|
|
4
5
|
export interface IGetShortLinkAdminData {
|
|
5
6
|
shortLink: IShortLink;
|
|
@@ -12,3 +13,4 @@ export interface IUpdateShortLinkAdminData {
|
|
|
12
13
|
shortLink: IShortLink;
|
|
13
14
|
}
|
|
14
15
|
export type IUpdateShortLinkAdminResponse = IResponse<IUpdateShortLinkAdminData>;
|
|
16
|
+
export type IGetClicksShortLinkAdminResponse = IResponse<BasePaginate<IShortLinkClick>>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { BasePaginate, IResponse } from '..';
|
|
2
|
+
import { IShortLink, IShortLinkWithStats } from '../../models/short-link.model';
|
|
3
|
+
import { IShortLinkClick } from '../../models/short-link-click.model';
|
|
4
|
+
export interface ICreateShortLinkPublicData {
|
|
5
|
+
shortLink: IShortLink;
|
|
6
|
+
}
|
|
7
|
+
export type ICreateShortLinkPublicResponse = IResponse<ICreateShortLinkPublicData>;
|
|
8
|
+
export interface IRedirectShortLinkPublicData {
|
|
9
|
+
url: string;
|
|
10
|
+
}
|
|
11
|
+
export type IRedirectShortLinkPublicResponse = IResponse<IRedirectShortLinkPublicData>;
|
|
12
|
+
export interface IGetStatsShortLinkPublicData {
|
|
13
|
+
shortLink: IShortLinkWithStats;
|
|
14
|
+
}
|
|
15
|
+
export type IGetStatsShortLinkPublicResponse = IResponse<IGetStatsShortLinkPublicData>;
|
|
16
|
+
export interface IRenewShortLinkPublicData {
|
|
17
|
+
shortLink: IShortLink;
|
|
18
|
+
}
|
|
19
|
+
export type IRenewShortLinkPublicResponse = IResponse<IRenewShortLinkPublicData>;
|
|
20
|
+
export type IGetClicksShortLinkPublicResponse = IResponse<BasePaginate<IShortLinkClick>>;
|
|
@@ -1,18 +1,10 @@
|
|
|
1
1
|
import { BasePaginate, IResponse } from '..';
|
|
2
2
|
import { IShortLink, IShortLinkWithStats } from '../../models/short-link.model';
|
|
3
|
+
import { IShortLinkClick } from '../../models/short-link-click.model';
|
|
3
4
|
export interface IGetShortLinkData {
|
|
4
5
|
shortLink: IShortLink;
|
|
5
6
|
}
|
|
6
7
|
export type IGetShortLinkResponse = IResponse<IGetShortLinkData>;
|
|
7
|
-
export interface IGetShortLinkBySlugData {
|
|
8
|
-
shortLink: IShortLink;
|
|
9
|
-
requiresPassword: boolean;
|
|
10
|
-
}
|
|
11
|
-
export type IGetShortLinkBySlugResponse = IResponse<IGetShortLinkBySlugData>;
|
|
12
|
-
export interface IValidateShortLinkPasswordData {
|
|
13
|
-
valid: boolean;
|
|
14
|
-
}
|
|
15
|
-
export type IValidateShortLinkPasswordResponse = IResponse<IValidateShortLinkPasswordData>;
|
|
16
8
|
export type IPaginateShortLinkResponse = IResponse<BasePaginate<IShortLink>>;
|
|
17
9
|
export interface ICreateShortLinkData {
|
|
18
10
|
shortLink: IShortLink;
|
|
@@ -25,11 +17,8 @@ export type IUpdateShortLinkResponse = IResponse<IUpdateShortLinkData>;
|
|
|
25
17
|
export interface IDeleteShortLinkData {
|
|
26
18
|
}
|
|
27
19
|
export type IDeleteShortLinkResponse = IResponse<IDeleteShortLinkData>;
|
|
28
|
-
export interface
|
|
20
|
+
export interface IGetStatsShortLinkData {
|
|
29
21
|
shortLink: IShortLinkWithStats;
|
|
30
22
|
}
|
|
31
|
-
export type
|
|
32
|
-
export
|
|
33
|
-
url: string;
|
|
34
|
-
}
|
|
35
|
-
export type IRedirectShortLinkResponse = IResponse<IRedirectShortLinkData>;
|
|
23
|
+
export type IGetStatsShortLinkResponse = IResponse<IGetStatsShortLinkData>;
|
|
24
|
+
export type IGetClicksShortLinkResponse = IResponse<BasePaginate<IShortLinkClick>>;
|
|
@@ -6,11 +6,23 @@ export interface IShortLinkClick {
|
|
|
6
6
|
ipHash: string;
|
|
7
7
|
userAgent: string | null;
|
|
8
8
|
referer: string | null;
|
|
9
|
-
|
|
9
|
+
refererDomain: string | null;
|
|
10
|
+
countryCodeIso: string | null;
|
|
11
|
+
countryCode: string | null;
|
|
12
|
+
countryName: string | null;
|
|
13
|
+
continentCode: string | null;
|
|
10
14
|
city: string | null;
|
|
11
15
|
device: string | null;
|
|
12
16
|
browser: string | null;
|
|
13
17
|
os: string | null;
|
|
18
|
+
language: string | null;
|
|
19
|
+
utmSource: string | null;
|
|
20
|
+
utmMedium: string | null;
|
|
21
|
+
utmCampaign: string | null;
|
|
22
|
+
utmTerm: string | null;
|
|
23
|
+
utmContent: string | null;
|
|
24
|
+
isBotLikely: boolean;
|
|
25
|
+
isReturningVisitor: boolean;
|
|
14
26
|
clickedAt: Date;
|
|
15
27
|
createdAt?: Date;
|
|
16
28
|
updatedAt?: Date;
|
|
@@ -33,6 +33,7 @@ export interface IShortLinkWithStats extends IShortLink {
|
|
|
33
33
|
clicksByCountry: {
|
|
34
34
|
country: string;
|
|
35
35
|
clicks: number;
|
|
36
|
+
countryName: string;
|
|
36
37
|
}[];
|
|
37
38
|
clicksByDevice: {
|
|
38
39
|
device: string;
|
|
@@ -46,5 +47,20 @@ export interface IShortLinkWithStats extends IShortLink {
|
|
|
46
47
|
referer: string;
|
|
47
48
|
clicks: number;
|
|
48
49
|
}[];
|
|
50
|
+
clicksByUtmSource: {
|
|
51
|
+
utmSource: string;
|
|
52
|
+
clicks: number;
|
|
53
|
+
}[];
|
|
54
|
+
clicksByLanguage: {
|
|
55
|
+
language: string;
|
|
56
|
+
clicks: number;
|
|
57
|
+
}[];
|
|
58
|
+
clicksByRefererDomain: {
|
|
59
|
+
refererDomain: string;
|
|
60
|
+
clicks: number;
|
|
61
|
+
}[];
|
|
62
|
+
clicksLast24h: number;
|
|
63
|
+
returningVisitorsCount: number;
|
|
64
|
+
botClicksCount: number;
|
|
49
65
|
};
|
|
50
66
|
}
|
package/dist/utils/index.d.ts
CHANGED
package/dist/utils/index.js
CHANGED
|
@@ -30,3 +30,6 @@ __exportStar(require("./file.utils"), exports);
|
|
|
30
30
|
__exportStar(require("./compression.utils"), exports);
|
|
31
31
|
__exportStar(require("./shape.utils"), exports);
|
|
32
32
|
__exportStar(require("./icons.utils"), exports);
|
|
33
|
+
__exportStar(require("./string.utils"), exports);
|
|
34
|
+
__exportStar(require("./tracking.utils"), exports);
|
|
35
|
+
__exportStar(require("./duration.utils"), exports);
|