@elevasis/sdk 1.19.0 → 1.20.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/cli.cjs +1712 -72
- package/dist/index.d.ts +659 -5
- package/dist/index.js +565 -42
- package/dist/node/index.d.ts +1 -0
- package/dist/node/index.js +213 -2
- package/dist/test-utils/index.d.ts +459 -4
- package/dist/test-utils/index.js +509 -37
- package/dist/worker/index.js +365 -37
- package/package.json +4 -4
- package/reference/_navigation.md +2 -1
- package/reference/_reference-manifest.json +14 -0
- package/reference/claude-config/rules/agent-start-here.md +5 -5
- package/reference/claude-config/rules/deployment.md +4 -3
- package/reference/claude-config/rules/frontend.md +2 -2
- package/reference/claude-config/rules/operations.md +17 -13
- package/reference/claude-config/rules/organization-model.md +7 -5
- package/reference/claude-config/rules/organization-os.md +13 -11
- package/reference/claude-config/rules/ui.md +3 -3
- package/reference/claude-config/rules/vibe.md +4 -4
- package/reference/claude-config/skills/explore/SKILL.md +4 -4
- package/reference/claude-config/skills/knowledge/SKILL.md +8 -8
- package/reference/claude-config/skills/knowledge/operations/codify-level-a.md +7 -7
- package/reference/claude-config/skills/knowledge/operations/codify-level-b.md +13 -13
- package/reference/claude-config/skills/knowledge/operations/customers.md +1 -1
- package/reference/claude-config/skills/knowledge/operations/goals.md +1 -1
- package/reference/claude-config/skills/knowledge/operations/identity.md +1 -1
- package/reference/claude-config/skills/knowledge/operations/offerings.md +1 -1
- package/reference/claude-config/skills/knowledge/operations/roles.md +1 -1
- package/reference/claude-config/skills/knowledge/operations/techStack.md +19 -91
- package/reference/claude-config/skills/project/SKILL.md +73 -13
- package/reference/claude-config/skills/save/SKILL.md +5 -5
- package/reference/claude-config/skills/tutorial/technical.md +5 -6
- package/reference/claude-config/sync-notes/2026-05-07-sdk-changes-release-train.md +34 -0
- package/reference/claude-config/sync-notes/2026-05-08-resource-governance-scaffold-guidance.md +38 -0
- package/reference/claude-config/sync-notes/2026-05-09-clients-domain.md +32 -0
- package/reference/claude-config/sync-notes/2026-05-09-command-system.md +33 -0
- package/reference/claude-config/sync-notes/2026-05-09-resource-governance-and-misc.md +69 -0
- package/reference/examples/organization-model.ts +17 -5
- package/reference/framework/index.mdx +1 -1
- package/reference/framework/project-structure.mdx +10 -8
- package/reference/packages/core/src/business/README.md +2 -2
- package/reference/packages/core/src/organization-model/README.md +10 -3
- package/reference/resources/index.mdx +27 -17
- package/reference/scaffold/core/organization-model.mdx +33 -14
- package/reference/scaffold/operations/workflow-recipes.md +35 -29
- package/reference/scaffold/recipes/add-a-feature.md +18 -3
- package/reference/scaffold/recipes/add-a-resource.md +50 -10
- package/reference/scaffold/recipes/customize-crm-actions.md +12 -6
- package/reference/scaffold/recipes/customize-organization-model.md +18 -3
- package/reference/scaffold/recipes/extend-crm.md +17 -19
- package/reference/scaffold/recipes/extend-lead-gen.md +31 -31
- package/reference/scaffold/recipes/index.md +1 -1
- package/reference/scaffold/reference/contracts.md +501 -303
- package/reference/scaffold/reference/feature-registry.md +1 -1
- package/reference/scaffold/reference/glossary.md +8 -3
- package/reference/scaffold/ui/recipes.md +21 -6
|
@@ -1,102 +1,30 @@
|
|
|
1
|
-
# TechStack
|
|
1
|
+
# TechStack Context
|
|
2
2
|
|
|
3
|
-
Tech stack information is
|
|
4
|
-
extension field on individual `ResourceMapping` entries in the organization model. This keeps all
|
|
5
|
-
integration metadata co-located with the resource mapping that represents it, while adding fields
|
|
6
|
-
that agents need for cross-integration automation and system-of-record resolution.
|
|
3
|
+
Tech stack information is no longer modeled through `resourceMappings`. Resource identity and governance metadata live in OM Resources descriptors under `organizationModel.resources.entries`; external platform context belongs on the relevant integration descriptor or in project knowledge when the descriptor schema does not expose a dedicated field yet.
|
|
7
4
|
|
|
8
|
-
##
|
|
5
|
+
## Current Resource-Governance Contract
|
|
9
6
|
|
|
10
|
-
|
|
7
|
+
- Resource IDs are authored once in `core/config/organization-model.ts`.
|
|
8
|
+
- Runtime workflows, agents, and integrations derive `resourceId` / `type` from OM descriptors during deployment assembly.
|
|
9
|
+
- `DeploymentSpec` remains the runtime/deploy bundle, not an independent identity catalog.
|
|
10
|
+
- `pnpm -C operations check` validates descriptor/code alignment before deploy.
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
TechStackEntrySchema = z.object({
|
|
14
|
-
platform: z.string().trim().min(1).max(200),
|
|
15
|
-
purpose: z.string().trim().min(1).max(500),
|
|
16
|
-
credentialStatus: z.enum(['configured', 'pending', 'expired', 'missing']),
|
|
17
|
-
isSystemOfRecord: z.boolean().default(false)
|
|
18
|
-
})
|
|
19
|
-
```
|
|
12
|
+
## Where To Look
|
|
20
13
|
|
|
21
|
-
`
|
|
22
|
-
|
|
14
|
+
- `core/config/organization-model.ts` -- Systems and Resources descriptors.
|
|
15
|
+
- `operations/src/index.ts` -- deployment assembly that binds executable behavior to descriptors.
|
|
16
|
+
- `pnpm elevasis-sdk project:list --pretty` -- live deployed resource surface.
|
|
17
|
+
- Project knowledge nodes -- narrative details such as credential owner, setup notes, and system-of-record rationale when they do not fit the descriptor shape.
|
|
23
18
|
|
|
24
|
-
##
|
|
19
|
+
## Write Path
|
|
25
20
|
|
|
26
|
-
|
|
27
|
-
| ------------------ | ------- | ---------------------------------------------------------------------- |
|
|
28
|
-
| `platform` | string | Name of the external platform; e.g. `"HubSpot"`, `"Stripe"`, `"Apify"` |
|
|
29
|
-
| `purpose` | string | Free-form description of what this integration is used for |
|
|
30
|
-
| `credentialStatus` | enum | `configured`, `pending`, `expired`, or `missing` |
|
|
31
|
-
| `isSystemOfRecord` | boolean | `true` if this integration is the authoritative source for its domain |
|
|
21
|
+
When the user wants to document or change integration ownership, credential status, or system-of-record context:
|
|
32
22
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
- `isSystemOfRecord` defaults to `false`; only one integration per domain should be `true`,
|
|
38
|
-
though the schema does not enforce uniqueness — agents should surface conflicts
|
|
39
|
-
- `techStack` applies only to resource mappings with `resourceType: 'integration'` or
|
|
40
|
-
`'external'`; adding it to other resource types is valid at schema level but semantically
|
|
41
|
-
incorrect
|
|
42
|
-
|
|
43
|
-
`credentialStatus` semantics:
|
|
44
|
-
|
|
45
|
-
- `configured` -- credential present and active
|
|
46
|
-
- `pending` -- integration planned but not yet set up
|
|
47
|
-
- `expired` -- credential previously configured but has lapsed
|
|
48
|
-
- `missing` -- expected to be configured but not present
|
|
49
|
-
|
|
50
|
-
## Examples
|
|
51
|
-
|
|
52
|
-
```typescript
|
|
53
|
-
// Inside resourceMappings array in defineOrganizationModel({...})
|
|
54
|
-
resourceMappings: [
|
|
55
|
-
{
|
|
56
|
-
id: "rm-hubspot",
|
|
57
|
-
label: "HubSpot CRM Integration",
|
|
58
|
-
resourceType: "integration",
|
|
59
|
-
techStack: {
|
|
60
|
-
platform: "HubSpot",
|
|
61
|
-
purpose: "CRM for contacts, companies, and deal pipeline",
|
|
62
|
-
credentialStatus: "configured",
|
|
63
|
-
isSystemOfRecord: true
|
|
64
|
-
}
|
|
65
|
-
},
|
|
66
|
-
{
|
|
67
|
-
id: "rm-apify",
|
|
68
|
-
label: "Apify Web Scraping",
|
|
69
|
-
resourceType: "integration",
|
|
70
|
-
techStack: {
|
|
71
|
-
platform: "Apify",
|
|
72
|
-
purpose: "Web scraping and data extraction for lead enrichment",
|
|
73
|
-
credentialStatus: "pending",
|
|
74
|
-
isSystemOfRecord: false
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
]
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
## Where it lives in the adapter
|
|
81
|
-
|
|
82
|
-
`foundations/config/organization-model.ts` inside the `resourceMappings` array of
|
|
83
|
-
`defineOrganizationModel({...})`. The `techStack` field is set on the matching `ResourceMapping`
|
|
84
|
-
object by `id`.
|
|
85
|
-
|
|
86
|
-
To read current tech stack entries: open the adapter file and inspect the `resourceMappings`
|
|
87
|
-
array, filtering to entries with a `techStack` field, or use
|
|
88
|
-
`pnpm exec elevasis-sdk knowledge:cat techStack` (external project).
|
|
89
|
-
|
|
90
|
-
## Write path
|
|
91
|
-
|
|
92
|
-
To add or update `techStack` metadata on a resource mapping, the `/knowledge` skill runs the
|
|
93
|
-
codify ceremony (`operations/codify-level-a.md`): snapshot → propose → confirm → write →
|
|
94
|
-
typecheck → Zod parse → rollback on failure. Only the targeted `resourceMappings` entry (matched
|
|
95
|
-
by `id`) is modified; all other entries are left unchanged. If the user only wants to update
|
|
96
|
-
`credentialStatus`, a targeted edit to that single field is preferred.
|
|
23
|
+
1. Inspect `core/config/organization-model.ts` for the relevant integration Resource descriptor.
|
|
24
|
+
2. If the descriptor identity, System membership, owner role, or status is wrong, update the descriptor through the `/knowledge` ceremony where possible.
|
|
25
|
+
3. If the requested detail is operational narrative rather than descriptor schema, capture it in a knowledge node or project documentation instead of recreating `resourceMappings`.
|
|
26
|
+
4. Run `pnpm -C operations check` after descriptor or deployment assembly changes.
|
|
97
27
|
|
|
98
28
|
---
|
|
99
29
|
|
|
100
|
-
**Read via `/knowledge`**
|
|
101
|
-
"is HubSpot our system of record for contacts?" route to this domain via the skill's intent
|
|
102
|
-
classifier.
|
|
30
|
+
**Read via `/knowledge`** -- natural-language queries like "what integrations are configured?" or "is HubSpot our system of record for contacts?" route here for inspection and recommendation.
|
|
@@ -41,11 +41,11 @@ allowed-tools: Bash, Read, Write, Edit, Glob, Grep
|
|
|
41
41
|
|
|
42
42
|
This skill is the landing point for three of the seven vibe intent types. Agents arriving from the ambient layer should behave identically to a direct invocation — vibe is a classifier, not a different code path.
|
|
43
43
|
|
|
44
|
-
| Vibe intent
|
|
45
|
-
|
|
46
|
-
| **Capture**
|
|
47
|
-
| **Transition** | "done", "stuck", "blocked", "finished"
|
|
48
|
-
| **Navigate**
|
|
44
|
+
| Vibe intent | What vibe detected | What to do here |
|
|
45
|
+
| -------------- | ----------------------------------------- | --------------------------------------------------------------------------------------------------------- |
|
|
46
|
+
| **Capture** | "add a task", "remember to", "track this" | Draft the task/note, confirm with user, then `project:task:create` or `project:note:create` |
|
|
47
|
+
| **Transition** | "done", "stuck", "blocked", "finished" | Resolve current task from session context, confirm status, then `project:task:update --status <new>` |
|
|
48
|
+
| **Navigate** | "focus on", "switch to", "back to" | Resolve target via `project:resolve <query>` or `project:work <query>`, update scope, narrate new context |
|
|
49
49
|
|
|
50
50
|
**The full continuity loop** — how work flows across sessions:
|
|
51
51
|
|
|
@@ -316,7 +316,8 @@ To clear a checklist: `--checklist '[]'`.
|
|
|
316
316
|
- `prj_notes.task_id` → `prj_tasks.id` (SET NULL)
|
|
317
317
|
- `prj_notes.milestone_id` → `prj_milestones.id` (SET NULL)
|
|
318
318
|
- `prj_projects.deal_id` → `acq_deals.id` (SET NULL)
|
|
319
|
-
- `prj_projects.
|
|
319
|
+
- `prj_projects.client_id` → `clients.id` (SET NULL) — clients-hub link; set via `--client`
|
|
320
|
+
- `prj_projects.client_company_id` → `acq_companies.id` (SET NULL) — legacy direct-company link; set via `--client-company-id`
|
|
320
321
|
|
|
321
322
|
---
|
|
322
323
|
|
|
@@ -328,6 +329,9 @@ For a plain project table without resume context or next-action suggestions (use
|
|
|
328
329
|
|
|
329
330
|
```bash
|
|
330
331
|
pnpm elevasis-sdk project:list --kind client_engagement --pretty
|
|
332
|
+
|
|
333
|
+
# Filter by client (accepts the client's name or UUID)
|
|
334
|
+
pnpm elevasis-sdk project:list --client "Acme" --pretty
|
|
331
335
|
```
|
|
332
336
|
|
|
333
337
|
Present as:
|
|
@@ -540,11 +544,15 @@ Create everything in sequence using the CLI:
|
|
|
540
544
|
|
|
541
545
|
```bash
|
|
542
546
|
# 1. Create project
|
|
547
|
+
# If the user mentioned a client by name, resolve it first:
|
|
548
|
+
# pnpm elevasis-sdk client:resolve "<client name>"
|
|
549
|
+
# Then pass the name (or UUID) via --client
|
|
543
550
|
pnpm elevasis-sdk project:create \
|
|
544
551
|
--name "<name>" \
|
|
545
552
|
--kind client_engagement \
|
|
546
553
|
--status active \
|
|
547
|
-
--description "<desc>"
|
|
554
|
+
--description "<desc>" \
|
|
555
|
+
--client "<client-name-or-uuid>"
|
|
548
556
|
|
|
549
557
|
# 2. Create milestones
|
|
550
558
|
pnpm elevasis-sdk project:milestone:create \
|
|
@@ -563,12 +571,16 @@ pnpm elevasis-sdk project:note:create \
|
|
|
563
571
|
If `--company` or `--deal` linking was confirmed, use `project:update` after creation:
|
|
564
572
|
|
|
565
573
|
```bash
|
|
566
|
-
pnpm elevasis-sdk project:update <project-id> --
|
|
574
|
+
pnpm elevasis-sdk project:update <project-id> --client "<client-name-or-uuid>"
|
|
575
|
+
```
|
|
576
|
+
|
|
577
|
+
To remove a client link later:
|
|
578
|
+
|
|
579
|
+
```bash
|
|
580
|
+
pnpm elevasis-sdk project:update <project-id> --clear-client
|
|
567
581
|
```
|
|
568
582
|
|
|
569
|
-
|
|
570
|
-
doesn't expose `--client-company-id` or `--deal-id` directly, document the project ID and
|
|
571
|
-
advise the user to link via the Command Center UI.)
|
|
583
|
+
Do NOT pass `--client ""` to clear — an empty string is rejected as ambiguous. Use `--clear-client` instead.
|
|
572
584
|
|
|
573
585
|
**Step 7: Summary**
|
|
574
586
|
|
|
@@ -618,7 +630,7 @@ pnpm elevasis-sdk project:create \
|
|
|
618
630
|
|
|
619
631
|
### `update <client> [options]` — Update Project
|
|
620
632
|
|
|
621
|
-
**Options:** `--status`, `--name`, `--description
|
|
633
|
+
**Options:** `--status`, `--name`, `--description`, `--client <id-or-name>`, `--clear-client`, `--client-company-id <uuid>`
|
|
622
634
|
|
|
623
635
|
First resolve the client (see Client Inference below), then:
|
|
624
636
|
|
|
@@ -1005,6 +1017,54 @@ source .env && psql "$SUPABASE_READONLY_URL" -c \
|
|
|
1005
1017
|
|
|
1006
1018
|
---
|
|
1007
1019
|
|
|
1020
|
+
## Client Linking
|
|
1021
|
+
|
|
1022
|
+
Projects can be linked to a client in the clients hub. When a user mentions a client by name, resolve it to an ID and use `--client` to wire the project.
|
|
1023
|
+
|
|
1024
|
+
### Two linking flags, two different columns
|
|
1025
|
+
|
|
1026
|
+
- `--client <name-or-uuid>` — links to a clients-hub record (`prj_projects.client_id`). Use this for new client linkage. Accepts a name (the CLI fuzzy-resolves it) or a UUID.
|
|
1027
|
+
- `--client-company-id <uuid>` — legacy direct-company linkage (`prj_projects.client_company_id`); kept for back-compat. UUID only.
|
|
1028
|
+
|
|
1029
|
+
These are independent. Do not use `--client-company-id` when you mean `--client`.
|
|
1030
|
+
|
|
1031
|
+
### When the user mentions a client by name
|
|
1032
|
+
|
|
1033
|
+
1. Resolve the client name to a UUID first (optional but gives an explicit confirmation step):
|
|
1034
|
+
```bash
|
|
1035
|
+
pnpm elevasis-sdk client:resolve "Acme"
|
|
1036
|
+
```
|
|
1037
|
+
2. Pass the name or UUID to `--client` — the CLI fuzzy-resolves names automatically:
|
|
1038
|
+
```bash
|
|
1039
|
+
pnpm elevasis-sdk project:create --name "Acme Automation" --kind client_engagement --client "Acme"
|
|
1040
|
+
pnpm elevasis-sdk project:update <project-id> --client "Acme"
|
|
1041
|
+
```
|
|
1042
|
+
3. If the client name matches multiple records, the CLI returns an error listing candidates. In that case, run `client:resolve "Acme"` to disambiguate, then pass the UUID directly.
|
|
1043
|
+
|
|
1044
|
+
### Filtering projects by client
|
|
1045
|
+
|
|
1046
|
+
```bash
|
|
1047
|
+
pnpm elevasis-sdk project:list --client "Acme" --pretty
|
|
1048
|
+
```
|
|
1049
|
+
|
|
1050
|
+
### Removing a client link
|
|
1051
|
+
|
|
1052
|
+
```bash
|
|
1053
|
+
pnpm elevasis-sdk project:update <project-id> --clear-client
|
|
1054
|
+
```
|
|
1055
|
+
|
|
1056
|
+
`--client` and `--clear-client` are mutually exclusive on the same command call.
|
|
1057
|
+
|
|
1058
|
+
### Soft recommendation for client engagement projects
|
|
1059
|
+
|
|
1060
|
+
When the user creates a `client_engagement` project without mentioning a client, gently note that linking a client is recommended so the project appears in client lineage views. Do not block creation — the flag is optional.
|
|
1061
|
+
|
|
1062
|
+
### Client command reference
|
|
1063
|
+
|
|
1064
|
+
The full `client:*` surface (list, get, status, resolve) is available via `elevasis-sdk client:*`. The `client:resolve` command mirrors `project:resolve` in shape and is the canonical tool for name-to-ID translation.
|
|
1065
|
+
|
|
1066
|
+
---
|
|
1067
|
+
|
|
1008
1068
|
## Safety Rules
|
|
1009
1069
|
|
|
1010
1070
|
1. **Always confirm deletes** — show what will be cascade-deleted before executing
|
|
@@ -1025,4 +1085,4 @@ source .env && psql "$SUPABASE_READONLY_URL" -c \
|
|
|
1025
1085
|
|
|
1026
1086
|
---
|
|
1027
1087
|
|
|
1028
|
-
**Last Updated:** 2026-
|
|
1088
|
+
**Last Updated:** 2026-05-08
|
|
@@ -45,18 +45,18 @@ Review the current conversation to identify:
|
|
|
45
45
|
3. **Stale docs** -- information in existing docs that is now outdated
|
|
46
46
|
4. **Signal events** -- blocker hit, status update worth recording, issue uncovered, call outcome
|
|
47
47
|
5. **OS contract paths touched** -- scan files read/written/edited for any of these signals:
|
|
48
|
-
- `
|
|
49
|
-
- `
|
|
48
|
+
- `core/config/organization-model.ts` -> Foundations layer, Organization Model
|
|
49
|
+
- `core/types/index.ts` -> Foundations layer, Workflow Contracts
|
|
50
50
|
- `ui/src/routes/__root.tsx` -> UI Shell Runtime composition
|
|
51
51
|
- `ui/src/features/**/manifest.ts` or any file defining a `FeatureModule` -> Features layer
|
|
52
|
-
- `operations/src/index.ts` or `operations/elevasis.config.ts` ->
|
|
52
|
+
- `operations/src/index.ts` or `operations/elevasis.config.ts` -> core/Deployment (DeploymentSpec)
|
|
53
53
|
- Any file inside `ui/src/features/<feature>/` combined with manifest, nav, or sidebar changes -> Features + Toolkit layers
|
|
54
54
|
|
|
55
55
|
Record which OS layers were touched: `foundations`, `features`, `shell-runtime`, `toolkit`, `deployment`. If none matched, OS awareness stays dormant for the rest of this run.
|
|
56
56
|
|
|
57
57
|
### Step 3: Update Knowledge Docs
|
|
58
58
|
|
|
59
|
-
Scan for unindexed or stale knowledge docs and draft creates / updates / moves. This template does not have a `docs/` tree — look for any local knowledge files (`.claude/rules/`, `operations/src/README.md`, `
|
|
59
|
+
Scan for unindexed or stale knowledge docs and draft creates / updates / moves. This template does not have a `docs/` tree — look for any local knowledge files (`.claude/rules/`, `operations/src/README.md`, `core/`, or project-specific docs the user has created). All edits are on knowledge/architecture/feature docs -- NOT on task resume state (that flows to the DB in Step 4).
|
|
60
60
|
|
|
61
61
|
Determine what needs to happen:
|
|
62
62
|
|
|
@@ -115,7 +115,7 @@ pnpm elevasis-sdk project:task:save <task-uuid> \
|
|
|
115
115
|
--current-state "<concise prose summary of where we are>" \
|
|
116
116
|
--next-steps "<concise prose of the next concrete action>" \
|
|
117
117
|
--files-modified '["path/one.ts","path/two.tsx"]' \
|
|
118
|
-
--key-docs '["operations/
|
|
118
|
+
--key-docs '["operations/src/foo/index.ts","core/config/organization-model.ts"]' \
|
|
119
119
|
--tools '["project:task:save","project:note:create"]'
|
|
120
120
|
```
|
|
121
121
|
|
|
@@ -686,7 +686,7 @@ Or target a specific domain:
|
|
|
686
686
|
- `/knowledge offerings` -- products and services with pricing model and segment references
|
|
687
687
|
- `/knowledge roles` -- role chart with responsibilities and reporting lines
|
|
688
688
|
- `/knowledge goals` -- organizational goals with period and measurable outcomes
|
|
689
|
-
- `/knowledge techStack` -- external SaaS integration
|
|
689
|
+
- `/knowledge techStack` -- external SaaS and integration context tied to OM Resources descriptors or knowledge nodes
|
|
690
690
|
|
|
691
691
|
**Demo.** Ask the user to run `/knowledge identity`. Walk through the ceremony together -- read
|
|
692
692
|
the current state, propose an edit, confirm, watch it validate.
|
|
@@ -757,7 +757,7 @@ how to add project-specific metadata fields to base entities.
|
|
|
757
757
|
**Estimated time:** 20 min
|
|
758
758
|
|
|
759
759
|
**Files referenced:** `core/types/entities.ts`, `core/config/organization-model.ts`
|
|
760
|
-
(for the
|
|
760
|
+
(for the OM Resources descriptor context)
|
|
761
761
|
|
|
762
762
|
**Flow:**
|
|
763
763
|
|
|
@@ -953,10 +953,9 @@ await email.send({
|
|
|
953
953
|
})
|
|
954
954
|
```
|
|
955
955
|
|
|
956
|
-
**Real adapter integration.** Read `core/config/organization-model.ts` and find the
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
Use the credential name from there as the constructor argument:
|
|
956
|
+
**Real adapter integration.** Read `core/config/organization-model.ts` and find the relevant
|
|
957
|
+
OM Resources descriptor or project knowledge node for the integration. Use the documented
|
|
958
|
+
credential name as the constructor argument:
|
|
960
959
|
|
|
961
960
|
```typescript
|
|
962
961
|
import { createAttioAdapter } from '@elevasis/sdk/worker'
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# 2026-05-07 -- SDK Changes Release Train
|
|
2
|
+
|
|
3
|
+
## Why this note exists
|
|
4
|
+
|
|
5
|
+
This train coordinates the DTC list-builder overhaul (Apollo/Apify/ClickUp credential plumbing, live build-status panel, useInFlightExecutions hook) and the right-panel reusability refactor (theme tokens, compact chart sizing, plain chat message variant) into one published `@elevasis/core` + `@elevasis/ui` release plus a coordinated SDK resource deploy and external sync.
|
|
6
|
+
|
|
7
|
+
## Applies to
|
|
8
|
+
|
|
9
|
+
- Template-derived projects consuming `@elevasis/core` or `@elevasis/ui`.
|
|
10
|
+
- Projects using the lead-gen list-builder UI (selectors, records views, live status panel) or the shared chat/chart primitives.
|
|
11
|
+
- Projects that mount Command Center-style right-panel composition (only the shared `@elevasis/ui` surfaces moved; the panel host itself stays app-local to Command Center).
|
|
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` patch bump (Apify/Apollo/ClickUp adapter updates + Apollo `credentialRequirements` on prospecting Steps 1 and 5).
|
|
18
|
+
- `ui/package.json`: `@elevasis/ui` minor bump (additive: `useInFlightExecutions` hook, `useListProgress` accepts `{ enabled, refetchInterval }`, `--right-panel-background` theme token, compact `CombinedTrendChart` sizing, plain `ChatInterface` message variant, card-based `MessageBubble` styling).
|
|
19
|
+
3. If a project pins integration credentials by provider name, verify generic API-key credentials named like `apify`, `apollo`, or `clickup` continue to verify after the adapter alias normalization.
|
|
20
|
+
4. If a project consumed the shared chat/chart primitives, review compact-variant render output against existing layouts.
|
|
21
|
+
|
|
22
|
+
## Verification
|
|
23
|
+
|
|
24
|
+
- `pnpm -C ui check-types`
|
|
25
|
+
- `pnpm -C ui build`
|
|
26
|
+
- `pnpm -C ui test`
|
|
27
|
+
- `pnpm -C operations check`
|
|
28
|
+
- `pnpm -C operations check-types`
|
|
29
|
+
|
|
30
|
+
## Not handled by /git-sync
|
|
31
|
+
|
|
32
|
+
- Project-authored right-panel registries remain project-owned code; the host generalization is app-local to Command Center and does not propagate to template projects.
|
|
33
|
+
- ClickUp List ID destination configuration is per-project and is not synced.
|
|
34
|
+
- The Apollo plan-gated `403 API_INACCESSIBLE` for `mixed_companies/search` is tracked separately in the Elevasis monorepo and is not a tenant migration concern.
|
package/reference/claude-config/sync-notes/2026-05-08-resource-governance-scaffold-guidance.md
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# Resource Governance Scaffold Guidance
|
|
2
|
+
|
|
3
|
+
## Why this note exists
|
|
4
|
+
|
|
5
|
+
The template guidance now treats OM Resources descriptors as the source of truth for resource identity and governance metadata. Operations code should import descriptors from `core/config/organization-model.ts`, derive runtime `resourceId` / `type` from them, and use `DeploymentSpec` only as the deployment assembly artifact.
|
|
6
|
+
|
|
7
|
+
This also removes stale references to legacy `resourceMappings`, `organization-model.examples.ts`, `foundations/`, and `operations/resources/**` paths in the template agent guidance.
|
|
8
|
+
|
|
9
|
+
## Applies to
|
|
10
|
+
|
|
11
|
+
Template-derived projects that author workflows, agents, integrations, or project-local agent guidance from the SDK scaffold reference.
|
|
12
|
+
|
|
13
|
+
## Required actions
|
|
14
|
+
|
|
15
|
+
- When adding a workflow, agent, or integration, author the descriptor first in `core/config/organization-model.ts` under `resources.entries`.
|
|
16
|
+
- Update operations code to derive deployed runtime IDs from descriptors rather than duplicating raw string IDs.
|
|
17
|
+
- Treat existing `resourceMappings` mentions in project-local notes as stale migration history.
|
|
18
|
+
- Keep runtime invocation calls honest: `/execute`, scheduler targets, and nested execution still call deployed resource IDs.
|
|
19
|
+
|
|
20
|
+
## Verification
|
|
21
|
+
|
|
22
|
+
Run these after reconciling local project guidance or resource authoring:
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
pnpm -C core test
|
|
26
|
+
pnpm -C operations check
|
|
27
|
+
pnpm -C operations check-types
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
For UI surfaces that execute resources, also run:
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
pnpm -C ui check-types
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
## Not handled by /git-sync
|
|
37
|
+
|
|
38
|
+
`/git-sync` pulls the updated guidance and template-owned files, but it does not rewrite project-owned workflow definitions or decide System ownership for real tenant resources. Maintainers must review existing project resources and migrate any duplicated raw IDs to descriptor-backed authoring intentionally.
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# Clients Domain Release Train
|
|
2
|
+
|
|
3
|
+
## Why this note exists
|
|
4
|
+
|
|
5
|
+
The clients domain release train adds client-management surfaces across the shared platform packages and updates template-facing project guidance. Template-derived projects need the new package baselines and guidance before they rely on the clients CLI, published clients UI feature exports, or project skill client-linkage instructions.
|
|
6
|
+
|
|
7
|
+
## Applies to
|
|
8
|
+
|
|
9
|
+
Template-derived projects that consume `@elevasis/core`, `@elevasis/ui`, or `@elevasis/sdk`, especially projects that expose client management in UI shells or use the SDK CLI for project/client linkage.
|
|
10
|
+
|
|
11
|
+
## Required actions
|
|
12
|
+
|
|
13
|
+
- Pull the updated template dependency baselines for `core/package.json`, `ui/package.json`, and `operations/package.json` after the release stages publish new package versions.
|
|
14
|
+
- Review project-local usage of project/client CLI flags and prefer `--client` / `--clear-client` for client linkage; keep `--client-company-id` only for the legacy company field.
|
|
15
|
+
- If the project maintains local Claude skill guidance, reconcile the project skill client-linkage wording with the updated template baseline.
|
|
16
|
+
- Smoke the clients UI route only after the project has the updated `@elevasis/ui` baseline.
|
|
17
|
+
|
|
18
|
+
## Verification
|
|
19
|
+
|
|
20
|
+
Run the package-specific checks after sync:
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
pnpm -C core check-types
|
|
24
|
+
pnpm -C operations check-types
|
|
25
|
+
pnpm -C ui check-types
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
For projects adopting the clients UI immediately, also open the clients list and detail routes and verify the route renders with the current organization selected.
|
|
29
|
+
|
|
30
|
+
## Not handled by /git-sync
|
|
31
|
+
|
|
32
|
+
`/git-sync` can propagate template baselines and guidance, but it does not publish packages, deploy the SDK resources bundle, decide project-specific client data migration policy, or validate tenant-specific WorkOS/Supabase data availability.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# 2026-05-09 -- Command System SDK Release Train
|
|
2
|
+
|
|
3
|
+
## Why this note exists
|
|
4
|
+
|
|
5
|
+
This train adds SDK CLI catalog, acquisition CLI read, API-key external route, and deterministic knowledge-routing changes to the existing SDK release queue. It publishes updated `@elevasis/core` and `@elevasis/sdk` baselines, then syncs the template dependency pins to derived projects.
|
|
6
|
+
|
|
7
|
+
## Applies to
|
|
8
|
+
|
|
9
|
+
- Template-derived projects consuming `@elevasis/core` or `@elevasis/sdk`.
|
|
10
|
+
- Operators using `elevasis-sdk cli`, `acquisition:list:*`, `acquisition:deal:*`, `client:*`, or generated `/knowledge` routing guidance.
|
|
11
|
+
- Projects that rely on API-key-gated SDK CLI access to platform external routes.
|
|
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
|
+
- `operations/package.json`: `@elevasis/core` and `@elevasis/sdk`
|
|
19
|
+
3. Verify local `operations` commands still have the expected platform key environment variables before using SDK CLI API calls.
|
|
20
|
+
4. Review local operator guidance if the project documents SDK CLI command discovery or acquisition/client/deal command usage.
|
|
21
|
+
|
|
22
|
+
## Verification
|
|
23
|
+
|
|
24
|
+
- `pnpm -C operations check`
|
|
25
|
+
- `pnpm -C operations check-types`
|
|
26
|
+
- `pnpm -C operations test`
|
|
27
|
+
- `pnpm -C core test`
|
|
28
|
+
|
|
29
|
+
## Not handled by /git-sync
|
|
30
|
+
|
|
31
|
+
- Platform API route deployment remains an Elevasis monorepo/API deployment concern.
|
|
32
|
+
- Tenant-specific platform keys and API base URLs remain project-owned secrets and environment configuration.
|
|
33
|
+
- Project-authored knowledge nodes and routing guidance remain project-owned content.
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
# Resource Governance Runtime + CRM Detail Pages + Service-Context Rename
|
|
2
|
+
|
|
3
|
+
## Why this note exists
|
|
4
|
+
|
|
5
|
+
The 2026-05-09 release train extends the clients-domain ship with three additional bodies of work that affect template-derived projects:
|
|
6
|
+
|
|
7
|
+
1. **Resource Governance runtime cutover.** The shared resource-governance validator now defaults to **strict** mode. The OM Resources/Systems descriptor catalog is the source of truth for resource identity. Operations bundles must bind workflows, agents, and integrations to descriptors via `defineResource(s)` + descriptor binding helpers; raw `resourceId` literals in `DeploymentSpec` no longer pass strict validation.
|
|
8
|
+
2. **CRM detail-page surface expansion.** `@elevasis/ui` now publishes `ContactDetailPage` (new) and `CompanyDetailPage` (now exported from `sdk-barrel`) under `@elevasis/ui/features/crm`. The lead-gen flow no longer renders detail modals on row click — both pages are reached via TanStack Router routes (`/crm/contacts/$contactId`, `/crm/companies/$companyId`). The legacy `CompanyDetailModal` and `ContactDetailModal` exports were removed from `@elevasis/ui/features/lead-gen/shared`.
|
|
9
|
+
3. **`ElevasisServiceContext` field rename.** `useElevasisServices().organizationId` is renamed to `useElevasisServices().workOSOrganizationId` to make the WorkOS-vs-Supabase distinction loud at call sites. The old `organizationId` field is preserved as a back-compat alias on both `ElevasisServiceContextValue` and `ElevasisServiceProviderProps` for one release cycle, so existing template consumers continue to work without immediate migration.
|
|
10
|
+
|
|
11
|
+
Companion items already covered elsewhere:
|
|
12
|
+
|
|
13
|
+
- Scaffold/agent guidance for descriptor-first authoring → see `2026-05-08-resource-governance-scaffold-guidance.md`.
|
|
14
|
+
- Clients domain (new sidebar pillar, write operations, project/client linkage) → see `2026-05-09-clients-domain.md`.
|
|
15
|
+
|
|
16
|
+
## Applies to
|
|
17
|
+
|
|
18
|
+
Any template-derived project (e.g. `nirvana-marketing`, `ZentaraHQ`) that:
|
|
19
|
+
|
|
20
|
+
- Deploys workflows, agents, or integrations through `operations/src/index.ts` (resource-governance validator).
|
|
21
|
+
- Renders contacts/companies in any feature surface, including custom CRM views (CRM detail pages + modal removal).
|
|
22
|
+
- Uses `useElevasisServices()` from `@elevasis/ui` in custom hooks, components, or test fixtures (service-context rename).
|
|
23
|
+
|
|
24
|
+
## Required actions
|
|
25
|
+
|
|
26
|
+
### 1. Resource Governance — descriptor-backed deployment
|
|
27
|
+
|
|
28
|
+
- Confirm `core/config/organization-model.ts` declares your tenant's resources at `organizationModel.resources.entries` (single-author resource IDs).
|
|
29
|
+
- In `operations/src/index.ts`, bind your workflow/agent/integration definitions to those descriptors via the helpers exported from `@elevasis/sdk` instead of authoring raw `resourceId` strings inline in `DeploymentSpec`.
|
|
30
|
+
- Run `pnpm -C operations check`. The default validator mode is now strict; missing descriptors, raw-ID authoring, runtime/OM type mismatches, and missing Systems will fail the build. Set `ELEVASIS_RESOURCE_VALIDATOR=warn-only` only as a temporary emergency escape hatch — do not let normal CI silently depend on it.
|
|
31
|
+
- New SDK CLI commands are available: `elevasis-sdk agent:list`, `elevasis-sdk agent:get \<id>`, `elevasis-sdk session:list`, `elevasis-sdk session:get \<id>`, `elevasis-sdk session:end \<id>`. Existing `resources` / `describe` / `exec` / `executions` / `execution` are unchanged.
|
|
32
|
+
|
|
33
|
+
### 2. CRM detail pages
|
|
34
|
+
|
|
35
|
+
- If your project imports `CompanyDetailModal` or `ContactDetailModal` from `@elevasis/ui/features/lead-gen/shared`, those exports were removed. Replace modal-on-row-click patterns with `useNavigate` to `/crm/contacts/$contactId` or `/crm/companies/$companyId`.
|
|
36
|
+
- If you need detail-page UI in custom routes, import `ContactDetailPage` and `CompanyDetailPage` from `@elevasis/ui/features/crm`. Both are part of the published `sdk-barrel` and accept `contactId` / `companyId` props.
|
|
37
|
+
- The `extend-lead-gen.md` recipe in `node_modules/@elevasis/sdk/reference/scaffold/recipes/` was updated — it no longer documents the modal helpers.
|
|
38
|
+
|
|
39
|
+
### 3. `workOSOrganizationId` field rename
|
|
40
|
+
|
|
41
|
+
- New idiomatic destructure: `const { apiRequest, workOSOrganizationId, isReady } = useElevasisServices()`.
|
|
42
|
+
- The old `organizationId` field still resolves correctly through the back-compat alias, so existing template code compiles and runs without changes. New code in this project should use `workOSOrganizationId`.
|
|
43
|
+
- If your project uses `<ElevasisServiceProvider organizationId={...}>`, that prop also accepts both names. Provider's resolver is `workOSOrganizationId ?? organizationId ?? null` — passing both names is supported but unnecessary.
|
|
44
|
+
- For test fixtures that mock `useElevasisServices` via `vi.mock`, return `workOSOrganizationId` rather than `organizationId` when authoring NEW mocks; existing mocks will continue to work via the alias but should be migrated opportunistically. The runtime trap is: `vi.mock(...)` is untyped — TypeScript will not catch a mock that returns the deprecated key, but the resolver bypass means downstream `services.workOSOrganizationId` reads `undefined`.
|
|
45
|
+
|
|
46
|
+
## Verification
|
|
47
|
+
|
|
48
|
+
After reconciling local project guidance and writing any descriptor / service-context updates:
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
pnpm -C operations check
|
|
52
|
+
pnpm -C operations check-types
|
|
53
|
+
pnpm -C ui check-types
|
|
54
|
+
pnpm -C ui test
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
If your project deploys to production and you author runtime resources directly:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
pnpm -C operations exec elevasis-sdk deploy
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Expect strict-mode validator output. Investigate any "OM resource missing for code resource" or "raw resourceId authoring detected" errors as descriptor-binding work, not as test bypass.
|
|
64
|
+
|
|
65
|
+
## Not handled by /git-sync
|
|
66
|
+
|
|
67
|
+
- `/git-sync` pulls the new `@elevasis/sdk`, `@elevasis/ui`, and `@elevasis/core` versions and template-owned files, but it does **not** rewrite existing project-owned `operations/src/**` workflow/agent/integration files to use descriptor-backed binding. Maintainers must migrate raw `resourceId` literals to descriptor lookups intentionally.
|
|
68
|
+
- `/git-sync` does **not** rewrite custom UI routes that import `CompanyDetailModal` / `ContactDetailModal` from `@elevasis/ui/features/lead-gen/shared`. Replace those imports with `useNavigate` to detail-page routes manually.
|
|
69
|
+
- `/git-sync` does **not** rename `useElevasisServices().organizationId` reads in project-owned code. The back-compat alias keeps existing code working; proactive renaming is a manual cleanup.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
// Pure reference file -- NOT imported anywhere.
|
|
5
5
|
// Copy individual examples into core/config/organization-model.ts or resource definitions as needed.
|
|
6
6
|
|
|
7
|
-
import { defineOrganizationModel } from '@elevasis/core/organization-model'
|
|
7
|
+
import { defineOrganizationModel, defineResources } from '@elevasis/core/organization-model'
|
|
8
8
|
|
|
9
9
|
// ---------------------------------------------------------------------------
|
|
10
10
|
// Branding override
|
|
@@ -166,12 +166,24 @@ export const customersAndOfferingsExample = defineOrganizationModel({
|
|
|
166
166
|
})
|
|
167
167
|
|
|
168
168
|
// ---------------------------------------------------------------------------
|
|
169
|
-
// Resource
|
|
169
|
+
// Resource descriptor example
|
|
170
170
|
// ---------------------------------------------------------------------------
|
|
171
|
-
export const
|
|
172
|
-
|
|
171
|
+
export const workflowResourceDescriptorsExample = defineResources({
|
|
172
|
+
leadEnrichment: {
|
|
173
|
+
id: 'lead-enrichment-workflow',
|
|
174
|
+
kind: 'workflow',
|
|
175
|
+
systemId: 'sys.prospecting',
|
|
176
|
+
ownerRoleId: 'role-ops-lead',
|
|
177
|
+
capabilityKey: 'prospecting.lead-enrichment',
|
|
178
|
+
status: 'active' as const
|
|
179
|
+
}
|
|
180
|
+
})
|
|
181
|
+
|
|
182
|
+
export const workflowResourceRuntimeMetadataExample = {
|
|
183
|
+
resource: workflowResourceDescriptorsExample.leadEnrichment,
|
|
184
|
+
resourceId: workflowResourceDescriptorsExample.leadEnrichment.id,
|
|
173
185
|
name: 'Lead Enrichment',
|
|
174
|
-
type:
|
|
186
|
+
type: workflowResourceDescriptorsExample.leadEnrichment.kind,
|
|
175
187
|
version: '1.0.0',
|
|
176
188
|
status: 'prod' as const,
|
|
177
189
|
links: [
|
|
@@ -70,7 +70,7 @@ See [Memory System](memory.mdx) for architecture, error tracking format, scaling
|
|
|
70
70
|
|
|
71
71
|
### Project Structure
|
|
72
72
|
|
|
73
|
-
The scaffolded project separates concerns clearly: `
|
|
73
|
+
The scaffolded project separates concerns clearly: `operations/` for executable resources, `core/` for shared contracts and Organization Model configuration, `ui/` for the shell, `docs/` for platform documentation, and `.claude/` for agent infrastructure. Understanding which files are gitignored, which are committed, and why matters for collaborating on projects.
|
|
74
74
|
|
|
75
75
|
See [Project Structure](project-structure.mdx) for a file-by-file walkthrough of the scaffolded project.
|
|
76
76
|
|