conduyt 1.24.0 → 1.26.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/dist/index.js +52 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2362,6 +2362,58 @@ reports
|
|
|
2362
2362
|
throw new Error("Pass at least one change.");
|
|
2363
2363
|
return client.patch(`/api/v1/reports/subscriptions/${sid}`, body);
|
|
2364
2364
|
}));
|
|
2365
|
+
reports
|
|
2366
|
+
.command("sms-drip-conversion")
|
|
2367
|
+
.description("Conversion by drip step for external-workflow SMS drips: texted / replied / booked / moved forward / won per text, credited last-touch within the attribution window, the next text from any drip closes it (spans clamp to 90 days; the response notes list the one approximation)")
|
|
2368
|
+
.option("--from <iso>", "window start (default: 90 days before --to)")
|
|
2369
|
+
.option("--to <iso>", "window end (default: now)")
|
|
2370
|
+
.option("--automation <id>", "scope to one automation")
|
|
2371
|
+
.option("--smart-list <id>", "scope to contacts in this smart list")
|
|
2372
|
+
.option("--attribution-days <n>", "credit an outcome only within this many days of the text (1-14, default 3)")
|
|
2373
|
+
.action(run(async (client, opts) => {
|
|
2374
|
+
const params = new URLSearchParams();
|
|
2375
|
+
if (opts.from)
|
|
2376
|
+
params.set("from", opts.from);
|
|
2377
|
+
if (opts.to)
|
|
2378
|
+
params.set("to", opts.to);
|
|
2379
|
+
if (opts.automation) {
|
|
2380
|
+
assertUuid(opts.automation, "automation id");
|
|
2381
|
+
params.set("automationId", opts.automation);
|
|
2382
|
+
}
|
|
2383
|
+
if (opts.smartList) {
|
|
2384
|
+
assertUuid(opts.smartList, "smart list id");
|
|
2385
|
+
params.set("smartListId", opts.smartList);
|
|
2386
|
+
}
|
|
2387
|
+
if (opts.attributionDays !== undefined)
|
|
2388
|
+
params.set("attributionDays", opts.attributionDays);
|
|
2389
|
+
return client.get(`/api/v1/reports/sms-drip-conversion?${params.toString()}`);
|
|
2390
|
+
}));
|
|
2391
|
+
reports
|
|
2392
|
+
.command("speed-to-lead")
|
|
2393
|
+
.description("Speed to lead: time from a new lead to the first call, text, email or note by a person inside the CRM (median, p90, within 5/15 min and 1/4/24 h, never), by assigned rep, by lead source and by who touched; spans clamp to 90 days")
|
|
2394
|
+
.option("--from <iso>", "window start (default: 90 days before --to)")
|
|
2395
|
+
.option("--to <iso>", "window end (default: now)")
|
|
2396
|
+
.option("--assigned-to <id>", "only leads assigned to this user")
|
|
2397
|
+
.option("--sources <list>", "comma-separated exact contact source values; __none__ adds contacts with no source")
|
|
2398
|
+
.option("--smart-list <id>", "only contacts in this smart list")
|
|
2399
|
+
.action(run(async (client, opts) => {
|
|
2400
|
+
const params = new URLSearchParams();
|
|
2401
|
+
if (opts.from)
|
|
2402
|
+
params.set("from", opts.from);
|
|
2403
|
+
if (opts.to)
|
|
2404
|
+
params.set("to", opts.to);
|
|
2405
|
+
if (opts.assignedTo) {
|
|
2406
|
+
assertUuid(opts.assignedTo, "user id");
|
|
2407
|
+
params.set("assignedTo", opts.assignedTo);
|
|
2408
|
+
}
|
|
2409
|
+
if (opts.sources)
|
|
2410
|
+
params.set("sources", opts.sources);
|
|
2411
|
+
if (opts.smartList) {
|
|
2412
|
+
assertUuid(opts.smartList, "smart list id");
|
|
2413
|
+
params.set("smartListId", opts.smartList);
|
|
2414
|
+
}
|
|
2415
|
+
return client.get(`/api/v1/reports/speed-to-lead?${params.toString()}`);
|
|
2416
|
+
}));
|
|
2365
2417
|
reports
|
|
2366
2418
|
.command("schedule-delete <sid>")
|
|
2367
2419
|
.description("Remove a schedule (past deliveries stay downloadable until they expire)")
|
package/package.json
CHANGED