@aepstore-dev/contracts 1.82.0 → 1.84.0
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/gen/notifications.d.ts +29 -0
- package/gen/notifications.js +2 -0
- package/gen/notifications.ts +43 -0
- package/package.json +1 -1
- package/proto/notifications.proto +30 -0
package/gen/notifications.d.ts
CHANGED
|
@@ -25,6 +25,8 @@ export interface ListNotificationsRequest {
|
|
|
25
25
|
isRead: string;
|
|
26
26
|
page: number;
|
|
27
27
|
limit: number;
|
|
28
|
+
entityType: string;
|
|
29
|
+
entityId: string;
|
|
28
30
|
}
|
|
29
31
|
export interface NotificationsListResponse {
|
|
30
32
|
items: Notification[];
|
|
@@ -48,23 +50,50 @@ export interface MarkAllNotificationsReadRequest {
|
|
|
48
50
|
userId: string;
|
|
49
51
|
category: string;
|
|
50
52
|
type: string;
|
|
53
|
+
entityType: string;
|
|
54
|
+
entityId: string;
|
|
51
55
|
}
|
|
52
56
|
export interface MarkAllNotificationsReadResponse {
|
|
53
57
|
updatedCount: number;
|
|
54
58
|
unreadCount: number;
|
|
55
59
|
}
|
|
60
|
+
export interface DeleteNotificationRequest {
|
|
61
|
+
userId: string;
|
|
62
|
+
notificationId: string;
|
|
63
|
+
}
|
|
64
|
+
export interface DeleteNotificationResponse {
|
|
65
|
+
notificationId: string;
|
|
66
|
+
unreadCount: number;
|
|
67
|
+
}
|
|
68
|
+
export interface DeleteNotificationsRequest {
|
|
69
|
+
userId: string;
|
|
70
|
+
category: string;
|
|
71
|
+
type: string;
|
|
72
|
+
/** empty|true|false */
|
|
73
|
+
isRead: string;
|
|
74
|
+
entityType: string;
|
|
75
|
+
entityId: string;
|
|
76
|
+
}
|
|
77
|
+
export interface DeleteNotificationsResponse {
|
|
78
|
+
deletedCount: number;
|
|
79
|
+
unreadCount: number;
|
|
80
|
+
}
|
|
56
81
|
export declare const NOTIFICATIONS_V1_PACKAGE_NAME = "notifications.v1";
|
|
57
82
|
export interface NotificationsServiceClient {
|
|
58
83
|
listNotifications(request: ListNotificationsRequest): Observable<NotificationsListResponse>;
|
|
59
84
|
getUnreadCount(request: GetUnreadCountRequest): Observable<UnreadCountResponse>;
|
|
60
85
|
markNotificationRead(request: MarkNotificationReadRequest): Observable<Notification>;
|
|
61
86
|
markAllNotificationsRead(request: MarkAllNotificationsReadRequest): Observable<MarkAllNotificationsReadResponse>;
|
|
87
|
+
deleteNotification(request: DeleteNotificationRequest): Observable<DeleteNotificationResponse>;
|
|
88
|
+
deleteNotifications(request: DeleteNotificationsRequest): Observable<DeleteNotificationsResponse>;
|
|
62
89
|
}
|
|
63
90
|
export interface NotificationsServiceController {
|
|
64
91
|
listNotifications(request: ListNotificationsRequest): Promise<NotificationsListResponse> | Observable<NotificationsListResponse> | NotificationsListResponse;
|
|
65
92
|
getUnreadCount(request: GetUnreadCountRequest): Promise<UnreadCountResponse> | Observable<UnreadCountResponse> | UnreadCountResponse;
|
|
66
93
|
markNotificationRead(request: MarkNotificationReadRequest): Promise<Notification> | Observable<Notification> | Notification;
|
|
67
94
|
markAllNotificationsRead(request: MarkAllNotificationsReadRequest): Promise<MarkAllNotificationsReadResponse> | Observable<MarkAllNotificationsReadResponse> | MarkAllNotificationsReadResponse;
|
|
95
|
+
deleteNotification(request: DeleteNotificationRequest): Promise<DeleteNotificationResponse> | Observable<DeleteNotificationResponse> | DeleteNotificationResponse;
|
|
96
|
+
deleteNotifications(request: DeleteNotificationsRequest): Promise<DeleteNotificationsResponse> | Observable<DeleteNotificationsResponse> | DeleteNotificationsResponse;
|
|
68
97
|
}
|
|
69
98
|
export declare function NotificationsServiceControllerMethods(): (constructor: Function) => void;
|
|
70
99
|
export declare const NOTIFICATIONS_SERVICE_NAME = "NotificationsService";
|
package/gen/notifications.js
CHANGED
|
@@ -18,6 +18,8 @@ function NotificationsServiceControllerMethods() {
|
|
|
18
18
|
"getUnreadCount",
|
|
19
19
|
"markNotificationRead",
|
|
20
20
|
"markAllNotificationsRead",
|
|
21
|
+
"deleteNotification",
|
|
22
|
+
"deleteNotifications",
|
|
21
23
|
];
|
|
22
24
|
for (const method of grpcMethods) {
|
|
23
25
|
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
package/gen/notifications.ts
CHANGED
|
@@ -37,6 +37,8 @@ export interface ListNotificationsRequest {
|
|
|
37
37
|
isRead: string;
|
|
38
38
|
page: number;
|
|
39
39
|
limit: number;
|
|
40
|
+
entityType: string;
|
|
41
|
+
entityId: string;
|
|
40
42
|
}
|
|
41
43
|
|
|
42
44
|
export interface NotificationsListResponse {
|
|
@@ -65,6 +67,8 @@ export interface MarkAllNotificationsReadRequest {
|
|
|
65
67
|
userId: string;
|
|
66
68
|
category: string;
|
|
67
69
|
type: string;
|
|
70
|
+
entityType: string;
|
|
71
|
+
entityId: string;
|
|
68
72
|
}
|
|
69
73
|
|
|
70
74
|
export interface MarkAllNotificationsReadResponse {
|
|
@@ -72,6 +76,31 @@ export interface MarkAllNotificationsReadResponse {
|
|
|
72
76
|
unreadCount: number;
|
|
73
77
|
}
|
|
74
78
|
|
|
79
|
+
export interface DeleteNotificationRequest {
|
|
80
|
+
userId: string;
|
|
81
|
+
notificationId: string;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export interface DeleteNotificationResponse {
|
|
85
|
+
notificationId: string;
|
|
86
|
+
unreadCount: number;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export interface DeleteNotificationsRequest {
|
|
90
|
+
userId: string;
|
|
91
|
+
category: string;
|
|
92
|
+
type: string;
|
|
93
|
+
/** empty|true|false */
|
|
94
|
+
isRead: string;
|
|
95
|
+
entityType: string;
|
|
96
|
+
entityId: string;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
export interface DeleteNotificationsResponse {
|
|
100
|
+
deletedCount: number;
|
|
101
|
+
unreadCount: number;
|
|
102
|
+
}
|
|
103
|
+
|
|
75
104
|
export const NOTIFICATIONS_V1_PACKAGE_NAME = "notifications.v1";
|
|
76
105
|
|
|
77
106
|
export interface NotificationsServiceClient {
|
|
@@ -82,6 +111,10 @@ export interface NotificationsServiceClient {
|
|
|
82
111
|
markNotificationRead(request: MarkNotificationReadRequest): Observable<Notification>;
|
|
83
112
|
|
|
84
113
|
markAllNotificationsRead(request: MarkAllNotificationsReadRequest): Observable<MarkAllNotificationsReadResponse>;
|
|
114
|
+
|
|
115
|
+
deleteNotification(request: DeleteNotificationRequest): Observable<DeleteNotificationResponse>;
|
|
116
|
+
|
|
117
|
+
deleteNotifications(request: DeleteNotificationsRequest): Observable<DeleteNotificationsResponse>;
|
|
85
118
|
}
|
|
86
119
|
|
|
87
120
|
export interface NotificationsServiceController {
|
|
@@ -103,6 +136,14 @@ export interface NotificationsServiceController {
|
|
|
103
136
|
| Promise<MarkAllNotificationsReadResponse>
|
|
104
137
|
| Observable<MarkAllNotificationsReadResponse>
|
|
105
138
|
| MarkAllNotificationsReadResponse;
|
|
139
|
+
|
|
140
|
+
deleteNotification(
|
|
141
|
+
request: DeleteNotificationRequest,
|
|
142
|
+
): Promise<DeleteNotificationResponse> | Observable<DeleteNotificationResponse> | DeleteNotificationResponse;
|
|
143
|
+
|
|
144
|
+
deleteNotifications(
|
|
145
|
+
request: DeleteNotificationsRequest,
|
|
146
|
+
): Promise<DeleteNotificationsResponse> | Observable<DeleteNotificationsResponse> | DeleteNotificationsResponse;
|
|
106
147
|
}
|
|
107
148
|
|
|
108
149
|
export function NotificationsServiceControllerMethods() {
|
|
@@ -112,6 +153,8 @@ export function NotificationsServiceControllerMethods() {
|
|
|
112
153
|
"getUnreadCount",
|
|
113
154
|
"markNotificationRead",
|
|
114
155
|
"markAllNotificationsRead",
|
|
156
|
+
"deleteNotification",
|
|
157
|
+
"deleteNotifications",
|
|
115
158
|
];
|
|
116
159
|
for (const method of grpcMethods) {
|
|
117
160
|
const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
package/package.json
CHANGED
|
@@ -7,6 +7,8 @@ service NotificationsService {
|
|
|
7
7
|
rpc GetUnreadCount(GetUnreadCountRequest) returns (UnreadCountResponse);
|
|
8
8
|
rpc MarkNotificationRead(MarkNotificationReadRequest) returns (Notification);
|
|
9
9
|
rpc MarkAllNotificationsRead(MarkAllNotificationsReadRequest) returns (MarkAllNotificationsReadResponse);
|
|
10
|
+
rpc DeleteNotification(DeleteNotificationRequest) returns (DeleteNotificationResponse);
|
|
11
|
+
rpc DeleteNotifications(DeleteNotificationsRequest) returns (DeleteNotificationsResponse);
|
|
10
12
|
}
|
|
11
13
|
|
|
12
14
|
message NotificationEntity {
|
|
@@ -34,6 +36,8 @@ message ListNotificationsRequest {
|
|
|
34
36
|
string is_read = 4; // empty|true|false
|
|
35
37
|
int32 page = 5;
|
|
36
38
|
int32 limit = 6;
|
|
39
|
+
string entity_type = 7;
|
|
40
|
+
string entity_id = 8;
|
|
37
41
|
}
|
|
38
42
|
|
|
39
43
|
message NotificationsListResponse {
|
|
@@ -62,9 +66,35 @@ message MarkAllNotificationsReadRequest {
|
|
|
62
66
|
string user_id = 1;
|
|
63
67
|
string category = 2;
|
|
64
68
|
string type = 3;
|
|
69
|
+
string entity_type = 4;
|
|
70
|
+
string entity_id = 5;
|
|
65
71
|
}
|
|
66
72
|
|
|
67
73
|
message MarkAllNotificationsReadResponse {
|
|
68
74
|
int32 updated_count = 1;
|
|
69
75
|
int32 unread_count = 2;
|
|
70
76
|
}
|
|
77
|
+
|
|
78
|
+
message DeleteNotificationRequest {
|
|
79
|
+
string user_id = 1;
|
|
80
|
+
string notification_id = 2;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
message DeleteNotificationResponse {
|
|
84
|
+
string notification_id = 1;
|
|
85
|
+
int32 unread_count = 2;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
message DeleteNotificationsRequest {
|
|
89
|
+
string user_id = 1;
|
|
90
|
+
string category = 2;
|
|
91
|
+
string type = 3;
|
|
92
|
+
string is_read = 4; // empty|true|false
|
|
93
|
+
string entity_type = 5;
|
|
94
|
+
string entity_id = 6;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
message DeleteNotificationsResponse {
|
|
98
|
+
int32 deleted_count = 1;
|
|
99
|
+
int32 unread_count = 2;
|
|
100
|
+
}
|