@elevasis/sdk 1.17.0 → 1.18.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elevasis/sdk",
3
- "version": "1.17.0",
3
+ "version": "1.18.0",
4
4
  "description": "SDK for building Elevasis organization resources",
5
5
  "type": "module",
6
6
  "bin": {
@@ -57,7 +57,7 @@
57
57
  "tsup": "^8.0.0",
58
58
  "typescript": "5.9.2",
59
59
  "zod": "^4.1.0",
60
- "@repo/core": "0.17.0",
60
+ "@repo/core": "0.19.0",
61
61
  "@repo/eslint-config": "0.0.0",
62
62
  "@repo/typescript-config": "0.0.0"
63
63
  },
@@ -0,0 +1,33 @@
1
+ # Package Taxonomy (Consumer View)
2
+
3
+ External projects consume the **published `@elevasis/*` surface only**. The Elevasis monorepo also has workspace-internal `@repo/elevasis-*` packages — those are NOT installable here and should never appear in your imports or `package.json`.
4
+
5
+ ## What You Can Import
6
+
7
+ | Package | Subpaths | Where it lives in `node_modules` |
8
+ | ---------------- | -------------------------------------------- | -------------------------------- |
9
+ | `@elevasis/sdk` | default, `/worker`, `/node`, `/test-utils` | `node_modules/@elevasis/sdk/` |
10
+ | `@elevasis/ui` | default, `/auth`, `/initialization`, etc. | `node_modules/@elevasis/ui/` |
11
+ | `@elevasis/core` | `/organization-model`, `/entities`, `/utils` | `node_modules/@elevasis/core/` |
12
+
13
+ ## What You Will See in Monorepo Docs (and should NOT import)
14
+
15
+ Monorepo source and docs reference `@repo/elevasis-core` and `@repo/elevasis-operations`. These are workspace-internal packages used by Elevasis as a tenant of its own platform. They are `private: true` and never published. If you see them mentioned:
16
+
17
+ - Do NOT add them to this project's `package.json`
18
+ - Do NOT try to import from them — they are not in your `node_modules`
19
+ - They are not a substitute for `@elevasis/core` even though the name overlaps
20
+
21
+ ## Confused About Where Something Lives?
22
+
23
+ Check the import path:
24
+
25
+ - `@elevasis/...` → published, consumable here
26
+ - `@repo/...` → monorepo-internal, not consumable
27
+
28
+ This project's own org-model and workflows live in `core/config/organization-model.ts` and `operations/src/**` — those are project-owned, not part of either family above.
29
+
30
+ ## References
31
+
32
+ - `node_modules/@elevasis/sdk/reference/scaffold/index.mdx` — full SDK scaffold reference
33
+ - Monorepo source rule: `.claude/rules/package-taxonomy.md` in the elevasis-monorepo (when working across both)
@@ -66,6 +66,17 @@ The user wants the agent to explain something -- a scope, an entity, a concept w
66
66
 
67
67
  **Agent action:** read the relevant org-model label, entity, or scope. Narrate in plain language using label fields from the model -- never invent vocabulary not present in the model. Phase-1 scope covers Model, Features, and Foundations layers only.
68
68
 
69
+ **Stage/state/catalog sub-routing:** when the noun being described is a stage, state, status
70
+ bucket, catalog entry, progress step, pipeline column, or similarly closed business vocabulary,
71
+ also show the cross-system impact before the normal description:
72
+
73
+ 1. Read `node_modules/@elevasis/sdk/reference/spine/spine-primer.md` for the layering pattern.
74
+ 2. Read the relevant domain in `foundations/config/organization-model.ts`.
75
+ 3. Explain the impact in vibe-coder language only: the business profile entry, the saved progress
76
+ on each record, the automations that produce updates, and the dashboard or reports that read it.
77
+ 4. Route follow-up changes through `/knowledge <domain>`. Do not mention the technical pattern name
78
+ unless the user explicitly asks for internals.
79
+
69
80
  ### 4. Transition
70
81
 
71
82
  The user wants to change the status of a task or entity.
@@ -114,6 +125,18 @@ The user describes organizational reality that is not yet expressed in the model
114
125
 
115
126
  **Agent action:** delegate immediately to `/knowledge`. Do not attempt the ceremony yourself. Invoke with the relevant domain: `/knowledge crm` for deal/contact changes, `/knowledge projects` for project types, `/knowledge features` for feature toggles. Plain-language summary of what was detected is acceptable before delegating, but the actual draft-confirm-write ceremony belongs to `/knowledge`.
116
127
 
