@elevasis/core 0.14.0 → 0.15.1
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.d.ts +60 -0
- package/dist/index.js +198 -1
- package/dist/organization-model/index.d.ts +60 -0
- package/dist/organization-model/index.js +198 -1
- package/dist/test-utils/index.d.ts +399 -363
- package/dist/test-utils/index.js +198 -1
- package/package.json +3 -3
- package/src/_gen/__tests__/__snapshots__/contracts.md.snap +444 -309
- package/src/business/acquisition/activity-events.ts +12 -3
- package/src/business/acquisition/api-schemas.test.ts +315 -4
- package/src/business/acquisition/api-schemas.ts +140 -17
- package/src/business/acquisition/build-templates.ts +44 -0
- package/src/business/acquisition/crm-next-action.test.ts +262 -0
- package/src/business/acquisition/crm-next-action.ts +220 -0
- package/src/business/acquisition/crm-priority.test.ts +216 -0
- package/src/business/acquisition/crm-priority.ts +349 -0
- package/src/business/acquisition/crm-state-actions.test.ts +12 -21
- package/src/business/acquisition/deal-ownership.test.ts +351 -0
- package/src/business/acquisition/deal-ownership.ts +120 -0
- package/src/business/acquisition/derive-actions.test.ts +101 -37
- package/src/business/acquisition/derive-actions.ts +49 -24
- package/src/business/acquisition/index.ts +163 -149
- package/src/business/acquisition/types.ts +48 -4
- package/src/execution/engine/index.ts +4 -3
- package/src/execution/engine/tools/lead-service-types.ts +68 -51
- package/src/execution/engine/tools/platform/acquisition/list-tools.ts +6 -5
- package/src/execution/engine/tools/platform/acquisition/types.ts +3 -1
- package/src/execution/engine/tools/registry.ts +4 -3
- package/src/execution/engine/tools/tool-maps.ts +821 -816
- package/src/organization-model/domains/prospecting.ts +204 -1
- package/src/organization-model/domains/sales.test.ts +218 -0
- package/src/organization-model/domains/sales.ts +558 -366
- package/src/organization-model/types.ts +2 -2
- package/src/platform/constants/versions.ts +1 -1
- package/src/reference/_generated/contracts.md +444 -309
- package/src/supabase/database.types.ts +2978 -2958
package/dist/index.d.ts
CHANGED
|
@@ -107,6 +107,36 @@ declare const OrganizationModelSchema: z.ZodObject<{
|
|
|
107
107
|
id: z.ZodString;
|
|
108
108
|
order: z.ZodNumber;
|
|
109
109
|
}, z.core.$strip>>;
|
|
110
|
+
defaultBuildTemplateId: z.ZodString;
|
|
111
|
+
buildTemplates: z.ZodArray<z.ZodObject<{
|
|
112
|
+
label: z.ZodString;
|
|
113
|
+
description: z.ZodOptional<z.ZodString>;
|
|
114
|
+
color: z.ZodOptional<z.ZodString>;
|
|
115
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
116
|
+
id: z.ZodString;
|
|
117
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
118
|
+
label: z.ZodString;
|
|
119
|
+
description: z.ZodOptional<z.ZodString>;
|
|
120
|
+
color: z.ZodOptional<z.ZodString>;
|
|
121
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
122
|
+
id: z.ZodString;
|
|
123
|
+
primaryEntity: z.ZodEnum<{
|
|
124
|
+
company: "company";
|
|
125
|
+
contact: "contact";
|
|
126
|
+
}>;
|
|
127
|
+
outputs: z.ZodArray<z.ZodEnum<{
|
|
128
|
+
company: "company";
|
|
129
|
+
contact: "contact";
|
|
130
|
+
export: "export";
|
|
131
|
+
}>>;
|
|
132
|
+
stageKey: z.ZodString;
|
|
133
|
+
dependsOn: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
134
|
+
dependencyMode: z.ZodLiteral<"per-record-eligibility">;
|
|
135
|
+
capabilityKey: z.ZodString;
|
|
136
|
+
defaultBatchSize: z.ZodNumber;
|
|
137
|
+
maxBatchSize: z.ZodNumber;
|
|
138
|
+
}, z.core.$strip>>;
|
|
139
|
+
}, z.core.$strip>>;
|
|
110
140
|
}, z.core.$strip>;
|
|
111
141
|
projects: z.ZodObject<{
|
|
112
142
|
projectEntityId: z.ZodString;
|
|
@@ -419,6 +449,36 @@ declare const OrganizationModelProspectingSchema: z.ZodObject<{
|
|
|
419
449
|
id: z.ZodString;
|
|
420
450
|
order: z.ZodNumber;
|
|
421
451
|
}, z.core.$strip>>;
|
|
452
|
+
defaultBuildTemplateId: z.ZodString;
|
|
453
|
+
buildTemplates: z.ZodArray<z.ZodObject<{
|
|
454
|
+
label: z.ZodString;
|
|
455
|
+
description: z.ZodOptional<z.ZodString>;
|
|
456
|
+
color: z.ZodOptional<z.ZodString>;
|
|
457
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
458
|
+
id: z.ZodString;
|
|
459
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
460
|
+
label: z.ZodString;
|
|
461
|
+
description: z.ZodOptional<z.ZodString>;
|
|
462
|
+
color: z.ZodOptional<z.ZodString>;
|
|
463
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
464
|
+
id: z.ZodString;
|
|
465
|
+
primaryEntity: z.ZodEnum<{
|
|
466
|
+
company: "company";
|
|
467
|
+
contact: "contact";
|
|
468
|
+
}>;
|
|
469
|
+
outputs: z.ZodArray<z.ZodEnum<{
|
|
470
|
+
company: "company";
|
|
471
|
+
contact: "contact";
|
|
472
|
+
export: "export";
|
|
473
|
+
}>>;
|
|
474
|
+
stageKey: z.ZodString;
|
|
475
|
+
dependsOn: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
476
|
+
dependencyMode: z.ZodLiteral<"per-record-eligibility">;
|
|
477
|
+
capabilityKey: z.ZodString;
|
|
478
|
+
defaultBatchSize: z.ZodNumber;
|
|
479
|
+
maxBatchSize: z.ZodNumber;
|
|
480
|
+
}, z.core.$strip>>;
|
|
481
|
+
}, z.core.$strip>>;
|
|
422
482
|
}, z.core.$strip>;
|
|
423
483
|
|
|
424
484
|
declare const OperationSemanticClassSchema: z.ZodEnum<{
|
package/dist/index.js
CHANGED
|
@@ -211,13 +211,33 @@ var ProspectingLifecycleStageSchema = DisplayMetadataSchema.extend({
|
|
|
211
211
|
id: ModelIdSchema,
|
|
212
212
|
order: z.number().int().min(0)
|
|
213
213
|
});
|
|
214
|
+
var ProspectingBuildTemplateStepSchema = DisplayMetadataSchema.extend({
|
|
215
|
+
id: ModelIdSchema,
|
|
216
|
+
primaryEntity: z.enum(["company", "contact"]),
|
|
217
|
+
outputs: z.array(z.enum(["company", "contact", "export"])).min(1),
|
|
218
|
+
stageKey: ModelIdSchema,
|
|
219
|
+
dependsOn: z.array(ModelIdSchema).optional(),
|
|
220
|
+
dependencyMode: z.literal("per-record-eligibility"),
|
|
221
|
+
capabilityKey: ModelIdSchema,
|
|
222
|
+
defaultBatchSize: z.number().int().positive(),
|
|
223
|
+
maxBatchSize: z.number().int().positive()
|
|
224
|
+
}).refine((step) => step.defaultBatchSize <= step.maxBatchSize, {
|
|
225
|
+
message: "defaultBatchSize must be less than or equal to maxBatchSize",
|
|
226
|
+
path: ["defaultBatchSize"]
|
|
227
|
+
});
|
|
228
|
+
var ProspectingBuildTemplateSchema = DisplayMetadataSchema.extend({
|
|
229
|
+
id: ModelIdSchema,
|
|
230
|
+
steps: z.array(ProspectingBuildTemplateStepSchema).min(1)
|
|
231
|
+
});
|
|
214
232
|
var OrganizationModelProspectingSchema = z.object({
|
|
215
233
|
listEntityId: ModelIdSchema,
|
|
216
234
|
companyEntityId: ModelIdSchema,
|
|
217
235
|
contactEntityId: ModelIdSchema,
|
|
218
236
|
description: DescriptionSchema.optional(),
|
|
219
237
|
companyStages: z.array(ProspectingLifecycleStageSchema).min(1),
|
|
220
|
-
contactStages: z.array(ProspectingLifecycleStageSchema).min(1)
|
|
238
|
+
contactStages: z.array(ProspectingLifecycleStageSchema).min(1),
|
|
239
|
+
defaultBuildTemplateId: ModelIdSchema,
|
|
240
|
+
buildTemplates: z.array(ProspectingBuildTemplateSchema).min(1)
|
|
221
241
|
});
|
|
222
242
|
var DEFAULT_ORGANIZATION_MODEL_PROSPECTING = {
|
|
223
243
|
listEntityId: "leadgen.list",
|
|
@@ -233,6 +253,183 @@ var DEFAULT_ORGANIZATION_MODEL_PROSPECTING = {
|
|
|
233
253
|
{ id: "verified", label: "Verified", order: 2 },
|
|
234
254
|
{ id: "personalized", label: "Personalized", order: 3 },
|
|
235
255
|
{ id: "uploaded", label: "Uploaded", order: 4 }
|
|
256
|
+
],
|
|
257
|
+
defaultBuildTemplateId: "local-services",
|
|
258
|
+
buildTemplates: [
|
|
259
|
+
{
|
|
260
|
+
id: "local-services",
|
|
261
|
+
label: "Local Services Prospecting",
|
|
262
|
+
description: "Curated local-services list build using company sourcing, website analysis, qualification, contact discovery, verification, personalization, and review.",
|
|
263
|
+
steps: [
|
|
264
|
+
{
|
|
265
|
+
id: "source-companies",
|
|
266
|
+
label: "Source companies",
|
|
267
|
+
primaryEntity: "company",
|
|
268
|
+
outputs: ["company"],
|
|
269
|
+
stageKey: "populated",
|
|
270
|
+
dependencyMode: "per-record-eligibility",
|
|
271
|
+
capabilityKey: "lead-gen.company.source",
|
|
272
|
+
defaultBatchSize: 100,
|
|
273
|
+
maxBatchSize: 250
|
|
274
|
+
},
|
|
275
|
+
{
|
|
276
|
+
id: "analyze-websites",
|
|
277
|
+
label: "Analyze websites",
|
|
278
|
+
primaryEntity: "company",
|
|
279
|
+
outputs: ["company"],
|
|
280
|
+
stageKey: "extracted",
|
|
281
|
+
dependsOn: ["source-companies"],
|
|
282
|
+
dependencyMode: "per-record-eligibility",
|
|
283
|
+
capabilityKey: "lead-gen.company.website-extract",
|
|
284
|
+
defaultBatchSize: 50,
|
|
285
|
+
maxBatchSize: 100
|
|
286
|
+
},
|
|
287
|
+
{
|
|
288
|
+
id: "qualify-companies",
|
|
289
|
+
label: "Qualify companies",
|
|
290
|
+
primaryEntity: "company",
|
|
291
|
+
outputs: ["company"],
|
|
292
|
+
stageKey: "qualified",
|
|
293
|
+
dependsOn: ["analyze-websites"],
|
|
294
|
+
dependencyMode: "per-record-eligibility",
|
|
295
|
+
capabilityKey: "lead-gen.company.qualify",
|
|
296
|
+
defaultBatchSize: 100,
|
|
297
|
+
maxBatchSize: 250
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
id: "find-contacts",
|
|
301
|
+
label: "Find contacts",
|
|
302
|
+
primaryEntity: "contact",
|
|
303
|
+
outputs: ["contact"],
|
|
304
|
+
stageKey: "discovered",
|
|
305
|
+
dependsOn: ["qualify-companies"],
|
|
306
|
+
dependencyMode: "per-record-eligibility",
|
|
307
|
+
capabilityKey: "lead-gen.contact.discover",
|
|
308
|
+
defaultBatchSize: 50,
|
|
309
|
+
maxBatchSize: 100
|
|
310
|
+
},
|
|
311
|
+
{
|
|
312
|
+
id: "verify-emails",
|
|
313
|
+
label: "Verify emails",
|
|
314
|
+
primaryEntity: "contact",
|
|
315
|
+
outputs: ["contact"],
|
|
316
|
+
stageKey: "verified",
|
|
317
|
+
dependsOn: ["find-contacts"],
|
|
318
|
+
dependencyMode: "per-record-eligibility",
|
|
319
|
+
capabilityKey: "lead-gen.contact.verify-email",
|
|
320
|
+
defaultBatchSize: 100,
|
|
321
|
+
maxBatchSize: 500
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
id: "personalize",
|
|
325
|
+
label: "Personalize",
|
|
326
|
+
primaryEntity: "contact",
|
|
327
|
+
outputs: ["contact"],
|
|
328
|
+
stageKey: "personalized",
|
|
329
|
+
dependsOn: ["verify-emails"],
|
|
330
|
+
dependencyMode: "per-record-eligibility",
|
|
331
|
+
capabilityKey: "lead-gen.contact.personalize",
|
|
332
|
+
defaultBatchSize: 25,
|
|
333
|
+
maxBatchSize: 100
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
id: "review",
|
|
337
|
+
label: "Review",
|
|
338
|
+
primaryEntity: "contact",
|
|
339
|
+
outputs: ["export"],
|
|
340
|
+
stageKey: "uploaded",
|
|
341
|
+
dependsOn: ["personalize"],
|
|
342
|
+
dependencyMode: "per-record-eligibility",
|
|
343
|
+
capabilityKey: "lead-gen.review.outreach-ready",
|
|
344
|
+
defaultBatchSize: 25,
|
|
345
|
+
maxBatchSize: 100
|
|
346
|
+
}
|
|
347
|
+
]
|
|
348
|
+
},
|
|
349
|
+
{
|
|
350
|
+
id: "dtc-subscription-apollo-clickup",
|
|
351
|
+
label: "DTC Subscription Apollo Export",
|
|
352
|
+
description: "Prospecting pipeline for DTC subscription or subscription-ready brands where Apollo is the source and contact-enrichment layer, Elevasis handles company research and fit scoring, and approved leads export as an approved lead list.",
|
|
353
|
+
steps: [
|
|
354
|
+
{
|
|
355
|
+
id: "import-apollo-search",
|
|
356
|
+
label: "Import Apollo search",
|
|
357
|
+
description: "Pull companies and seed contact data from a predefined Apollo search or list.",
|
|
358
|
+
primaryEntity: "company",
|
|
359
|
+
outputs: ["company", "contact"],
|
|
360
|
+
stageKey: "populated",
|
|
361
|
+
dependencyMode: "per-record-eligibility",
|
|
362
|
+
capabilityKey: "lead-gen.company.apollo-import",
|
|
363
|
+
defaultBatchSize: 250,
|
|
364
|
+
maxBatchSize: 1e3
|
|
365
|
+
},
|
|
366
|
+
{
|
|
367
|
+
id: "analyze-websites",
|
|
368
|
+
label: "Analyze websites",
|
|
369
|
+
description: "Extract subscription, product, retention, and tech-stack signals from each brand website.",
|
|
370
|
+
primaryEntity: "company",
|
|
371
|
+
outputs: ["company"],
|
|
372
|
+
stageKey: "extracted",
|
|
373
|
+
dependsOn: ["import-apollo-search"],
|
|
374
|
+
dependencyMode: "per-record-eligibility",
|
|
375
|
+
capabilityKey: "lead-gen.company.website-extract",
|
|
376
|
+
defaultBatchSize: 50,
|
|
377
|
+
maxBatchSize: 100
|
|
378
|
+
},
|
|
379
|
+
{
|
|
380
|
+
id: "score-dtc-fit",
|
|
381
|
+
label: "Score DTC fit",
|
|
382
|
+
description: "Classify subscription potential, consumable-product fit, retention maturity, and disqualifiers.",
|
|
383
|
+
primaryEntity: "company",
|
|
384
|
+
outputs: ["company"],
|
|
385
|
+
stageKey: "qualified",
|
|
386
|
+
dependsOn: ["analyze-websites"],
|
|
387
|
+
dependencyMode: "per-record-eligibility",
|
|
388
|
+
capabilityKey: "lead-gen.company.dtc-subscription-qualify",
|
|
389
|
+
defaultBatchSize: 100,
|
|
390
|
+
maxBatchSize: 250
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
id: "enrich-decision-makers",
|
|
394
|
+
label: "Enrich decision-makers",
|
|
395
|
+
description: "Use Apollo to find qualified contacts such as founders, retention leads, lifecycle leads, and marketing owners.",
|
|
396
|
+
primaryEntity: "contact",
|
|
397
|
+
outputs: ["contact"],
|
|
398
|
+
stageKey: "discovered",
|
|
399
|
+
dependsOn: ["score-dtc-fit"],
|
|
400
|
+
dependencyMode: "per-record-eligibility",
|
|
401
|
+
capabilityKey: "lead-gen.contact.apollo-decision-maker-enrich",
|
|
402
|
+
defaultBatchSize: 100,
|
|
403
|
+
maxBatchSize: 250
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
id: "verify-emails",
|
|
407
|
+
label: "Verify emails",
|
|
408
|
+
description: "Verify deliverability before the QC and handoff step.",
|
|
409
|
+
primaryEntity: "contact",
|
|
410
|
+
outputs: ["contact"],
|
|
411
|
+
stageKey: "verified",
|
|
412
|
+
dependsOn: ["enrich-decision-makers"],
|
|
413
|
+
dependencyMode: "per-record-eligibility",
|
|
414
|
+
capabilityKey: "lead-gen.contact.verify-email",
|
|
415
|
+
defaultBatchSize: 250,
|
|
416
|
+
maxBatchSize: 500
|
|
417
|
+
},
|
|
418
|
+
{
|
|
419
|
+
id: "review-and-export",
|
|
420
|
+
label: "Review and export",
|
|
421
|
+
description: "Operator QC approves or rejects leads, then approved records are exported as a lead list.",
|
|
422
|
+
primaryEntity: "company",
|
|
423
|
+
outputs: ["export"],
|
|
424
|
+
stageKey: "uploaded",
|
|
425
|
+
dependsOn: ["verify-emails"],
|
|
426
|
+
dependencyMode: "per-record-eligibility",
|
|
427
|
+
capabilityKey: "lead-gen.export.list",
|
|
428
|
+
defaultBatchSize: 100,
|
|
429
|
+
maxBatchSize: 250
|
|
430
|
+
}
|
|
431
|
+
]
|
|
432
|
+
}
|
|
236
433
|
]
|
|
237
434
|
};
|
|
238
435
|
|
|
@@ -107,6 +107,36 @@ declare const OrganizationModelSchema: z.ZodObject<{
|
|
|
107
107
|
id: z.ZodString;
|
|
108
108
|
order: z.ZodNumber;
|
|
109
109
|
}, z.core.$strip>>;
|
|
110
|
+
defaultBuildTemplateId: z.ZodString;
|
|
111
|
+
buildTemplates: z.ZodArray<z.ZodObject<{
|
|
112
|
+
label: z.ZodString;
|
|
113
|
+
description: z.ZodOptional<z.ZodString>;
|
|
114
|
+
color: z.ZodOptional<z.ZodString>;
|
|
115
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
116
|
+
id: z.ZodString;
|
|
117
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
118
|
+
label: z.ZodString;
|
|
119
|
+
description: z.ZodOptional<z.ZodString>;
|
|
120
|
+
color: z.ZodOptional<z.ZodString>;
|
|
121
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
122
|
+
id: z.ZodString;
|
|
123
|
+
primaryEntity: z.ZodEnum<{
|
|
124
|
+
company: "company";
|
|
125
|
+
contact: "contact";
|
|
126
|
+
}>;
|
|
127
|
+
outputs: z.ZodArray<z.ZodEnum<{
|
|
128
|
+
company: "company";
|
|
129
|
+
contact: "contact";
|
|
130
|
+
export: "export";
|
|
131
|
+
}>>;
|
|
132
|
+
stageKey: z.ZodString;
|
|
133
|
+
dependsOn: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
134
|
+
dependencyMode: z.ZodLiteral<"per-record-eligibility">;
|
|
135
|
+
capabilityKey: z.ZodString;
|
|
136
|
+
defaultBatchSize: z.ZodNumber;
|
|
137
|
+
maxBatchSize: z.ZodNumber;
|
|
138
|
+
}, z.core.$strip>>;
|
|
139
|
+
}, z.core.$strip>>;
|
|
110
140
|
}, z.core.$strip>;
|
|
111
141
|
projects: z.ZodObject<{
|
|
112
142
|
projectEntityId: z.ZodString;
|
|
@@ -419,6 +449,36 @@ declare const OrganizationModelProspectingSchema: z.ZodObject<{
|
|
|
419
449
|
id: z.ZodString;
|
|
420
450
|
order: z.ZodNumber;
|
|
421
451
|
}, z.core.$strip>>;
|
|
452
|
+
defaultBuildTemplateId: z.ZodString;
|
|
453
|
+
buildTemplates: z.ZodArray<z.ZodObject<{
|
|
454
|
+
label: z.ZodString;
|
|
455
|
+
description: z.ZodOptional<z.ZodString>;
|
|
456
|
+
color: z.ZodOptional<z.ZodString>;
|
|
457
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
458
|
+
id: z.ZodString;
|
|
459
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
460
|
+
label: z.ZodString;
|
|
461
|
+
description: z.ZodOptional<z.ZodString>;
|
|
462
|
+
color: z.ZodOptional<z.ZodString>;
|
|
463
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
464
|
+
id: z.ZodString;
|
|
465
|
+
primaryEntity: z.ZodEnum<{
|
|
466
|
+
company: "company";
|
|
467
|
+
contact: "contact";
|
|
468
|
+
}>;
|
|
469
|
+
outputs: z.ZodArray<z.ZodEnum<{
|
|
470
|
+
company: "company";
|
|
471
|
+
contact: "contact";
|
|
472
|
+
export: "export";
|
|
473
|
+
}>>;
|
|
474
|
+
stageKey: z.ZodString;
|
|
475
|
+
dependsOn: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
476
|
+
dependencyMode: z.ZodLiteral<"per-record-eligibility">;
|
|
477
|
+
capabilityKey: z.ZodString;
|
|
478
|
+
defaultBatchSize: z.ZodNumber;
|
|
479
|
+
maxBatchSize: z.ZodNumber;
|
|
480
|
+
}, z.core.$strip>>;
|
|
481
|
+
}, z.core.$strip>>;
|
|
422
482
|
}, z.core.$strip>;
|
|
423
483
|
|
|
424
484
|
declare const OperationSemanticClassSchema: z.ZodEnum<{
|
|
@@ -211,13 +211,33 @@ var ProspectingLifecycleStageSchema = DisplayMetadataSchema.extend({
|
|
|
211
211
|
id: ModelIdSchema,
|
|
212
212
|
order: z.number().int().min(0)
|
|
213
213
|
});
|
|
214
|
+
var ProspectingBuildTemplateStepSchema = DisplayMetadataSchema.extend({
|
|
215
|
+
id: ModelIdSchema,
|
|
216
|
+
primaryEntity: z.enum(["company", "contact"]),
|
|
217
|
+
outputs: z.array(z.enum(["company", "contact", "export"])).min(1),
|
|
218
|
+
stageKey: ModelIdSchema,
|
|
219
|
+
dependsOn: z.array(ModelIdSchema).optional(),
|
|
220
|
+
dependencyMode: z.literal("per-record-eligibility"),
|
|
221
|
+
capabilityKey: ModelIdSchema,
|
|
222
|
+
defaultBatchSize: z.number().int().positive(),
|
|
223
|
+
maxBatchSize: z.number().int().positive()
|
|
224
|
+
}).refine((step) => step.defaultBatchSize <= step.maxBatchSize, {
|
|
225
|
+
message: "defaultBatchSize must be less than or equal to maxBatchSize",
|
|
226
|
+
path: ["defaultBatchSize"]
|
|
227
|
+
});
|
|
228
|
+
var ProspectingBuildTemplateSchema = DisplayMetadataSchema.extend({
|
|
229
|
+
id: ModelIdSchema,
|
|
230
|
+
steps: z.array(ProspectingBuildTemplateStepSchema).min(1)
|
|
231
|
+
});
|
|
214
232
|
var OrganizationModelProspectingSchema = z.object({
|
|
215
233
|
listEntityId: ModelIdSchema,
|
|
216
234
|
companyEntityId: ModelIdSchema,
|
|
217
235
|
contactEntityId: ModelIdSchema,
|
|
218
236
|
description: DescriptionSchema.optional(),
|
|
219
237
|
companyStages: z.array(ProspectingLifecycleStageSchema).min(1),
|
|
220
|
-
contactStages: z.array(ProspectingLifecycleStageSchema).min(1)
|
|
238
|
+
contactStages: z.array(ProspectingLifecycleStageSchema).min(1),
|
|
239
|
+
defaultBuildTemplateId: ModelIdSchema,
|
|
240
|
+
buildTemplates: z.array(ProspectingBuildTemplateSchema).min(1)
|
|
221
241
|
});
|
|
222
242
|
var DEFAULT_ORGANIZATION_MODEL_PROSPECTING = {
|
|
223
243
|
listEntityId: "leadgen.list",
|
|
@@ -233,6 +253,183 @@ var DEFAULT_ORGANIZATION_MODEL_PROSPECTING = {
|
|
|
233
253
|
{ id: "verified", label: "Verified", order: 2 },
|
|
234
254
|
{ id: "personalized", label: "Personalized", order: 3 },
|
|
235
255
|
{ id: "uploaded", label: "Uploaded", order: 4 }
|
|
256
|
+
],
|
|
257
|
+
defaultBuildTemplateId: "local-services",
|
|
258
|
+
buildTemplates: [
|
|
259
|
+
{
|
|
260
|
+
id: "local-services",
|
|
261
|
+
label: "Local Services Prospecting",
|
|
262
|
+
description: "Curated local-services list build using company sourcing, website analysis, qualification, contact discovery, verification, personalization, and review.",
|
|
263
|
+
steps: [
|
|
264
|
+
{
|
|
265
|
+
id: "source-companies",
|
|
266
|
+
label: "Source companies",
|
|
267
|
+
primaryEntity: "company",
|
|
268
|
+
outputs: ["company"],
|
|
269
|
+
stageKey: "populated",
|
|
270
|
+
dependencyMode: "per-record-eligibility",
|
|
271
|
+
capabilityKey: "lead-gen.company.source",
|
|
272
|
+
defaultBatchSize: 100,
|
|
273
|
+
maxBatchSize: 250
|
|
274
|
+
},
|
|
275
|
+
{
|
|
276
|
+
id: "analyze-websites",
|
|
277
|
+
label: "Analyze websites",
|
|
278
|
+
primaryEntity: "company",
|
|
279
|
+
outputs: ["company"],
|
|
280
|
+
stageKey: "extracted",
|
|
281
|
+
dependsOn: ["source-companies"],
|
|
282
|
+
dependencyMode: "per-record-eligibility",
|
|
283
|
+
capabilityKey: "lead-gen.company.website-extract",
|
|
284
|
+
defaultBatchSize: 50,
|
|
285
|
+
maxBatchSize: 100
|
|
286
|
+
},
|
|
287
|
+
{
|
|
288
|
+
id: "qualify-companies",
|
|
289
|
+
label: "Qualify companies",
|
|
290
|
+
primaryEntity: "company",
|
|
291
|
+
outputs: ["company"],
|
|
292
|
+
stageKey: "qualified",
|
|
293
|
+
dependsOn: ["analyze-websites"],
|
|
294
|
+
dependencyMode: "per-record-eligibility",
|
|
295
|
+
capabilityKey: "lead-gen.company.qualify",
|
|
296
|
+
defaultBatchSize: 100,
|
|
297
|
+
maxBatchSize: 250
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
id: "find-contacts",
|
|
301
|
+
label: "Find contacts",
|
|
302
|
+
primaryEntity: "contact",
|
|
303
|
+
outputs: ["contact"],
|
|
304
|
+
stageKey: "discovered",
|
|
305
|
+
dependsOn: ["qualify-companies"],
|
|
306
|
+
dependencyMode: "per-record-eligibility",
|
|
307
|
+
capabilityKey: "lead-gen.contact.discover",
|
|
308
|
+
defaultBatchSize: 50,
|
|
309
|
+
maxBatchSize: 100
|
|
310
|
+
},
|
|
311
|
+
{
|
|
312
|
+
id: "verify-emails",
|
|
313
|
+
label: "Verify emails",
|
|
314
|
+
primaryEntity: "contact",
|
|
315
|
+
outputs: ["contact"],
|
|
316
|
+
stageKey: "verified",
|
|
317
|
+
dependsOn: ["find-contacts"],
|
|
318
|
+
dependencyMode: "per-record-eligibility",
|
|
319
|
+
capabilityKey: "lead-gen.contact.verify-email",
|
|
320
|
+
defaultBatchSize: 100,
|
|
321
|
+
maxBatchSize: 500
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
id: "personalize",
|
|
325
|
+
label: "Personalize",
|
|
326
|
+
primaryEntity: "contact",
|
|
327
|
+
outputs: ["contact"],
|
|
328
|
+
stageKey: "personalized",
|
|
329
|
+
dependsOn: ["verify-emails"],
|
|
330
|
+
dependencyMode: "per-record-eligibility",
|
|
331
|
+
capabilityKey: "lead-gen.contact.personalize",
|
|
332
|
+
defaultBatchSize: 25,
|
|
333
|
+
maxBatchSize: 100
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
id: "review",
|
|
337
|
+
label: "Review",
|
|
338
|
+
primaryEntity: "contact",
|
|
339
|
+
outputs: ["export"],
|
|
340
|
+
stageKey: "uploaded",
|
|
341
|
+
dependsOn: ["personalize"],
|
|
342
|
+
dependencyMode: "per-record-eligibility",
|
|
343
|
+
capabilityKey: "lead-gen.review.outreach-ready",
|
|
344
|
+
defaultBatchSize: 25,
|
|
345
|
+
maxBatchSize: 100
|
|
346
|
+
}
|
|
347
|
+
]
|
|
348
|
+
},
|
|
349
|
+
{
|
|
350
|
+
id: "dtc-subscription-apollo-clickup",
|
|
351
|
+
label: "DTC Subscription Apollo Export",
|
|
352
|
+
description: "Prospecting pipeline for DTC subscription or subscription-ready brands where Apollo is the source and contact-enrichment layer, Elevasis handles company research and fit scoring, and approved leads export as an approved lead list.",
|
|
353
|
+
steps: [
|
|
354
|
+
{
|
|
355
|
+
id: "import-apollo-search",
|
|
356
|
+
label: "Import Apollo search",
|
|
357
|
+
description: "Pull companies and seed contact data from a predefined Apollo search or list.",
|
|
358
|
+
primaryEntity: "company",
|
|
359
|
+
outputs: ["company", "contact"],
|
|
360
|
+
stageKey: "populated",
|
|
361
|
+
dependencyMode: "per-record-eligibility",
|
|
362
|
+
capabilityKey: "lead-gen.company.apollo-import",
|
|
363
|
+
defaultBatchSize: 250,
|
|
364
|
+
maxBatchSize: 1e3
|
|
365
|
+
},
|
|
366
|
+
{
|
|
367
|
+
id: "analyze-websites",
|
|
368
|
+
label: "Analyze websites",
|
|
369
|
+
description: "Extract subscription, product, retention, and tech-stack signals from each brand website.",
|
|
370
|
+
primaryEntity: "company",
|
|
371
|
+
outputs: ["company"],
|
|
372
|
+
stageKey: "extracted",
|
|
373
|
+
dependsOn: ["import-apollo-search"],
|
|
374
|
+
dependencyMode: "per-record-eligibility",
|
|
375
|
+
capabilityKey: "lead-gen.company.website-extract",
|
|
376
|
+
defaultBatchSize: 50,
|
|
377
|
+
maxBatchSize: 100
|
|
378
|
+
},
|
|
379
|
+
{
|
|
380
|
+
id: "score-dtc-fit",
|
|
381
|
+
label: "Score DTC fit",
|
|
382
|
+
description: "Classify subscription potential, consumable-product fit, retention maturity, and disqualifiers.",
|
|
383
|
+
primaryEntity: "company",
|
|
384
|
+
outputs: ["company"],
|
|
385
|
+
stageKey: "qualified",
|
|
386
|
+
dependsOn: ["analyze-websites"],
|
|
387
|
+
dependencyMode: "per-record-eligibility",
|
|
388
|
+
capabilityKey: "lead-gen.company.dtc-subscription-qualify",
|
|
389
|
+
defaultBatchSize: 100,
|
|
390
|
+
maxBatchSize: 250
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
id: "enrich-decision-makers",
|
|
394
|
+
label: "Enrich decision-makers",
|
|
395
|
+
description: "Use Apollo to find qualified contacts such as founders, retention leads, lifecycle leads, and marketing owners.",
|
|
396
|
+
primaryEntity: "contact",
|
|
397
|
+
outputs: ["contact"],
|
|
398
|
+
stageKey: "discovered",
|
|
399
|
+
dependsOn: ["score-dtc-fit"],
|
|
400
|
+
dependencyMode: "per-record-eligibility",
|
|
401
|
+
capabilityKey: "lead-gen.contact.apollo-decision-maker-enrich",
|
|
402
|
+
defaultBatchSize: 100,
|
|
403
|
+
maxBatchSize: 250
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
id: "verify-emails",
|
|
407
|
+
label: "Verify emails",
|
|
408
|
+
description: "Verify deliverability before the QC and handoff step.",
|
|
409
|
+
primaryEntity: "contact",
|
|
410
|
+
outputs: ["contact"],
|
|
411
|
+
stageKey: "verified",
|
|
412
|
+
dependsOn: ["enrich-decision-makers"],
|
|
413
|
+
dependencyMode: "per-record-eligibility",
|
|
414
|
+
capabilityKey: "lead-gen.contact.verify-email",
|
|
415
|
+
defaultBatchSize: 250,
|
|
416
|
+
maxBatchSize: 500
|
|
417
|
+
},
|
|
418
|
+
{
|
|
419
|
+
id: "review-and-export",
|
|
420
|
+
label: "Review and export",
|
|
421
|
+
description: "Operator QC approves or rejects leads, then approved records are exported as a lead list.",
|
|
422
|
+
primaryEntity: "company",
|
|
423
|
+
outputs: ["export"],
|
|
424
|
+
stageKey: "uploaded",
|
|
425
|
+
dependsOn: ["verify-emails"],
|
|
426
|
+
dependencyMode: "per-record-eligibility",
|
|
427
|
+
capabilityKey: "lead-gen.export.list",
|
|
428
|
+
defaultBatchSize: 100,
|
|
429
|
+
maxBatchSize: 250
|
|
430
|
+
}
|
|
431
|
+
]
|
|
432
|
+
}
|
|
236
433
|
]
|
|
237
434
|
};
|
|
238
435
|
|