@ibiliaze/global-vars 1.138.0 → 1.139.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.
@@ -1,31 +1,88 @@
1
- export declare const flowFlowDefs: readonly [{
1
+ import type { FlowBase } from '../inputsDefault';
2
+ export declare const flowFlowDefs: <TId, TDate>() => readonly [{
2
3
  readonly method: "post";
3
4
  readonly path: "/flow";
4
5
  readonly role: "postFlow";
5
6
  readonly name: "Create flow";
7
+ readonly response_201: {
8
+ flow: FlowBase<TId, TDate>;
9
+ message: string;
10
+ };
11
+ readonly response_500: {
12
+ message: string;
13
+ error: string;
14
+ };
6
15
  }, {
7
16
  readonly method: "get";
8
17
  readonly path: "/flow";
9
18
  readonly role: "getFlows";
10
19
  readonly name: "Get flows";
20
+ readonly response_200: {
21
+ flows: FlowBase<TId, TDate>[];
22
+ count: number;
23
+ };
24
+ readonly response_500: {
25
+ message: string;
26
+ error: string;
27
+ };
11
28
  }, {
12
29
  readonly method: "get";
13
30
  readonly path: "/flow/api";
14
31
  readonly role: "getFlowApis";
15
32
  readonly name: "Get APIs";
33
+ readonly response_200: {
34
+ apis: unknown;
35
+ };
36
+ readonly response_500: {
37
+ message: string;
38
+ error: string;
39
+ };
16
40
  }, {
17
41
  readonly method: "get";
18
42
  readonly path: "/flow/:id";
19
43
  readonly role: "getFlowById";
20
44
  readonly name: "Get flow";
45
+ readonly response_200: {
46
+ flow: FlowBase<TId, TDate> | null;
47
+ message: string;
48
+ };
49
+ readonly response_404: {
50
+ message: string;
51
+ error: string;
52
+ };
21
53
  }, {
22
54
  readonly method: "put";
23
55
  readonly path: "/flow/:id";
24
56
  readonly role: "putFlowById";
25
57
  readonly name: "Update flow";
58
+ readonly response_200: {
59
+ flow: FlowBase<TId, TDate>;
60
+ message: string;
61
+ };
62
+ readonly response_404: {
63
+ flow: FlowBase<TId, TDate> | null;
64
+ message: string;
65
+ error?: string;
66
+ };
67
+ readonly response_500: {
68
+ message: string;
69
+ error: string;
70
+ };
26
71
  }, {
27
72
  readonly method: "delete";
28
73
  readonly path: "/flow/:id";
29
74
  readonly role: "deleteFlowById";
30
75
  readonly name: "Delete flow";
76
+ readonly response_200: {
77
+ flow: FlowBase<TId, TDate>;
78
+ message: string;
79
+ };
80
+ readonly response_404: {
81
+ flow: FlowBase<TId, TDate> | null;
82
+ message: string;
83
+ };
84
+ readonly response_500: {
85
+ message: string;
86
+ error: string;
87
+ };
31
88
  }];
@@ -1,11 +1,58 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.flowFlowDefs = void 0;
4
- exports.flowFlowDefs = [
5
- { method: 'post', path: '/flow', role: 'postFlow', name: 'Create flow' },
6
- { method: 'get', path: '/flow', role: 'getFlows', name: 'Get flows' },
7
- { method: 'get', path: '/flow/api', role: 'getFlowApis', name: 'Get APIs' },
8
- { method: 'get', path: '/flow/:id', role: 'getFlowById', name: 'Get flow' },
9
- { method: 'put', path: '/flow/:id', role: 'putFlowById', name: 'Update flow' },
10
- { method: 'delete', path: '/flow/:id', role: 'deleteFlowById', name: 'Delete flow' },
11
- ];
4
+ const flowFlowDefs = () => {
5
+ return [
6
+ {
7
+ method: 'post',
8
+ path: '/flow',
9
+ role: 'postFlow',
10
+ name: 'Create flow',
11
+ response_201: {},
12
+ response_500: {},
13
+ },
14
+ {
15
+ method: 'get',
16
+ path: '/flow',
17
+ role: 'getFlows',
18
+ name: 'Get flows',
19
+ response_200: {},
20
+ response_500: {},
21
+ },
22
+ {
23
+ method: 'get',
24
+ path: '/flow/api',
25
+ role: 'getFlowApis',
26
+ name: 'Get APIs',
27
+ response_200: {},
28
+ response_500: {},
29
+ },
30
+ {
31
+ method: 'get',
32
+ path: '/flow/:id',
33
+ role: 'getFlowById',
34
+ name: 'Get flow',
35
+ response_200: {},
36
+ response_404: {},
37
+ },
38
+ {
39
+ method: 'put',
40
+ path: '/flow/:id',
41
+ role: 'putFlowById',
42
+ name: 'Update flow',
43
+ response_200: {},
44
+ response_404: {},
45
+ response_500: {},
46
+ },
47
+ {
48
+ method: 'delete',
49
+ path: '/flow/:id',
50
+ role: 'deleteFlowById',
51
+ name: 'Delete flow',
52
+ response_200: {},
53
+ response_404: {},
54
+ response_500: {},
55
+ },
56
+ ];
57
+ };
58
+ exports.flowFlowDefs = flowFlowDefs;
@@ -1,26 +1,76 @@
1
- export declare const groupRoleDefs: readonly [{
1
+ import type { GroupBase } from '../inputsDefault';
2
+ export declare const groupRoleDefs: <TId, TDate>() => readonly [{
2
3
  readonly method: "post";
3
4
  readonly path: "/group";
4
5
  readonly role: "postGroup";
5
6
  readonly name: "Create group";
7
+ readonly response_201: {
8
+ group: GroupBase<TId, TDate>;
9
+ message: string;
10
+ };
11
+ readonly response_500: {
12
+ message: string;
13
+ error: string;
14
+ };
6
15
  }, {
7
16
  readonly method: "get";
8
17
  readonly path: "/group";
9
18
  readonly role: "getGroups";
10
19
  readonly name: "Get groups";
20
+ readonly response_200: {
21
+ groups: GroupBase<TId, TDate>[];
22
+ count: number;
23
+ };
24
+ readonly response_500: {
25
+ message: string;
26
+ error: string;
27
+ };
11
28
  }, {
12
29
  readonly method: "get";
13
30
  readonly path: "/group/:id";
14
31
  readonly role: "getGroupById";
15
32
  readonly name: "Get group";
33
+ readonly response_200: {
34
+ group: GroupBase<TId, TDate> | null;
35
+ message: string;
36
+ };
37
+ readonly response_404: {
38
+ message: string;
39
+ error: string;
40
+ };
16
41
  }, {
17
42
  readonly method: "put";
18
43
  readonly path: "/group/:id";
19
44
  readonly role: "putGroupById";
20
45
  readonly name: "Update group";
46
+ readonly response_200: {
47
+ group: GroupBase<TId, TDate>;
48
+ message: string;
49
+ };
50
+ readonly response_404: {
51
+ group?: GroupBase<TId, TDate> | null;
52
+ message: string;
53
+ error?: string;
54
+ };
55
+ readonly response_500: {
56
+ message: string;
57
+ error: string;
58
+ };
21
59
  }, {
22
60
  readonly method: "delete";
23
61
  readonly path: "/group/:id";
24
62
  readonly role: "deleteGroupById";
25
63
  readonly name: "Delete group";
64
+ readonly response_200: {
65
+ group: GroupBase<TId, TDate>;
66
+ message: string;
67
+ };
68
+ readonly response_404: {
69
+ group?: GroupBase<TId, TDate> | null;
70
+ message: string;
71
+ };
72
+ readonly response_500: {
73
+ message: string;
74
+ error: string;
75
+ };
26
76
  }];
@@ -1,10 +1,50 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.groupRoleDefs = void 0;
4
- exports.groupRoleDefs = [
5
- { method: 'post', path: '/group', role: 'postGroup', name: 'Create group' },
6
- { method: 'get', path: '/group', role: 'getGroups', name: 'Get groups' },
7
- { method: 'get', path: '/group/:id', role: 'getGroupById', name: 'Get group' },
8
- { method: 'put', path: '/group/:id', role: 'putGroupById', name: 'Update group' },
9
- { method: 'delete', path: '/group/:id', role: 'deleteGroupById', name: 'Delete group' },
10
- ];
4
+ const groupRoleDefs = () => {
5
+ return [
6
+ {
7
+ method: 'post',
8
+ path: '/group',
9
+ role: 'postGroup',
10
+ name: 'Create group',
11
+ response_201: {},
12
+ response_500: {},
13
+ },
14
+ {
15
+ method: 'get',
16
+ path: '/group',
17
+ role: 'getGroups',
18
+ name: 'Get groups',
19
+ response_200: {},
20
+ response_500: {},
21
+ },
22
+ {
23
+ method: 'get',
24
+ path: '/group/:id',
25
+ role: 'getGroupById',
26
+ name: 'Get group',
27
+ response_200: {},
28
+ response_404: {},
29
+ },
30
+ {
31
+ method: 'put',
32
+ path: '/group/:id',
33
+ role: 'putGroupById',
34
+ name: 'Update group',
35
+ response_200: {},
36
+ response_404: {},
37
+ response_500: {},
38
+ },
39
+ {
40
+ method: 'delete',
41
+ path: '/group/:id',
42
+ role: 'deleteGroupById',
43
+ name: 'Delete group',
44
+ response_200: {},
45
+ response_404: {},
46
+ response_500: {},
47
+ },
48
+ ];
49
+ };
50
+ exports.groupRoleDefs = groupRoleDefs;
@@ -1,41 +1,125 @@
1
- export declare const jobRoleDefs: readonly [{
1
+ import type { CampaignBase, GroupBase, JobBase } from '../inputsDefault';
2
+ export declare const jobRoleDefs: <TId, TDate>() => readonly [{
2
3
  readonly method: "post";
3
4
  readonly path: "/job";
4
5
  readonly role: "postJob";
5
6
  readonly name: "Create job";
7
+ readonly response_201: {
8
+ job: JobBase<TId, TDate>;
9
+ message: string;
10
+ };
11
+ readonly response_500: {
12
+ message: string;
13
+ error: string;
14
+ };
6
15
  }, {
7
16
  readonly method: "post";
8
17
  readonly path: "/job/many";
9
18
  readonly role: "postJobMany";
10
19
  readonly name: "Create many jobs";
20
+ readonly response_201: {
21
+ jobs: JobBase<TId, TDate>[];
22
+ message: string;
23
+ };
24
+ readonly response_500: {
25
+ message: string;
26
+ error: string;
27
+ };
11
28
  }, {
12
29
  readonly method: "post";
13
30
  readonly path: "/job/start/:id";
14
31
  readonly role: "postJobStartById";
15
32
  readonly name: "Run job by ID";
33
+ readonly response_201: {
34
+ job: JobBase<TId, TDate>;
35
+ message: string;
36
+ };
37
+ readonly response_404: {
38
+ message: string;
39
+ };
40
+ readonly response_500: {
41
+ message: string;
42
+ error: string;
43
+ };
16
44
  }, {
17
45
  readonly method: "get";
18
46
  readonly path: "/job";
19
47
  readonly role: "getJobs";
20
48
  readonly name: "Get jobs";
49
+ readonly response_200: {
50
+ jobs: JobBase<TId, TDate>[];
51
+ count: number;
52
+ };
53
+ readonly response_500: {
54
+ message: string;
55
+ error: string;
56
+ };
21
57
  }, {
22
58
  readonly method: "get";
23
59
  readonly path: "/job/:id";
24
60
  readonly role: "getJobById";
25
61
  readonly name: "Get job";
62
+ readonly response_200: {
63
+ job: JobBase<TId, TDate> | null;
64
+ message: string;
65
+ };
66
+ readonly response_404: {
67
+ message: string;
68
+ error: string;
69
+ };
26
70
  }, {
27
71
  readonly method: "get";
28
72
  readonly path: "/job/details/:id";
29
73
  readonly role: "getJobDetailsById";
30
74
  readonly name: "Get job details";
75
+ readonly response_200: {
76
+ job: JobBase<TId, TDate>;
77
+ campaign: CampaignBase<TId, TDate> | null;
78
+ group: GroupBase<TId, TDate> | null;
79
+ template: GroupBase<TId, TDate> | null;
80
+ message: string;
81
+ };
82
+ readonly response_400: {
83
+ job?: JobBase<TId, TDate> | null;
84
+ message: string;
85
+ };
86
+ readonly response_404: {
87
+ job?: JobBase<TId, TDate> | null;
88
+ message: string;
89
+ error: string;
90
+ };
31
91
  }, {
32
92
  readonly method: "put";
33
93
  readonly path: "/job/:id";
34
94
  readonly role: "putJobById";
35
95
  readonly name: "Update job";
96
+ readonly response_200: {
97
+ job: JobBase<TId, TDate>;
98
+ message: string;
99
+ };
100
+ readonly response_404: {
101
+ job?: JobBase<TId, TDate> | null;
102
+ message: string;
103
+ };
104
+ readonly response_500: {
105
+ message: string;
106
+ error: string;
107
+ };
36
108
  }, {
37
109
  readonly method: "delete";
38
110
  readonly path: "/job/:id";
39
111
  readonly role: "deleteJobById";
40
112
  readonly name: "Delete job";
113
+ readonly response_200: {
114
+ job: JobBase<TId, TDate>;
115
+ message: string;
116
+ };
117
+ readonly response_404: {
118
+ job?: JobBase<TId, TDate> | null;
119
+ message: string;
120
+ };
121
+ readonly response_500: {
122
+ message: string;
123
+ error: string;
124
+ };
41
125
  }];
@@ -1,13 +1,76 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.jobRoleDefs = void 0;
4
- exports.jobRoleDefs = [
5
- { method: 'post', path: '/job', role: 'postJob', name: 'Create job' },
6
- { method: 'post', path: '/job/many', role: 'postJobMany', name: 'Create many jobs' },
7
- { method: 'post', path: '/job/start/:id', role: 'postJobStartById', name: 'Run job by ID' },
8
- { method: 'get', path: '/job', role: 'getJobs', name: 'Get jobs' },
9
- { method: 'get', path: '/job/:id', role: 'getJobById', name: 'Get job' },
10
- { method: 'get', path: '/job/details/:id', role: 'getJobDetailsById', name: 'Get job details' },
11
- { method: 'put', path: '/job/:id', role: 'putJobById', name: 'Update job' },
12
- { method: 'delete', path: '/job/:id', role: 'deleteJobById', name: 'Delete job' },
13
- ];
4
+ const jobRoleDefs = () => {
5
+ return [
6
+ {
7
+ method: 'post',
8
+ path: '/job',
9
+ role: 'postJob',
10
+ name: 'Create job',
11
+ response_201: {},
12
+ response_500: {},
13
+ },
14
+ {
15
+ method: 'post',
16
+ path: '/job/many',
17
+ role: 'postJobMany',
18
+ name: 'Create many jobs',
19
+ response_201: {},
20
+ response_500: {},
21
+ },
22
+ {
23
+ method: 'post',
24
+ path: '/job/start/:id',
25
+ role: 'postJobStartById',
26
+ name: 'Run job by ID',
27
+ response_201: {},
28
+ response_404: {},
29
+ response_500: {},
30
+ },
31
+ {
32
+ method: 'get',
33
+ path: '/job',
34
+ role: 'getJobs',
35
+ name: 'Get jobs',
36
+ response_200: {},
37
+ response_500: {},
38
+ },
39
+ {
40
+ method: 'get',
41
+ path: '/job/:id',
42
+ role: 'getJobById',
43
+ name: 'Get job',
44
+ response_200: {},
45
+ response_404: {},
46
+ },
47
+ {
48
+ method: 'get',
49
+ path: '/job/details/:id',
50
+ role: 'getJobDetailsById',
51
+ name: 'Get job details',
52
+ response_200: {},
53
+ response_400: {},
54
+ response_404: {},
55
+ },
56
+ {
57
+ method: 'put',
58
+ path: '/job/:id',
59
+ role: 'putJobById',
60
+ name: 'Update job',
61
+ response_200: {},
62
+ response_404: {},
63
+ response_500: {},
64
+ },
65
+ {
66
+ method: 'delete',
67
+ path: '/job/:id',
68
+ role: 'deleteJobById',
69
+ name: 'Delete job',
70
+ response_200: {},
71
+ response_404: {},
72
+ response_500: {},
73
+ },
74
+ ];
75
+ };
76
+ exports.jobRoleDefs = jobRoleDefs;
@@ -1,16 +1,44 @@
1
- export declare const logRoleDefs: readonly [{
1
+ import type { LogBase } from '../inputsDefault';
2
+ export declare const logRoleDefs: <TId, TDate>() => readonly [{
2
3
  readonly method: "get";
3
4
  readonly path: "/log";
4
5
  readonly role: "getLogs";
5
6
  readonly name: "Get logs";
7
+ readonly response_200: {
8
+ logs: LogBase<TId, TDate>[];
9
+ count: number;
10
+ };
11
+ readonly response_500: {
12
+ message: string;
13
+ error: string;
14
+ };
6
15
  }, {
7
16
  readonly method: "delete";
8
17
  readonly path: "/log/all";
9
18
  readonly role: "deleteLogsAll";
10
19
  readonly name: "Delete all logs";
20
+ readonly response_200: {
21
+ message: string;
22
+ };
23
+ readonly response_500: {
24
+ message: string;
25
+ error: string;
26
+ };
11
27
  }, {
12
28
  readonly method: "delete";
13
29
  readonly path: "/log/:id";
14
30
  readonly role: "deleteLogById";
15
31
  readonly name: "Delete log by ID";
32
+ readonly response_200: {
33
+ log: LogBase<TId, TDate>;
34
+ message: string;
35
+ };
36
+ readonly response_404: {
37
+ log: LogBase<TId, TDate> | null;
38
+ message: string;
39
+ };
40
+ readonly response_500: {
41
+ message: string;
42
+ error: string;
43
+ };
16
44
  }];
@@ -1,8 +1,33 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.logRoleDefs = void 0;
4
- exports.logRoleDefs = [
5
- { method: 'get', path: '/log', role: 'getLogs', name: 'Get logs' },
6
- { method: 'delete', path: '/log/all', role: 'deleteLogsAll', name: 'Delete all logs' },
7
- { method: 'delete', path: '/log/:id', role: 'deleteLogById', name: 'Delete log by ID' },
8
- ];
4
+ const logRoleDefs = () => {
5
+ return [
6
+ {
7
+ method: 'get',
8
+ path: '/log',
9
+ role: 'getLogs',
10
+ name: 'Get logs',
11
+ response_200: {},
12
+ response_500: {},
13
+ },
14
+ {
15
+ method: 'delete',
16
+ path: '/log/all',
17
+ role: 'deleteLogsAll',
18
+ name: 'Delete all logs',
19
+ response_200: {},
20
+ response_500: {},
21
+ },
22
+ {
23
+ method: 'delete',
24
+ path: '/log/:id',
25
+ role: 'deleteLogById',
26
+ name: 'Delete log by ID',
27
+ response_200: {},
28
+ response_404: {},
29
+ response_500: {},
30
+ },
31
+ ];
32
+ };
33
+ exports.logRoleDefs = logRoleDefs;
@@ -1,31 +1,89 @@
1
- export declare const notificationRoleDefs: readonly [{
1
+ import type { NotificationBase } from '../inputsDefault';
2
+ export declare const notificationRoleDefs: <TId, TDate>() => readonly [{
2
3
  readonly method: "post";
3
4
  readonly path: "/notification";
4
5
  readonly role: "postNotification";
5
6
  readonly name: "Create notification";
7
+ readonly response_201: {
8
+ notification: NotificationBase<TId, TDate>;
9
+ message: string;
10
+ };
11
+ readonly response_500: {
12
+ message: string;
13
+ error: string;
14
+ };
6
15
  }, {
7
16
  readonly method: "post";
8
17
  readonly path: "/notification/read";
9
18
  readonly role: "postNotificationRead";
10
19
  readonly name: "Mark notifications read";
20
+ readonly response_201: {
21
+ notificationIds: string[];
22
+ message: string;
23
+ };
24
+ readonly response_500: {
25
+ message: string;
26
+ error: string;
27
+ };
11
28
  }, {
12
29
  readonly method: "get";
13
30
  readonly path: "/notification";
14
31
  readonly role: "getNotifications";
15
32
  readonly name: "Get notifications";
33
+ readonly response_200: {
34
+ notifications: NotificationBase<TId, TDate>[];
35
+ count: number;
36
+ unreadCount: number;
37
+ };
38
+ readonly response_500: {
39
+ message: string;
40
+ error: string;
41
+ };
16
42
  }, {
17
43
  readonly method: "get";
18
44
  readonly path: "/notification/:id";
19
45
  readonly role: "getNotificationById";
20
46
  readonly name: "Get notification by ID";
47
+ readonly response_200: {
48
+ notification: NotificationBase<TId, TDate> | null;
49
+ message: string;
50
+ };
51
+ readonly response_404: {
52
+ message: string;
53
+ error: string;
54
+ };
21
55
  }, {
22
56
  readonly method: "put";
23
57
  readonly path: "/notification/:id";
24
58
  readonly role: "putNotificationById";
25
59
  readonly name: "Update notification";
60
+ readonly response_200: {
61
+ notification: NotificationBase<TId, TDate>;
62
+ message: string;
63
+ };
64
+ readonly response_404: {
65
+ notification: NotificationBase<TId, TDate> | null;
66
+ message: string;
67
+ };
68
+ readonly response_500: {
69
+ message: string;
70
+ error: string;
71
+ };
26
72
  }, {
27
73
  readonly method: "delete";
28
74
  readonly path: "/notification/:id";
29
75
  readonly role: "deleteNotificationById";
30
76
  readonly name: "Delete notification";
77
+ readonly response_200: {
78
+ notification: NotificationBase<TId, TDate>;
79
+ message: string;
80
+ };
81
+ readonly response_404: {
82
+ notification: NotificationBase<TId, TDate> | null;
83
+ message: string;
84
+ };
85
+ readonly response_500: {
86
+ message: string;
87
+ error: string;
88
+ };
31
89
  }];