128
+ **Stage/state/catalog impact preview:** if the Codify intent adds, renames, removes, reorders, or
129
+ re-scopes a stage, state, status bucket, catalog member, pipeline step, or progress vocabulary,
130
+ preview the cross-system impact before delegating:
131
+
132
+ - Which business-profile entry changes.
133
+ - Which saved record progress keys may already exist.
134
+ - Which automations or templates reference the key.
135
+ - Which dashboard, report, queue, or API reads may display or filter by it.
136
+
137
+ Then delegate to `/knowledge <domain>` with that preview as context. Vibe does not write the
138
+ change and does not expose monorepo-only commands.
139
+
117
140
  This routing applies to both codify levels (decision #21 -- Codify ceremony delegated to `/knowledge`):
118
141
 
119
142
  - **Level A** (config-only edits to `organization-model.ts`, feature toggles, label renames): delegate to `/knowledge <domain>` immediately.
@@ -92,11 +92,38 @@ cannot bypass the write gate.
92
92
  | Read | "what playbooks govern sales.crm?", "show me all reference docs", "list my roles" | Run CLI read commands (monorepo or external); format result |
93
93
  | Navigate | "what governs this feature?", "where does outreach-cadence apply?" | Same CLI; pick mount axis from intent; default to `by-feature` for orientation queries |
94
94
  | Describe | "what is our identity set to?", "what's our timezone?" | Read current values from OM source; narrate |
95
- | Codify | "we're an e-commerce company", "add a customer segment", "our outreach goal is..." | Run codify ceremony: snapshot -> propose -> confirm -> write -> typecheck -> Zod parse -> rollback on failure |
95
+ | Codify | "we're an e-commerce company", "add a customer segment", "our outreach goal is..." | Run codify ceremony with shared-layer impact preview: snapshot -> propose -> confirm -> write -> typecheck -> Zod parse -> rollback on failure |
96
96
  | Toggle | "enable the lead-gen feature", "turn off SEO" | Codify ceremony scoped to `features` domain; flip the boolean; same validation/rollback |
97
97
 
98
98
  ---
99
99
 
100
+ ## Shared Layering Preview
101
+
102
+ When opening a domain that uses a closed stage, status, or catalog vocabulary -- especially
103
+ prospecting, CRM, outreach, or another pipeline-like domain -- read the scaffold-shipped primer:
104
+
105
+ ```bash
106
+ node_modules/@elevasis/sdk/reference/spine/spine-primer.md
107
+ ```
108
+
109
+ Use it to emit a short domain layering preview before the normal read, describe, or codify flow:
110
+
111
+ 1. **Catalog:** which `organizationModel.<domain>` catalog owns the keys, labels, descriptions,
112
+ ordering, and entity ownership.
113
+ 2. **Runtime state:** where record progress is stored as sparse state keyed by those catalog
114
+ members.
115
+ 3. **Producers:** which templates, automations, or factories write entity-tagged results for those
116
+ keys.
117
+ 4. **Consumers:** which dashboards, queues, reports, filters, or API reads render or aggregate the
118
+ same keys.
119
+
120
+ For vibe-coder sessions, translate this into plain language: "business profile", "saved progress",
121
+ "automations", and "dashboard or reports". For technical sessions, it is acceptable to name the
122
+ catalog, state map, producer, and consumer surfaces directly. External tenants route all follow-ups
123
+ through `/knowledge`; do not point them at monorepo-only commands.
124
+
125
+ ---
126
+
100
127
  ## Read Patterns
101
128
 
102
129
  ### Monorepo (platform defaults)
@@ -156,6 +183,12 @@ Read `foundations/config/organization-model.ts` (external) or the appropriate pl
156
183
  Show the diff in chat. Identify which domain and field changes. Present the proposed new value
157
184
  in context alongside the current value.
158
185
 
186
+ For stage, status, or catalog vocabulary edits, include the shared-layer impact preview before
187
+ asking for confirmation. Name the affected catalog key, whether existing sparse runtime state may
188
+ contain the old key, which producers/templates reference it, and which consumers render or filter by
189
+ it. If the impact cannot be determined from the local project, say which surface is unknown and keep
190
+ the write gated.
191
+
159
192
  ### Step 3: Confirm
160
193
 
161
194
  Pause for explicit user confirmation. Do not proceed without a clear yes. Permission prompts
@@ -240,13 +273,12 @@ Cross-link: `.claude/skills/knowledge/SKILL.md` (monorepo pointer)
240
273
 
241
274
  ## Cross-Links
242
275
 
243
- - `/org-os` -- Organization OS architecture overview, seven layers, propagation pipeline,
244
- feature/surface management. Use `/org-os` when the question is about the architecture or
245
- propagation system rather than reading or editing org-model values. Cross-link:
246
- `.claude/skills/org-os/SKILL.md`
247
276
  - `/configure` -- Legacy org-model editor (pre-absorption). Absorbed into this skill; all
248
277
  Codify and Toggle intents now route here. `/configure` vocabulary still works as a domain
249
278
  hint (e.g., "configure identity" is parsed as domain=identity, intent=Describe-or-Codify).
279
+ - `node_modules/@elevasis/sdk/reference/spine/spine-primer.md` -- Scaffold-shipped layering
280
+ primer for stage/status/catalog vocabularies that coordinate business-profile entries, runtime
281
+ progress, producers, and consumers in tenant projects.
250
282
 
251
283
  ---
252
284
 
@@ -399,6 +399,27 @@ Recent Notes
399
399
  2026-04-01 [call_note] Kickoff — confirmed scope and timeline
400
400
  ```
401
401
 
402
+ #### Tenant Skill Bindings Footer
403
+
404
+ After the normal status output, append a short footer when the project kind, tags, name,
405
+ description, milestones, or active tasks map to a known tenant domain such as `prospecting`,
406
+ `crm`, `outreach`, `finance`, or `support`.
407
+
408
+ Resolve the best domain from explicit metadata first (`tags`, `kind`, domain fields), then from
409
+ project/task text. If no clear domain maps, omit the footer.
410
+
411
+ Footer shape:
412
+
413
+ ```text
414
+ Related skill bindings
415
+ - Domain: <domain>
416
+ - Read or change business profile: /knowledge <domain>
417
+ - Layering primer: node_modules/@elevasis/sdk/reference/spine/spine-primer.md
418
+ ```
419
+
420
+ External projects do not expose monorepo-only architecture commands. Never suggest `/org-os`,
421
+ `/om-spine`, or monorepo paths in this footer.
422
+
402
423
  ### `create` — Guided Project Creation (QnA Flow)
403
424
 
404
425
  Interactive walkthrough that collects project details step by step using `AskUserQuestion`,
@@ -29,6 +29,15 @@ This router does not enforce that tone -- it only writes profile.md and loads th
29
29
  file. The project-wide tone effect is handled by the rules layer reading profile.md on each
30
30
  session start.
31
31
 
32
+ Track separation is explicit:
33
+
34
+ - The vibe-coder track teaches the underlying coordination idea through business language only:
35
+ business profile, saved progress, automations, dashboard, and reports. Do not name the technical
36
+ pattern in vibe-coder menus, lessons, prompts, or progress labels.
37
+ - The technical track may name OM spine vocabulary and can point developers at
38
+ `node_modules/@elevasis/sdk/reference/spine/spine-primer.md` when lessons discuss shared stage,
39
+ status, or catalog vocabularies.
40
+
32
41
  ---
33
42
 
34
43
  ## Step 1: Parse the Argument
@@ -111,8 +120,9 @@ In this project, always:
111
120
 
112
121
  ## Tone Implications
113
122
 
114
- Code-first communication. Use current command names and SDK terminology without hand-holding.
115
- No vocabulary substitutions. Slash commands may be surfaced directly. Full technical depth.
123
+ Code-first communication. Use current command names, SDK terminology, and OM spine vocabulary
124
+ without hand-holding. No vocabulary substitutions. Slash commands may be surfaced directly. Full
125
+ technical depth.
116
126
  ```
117
127
 
118
128
  ### Initialize Progress File
@@ -156,7 +166,7 @@ Read `.claude/memory/tutorial-progress.md`.
156
166
  - [ ] 15 Error handling
157
167
  - [ ] 16 LLM and agents
158
168
  - [ ] 17 Composition
159
- - [ ] 18 Rules, memory, scaffold registry
169
+ - [ ] 18 Rules, memory, scaffold registry, OM spine
160
170
  - [ ] 19 Template lifecycle and /git-sync
161
171
  ```
162
172
 
@@ -0,0 +1,42 @@
1
+ # 2026-05-05 — List Builder UX + Schema-Driven Step Config
2
+
3
+ ## Why this note exists
4
+
5
+ The list-builder ship train publishes a coordinated `@elevasis/core` + `@elevasis/ui` release that:
6
+
7
+ - Replaces every per-integration bespoke step-config component (and the `SerializedExecutionFormSchema` middle tier) with one generic `<StepConfigForm>` driven by the workflow's `contract.inputSchema` (Zod) plus a small `StepConfigLayout` hints object per integration.
8
+ - Standardizes the BuildTab step-detail right column on a `Configuration | Advanced | Runs` tab shell (`StepDetailRightColumn`).
9
+ - Makes `schema + layout` REQUIRED on `ListBuilderWorkflow`. The legacy `configSchema?` / `ConfigurationFields?` / `AdvancedFields?` / `inputForm?` fields are gone.
10
+ - Removes several `@elevasis/core` execution-form types (`SerializedFormField`, `SerializedFormSchema`, `SerializedExecutionFormSchema`, `SerializedExecutionInterface`, `ExecutionRunnerCatalogItem`, `ExecutionRunnerCatalogResponse`, plus `interface?` from definition types), the `ResourceExecuteForm` / `ResourceExecuteDialog` / `ExecutionRunner` surfaces from `@elevasis/ui`, and the API `execution/runner/` runtime.
11
+
12
+ If a derived project authors its own list-builder step actions or imported any of the deleted types, it will not compile against the new `@elevasis/ui` / `@elevasis/core` baselines without the migration below.
13
+
14
+ ## Applies to
15
+
16
+ - All template-derived projects whose `ui/` consumes `@elevasis/ui` and registers list-builder actions.
17
+ - Any project whose `core/` or `operations/` imports the removed execution-form types from `@elevasis/core`.
18
+ - Any project rendering the list-builder Build tab via `LeadGenListDetailPage` or its `RunWorkflowModal`.
19
+
20
+ ## Required actions
21
+
22
+ 1. Bump `@elevasis/core` and `@elevasis/ui` to the versions published by this train (see `external/_template/{core,ui}/package.json` baselines).
23
+ 2. For every `ListBuilderWorkflow` registry entry the project authors locally, swap to the `schema + layout` contract:
24
+ - Add a browser-safe sibling schema export (split-file pattern: keep Node-only deps out of `ui/`).
25
+ - Provide a `StepConfigLayout<T>` describing field hints (no React, no validation logic).
26
+ - Drop any `ConfigurationFields` / `AdvancedFields` / `configSchema` / `inputForm` references.
27
+ 3. Delete any imports of the removed core types: `SerializedFormField`, `SerializedFormSchema`, `SerializedExecutionFormSchema`, `SerializedExecutionInterface`, `ExecutionRunnerCatalogItem`, `ExecutionRunnerCatalogResponse`, and the `interface?` field on workflow definitions.
28
+ 4. If the project rendered the deleted `ResourceExecuteForm` / `ResourceExecuteDialog` / `ExecutionRunner` surfaces, replace with `<StepConfigForm>` (curated UX) or `<ZodFormRenderer>` (auto-derived from Zod) as appropriate. `renderExecuteDialog` is now REQUIRED on `ResourceDetailPage`.
29
+ 5. Re-run `pnpm -C ui check-types` and `pnpm -C operations check-types` to confirm the schema sibling files resolve and no removed types remain referenced.
30
+
31
+ ## Verification
32
+
33
+ - `pnpm -C ui check-types` — no references to `SerializedFormField`, `SerializedExecutionFormSchema`, `ResourceExecuteForm`, etc.
34
+ - `pnpm -C ui build` — clean build with the new `@elevasis/ui` baseline.
35
+ - `pnpm -C operations check` and `check-types` — clean.
36
+ - BuildTab smoke (manual): open a list under `/lead-gen/lists/{listId}`, select a step, confirm the right column renders the `Configuration | Advanced | Runs` tabs and the schema-driven form (defaults populate, validation Alert fires + clears on edit, conditional `when:` predicates toggle, `recentRuns[0]` auto-load works).
37
+
38
+ ## Not handled by /git-sync
39
+
40
+ - Project-authored `ListBuilderWorkflow` registrations are project-owned code; `/git-sync` does not migrate them. Each project must port its action entries to `schema + layout` by hand following the `apolloImportLayout` pattern in the template's `apps/command-center/src/main.tsx`.
41
+ - Browser dev-smoke for each migrated step type is operator-driven; not automatable through sync.
42
+ - Any local re-implementations or extensions of the deleted `ResourceExecuteForm` / `ExecutionRunner` surfaces must be removed manually before this baseline can be adopted.
@@ -0,0 +1,37 @@
1
+ # 2026-05-06 -- SDK Changes Release Train
2
+
3
+ ## Why this note exists
4
+
5
+ This train coordinates the Google Calendar integration, list-builder OM Spine cleanup, and OM Spine documentation/skill surfaces into one package and external-sync release. It publishes updated `@elevasis/core`, `@elevasis/ui`, and `@elevasis/sdk` baselines, then syncs template Claude guidance and package versions to derived projects.
6
+
7
+ ## Applies to
8
+
9
+ - Template-derived projects consuming `@elevasis/core`, `@elevasis/ui`, or `@elevasis/sdk`.
10
+ - Projects using the list-builder workflow factory or custom lead-gen build-state UI.
11
+ - Projects relying on tenant Claude guidance for `/knowledge`, `/project`, `/tutorial`, or ambient `vibe` behavior.
12
+
13
+ ## Required actions
14
+
15
+ 1. Pull the synced template changes through `/git-sync`.
16
+ 2. Accept the package baseline bumps published by this train:
17
+ - `core/package.json`: `@elevasis/core`
18
+ - `ui/package.json`: `@elevasis/ui`
19
+ - `operations/package.json`: `@elevasis/core` and `@elevasis/sdk`
20
+ 3. Review local list-builder customizations against the OM-owned stage vocabulary and SDK `listBuilderWorkflow(...)` factory.
21
+ 4. Review any local tenant guidance overrides before accepting the synced `.claude/rules/vibe.md` and `.claude/skills/{knowledge,project,tutorial}/SKILL.md` changes.
22
+
23
+ ## Verification
24
+
25
+ - `pnpm -C ui check-types`
26
+ - `pnpm -C ui build`
27
+ - `pnpm -C ui test`
28
+ - `pnpm -C operations check`
29
+ - `pnpm -C operations check-types`
30
+ - `pnpm -C operations test`
31
+ - `pnpm -C core test`
32
+
33
+ ## Not handled by /git-sync
34
+
35
+ - Project-authored list-builder workflow registrations remain project-owned code.
36
+ - Google Calendar OAuth configuration remains an Elevasis platform/admin responsibility, not a tenant scaffold migration.
37
+ - Manual browser smoke for authenticated calendar views is not automated by template sync.
@@ -198,6 +198,18 @@ export type OrgKnowledgeNode = z.infer<typeof OrgKnowledgeNodeSchema>
198
198
  export type OrgKnowledgeKind = z.infer<typeof OrgKnowledgeKindSchema>
199
199
  ```
200
200
 
201
+ ### `KnowledgeSkillBinding`
202
+
203
+ ```typescript
204
+ export type KnowledgeSkillBinding = z.infer<typeof KnowledgeSkillBindingSchema>
205
+ ```
206
+
207
+ ### `KnowledgeDomainBinding`
208
+
209
+ ```typescript
210
+ export type KnowledgeDomainBinding = z.infer<typeof KnowledgeDomainBindingSchema>
211
+ ```
212
+
201
213
  ### `OrganizationModelIconToken`
202
214
 
203
215
  ```typescript
@@ -869,7 +881,9 @@ export interface AcqCompany {
869
881
  category: string | null
870
882
  categoryPain: string | null
871
883
  segment: string | null
872
- pipelineStatus: CompanyPipelineStatus | null
884
+ processingState: CompanyProcessingState | null
885
+ /** @deprecated Use `processingState`. This legacy DB column has been removed; responses return null. */
886
+ pipelineStatus?: LegacyPipelineStatus | null
873
887
  enrichmentData: CompanyEnrichmentData | null
874
888
  source: string | null
875
889
  batchId: string | null
@@ -909,7 +923,9 @@ export interface AcqContact {
909
923
  openingLine: string | null
910
924
  source: string | null
911
925
  sourceId: string | null
912
- pipelineStatus: ContactPipelineStatus | null
926
+ processingState: ContactProcessingState | null
927
+ /** @deprecated Use `processingState`. This legacy DB column has been removed; responses return null. */
928
+ pipelineStatus?: LegacyPipelineStatus | null
913
929
  enrichmentData: ContactEnrichmentData | null
914
930
  /** Attio Person record ID - set when contact responds and is added to CRM */
915
931
  attioPersonId: string | null
@@ -972,7 +988,7 @@ export interface DealContact {
972
988
  title: string | null
973
989
  headline: string | null
974
990
  linkedin_url: string | null
975
- pipeline_status: Record<string, unknown> | null
991
+ processing_state: Record<string, unknown> | null
976
992
  enrichment_data: Record<string, unknown> | null
977
993
  company: {
978
994
  id: string
@@ -1245,7 +1261,7 @@ export const DealContactSummarySchema = z.object({
1245
1261
  title: z.string().nullable(),
1246
1262
  headline: z.string().nullable(),
1247
1263
  linkedin_url: z.string().nullable(),
1248
- pipeline_status: z.record(z.string(), z.unknown()).nullable(),
1264
+ processing_state: ProcessingStateSchema.nullable(),
1249
1265
  enrichment_data: z.record(z.string(), z.unknown()).nullable(),
1250
1266
  company: z
1251
1267
  .object({
@@ -1573,51 +1589,6 @@ export interface WebPost {
1573
1589
  }
1574
1590
  ```
1575
1591
 
1576
- ### `CompanyPipelineStatus`
1577
-
1578
- ```typescript
1579
- /**
1580
- * Tracks pipeline status for a company across all processing stages.
1581
- */
1582
- export interface CompanyPipelineStatus {
1583
- acquired: boolean
1584
- enrichment: {
1585
- [source: string]: {
1586
- status: 'pending' | 'complete' | 'failed' | 'skipped'
1587
- completedAt?: string
1588
- error?: string
1589
- }
1590
- }
1591
- }
1592
- ```
1593
-
1594
- ### `ContactPipelineStatus`
1595
-
1596
- ```typescript
1597
- /**
1598
- * Tracks pipeline status for a contact across all processing stages.
1599
- */
1600
- export interface ContactPipelineStatus {
1601
- enrichment: {
1602
- [source: string]: {
1603
- status: 'pending' | 'complete' | 'failed' | 'skipped'
1604
- completedAt?: string
1605
- error?: string
1606
- }
1607
- }
1608
- personalization: {
1609
- status: 'pending' | 'complete' | 'failed' | 'skipped'
1610
- completedAt?: string
1611
- }
1612
- outreach: {
1613
- status: 'pending' | 'sent' | 'replied' | 'bounced' | 'opted-out'
1614
- sentAt?: string
1615
- channel?: string
1616
- campaignId?: string
1617
- }
1618
- }
1619
- ```
1620
-
1621
1592
  ### `CompanyEnrichmentData`
1622
1593
 
1623
1594
  ```typescript
@@ -1733,7 +1704,9 @@ export interface AcqCompany {
1733
1704
  category: string | null
1734
1705
  categoryPain: string | null
1735
1706
  segment: string | null
1736
- pipelineStatus: CompanyPipelineStatus | null
1707
+ processingState: CompanyProcessingState | null
1708
+ /** @deprecated Use `processingState`. This legacy DB column has been removed; responses return null. */
1709
+ pipelineStatus?: LegacyPipelineStatus | null
1737
1710
  enrichmentData: CompanyEnrichmentData | null
1738
1711
  source: string | null
1739
1712
  batchId: string | null
@@ -1773,7 +1746,9 @@ export interface AcqContact {
1773
1746
  openingLine: string | null
1774
1747
  source: string | null
1775
1748
  sourceId: string | null
1776
- pipelineStatus: ContactPipelineStatus | null
1749
+ processingState: ContactProcessingState | null
1750
+ /** @deprecated Use `processingState`. This legacy DB column has been removed; responses return null. */
1751
+ pipelineStatus?: LegacyPipelineStatus | null
1777
1752
  enrichmentData: ContactEnrichmentData | null
1778
1753
  /** Attio Person record ID - set when contact responds and is added to CRM */
1779
1754
  attioPersonId: string | null
@@ -2084,6 +2059,7 @@ export const ListCompaniesQuerySchema = z
2084
2059
  website: z.string().trim().min(1).max(2048).optional(),
2085
2060
  segment: z.string().trim().min(1).max(255).optional(),
2086
2061
  category: z.string().trim().min(1).max(255).optional(),
2062
+ pipelineStatus: z.unknown().optional(),
2087
2063
  batchId: z.string().trim().min(1).max(255).optional(),
2088
2064
  status: AcqCompanyStatusSchema.optional(),
2089
2065
  includeAll: QueryBooleanSchema.optional(),
@@ -2125,6 +2101,7 @@ export const CreateCompanyRequestSchema = z
2125
2101
  category: z.string().trim().min(1).max(255).optional(),
2126
2102
  source: z.string().trim().min(1).max(255).optional(),
2127
2103
  batchId: z.string().trim().min(1).max(255).optional(),
2104
+ pipelineStatus: z.unknown().optional(),
2128
2105
  verticalResearch: z.string().trim().min(1).max(5000).optional()
2129
2106
  })
2130
2107
  .strict()
@@ -2145,7 +2122,8 @@ export const UpdateCompanyRequestSchema = z
2145
2122
  locationState: z.string().trim().min(1).max(255).optional(),
2146
2123
  category: z.string().trim().min(1).max(255).optional(),
2147
2124
  segment: z.string().trim().min(1).max(255).optional(),
2148
- pipelineStatus: z.record(z.string(), z.unknown()).optional(),
2125
+ processingState: CompanyProcessingStateSchema.optional(),
2126
+ pipelineStatus: z.unknown().optional(),
2149
2127
  enrichmentData: z.record(z.string(), z.unknown()).optional(),
2150
2128
  source: z.string().trim().min(1).max(255).optional(),
2151
2129
  batchId: z.string().trim().min(1).max(255).optional(),
@@ -2165,6 +2143,7 @@ export const UpdateCompanyRequestSchema = z
2165
2143
  data.locationState !== undefined ||
2166
2144
  data.category !== undefined ||
2167
2145
  data.segment !== undefined ||
2146
+ data.processingState !== undefined ||
2168
2147
  data.pipelineStatus !== undefined ||
2169
2148
  data.enrichmentData !== undefined ||
2170
2149
  data.source !== undefined ||
@@ -2190,7 +2169,8 @@ export const CreateContactRequestSchema = z
2190
2169
  title: z.string().trim().min(1).max(255).optional(),
2191
2170
  source: z.string().trim().min(1).max(255).optional(),
2192
2171
  sourceId: z.string().trim().min(1).max(255).optional(),
2193
- batchId: z.string().trim().min(1).max(255).optional()
2172
+ batchId: z.string().trim().min(1).max(255).optional(),
2173
+ pipelineStatus: z.unknown().optional()
2194
2174
  })
2195
2175
  .strict()
2196
2176
  ```
@@ -2209,7 +2189,8 @@ export const UpdateContactRequestSchema = z
2209
2189
  headline: z.string().trim().min(1).max(5000).optional(),
2210
2190
  filterReason: z.string().trim().min(1).max(5000).optional(),
2211
2191
  openingLine: z.string().trim().min(1).max(5000).optional(),
2212
- pipelineStatus: z.record(z.string(), z.unknown()).optional(),
2192
+ processingState: ContactProcessingStateSchema.optional(),
2193
+ pipelineStatus: z.unknown().optional(),
2213
2194
  enrichmentData: z.record(z.string(), z.unknown()).optional(),
2214
2195
  status: AcqContactStatusSchema.optional()
2215
2196
  })
