@mesh-sync/worker-backend-client 4.0.19 → 4.0.24
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/README.md +533 -52
- package/dist/client.d.ts +98 -12
- package/dist/client.js +124 -16
- package/dist/types.d.ts +1576 -201
- package/dist/types.js +13 -2
- package/package.json +1 -1
package/dist/client.d.ts
CHANGED
|
@@ -37,6 +37,14 @@ export declare class WorkerClient {
|
|
|
37
37
|
* Get job status by job ID
|
|
38
38
|
*/
|
|
39
39
|
getJobStatus(jobId: string): Promise<JobStatus>;
|
|
40
|
+
/**
|
|
41
|
+
* Request to trigger a manual market data collection job.
|
|
42
|
+
Used for ad-hoc scraping of specific queries on marketplaces.
|
|
43
|
+
|
|
44
|
+
* @param data - The message payload
|
|
45
|
+
* @returns Job response with job ID
|
|
46
|
+
*/
|
|
47
|
+
analyticsCollectionRequest(data: types.AnalyticsCollectionRequestMessage): Promise<JobResponse>;
|
|
40
48
|
/**
|
|
41
49
|
* Centralized logging event for capturing all warn/error/failure logs from meshsync-backend.
|
|
42
50
|
This event is sent to ELK for centralized monitoring, alerting, and debugging.
|
|
@@ -58,18 +66,6 @@ export declare class WorkerClient {
|
|
|
58
66
|
* @returns Job response with job ID
|
|
59
67
|
*/
|
|
60
68
|
backendLoggingEvent(data: types.BackendLoggingEventMessage): Promise<JobResponse>;
|
|
61
|
-
/**
|
|
62
|
-
* Completion event for EKG edge batch creation with propagation results.
|
|
63
|
-
* @param data - The message payload
|
|
64
|
-
* @returns Job response with job ID
|
|
65
|
-
*/
|
|
66
|
-
ekgEdgeBatchCreateCompleted(data: types.EkgEdgeBatchCreateCompletedMessage): Promise<JobResponse>;
|
|
67
|
-
/**
|
|
68
|
-
* Create multiple EKG edges with Dempster-Shafer mass functions. Triggered by metamodel detection completion.
|
|
69
|
-
* @param data - The message payload
|
|
70
|
-
* @returns Job response with job ID
|
|
71
|
-
*/
|
|
72
|
-
ekgEdgeBatchCreateRequest(data: types.EkgEdgeBatchCreateRequestMessage): Promise<JobResponse>;
|
|
73
69
|
/**
|
|
74
70
|
* Contains synced analytics data for Etsy listings. Backend stores this in etsy_analytics_snapshots table and indexes to ELK.
|
|
75
71
|
|
|
@@ -133,6 +129,18 @@ export declare class WorkerClient {
|
|
|
133
129
|
* @returns Job response with job ID
|
|
134
130
|
*/
|
|
135
131
|
fileVectorizeRequest(data: types.FileVectorizeRequestMessage): Promise<JobResponse>;
|
|
132
|
+
/**
|
|
133
|
+
* Contains IP verification results including trademark risk, copyright risk, detected brands/franchises, and analysis confidence scores
|
|
134
|
+
* @param data - The message payload
|
|
135
|
+
* @returns Job response with job ID
|
|
136
|
+
*/
|
|
137
|
+
ipCheckCompleted(data: types.IpCheckCompletedMessage): Promise<JobResponse>;
|
|
138
|
+
/**
|
|
139
|
+
* Triggers intellectual property verification analysis for a model thumbnail, detecting potential trademark and copyright issues using perceptual hashing, text analysis, and optional reverse image search.
|
|
140
|
+
* @param data - The message payload
|
|
141
|
+
* @returns Job response with job ID
|
|
142
|
+
*/
|
|
143
|
+
ipCheckRequest(data: types.IpCheckRequestMessage): Promise<JobResponse>;
|
|
136
144
|
/**
|
|
137
145
|
* Contains synced analytics data for marketplace listings. Backend stores this in marketplace_analytics_snapshots table and indexes to ELK. Works with any marketplace provider.
|
|
138
146
|
* @param data - The message payload
|
|
@@ -174,6 +182,17 @@ export declare class WorkerClient {
|
|
|
174
182
|
* @returns Job response with job ID
|
|
175
183
|
*/
|
|
176
184
|
marketplaceCredentialRotationRequest(data: types.MarketplaceCredentialRotationRequestMessage): Promise<JobResponse>;
|
|
185
|
+
/**
|
|
186
|
+
* Response from marketplace intelligence scraping.
|
|
187
|
+
Contains aggregated similarity data from marketplace searches.
|
|
188
|
+
|
|
189
|
+
Consumed by worker-backend to update pipeline context before
|
|
190
|
+
sellability analysis runs.
|
|
191
|
+
|
|
192
|
+
* @param data - The message payload
|
|
193
|
+
* @returns Job response with job ID
|
|
194
|
+
*/
|
|
195
|
+
marketplaceIntelligenceCompleted(data: types.MarketplaceIntelligenceCompletedMessage): Promise<JobResponse>;
|
|
177
196
|
/**
|
|
178
197
|
* Public marketplace intelligence data scraped from external marketplaces.
|
|
179
198
|
|
|
@@ -195,6 +214,25 @@ export declare class WorkerClient {
|
|
|
195
214
|
* @returns Job response with job ID
|
|
196
215
|
*/
|
|
197
216
|
marketplaceIntelligenceEvent(data: types.MarketplaceIntelligenceEventMessage): Promise<JobResponse>;
|
|
217
|
+
/**
|
|
218
|
+
* Triggers automated marketplace scraping to find similar/competing listings
|
|
219
|
+
for a given model. This is a pipeline stage that runs after metadata generation
|
|
220
|
+
to inform sellability analysis with real market data.
|
|
221
|
+
|
|
222
|
+
The worker-analytic-collector (or marketplace-connectors worker) will:
|
|
223
|
+
1. Use model metadata (title, tags, category) to build search queries
|
|
224
|
+
2. Scrape connected marketplaces (Etsy, eBay, etc.) for similar listings
|
|
225
|
+
3. Emit marketplace-intelligence-event results for Elasticsearch indexing
|
|
226
|
+
4. Return aggregated similarity data to the pipeline context
|
|
227
|
+
|
|
228
|
+
Pipeline integration:
|
|
229
|
+
- Triggered after: metadata-generation (needs model title/tags/category)
|
|
230
|
+
- Results feed into: sellability-analysis (market positioning data)
|
|
231
|
+
|
|
232
|
+
* @param data - The message payload
|
|
233
|
+
* @returns Job response with job ID
|
|
234
|
+
*/
|
|
235
|
+
marketplaceIntelligenceRequest(data: types.MarketplaceIntelligenceRequestMessage): Promise<JobResponse>;
|
|
198
236
|
/**
|
|
199
237
|
* Notifies backend that marketplace description generation completed. Contains generated description with metadata tracking (AI model, confidence, generation timestamp) and suggested price.
|
|
200
238
|
* @param data - The message payload
|
|
@@ -372,6 +410,18 @@ export declare class WorkerClient {
|
|
|
372
410
|
* @returns Job response with job ID
|
|
373
411
|
*/
|
|
374
412
|
modelMetamodelDetectionRequest(data: types.ModelMetamodelDetectionRequestMessage): Promise<JobResponse>;
|
|
413
|
+
/**
|
|
414
|
+
* Reports completion of 3D print analysis — contains estimation, printability, and cost breakdown per FR-022
|
|
415
|
+
* @param data - The message payload
|
|
416
|
+
* @returns Job response with job ID
|
|
417
|
+
*/
|
|
418
|
+
modelPrintAnalysisCompleted(data: types.ModelPrintAnalysisCompletedMessage): Promise<JobResponse>;
|
|
419
|
+
/**
|
|
420
|
+
* Triggers 3D print analysis for a model — estimates print time, material usage, support needs, and cost breakdown per FR-022
|
|
421
|
+
* @param data - The message payload
|
|
422
|
+
* @returns Job response with job ID
|
|
423
|
+
*/
|
|
424
|
+
modelPrintAnalysisRequest(data: types.ModelPrintAnalysisRequestMessage): Promise<JobResponse>;
|
|
375
425
|
/**
|
|
376
426
|
* Contains sellability analysis results including Etsy-specific recommendations, material pricing, and marketplace compatibility scores
|
|
377
427
|
* @param data - The message payload
|
|
@@ -408,6 +458,42 @@ export declare class WorkerClient {
|
|
|
408
458
|
* @returns Job response with job ID
|
|
409
459
|
*/
|
|
410
460
|
modelTechnicalMetadataRequest(data: types.ModelTechnicalMetadataRequestMessage): Promise<JobResponse>;
|
|
461
|
+
/**
|
|
462
|
+
* Request FDM slicing simulation via OrcaSlicer (preferred) or heuristic fallback. Accepts OrcaSlicer-compatible printer/process/filament JSON profiles.
|
|
463
|
+
* @param data - The message payload
|
|
464
|
+
* @returns Job response with job ID
|
|
465
|
+
*/
|
|
466
|
+
slicingFdmRequest(data: types.SlicingFdmRequestMessage): Promise<JobResponse>;
|
|
467
|
+
/**
|
|
468
|
+
* Result of FDM slicing simulation from OrcaSlicer (toolpath) or heuristic fallback. Contains exact physical metrics for cost calculation.
|
|
469
|
+
* @param data - The message payload
|
|
470
|
+
* @returns Job response with job ID
|
|
471
|
+
*/
|
|
472
|
+
slicingFdmResult(data: types.SlicingFdmResultMessage): Promise<JobResponse>;
|
|
473
|
+
/**
|
|
474
|
+
* DEPRECATED: Use slicing-fdm-request or slicing-sla-request instead. Unified contract kept for backward compatibility only.
|
|
475
|
+
* @param data - The message payload
|
|
476
|
+
* @returns Job response with job ID
|
|
477
|
+
*/
|
|
478
|
+
slicingSimulationRequest(data: types.SlicingSimulationRequestMessage): Promise<JobResponse>;
|
|
479
|
+
/**
|
|
480
|
+
* DEPRECATED: Use slicing-fdm-result or slicing-sla-result instead. Unified contract kept for backward compatibility only.
|
|
481
|
+
* @param data - The message payload
|
|
482
|
+
* @returns Job response with job ID
|
|
483
|
+
*/
|
|
484
|
+
slicingSimulationResult(data: types.SlicingSimulationResultMessage): Promise<JobResponse>;
|
|
485
|
+
/**
|
|
486
|
+
* Request SLA/MSLA slicing simulation via PySLM cross-sectional analysis. Accepts resin printer profile with exposure, lift, and layer parameters.
|
|
487
|
+
* @param data - The message payload
|
|
488
|
+
* @returns Job response with job ID
|
|
489
|
+
*/
|
|
490
|
+
slicingSlaRequest(data: types.SlicingSlaRequestMessage): Promise<JobResponse>;
|
|
491
|
+
/**
|
|
492
|
+
* Result of SLA/MSLA slicing simulation from PySLM cross-sectional analysis. Contains exact resin usage and print time metrics.
|
|
493
|
+
* @param data - The message payload
|
|
494
|
+
* @returns Job response with job ID
|
|
495
|
+
*/
|
|
496
|
+
slicingSlaResult(data: types.SlicingSlaResultMessage): Promise<JobResponse>;
|
|
411
497
|
/**
|
|
412
498
|
* Handles thumbnail generation completed.
|
|
413
499
|
* @param data - The message payload
|
package/dist/client.js
CHANGED
|
@@ -60,6 +60,16 @@ export class WorkerClient {
|
|
|
60
60
|
}
|
|
61
61
|
return await response.json();
|
|
62
62
|
}
|
|
63
|
+
/**
|
|
64
|
+
* Request to trigger a manual market data collection job.
|
|
65
|
+
Used for ad-hoc scraping of specific queries on marketplaces.
|
|
66
|
+
|
|
67
|
+
* @param data - The message payload
|
|
68
|
+
* @returns Job response with job ID
|
|
69
|
+
*/
|
|
70
|
+
async analyticsCollectionRequest(data) {
|
|
71
|
+
return this.sendToQueue(types.MessageTypes.ANALYTICS_COLLECTION_REQUEST, data);
|
|
72
|
+
}
|
|
63
73
|
/**
|
|
64
74
|
* Centralized logging event for capturing all warn/error/failure logs from meshsync-backend.
|
|
65
75
|
This event is sent to ELK for centralized monitoring, alerting, and debugging.
|
|
@@ -83,22 +93,6 @@ export class WorkerClient {
|
|
|
83
93
|
async backendLoggingEvent(data) {
|
|
84
94
|
return this.sendToQueue(types.MessageTypes.BACKEND_LOGGING_EVENT, data);
|
|
85
95
|
}
|
|
86
|
-
/**
|
|
87
|
-
* Completion event for EKG edge batch creation with propagation results.
|
|
88
|
-
* @param data - The message payload
|
|
89
|
-
* @returns Job response with job ID
|
|
90
|
-
*/
|
|
91
|
-
async ekgEdgeBatchCreateCompleted(data) {
|
|
92
|
-
return this.sendToQueue(types.MessageTypes.EKG_EDGE_BATCH_CREATE_COMPLETED, data);
|
|
93
|
-
}
|
|
94
|
-
/**
|
|
95
|
-
* Create multiple EKG edges with Dempster-Shafer mass functions. Triggered by metamodel detection completion.
|
|
96
|
-
* @param data - The message payload
|
|
97
|
-
* @returns Job response with job ID
|
|
98
|
-
*/
|
|
99
|
-
async ekgEdgeBatchCreateRequest(data) {
|
|
100
|
-
return this.sendToQueue(types.MessageTypes.EKG_EDGE_BATCH_CREATE_REQUEST, data);
|
|
101
|
-
}
|
|
102
96
|
/**
|
|
103
97
|
* Contains synced analytics data for Etsy listings. Backend stores this in etsy_analytics_snapshots table and indexes to ELK.
|
|
104
98
|
|
|
@@ -178,6 +172,22 @@ export class WorkerClient {
|
|
|
178
172
|
async fileVectorizeRequest(data) {
|
|
179
173
|
return this.sendToQueue(types.MessageTypes.FILE_VECTORIZE_REQUEST, data);
|
|
180
174
|
}
|
|
175
|
+
/**
|
|
176
|
+
* Contains IP verification results including trademark risk, copyright risk, detected brands/franchises, and analysis confidence scores
|
|
177
|
+
* @param data - The message payload
|
|
178
|
+
* @returns Job response with job ID
|
|
179
|
+
*/
|
|
180
|
+
async ipCheckCompleted(data) {
|
|
181
|
+
return this.sendToQueue(types.MessageTypes.IP_CHECK_COMPLETED, data);
|
|
182
|
+
}
|
|
183
|
+
/**
|
|
184
|
+
* Triggers intellectual property verification analysis for a model thumbnail, detecting potential trademark and copyright issues using perceptual hashing, text analysis, and optional reverse image search.
|
|
185
|
+
* @param data - The message payload
|
|
186
|
+
* @returns Job response with job ID
|
|
187
|
+
*/
|
|
188
|
+
async ipCheckRequest(data) {
|
|
189
|
+
return this.sendToQueue(types.MessageTypes.IP_CHECK_REQUEST, data);
|
|
190
|
+
}
|
|
181
191
|
/**
|
|
182
192
|
* Contains synced analytics data for marketplace listings. Backend stores this in marketplace_analytics_snapshots table and indexes to ELK. Works with any marketplace provider.
|
|
183
193
|
* @param data - The message payload
|
|
@@ -231,6 +241,19 @@ export class WorkerClient {
|
|
|
231
241
|
async marketplaceCredentialRotationRequest(data) {
|
|
232
242
|
return this.sendToQueue(types.MessageTypes.MARKETPLACE_CREDENTIAL_ROTATION_REQUEST, data);
|
|
233
243
|
}
|
|
244
|
+
/**
|
|
245
|
+
* Response from marketplace intelligence scraping.
|
|
246
|
+
Contains aggregated similarity data from marketplace searches.
|
|
247
|
+
|
|
248
|
+
Consumed by worker-backend to update pipeline context before
|
|
249
|
+
sellability analysis runs.
|
|
250
|
+
|
|
251
|
+
* @param data - The message payload
|
|
252
|
+
* @returns Job response with job ID
|
|
253
|
+
*/
|
|
254
|
+
async marketplaceIntelligenceCompleted(data) {
|
|
255
|
+
return this.sendToQueue(types.MessageTypes.MARKETPLACE_INTELLIGENCE_COMPLETED, data);
|
|
256
|
+
}
|
|
234
257
|
/**
|
|
235
258
|
* Public marketplace intelligence data scraped from external marketplaces.
|
|
236
259
|
|
|
@@ -254,6 +277,27 @@ export class WorkerClient {
|
|
|
254
277
|
async marketplaceIntelligenceEvent(data) {
|
|
255
278
|
return this.sendToQueue(types.MessageTypes.MARKETPLACE_INTELLIGENCE_EVENT, data);
|
|
256
279
|
}
|
|
280
|
+
/**
|
|
281
|
+
* Triggers automated marketplace scraping to find similar/competing listings
|
|
282
|
+
for a given model. This is a pipeline stage that runs after metadata generation
|
|
283
|
+
to inform sellability analysis with real market data.
|
|
284
|
+
|
|
285
|
+
The worker-analytic-collector (or marketplace-connectors worker) will:
|
|
286
|
+
1. Use model metadata (title, tags, category) to build search queries
|
|
287
|
+
2. Scrape connected marketplaces (Etsy, eBay, etc.) for similar listings
|
|
288
|
+
3. Emit marketplace-intelligence-event results for Elasticsearch indexing
|
|
289
|
+
4. Return aggregated similarity data to the pipeline context
|
|
290
|
+
|
|
291
|
+
Pipeline integration:
|
|
292
|
+
- Triggered after: metadata-generation (needs model title/tags/category)
|
|
293
|
+
- Results feed into: sellability-analysis (market positioning data)
|
|
294
|
+
|
|
295
|
+
* @param data - The message payload
|
|
296
|
+
* @returns Job response with job ID
|
|
297
|
+
*/
|
|
298
|
+
async marketplaceIntelligenceRequest(data) {
|
|
299
|
+
return this.sendToQueue(types.MessageTypes.MARKETPLACE_INTELLIGENCE_REQUEST, data);
|
|
300
|
+
}
|
|
257
301
|
/**
|
|
258
302
|
* Notifies backend that marketplace description generation completed. Contains generated description with metadata tracking (AI model, confidence, generation timestamp) and suggested price.
|
|
259
303
|
* @param data - The message payload
|
|
@@ -487,6 +531,22 @@ export class WorkerClient {
|
|
|
487
531
|
async modelMetamodelDetectionRequest(data) {
|
|
488
532
|
return this.sendToQueue(types.MessageTypes.MODEL_METAMODEL_DETECTION_REQUEST, data);
|
|
489
533
|
}
|
|
534
|
+
/**
|
|
535
|
+
* Reports completion of 3D print analysis — contains estimation, printability, and cost breakdown per FR-022
|
|
536
|
+
* @param data - The message payload
|
|
537
|
+
* @returns Job response with job ID
|
|
538
|
+
*/
|
|
539
|
+
async modelPrintAnalysisCompleted(data) {
|
|
540
|
+
return this.sendToQueue(types.MessageTypes.MODEL_PRINT_ANALYSIS_COMPLETED, data);
|
|
541
|
+
}
|
|
542
|
+
/**
|
|
543
|
+
* Triggers 3D print analysis for a model — estimates print time, material usage, support needs, and cost breakdown per FR-022
|
|
544
|
+
* @param data - The message payload
|
|
545
|
+
* @returns Job response with job ID
|
|
546
|
+
*/
|
|
547
|
+
async modelPrintAnalysisRequest(data) {
|
|
548
|
+
return this.sendToQueue(types.MessageTypes.MODEL_PRINT_ANALYSIS_REQUEST, data);
|
|
549
|
+
}
|
|
490
550
|
/**
|
|
491
551
|
* Contains sellability analysis results including Etsy-specific recommendations, material pricing, and marketplace compatibility scores
|
|
492
552
|
* @param data - The message payload
|
|
@@ -535,6 +595,54 @@ export class WorkerClient {
|
|
|
535
595
|
async modelTechnicalMetadataRequest(data) {
|
|
536
596
|
return this.sendToQueue(types.MessageTypes.MODEL_TECHNICAL_METADATA_REQUEST, data);
|
|
537
597
|
}
|
|
598
|
+
/**
|
|
599
|
+
* Request FDM slicing simulation via OrcaSlicer (preferred) or heuristic fallback. Accepts OrcaSlicer-compatible printer/process/filament JSON profiles.
|
|
600
|
+
* @param data - The message payload
|
|
601
|
+
* @returns Job response with job ID
|
|
602
|
+
*/
|
|
603
|
+
async slicingFdmRequest(data) {
|
|
604
|
+
return this.sendToQueue(types.MessageTypes.SLICING_FDM_REQUEST, data);
|
|
605
|
+
}
|
|
606
|
+
/**
|
|
607
|
+
* Result of FDM slicing simulation from OrcaSlicer (toolpath) or heuristic fallback. Contains exact physical metrics for cost calculation.
|
|
608
|
+
* @param data - The message payload
|
|
609
|
+
* @returns Job response with job ID
|
|
610
|
+
*/
|
|
611
|
+
async slicingFdmResult(data) {
|
|
612
|
+
return this.sendToQueue(types.MessageTypes.SLICING_FDM_RESULT, data);
|
|
613
|
+
}
|
|
614
|
+
/**
|
|
615
|
+
* DEPRECATED: Use slicing-fdm-request or slicing-sla-request instead. Unified contract kept for backward compatibility only.
|
|
616
|
+
* @param data - The message payload
|
|
617
|
+
* @returns Job response with job ID
|
|
618
|
+
*/
|
|
619
|
+
async slicingSimulationRequest(data) {
|
|
620
|
+
return this.sendToQueue(types.MessageTypes.SLICING_SIMULATION_REQUEST, data);
|
|
621
|
+
}
|
|
622
|
+
/**
|
|
623
|
+
* DEPRECATED: Use slicing-fdm-result or slicing-sla-result instead. Unified contract kept for backward compatibility only.
|
|
624
|
+
* @param data - The message payload
|
|
625
|
+
* @returns Job response with job ID
|
|
626
|
+
*/
|
|
627
|
+
async slicingSimulationResult(data) {
|
|
628
|
+
return this.sendToQueue(types.MessageTypes.SLICING_SIMULATION_RESULT, data);
|
|
629
|
+
}
|
|
630
|
+
/**
|
|
631
|
+
* Request SLA/MSLA slicing simulation via PySLM cross-sectional analysis. Accepts resin printer profile with exposure, lift, and layer parameters.
|
|
632
|
+
* @param data - The message payload
|
|
633
|
+
* @returns Job response with job ID
|
|
634
|
+
*/
|
|
635
|
+
async slicingSlaRequest(data) {
|
|
636
|
+
return this.sendToQueue(types.MessageTypes.SLICING_SLA_REQUEST, data);
|
|
637
|
+
}
|
|
638
|
+
/**
|
|
639
|
+
* Result of SLA/MSLA slicing simulation from PySLM cross-sectional analysis. Contains exact resin usage and print time metrics.
|
|
640
|
+
* @param data - The message payload
|
|
641
|
+
* @returns Job response with job ID
|
|
642
|
+
*/
|
|
643
|
+
async slicingSlaResult(data) {
|
|
644
|
+
return this.sendToQueue(types.MessageTypes.SLICING_SLA_RESULT, data);
|
|
645
|
+
}
|
|
538
646
|
/**
|
|
539
647
|
* Handles thumbnail generation completed.
|
|
540
648
|
* @param data - The message payload
|