@signaliz/sdk 1.0.6 → 1.0.7
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 +100 -8
- package/dist/{chunk-GRVV37LD.mjs → chunk-BHL5NHVO.mjs} +1413 -55
- package/dist/cli.js +2370 -62
- package/dist/cli.mjs +962 -9
- package/dist/index.d.mts +245 -10
- package/dist/index.d.ts +245 -10
- package/dist/index.js +1423 -55
- package/dist/index.mjs +21 -1
- package/dist/mcp-config.js +1301 -55
- package/dist/mcp-config.mjs +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -62,6 +62,93 @@ console.log('Download:', csv?.signedUrl);
|
|
|
62
62
|
|
|
63
63
|
> **Downstream routing:** Signaliz outputs JSON, CSV, and webhook. Your agent routes rows to CRMs, outreach tools, or warehouses using their own APIs/MCPs.
|
|
64
64
|
|
|
65
|
+
## Campaign Builder Agent
|
|
66
|
+
|
|
67
|
+
Use `campaignBuilderAgent` when application code should compose the same
|
|
68
|
+
strategy-template MCP flow exposed in the CLI: strategy-memory readiness,
|
|
69
|
+
Signaliz-native sourcing, email finding, verification, signals, Brain risk, and
|
|
70
|
+
BYO tool routes.
|
|
71
|
+
|
|
72
|
+
```typescript
|
|
73
|
+
const plan = await signaliz.campaignBuilderAgent.createPlan({
|
|
74
|
+
goal: 'Build a strategy-template campaign for mature local operators',
|
|
75
|
+
strategyTemplate: 'non-medical-home-care',
|
|
76
|
+
targetCount: 500,
|
|
77
|
+
builtIns: ['lead_generation', 'local_leads', 'email_finding', 'email_verification', 'signals'],
|
|
78
|
+
integrations: [{
|
|
79
|
+
provider: 'workspace_mcp',
|
|
80
|
+
layer: 'enrichment',
|
|
81
|
+
gtmLayers: ['company_enrichment'],
|
|
82
|
+
toolName: 'account_enrich',
|
|
83
|
+
mcpServerName: 'workspace-mcp',
|
|
84
|
+
mode: 'required',
|
|
85
|
+
approvalRequired: true,
|
|
86
|
+
}],
|
|
87
|
+
agencyContext: {
|
|
88
|
+
strategyModel: 'strategy_template',
|
|
89
|
+
includeStrategyPatterns: true,
|
|
90
|
+
includeWorkflowPatterns: true,
|
|
91
|
+
includeNangoCatalog: true,
|
|
92
|
+
},
|
|
93
|
+
});
|
|
94
|
+
|
|
95
|
+
const dryRun = await signaliz.campaignBuilderAgent.dryRunPlan(plan);
|
|
96
|
+
|
|
97
|
+
console.log(plan.strategyMemoryStatus?.ready);
|
|
98
|
+
console.log(plan.mcpFlow.filter((step) =>
|
|
99
|
+
['gtm_provider_recipe_prepare', 'gtm_provider_route_activate'].includes(step.tool)
|
|
100
|
+
));
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
The CLI can run the same request shape from a reusable JSON file, with flags
|
|
104
|
+
overriding file fields:
|
|
105
|
+
|
|
106
|
+
```bash
|
|
107
|
+
npx @signaliz/sdk campaign-agent init \
|
|
108
|
+
--strategy-template non-medical-home-care \
|
|
109
|
+
--target-count 250 \
|
|
110
|
+
--use-local-leads \
|
|
111
|
+
--with-byo-placeholder \
|
|
112
|
+
--output-file campaign-request.json
|
|
113
|
+
|
|
114
|
+
npx @signaliz/sdk campaign-agent plan \
|
|
115
|
+
--request-file campaign-request.json \
|
|
116
|
+
--target-count 250 \
|
|
117
|
+
--json
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
Use the hosted MCP campaign-agent planner when you want Signaliz to return the
|
|
121
|
+
same strategy-template runbook exposed through MCP:
|
|
122
|
+
|
|
123
|
+
```typescript
|
|
124
|
+
const memoryStatus = await signaliz.gtm.campaignStrategyMemoryStatus({
|
|
125
|
+
strategyTemplate: 'non-medical-home-care',
|
|
126
|
+
includeSamples: true,
|
|
127
|
+
});
|
|
128
|
+
|
|
129
|
+
const hostedTemplate = await signaliz.gtm.campaignAgentRequestTemplate({
|
|
130
|
+
goal: 'Build a reusable strategy-template campaign request',
|
|
131
|
+
strategyTemplate: 'non-medical-home-care',
|
|
132
|
+
targetCount: 250,
|
|
133
|
+
includeLocalLeads: true,
|
|
134
|
+
includeByoPlaceholder: true,
|
|
135
|
+
privacyMode: 'workspace_only',
|
|
136
|
+
});
|
|
137
|
+
|
|
138
|
+
const hostedPlan = await signaliz.gtm.campaignAgentPlan({
|
|
139
|
+
goal: 'Build a strategy-template campaign for local operators',
|
|
140
|
+
strategyTemplate: 'non-medical-home-care',
|
|
141
|
+
targetCount: 500,
|
|
142
|
+
builtIns: ['lead_generation', 'local_leads', 'email_finding', 'email_verification', 'signals'],
|
|
143
|
+
customTools: [{
|
|
144
|
+
provider: 'workspace_mcp',
|
|
145
|
+
layer: 'enrichment',
|
|
146
|
+
tool: 'account_enrich',
|
|
147
|
+
mcp: 'workspace-mcp',
|
|
148
|
+
}],
|
|
149
|
+
});
|
|
150
|
+
```
|
|
151
|
+
|
|
65
152
|
## GTM Kernel + Brain
|
|
66
153
|
|
|
67
154
|
Use `signaliz.gtm` when an agent needs the substrate directly: workspace context, first-class campaign objects, ranked memory, Brain patterns/defaults, and provider routes.
|
|
@@ -177,11 +264,18 @@ connection reference and approval/audit context.
|
|
|
177
264
|
### Nango-Managed API Tools
|
|
178
265
|
|
|
179
266
|
Use Nango when a workspace brings its own provider account and the action should
|
|
180
|
-
run through Nango-managed auth.
|
|
181
|
-
|
|
182
|
-
|
|
267
|
+
run through Nango-managed auth. If the vendor is not connected yet, create a
|
|
268
|
+
Connect session and send the user to the returned auth link. Then list tools for
|
|
269
|
+
the saved workspace connection, dry-run the action, and confirm the write only
|
|
270
|
+
after the preview is approved.
|
|
183
271
|
|
|
184
272
|
```typescript
|
|
273
|
+
const session = await signaliz.gtm.createNangoConnectSession({
|
|
274
|
+
providerId: 'apollo',
|
|
275
|
+
integrationId: 'apollo',
|
|
276
|
+
});
|
|
277
|
+
console.log(session.connect_link);
|
|
278
|
+
|
|
185
279
|
const tools = await signaliz.gtm.listNangoTools({
|
|
186
280
|
workspaceConnectionId: 'workspace_conn_nango_hubspot',
|
|
187
281
|
providerConfigKey: 'hubspot',
|
|
@@ -217,13 +311,11 @@ if (preview.ready_for_confirmation) {
|
|
|
217
311
|
|
|
218
312
|
### GTM Kernel Smoke Test
|
|
219
313
|
|
|
220
|
-
After
|
|
314
|
+
After strategy imports or Campaign Builder backfills, run the read-only/dry-run
|
|
221
315
|
smoke harness before launching spendful provider work:
|
|
222
316
|
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
--campaign-build-id <campaign_build_id>
|
|
226
|
-
```
|
|
317
|
+
Run the internal smoke harness with `SIGNALIZ_API_KEY` and
|
|
318
|
+
`--campaign-build-id <campaign_build_id>` or `--campaign-id <campaign_id>`.
|
|
227
319
|
|
|
228
320
|
The receipt includes campaign/build/workspace IDs, execution stage, feedback and
|
|
229
321
|
memory counts, workspace bootstrap gate readiness, Brain phase readiness,
|