@ductape/sdk 0.0.4-v43 → 0.0.4-v44
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/apps/services/app.service.js +16 -69
- package/dist/apps/services/app.service.js.map +1 -1
- package/dist/apps/validators/joi-validators/create.appWebhook.validator.d.ts +1 -2
- package/dist/apps/validators/joi-validators/create.appWebhook.validator.js +2 -15
- package/dist/apps/validators/joi-validators/create.appWebhook.validator.js.map +1 -1
- package/dist/apps/validators/joi-validators/update.appWebhook.validator.d.ts +1 -2
- package/dist/apps/validators/joi-validators/update.appWebhook.validator.js +2 -14
- package/dist/apps/validators/joi-validators/update.appWebhook.validator.js.map +1 -1
- package/dist/database/adapters/dynamodb.adapter.d.ts +8 -0
- package/dist/database/adapters/dynamodb.adapter.js +243 -11
- package/dist/database/adapters/dynamodb.adapter.js.map +1 -1
- package/dist/database/adapters/mongodb.adapter.d.ts +1 -0
- package/dist/database/adapters/mongodb.adapter.js +170 -5
- package/dist/database/adapters/mongodb.adapter.js.map +1 -1
- package/dist/database/adapters/mysql.adapter.d.ts +5 -0
- package/dist/database/adapters/mysql.adapter.js +215 -19
- package/dist/database/adapters/mysql.adapter.js.map +1 -1
- package/dist/database/adapters/postgresql.adapter.d.ts +5 -0
- package/dist/database/adapters/postgresql.adapter.js +199 -15
- package/dist/database/adapters/postgresql.adapter.js.map +1 -1
- package/dist/database/database.service.d.ts +5 -0
- package/dist/database/database.service.js +45 -95
- package/dist/database/database.service.js.map +1 -1
- package/dist/database/types/aggregation.types.d.ts +28 -28
- package/dist/database/types/database.types.d.ts +2 -1
- package/dist/database/types/database.types.js +1 -0
- package/dist/database/types/database.types.js.map +1 -1
- package/dist/database/types/index.types.d.ts +20 -20
- package/dist/database/types/migration.types.d.ts +12 -12
- package/dist/database/types/query.types.d.ts +59 -28
- package/dist/index.d.ts +169 -142
- package/dist/index.js +196 -169
- package/dist/index.js.map +1 -1
- package/dist/processor/services/processor.service.js +51 -35
- package/dist/processor/services/processor.service.js.map +1 -1
- package/dist/test/test.processor.js +1 -3
- package/dist/test/test.processor.js.map +1 -1
- package/dist/types/appBuilder.types.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1055,25 +1055,177 @@ export default class Ductape implements IDuctape {
|
|
|
1055
1055
|
validation: (selector: string, update: Partial<IParsedSample>) => Promise<void>;
|
|
1056
1056
|
};
|
|
1057
1057
|
/**
|
|
1058
|
-
*
|
|
1058
|
+
* Job-related operations for scheduling jobs.
|
|
1059
|
+
*/
|
|
1060
|
+
job: {
|
|
1061
|
+
/**
|
|
1062
|
+
* Schedules a job for a product.
|
|
1063
|
+
* @param {IProduct} data - The product data.
|
|
1064
|
+
* @returns {Promise<any>} The result of the job scheduling.
|
|
1065
|
+
*/
|
|
1066
|
+
schedule: (data: IProduct) => Promise<void>;
|
|
1067
|
+
};
|
|
1068
|
+
/**
|
|
1069
|
+
* Action-related operations for running actions.
|
|
1070
|
+
*/
|
|
1071
|
+
action: {
|
|
1072
|
+
/**
|
|
1073
|
+
* Runs an action processor.
|
|
1074
|
+
* @param {IActionProcessorInput} data - The action processor input.
|
|
1075
|
+
* @returns {Promise<any>} The result of the action processing.
|
|
1076
|
+
*/
|
|
1077
|
+
run: (data: IActionProcessorInput) => Promise<any>;
|
|
1078
|
+
};
|
|
1079
|
+
/**
|
|
1080
|
+
* Session-related operations for creating, validating, and refreshing sessions.
|
|
1081
|
+
*/
|
|
1082
|
+
sessions: {
|
|
1083
|
+
/**
|
|
1084
|
+
* Starts a new session.
|
|
1085
|
+
* @param {ISessionInput} data - The session input data.
|
|
1086
|
+
* @returns {Promise<any>} The result of the session generation.
|
|
1087
|
+
*/
|
|
1088
|
+
create: (data: ISessionInput) => Promise<import("./types").ISessionOutput>;
|
|
1089
|
+
/**
|
|
1090
|
+
* Decrypts a session.
|
|
1091
|
+
* @param {ISessionPayload} data - The session payload.
|
|
1092
|
+
* @returns {Promise<any>} The decrypted session.
|
|
1093
|
+
*/
|
|
1094
|
+
validate: (data: ISessionPayload) => Promise<any>;
|
|
1095
|
+
/**
|
|
1096
|
+
* Refreshes a session.
|
|
1097
|
+
* @param {ISessionRefreshPayload} data - The session refresh payload.
|
|
1098
|
+
* @returns {Promise<any>} The refreshed session.
|
|
1099
|
+
*/
|
|
1100
|
+
refresh: (data: ISessionRefreshPayload) => Promise<import("./types").ISessionOutput>;
|
|
1101
|
+
};
|
|
1102
|
+
/**
|
|
1103
|
+
* Feature-related operations for running, replaying, and resuming features.
|
|
1104
|
+
*/
|
|
1105
|
+
feature: {
|
|
1106
|
+
/**
|
|
1107
|
+
* Runs a feature processor.
|
|
1108
|
+
* @param {IProcessorInput} data - The feature processor input.
|
|
1109
|
+
* @returns {Promise<any>} The result of the feature processing.
|
|
1110
|
+
*/
|
|
1111
|
+
run: (data: IProcessorInput) => Promise<{
|
|
1112
|
+
process_id: string;
|
|
1113
|
+
}>;
|
|
1114
|
+
/**
|
|
1115
|
+
* Generates output for a process by ID.
|
|
1116
|
+
* @param {string} process_id - The process ID.
|
|
1117
|
+
* @returns {Promise<any>} The generated output.
|
|
1118
|
+
*/
|
|
1119
|
+
output: (process_id: string) => Promise<{
|
|
1120
|
+
process_id: string;
|
|
1121
|
+
status: import("./types").LogEventStatus;
|
|
1122
|
+
data: Record<string, unknown>;
|
|
1123
|
+
errors?: undefined;
|
|
1124
|
+
} | {
|
|
1125
|
+
process_id: string;
|
|
1126
|
+
status: import("./types").LogEventStatus;
|
|
1127
|
+
errors: string[];
|
|
1128
|
+
data?: undefined;
|
|
1129
|
+
} | {
|
|
1130
|
+
process_id: string;
|
|
1131
|
+
status: import("./types").LogEventStatus;
|
|
1132
|
+
data?: undefined;
|
|
1133
|
+
errors?: undefined;
|
|
1134
|
+
}>;
|
|
1135
|
+
/**
|
|
1136
|
+
* Replays a process by ID.
|
|
1137
|
+
* @param {string} process_id - The process ID.
|
|
1138
|
+
* @returns {Promise<any>} The result of the replay.
|
|
1139
|
+
*/
|
|
1140
|
+
replay: (process_id: string) => Promise<{
|
|
1141
|
+
process_id: string;
|
|
1142
|
+
}>;
|
|
1143
|
+
/**
|
|
1144
|
+
* Resumes a process by ID.
|
|
1145
|
+
* @param {string} process_id - The process ID.
|
|
1146
|
+
* @returns {Promise<any>} The result of the resume.
|
|
1147
|
+
*/
|
|
1148
|
+
resume: (process_id: string) => Promise<{
|
|
1149
|
+
process_id: string;
|
|
1150
|
+
}>;
|
|
1151
|
+
};
|
|
1152
|
+
/**
|
|
1153
|
+
* Quota-related operations for running quota processors.
|
|
1154
|
+
*/
|
|
1155
|
+
quota: {
|
|
1156
|
+
/**
|
|
1157
|
+
* Runs a quota processor.
|
|
1158
|
+
* @param {IProcessorInput} data - The quota processor input.
|
|
1159
|
+
* @returns {Promise<any>} The result of the quota processing.
|
|
1160
|
+
*/
|
|
1161
|
+
run: (data: IProcessorInput) => Promise<any>;
|
|
1162
|
+
};
|
|
1163
|
+
/**
|
|
1164
|
+
* Fallback-related operations for running fallback processors.
|
|
1165
|
+
*/
|
|
1166
|
+
fallback: {
|
|
1167
|
+
/**
|
|
1168
|
+
* Runs a fallback processor.
|
|
1169
|
+
* @param {IProcessorInput} data - The fallback processor input.
|
|
1170
|
+
* @returns {Promise<any>} The result of the fallback processing.
|
|
1171
|
+
*/
|
|
1172
|
+
run: (data: IProcessorInput) => Promise<any>;
|
|
1173
|
+
};
|
|
1174
|
+
/**
|
|
1175
|
+
* Notification-related operations for sending notifications.
|
|
1176
|
+
*/
|
|
1177
|
+
notification: {
|
|
1178
|
+
/**
|
|
1179
|
+
* Sends a notification using the notification processor.
|
|
1180
|
+
* @param {INotificationProcessorInput} data - The notification processor input.
|
|
1181
|
+
* @returns {Promise<any>} The result of the notification processing.
|
|
1182
|
+
*/
|
|
1183
|
+
send: (data: INotificationProcessorInput) => Promise<{
|
|
1184
|
+
process_id: string;
|
|
1185
|
+
}>;
|
|
1186
|
+
};
|
|
1187
|
+
/**
|
|
1188
|
+
* Storage-related operations for reading and saving files.
|
|
1189
|
+
*/
|
|
1190
|
+
storage: {
|
|
1191
|
+
/**
|
|
1192
|
+
* Reads a file from storage.
|
|
1193
|
+
* @param {string} path - The file path.
|
|
1194
|
+
* @returns {Promise<IFileReadResult>} The file read result.
|
|
1195
|
+
*/
|
|
1196
|
+
read: (path: string) => Promise<IFileReadResult>;
|
|
1197
|
+
/**
|
|
1198
|
+
* Saves data to storage using the storage processor.
|
|
1199
|
+
* @param {IStorageProcessorInput} data - The storage processor input.
|
|
1200
|
+
* @returns {Promise<any>} The result of the storage processing.
|
|
1201
|
+
*/
|
|
1202
|
+
save: (data: IStorageProcessorInput) => Promise<any>;
|
|
1203
|
+
};
|
|
1204
|
+
/**
|
|
1205
|
+
* Message broker-related operations for publishing and subscribing to topics.
|
|
1206
|
+
*/
|
|
1207
|
+
broker: {
|
|
1208
|
+
/**
|
|
1209
|
+
* Publishes a message using the message broker processor.
|
|
1210
|
+
* @param {IMessageBrokerPublishInput} data - The publish input.
|
|
1211
|
+
* @returns {Promise<any>} The result of the publish operation.
|
|
1212
|
+
*/
|
|
1213
|
+
publish: (data: IMessageBrokerPublishInput) => Promise<void | {
|
|
1214
|
+
process_id: string;
|
|
1215
|
+
}>;
|
|
1216
|
+
/**
|
|
1217
|
+
* Subscribes to a message broker topic.
|
|
1218
|
+
* @param {IMessageBrokerSubscribeInput} data - The subscribe input.
|
|
1219
|
+
* @returns {Promise<any>} The result of the subscribe operation.
|
|
1220
|
+
*/
|
|
1221
|
+
subcribe: (data: IMessageBrokerSubscribeInput) => Promise<void | {
|
|
1222
|
+
process_id: string;
|
|
1223
|
+
}>;
|
|
1224
|
+
};
|
|
1225
|
+
/**
|
|
1226
|
+
* Processor-related operations for database actions only.
|
|
1059
1227
|
*/
|
|
1060
1228
|
processor: {
|
|
1061
|
-
job: {
|
|
1062
|
-
/**
|
|
1063
|
-
* Schedules a job for a product.
|
|
1064
|
-
* @param {IProduct} data - The product data.
|
|
1065
|
-
* @returns {Promise<any>} The result of the job scheduling.
|
|
1066
|
-
*/
|
|
1067
|
-
schedule: (data: IProduct) => Promise<void>;
|
|
1068
|
-
};
|
|
1069
|
-
action: {
|
|
1070
|
-
/**
|
|
1071
|
-
* Runs an action processor.
|
|
1072
|
-
* @param {IActionProcessorInput} data - The action processor input.
|
|
1073
|
-
* @returns {Promise<any>} The result of the action processing.
|
|
1074
|
-
*/
|
|
1075
|
-
run: (data: IActionProcessorInput) => Promise<any>;
|
|
1076
|
-
};
|
|
1077
1229
|
db: {
|
|
1078
1230
|
/**
|
|
1079
1231
|
* Executes a database action processor.
|
|
@@ -1114,131 +1266,6 @@ export default class Ductape implements IDuctape {
|
|
|
1114
1266
|
}>;
|
|
1115
1267
|
};
|
|
1116
1268
|
};
|
|
1117
|
-
sessions: {
|
|
1118
|
-
/**
|
|
1119
|
-
* Starts a new session.
|
|
1120
|
-
* @param {ISessionInput} data - The session input data.
|
|
1121
|
-
* @returns {Promise<any>} The result of the session generation.
|
|
1122
|
-
*/
|
|
1123
|
-
start: (data: ISessionInput) => Promise<import("./types").ISessionOutput>;
|
|
1124
|
-
/**
|
|
1125
|
-
* Decrypts a session.
|
|
1126
|
-
* @param {ISessionPayload} data - The session payload.
|
|
1127
|
-
* @returns {Promise<any>} The decrypted session.
|
|
1128
|
-
*/
|
|
1129
|
-
decrypt: (data: ISessionPayload) => Promise<any>;
|
|
1130
|
-
/**
|
|
1131
|
-
* Refreshes a session.
|
|
1132
|
-
* @param {ISessionRefreshPayload} data - The session refresh payload.
|
|
1133
|
-
* @returns {Promise<any>} The refreshed session.
|
|
1134
|
-
*/
|
|
1135
|
-
refresh: (data: ISessionRefreshPayload) => Promise<import("./types").ISessionOutput>;
|
|
1136
|
-
};
|
|
1137
|
-
feature: {
|
|
1138
|
-
/**
|
|
1139
|
-
* Runs a feature processor.
|
|
1140
|
-
* @param {IProcessorInput} data - The feature processor input.
|
|
1141
|
-
* @returns {Promise<any>} The result of the feature processing.
|
|
1142
|
-
*/
|
|
1143
|
-
run: (data: IProcessorInput) => Promise<{
|
|
1144
|
-
process_id: string;
|
|
1145
|
-
}>;
|
|
1146
|
-
/**
|
|
1147
|
-
* Generates output for a process by ID.
|
|
1148
|
-
* @param {string} process_id - The process ID.
|
|
1149
|
-
* @returns {Promise<any>} The generated output.
|
|
1150
|
-
*/
|
|
1151
|
-
output: (process_id: string) => Promise<{
|
|
1152
|
-
process_id: string;
|
|
1153
|
-
status: import("./types").LogEventStatus;
|
|
1154
|
-
data: Record<string, unknown>;
|
|
1155
|
-
errors?: undefined;
|
|
1156
|
-
} | {
|
|
1157
|
-
process_id: string;
|
|
1158
|
-
status: import("./types").LogEventStatus;
|
|
1159
|
-
errors: string[];
|
|
1160
|
-
data?: undefined;
|
|
1161
|
-
} | {
|
|
1162
|
-
process_id: string;
|
|
1163
|
-
status: import("./types").LogEventStatus;
|
|
1164
|
-
data?: undefined;
|
|
1165
|
-
errors?: undefined;
|
|
1166
|
-
}>;
|
|
1167
|
-
/**
|
|
1168
|
-
* Replays a process by ID.
|
|
1169
|
-
* @param {string} process_id - The process ID.
|
|
1170
|
-
* @returns {Promise<any>} The result of the replay.
|
|
1171
|
-
*/
|
|
1172
|
-
replay: (process_id: string) => Promise<{
|
|
1173
|
-
process_id: string;
|
|
1174
|
-
}>;
|
|
1175
|
-
/**
|
|
1176
|
-
* Resumes a process by ID.
|
|
1177
|
-
* @param {string} process_id - The process ID.
|
|
1178
|
-
* @returns {Promise<any>} The result of the resume.
|
|
1179
|
-
*/
|
|
1180
|
-
resume: (process_id: string) => Promise<{
|
|
1181
|
-
process_id: string;
|
|
1182
|
-
}>;
|
|
1183
|
-
};
|
|
1184
|
-
quota: {
|
|
1185
|
-
/**
|
|
1186
|
-
* Runs a quota processor.
|
|
1187
|
-
* @param {IProcessorInput} data - The quota processor input.
|
|
1188
|
-
* @returns {Promise<any>} The result of the quota processing.
|
|
1189
|
-
*/
|
|
1190
|
-
run: (data: IProcessorInput) => Promise<any>;
|
|
1191
|
-
};
|
|
1192
|
-
fallback: {
|
|
1193
|
-
/**
|
|
1194
|
-
* Runs a fallback processor.
|
|
1195
|
-
* @param {IProcessorInput} data - The fallback processor input.
|
|
1196
|
-
* @returns {Promise<any>} The result of the fallback processing.
|
|
1197
|
-
*/
|
|
1198
|
-
run: (data: IProcessorInput) => Promise<any>;
|
|
1199
|
-
};
|
|
1200
|
-
notification: {
|
|
1201
|
-
/**
|
|
1202
|
-
* Sends a notification using the notification processor.
|
|
1203
|
-
* @param {INotificationProcessorInput} data - The notification processor input.
|
|
1204
|
-
* @returns {Promise<any>} The result of the notification processing.
|
|
1205
|
-
*/
|
|
1206
|
-
send: (data: INotificationProcessorInput) => Promise<{
|
|
1207
|
-
process_id: string;
|
|
1208
|
-
}>;
|
|
1209
|
-
};
|
|
1210
|
-
storage: {
|
|
1211
|
-
/**
|
|
1212
|
-
* Reads a file from storage.
|
|
1213
|
-
* @param {string} path - The file path.
|
|
1214
|
-
* @returns {Promise<IFileReadResult>} The file read result.
|
|
1215
|
-
*/
|
|
1216
|
-
readFile: (path: string) => Promise<IFileReadResult>;
|
|
1217
|
-
/**
|
|
1218
|
-
* Saves data to storage using the storage processor.
|
|
1219
|
-
* @param {IStorageProcessorInput} data - The storage processor input.
|
|
1220
|
-
* @returns {Promise<any>} The result of the storage processing.
|
|
1221
|
-
*/
|
|
1222
|
-
save: (data: IStorageProcessorInput) => Promise<any>;
|
|
1223
|
-
};
|
|
1224
|
-
messageBroker: {
|
|
1225
|
-
/**
|
|
1226
|
-
* Publishes a message using the message broker processor.
|
|
1227
|
-
* @param {IMessageBrokerPublishInput} data - The publish input.
|
|
1228
|
-
* @returns {Promise<any>} The result of the publish operation.
|
|
1229
|
-
*/
|
|
1230
|
-
publish: (data: IMessageBrokerPublishInput) => Promise<void | {
|
|
1231
|
-
process_id: string;
|
|
1232
|
-
}>;
|
|
1233
|
-
/**
|
|
1234
|
-
* Subscribes to a message broker topic.
|
|
1235
|
-
* @param {IMessageBrokerSubscribeInput} data - The subscribe input.
|
|
1236
|
-
* @returns {Promise<any>} The result of the subscribe operation.
|
|
1237
|
-
*/
|
|
1238
|
-
subcribe: (data: IMessageBrokerSubscribeInput) => Promise<void | {
|
|
1239
|
-
process_id: string;
|
|
1240
|
-
}>;
|
|
1241
|
-
};
|
|
1242
1269
|
};
|
|
1243
1270
|
/**
|
|
1244
1271
|
* Database operations for querying, inserting, updating, and managing databases.
|