@@ -2225,6 +2206,7 @@ export const UpdateContactRequestSchema = z
2225
2206
  data.headline !== undefined ||
2226
2207
  data.filterReason !== undefined ||
2227
2208
  data.openingLine !== undefined ||
2209
+ data.processingState !== undefined ||
2228
2210
  data.pipelineStatus !== undefined ||
2229
2211
  data.enrichmentData !== undefined ||
2230
2212
  data.status !== undefined,
@@ -2251,7 +2233,8 @@ export const AcqCompanyResponseSchema = z.object({
2251
2233
  category: z.string().nullable(),
2252
2234
  categoryPain: z.string().nullable(),
2253
2235
  segment: z.string().nullable(),
2254
- pipelineStatus: z.record(z.string(), z.unknown()).nullable(),
2236
+ processingState: CompanyProcessingStateSchema.nullable(),
2237
+ pipelineStatus: z.unknown().nullable().optional(),
2255
2238
  enrichmentData: z.record(z.string(), z.unknown()).nullable(),
2256
2239
  source: z.string().nullable(),
2257
2240
  batchId: z.string().nullable(),
@@ -2317,7 +2300,8 @@ export const AcqContactResponseSchema = z.object({
2317
2300
  openingLine: z.string().nullable(),
2318
2301
  source: z.string().nullable(),
2319
2302
  sourceId: z.string().nullable(),
2320
- pipelineStatus: z.record(z.string(), z.unknown()).nullable(),
2303
+ processingState: ContactProcessingStateSchema.nullable(),
2304
+ pipelineStatus: z.unknown().nullable().optional(),
2321
2305
  enrichmentData: z.record(z.string(), z.unknown()).nullable(),
2322
2306
  attioPersonId: z.string().nullable(),
2323
2307
  batchId: z.string().nullable(),
@@ -2483,6 +2467,7 @@ export const AcqListCompanyResponseSchema = z.object({
2483
2467
 
2484
2468
  ```typescript
2485
2469
  export const AcqCompanySchemas = {
2470
+ CompanyProcessingState: CompanyProcessingStateSchema,
2486
2471
  CompanyIdParams: CompanyIdParamsSchema,
2487
2472
  ListCompaniesQuery: ListCompaniesQuerySchema,
2488
2473
  CreateCompanyRequest: CreateCompanyRequestSchema,
@@ -2497,6 +2482,7 @@ export const AcqCompanySchemas = {
2497
2482
 
2498
2483
  ```typescript
2499
2484
  export const AcqContactSchemas = {
2485
+ ContactProcessingState: ContactProcessingStateSchema,
2500
2486
  ContactIdParams: ContactIdParamsSchema,
2501
2487
  ListContactsQuery: ListContactsQuerySchema,
2502
2488
  CreateContactRequest: CreateContactRequestSchema,
@@ -2522,7 +2508,10 @@ export const AcqListSchemas = {
2522
2508
  BuildPlanSnapshot: BuildPlanSnapshotSchema,
2523
2509
  BuildPlanSnapshotStep: BuildPlanSnapshotStepSchema,
2524
2510
  AcqListMetadata: AcqListMetadataSchema,
2511
+ LeadGenStageKey: LeadGenStageKeySchema,
2512
+ LeadGenCapabilityKey: LeadGenCapabilityKeySchema,
2525
2513
  ProcessingStageStatus: ProcessingStageStatusSchema,
2514
+ ProcessingState: ProcessingStateSchema,
2526
2515
  ListStageCounts: ListStageCountsSchema,
2527
2516
  ListTelemetry: ListTelemetrySchema,
2528
2517
 
@@ -2815,6 +2804,8 @@ export interface CreateCompanyParams {
2815
2804
  source?: string
2816
2805
  batchId?: string
2817
2806
  verticalResearch?: string
2807
+ /** @deprecated Use processingState. Accepted as a no-op compatibility bridge for external tenants. */
2808
+ pipelineStatus?: unknown
2818
2809
  }
2819
2810
  ```
2820
2811
 
@@ -2832,7 +2823,9 @@ export interface UpdateCompanyParams {
2832
2823
  locationState?: string
2833
2824
  category?: string
2834
2825
  segment?: string
2835
- pipelineStatus?: Record<string, unknown>
2826
+ processingState?: ProcessingState
2827
+ /** @deprecated Use processingState. Accepted as a no-op compatibility bridge for external tenants. */
2828
+ pipelineStatus?: unknown
2836
2829
  enrichmentData?: Record<string, unknown>
2837
2830
  source?: string
2838
2831
  batchId?: string
@@ -2840,7 +2833,7 @@ export interface UpdateCompanyParams {
2840
2833
  verticalResearch?: string | null
2841
2834
  /** Track A: flat qualification score column (null until a scoring rubric is defined) */
2842
2835
  qualificationScore?: number | null
2843
- /** Track A: flat qualification signals jsonb — mirrors the former pipeline_status.qualification shape */
2836
+ /** Track A: flat qualification signals jsonb */
2844
2837
  qualificationSignals?: Record<string, unknown> | null
2845
2838
  /** Track A: key identifying the rubric used for qualification */
2846
2839
  qualificationRubricKey?: string | null
@@ -2863,13 +2856,15 @@ export interface CompanyFilters {
2863
2856
  website?: string
2864
2857
  segment?: string
2865
2858
  category?: string
2866
- pipelineStatus?: Record<string, unknown>
2867
- /** Exclude companies whose pipeline_status contains this value (PostgREST NOT contains) */
2868
- pipelineStatusNot?: Record<string, unknown>
2859
+ processingState?: ProcessingState
2860
+ /** @deprecated Use processingState. Accepted as a no-op compatibility bridge for external tenants. */
2861
+ pipelineStatus?: unknown
2862
+ /** Exclude companies whose processing state contains this value (PostgREST NOT contains) */
2863
+ processingStateNot?: ProcessingState
2869
2864
  batchId?: string
2870
2865
  status?: 'active' | 'invalid'
2871
2866
  includeAll?: boolean
2872
- excludeColumns?: Array<'enrichmentData' | 'pipelineStatus'>
2867
+ excludeColumns?: Array<'enrichmentData' | 'processingState'>
2873
2868
  limit?: number
2874
2869
  }
2875
2870
  ```
@@ -2888,6 +2883,8 @@ export interface CreateContactParams {
2888
2883
  source?: string
2889
2884
  sourceId?: string
2890
2885
  batchId?: string
2886
+ /** @deprecated Use processingState. Accepted as a no-op compatibility bridge for external tenants. */
2887
+ pipelineStatus?: unknown
2891
2888
  }
2892
2889
  ```
2893
2890
 
@@ -2904,7 +2901,9 @@ export interface UpdateContactParams {
2904
2901
  headline?: string
2905
2902
  filterReason?: string
2906
2903
  openingLine?: string
2907
- pipelineStatus?: Record<string, unknown>
2904
+ processingState?: ProcessingState
2905
+ /** @deprecated Use processingState. Accepted as a no-op compatibility bridge for external tenants. */
2906
+ pipelineStatus?: unknown
2908
2907
  enrichmentData?: Record<string, unknown>
2909
2908
  status?: 'active' | 'invalid'
2910
2909
  }
@@ -2923,7 +2922,9 @@ export interface ContactFilters {
2923
2922
  listId?: string // Filter to contacts in a specific list (via acq_list_members)
2924
2923
  search?: string
2925
2924
  openingLineIsNull?: boolean // Filter to contacts without personalization
2926
- pipelineStatus?: Record<string, unknown>
2925
+ processingState?: ProcessingState
2926
+ /** @deprecated Use processingState. Accepted as a no-op compatibility bridge for external tenants. */
2927
+ pipelineStatus?: unknown
2927
2928
  batchId?: string
2928
2929
  contactStatus?: 'active' | 'invalid' // Filter by contact status (soft-delete flag)
2929
2930
  }
@@ -3122,7 +3123,7 @@ export interface BulkImportCompanyEntry {
3122
3123
  category?: string
3123
3124
  source?: string
3124
3125
  enrichmentData?: Record<string, unknown>
3125
- pipelineStatus?: Record<string, unknown>
3126
+ processingState?: ProcessingState
3126
3127
  }
3127
3128
  ```
3128
3129
 
@@ -3303,6 +3304,14 @@ export type ListToolMap = {
3303
3304
  params: Omit<UpdateContactStageParams, 'organizationId'>
3304
3305
  result: void
3305
3306
  }
3307
+ listPendingCompanyIds: {
3308
+ params: Omit<ListPendingCompanyIdsParams, 'organizationId'>
3309
+ result: string[]
3310
+ }
3311
+ listPendingContactIds: {
3312
+ params: Omit<ListPendingContactIdsParams, 'organizationId'>
3313
+ result: string[]
3314
+ }
3306
3315
  }
3307
3316
  ```
3308
3317
 
@@ -3338,6 +3347,10 @@ export const OrgKnowledgeNodeSchema = z.object({
3338
3347
  * Each link emits a `governs` edge: knowledge-node -> target node.
3339
3348
  */
3340
3349
  links: z.array(KnowledgeLinkSchema).default([]),
3350
+ /** Operator skill or command bindings relevant to this node. */
3351
+ skills: z.array(KnowledgeSkillBindingSchema).optional(),
3352
+ /** Domain key used to derive fast graph->skill registries. */
3353
+ domain: KnowledgeDomainBindingSchema.optional(),
3341
3354
  /** Identifiers of the roles or members who own this knowledge node. */
3342
3355
  ownerIds: z.array(ModelIdSchema).default([]),
3343
3356
  /** ISO date string (YYYY-MM-DD or full ISO 8601) of last meaningful update. */