@elevasis/sdk 1.25.0 → 1.26.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.
Files changed (64) hide show
  1. package/dist/cli.cjs +87 -120
  2. package/dist/index.d.ts +220 -50
  3. package/dist/index.js +4 -435
  4. package/dist/node/index.d.ts +46 -38
  5. package/dist/test-utils/index.d.ts +154 -40
  6. package/dist/test-utils/index.js +27 -355
  7. package/dist/types/worker/adapters/clickup.d.ts +22 -0
  8. package/dist/types/worker/adapters/index.d.ts +1 -0
  9. package/dist/worker/index.js +32 -354
  10. package/package.json +2 -2
  11. package/reference/_navigation.md +11 -1
  12. package/reference/_reference-manifest.json +70 -0
  13. package/reference/claude-config/rules/organization-model.md +12 -1
  14. package/reference/claude-config/rules/organization-os.md +12 -1
  15. package/reference/claude-config/skills/om/SKILL.md +13 -5
  16. package/reference/claude-config/skills/om/operations/codify-level-a.md +109 -100
  17. package/reference/claude-config/skills/om/operations/customers.md +10 -6
  18. package/reference/claude-config/skills/om/operations/features.md +7 -3
  19. package/reference/claude-config/skills/om/operations/goals.md +10 -6
  20. package/reference/claude-config/skills/om/operations/identity.md +8 -5
  21. package/reference/claude-config/skills/om/operations/labels.md +17 -1
  22. package/reference/claude-config/skills/om/operations/offerings.md +11 -7
  23. package/reference/claude-config/skills/om/operations/roles.md +11 -7
  24. package/reference/claude-config/skills/om/operations/techStack.md +10 -2
  25. package/reference/claude-config/skills/setup/SKILL.md +2 -2
  26. package/reference/claude-config/sync-notes/2026-05-20-om-define-helpers.md +32 -0
  27. package/reference/claude-config/sync-notes/2026-05-22-access-model-and-right-panel.md +43 -0
  28. package/reference/claude-config/sync-notes/2026-05-22-lead-gen-tenant-config.md +40 -0
  29. package/reference/claude-config/sync-notes/2026-05-22-org-model-multi-file-split.md +61 -0
  30. package/reference/claude-config/sync-notes/2026-05-23-branding-names-to-identity.md +49 -0
  31. package/reference/claude-config/sync-notes/2026-05-23-om-deployment-drift-detection.md +42 -0
  32. package/reference/cli-management.mdx +541 -0
  33. package/reference/cli.mdx +4 -532
  34. package/reference/concepts.mdx +134 -146
  35. package/reference/deployment/api.mdx +296 -297
  36. package/reference/deployment/command-center.mdx +208 -209
  37. package/reference/deployment/index.mdx +194 -195
  38. package/reference/deployment/provided-features.mdx +110 -107
  39. package/reference/deployment/ui-execution.mdx +249 -250
  40. package/reference/examples/organization-model.ts +14 -4
  41. package/reference/framework/index.mdx +111 -195
  42. package/reference/framework/resource-documentation.mdx +90 -0
  43. package/reference/framework/tutorial-system.mdx +135 -135
  44. package/reference/getting-started.mdx +141 -142
  45. package/reference/index.mdx +95 -106
  46. package/reference/packages/ui/src/auth/README.md +6 -6
  47. package/reference/platform-tools/adapters-integration.mdx +300 -301
  48. package/reference/platform-tools/adapters-platform.mdx +552 -553
  49. package/reference/platform-tools/index.mdx +216 -217
  50. package/reference/platform-tools/type-safety.mdx +82 -82
  51. package/reference/resources/index.mdx +348 -349
  52. package/reference/resources/patterns.mdx +446 -449
  53. package/reference/resources/types.mdx +115 -116
  54. package/reference/roadmap.mdx +164 -165
  55. package/reference/rules/organization-model.md +14 -0
  56. package/reference/runtime.mdx +172 -173
  57. package/reference/scaffold/operations/propagation-pipeline.md +1 -1
  58. package/reference/scaffold/recipes/extend-lead-gen.md +130 -77
  59. package/reference/scaffold/reference/contracts.md +376 -446
  60. package/reference/scaffold/reference/glossary.md +8 -6
  61. package/reference/scaffold/ui/feature-flags-and-gating.md +59 -46
  62. package/reference/scaffold/ui/feature-shell.mdx +11 -11
  63. package/reference/scaffold/ui/recipes.md +24 -24
  64. package/reference/troubleshooting.mdx +222 -223
@@ -1,209 +1,208 @@
1
- ---
2
- title: Command Center
3
- description: Post-deployment UI reference -- what each page does, the resource graph model, relationships, validation, and how SDK concepts map to Command Center actions
4
- loadWhen: "User asks about the Command Center UI, post-deployment workflow, monitoring, or the resource graph"
5
- ---
6
-
7
- The Command Center is the browser UI for interacting with deployed resources. After you run `elevasis-sdk deploy`, this is where you run workflows, monitor executions, manage approvals, schedule tasks, and review logs.
8
-
9
- ---
10
-
11
- ## Quick Reference
12
-
13
- | Task | Page | Path |
14
- | -------------------------------------------------- | -------------- | ----------------------- |
15
- | Browse deployed resources, view the resource graph | Command View | `/command-view` |
16
- | Approve or reject pending HITL requests | Command Queue | `/queue` |
17
- | Search execution history across all resources | Execution Logs | `/logs` |
18
- | Create API key and OAuth credentials | Credentials | `/settings/credentials` |
19
- | View deployment history and active version | Deployments | `/settings/deployments` |
20
-
21
- ---
22
-
23
- ## Command View
24
-
25
- The Command View is a visual graph of your deployed resources. Each node is a resource (workflow, agent, trigger, integration). Edges are the relationships you declared in `DeploymentSpec`.
26
-
27
- **What you can do here:**
28
-
29
- - See all deployed resources at a glance
30
- - Trace data flow between resources via declared relationships
31
- - Identify which resources depend on which integrations
32
- - Click a node to view resource details (ID, status, type)
33
-
34
- ### Node Types
35
-
36
- Every resource you deploy becomes a node in the graph. Some nodes are executable; others are visual-only.
37
-
38
- **Executable nodes:**
39
-
40
- | Type | What It Does | Deployed By |
41
- | -------- | ------------------------------------------------- | --------------------- |
42
- | Workflow | Runs step handlers in sequence or branching paths | `elevasis-sdk deploy` |
43
- | Agent | Autonomous LLM-powered resource with tools | `elevasis-sdk deploy` |
44
-
45
- **Visual-only nodes** (no runtime behavior -- exist for the graph):
46
-
47
- | Type | What It Represents | Why It Exists |
48
- | ----------------- | --------------------------------------------------- | --------------------------------------------- |
49
- | Trigger | A webhook or schedule that starts a workflow | Shows how executions begin |
50
- | Integration | A credential reference (provider + credential name) | Shows which external services a resource uses |
51
- | External Resource | A third-party automation (n8n, Make, Zapier) | Documents automations outside the platform |
52
- | Human Checkpoint | A point where a human makes a decision | Shows where HITL approval gates exist |
53
-
54
- ### Relationships
55
-
56
- Relationships are edges in the graph. Declare them in `DeploymentSpec`:
57
-
58
- ```typescript
59
- const org: DeploymentSpec = {
60
- workflows: [scoreLeadWorkflow, sendProposalWorkflow],
61
- relationships: {
62
- 'score-lead': {
63
- triggers: {
64
- workflows: ['send-proposal'],
65
- },
66
- uses: {
67
- integrations: ['attio-integration'],
68
- },
69
- },
70
- },
71
- };
72
- ```
73
-
74
- | Field | Type | Meaning |
75
- | -------------------- | ---------- | ------------------------------------- |
76
- | `triggers.workflows` | `string[]` | Workflows this resource starts |
77
- | `triggers.agents` | `string[]` | Agents this resource starts |
78
- | `uses.integrations` | `string[]` | Integrations this resource depends on |
79
-
80
- **Relationships are declarations, not routing.** Declaring that workflow A triggers workflow B does not route A's output to B -- your handler must explicitly invoke B via the `execution` adapter. The graph can drift from reality if declarations don't match code.
81
-
82
- ### What Is Enforced vs Decorative
83
-
84
- | Category | Validated at Deploy | Matches Runtime | Status |
85
- | ---------------------------------------- | ---------------------------- | --------------- | -------------- |
86
- | Resource IDs unique | Yes | Yes | **Enforced** |
87
- | Input schema matches execution interface | Yes | Yes | **Enforced** |
88
- | Relationship targets exist | Yes | No | **Decorative** |
89
- | Trigger routing | No | No | **Decorative** |
90
- | Tool availability per agent | No | No | **Decorative** |
91
- | Model config | Yes (provider + model valid) | No | **Decorative** |
92
-
93
- Keep relationships in sync with your handler code. When you add an `execution.trigger()` call, add the corresponding relationship declaration.
94
-
95
- ### Deploy-Time Validation
96
-
97
- `elevasis-sdk deploy` and `elevasis-sdk check` both validate:
98
-
99
- - Duplicate resource IDs
100
- - Relationship targets must exist in the same `DeploymentSpec`
101
- - Agent model params (provider, model name, temperature bounds)
102
- - Workflow step chains (`next.target` must point to existing step names)
103
-
104
- **Validation error examples:**
105
-
106
- ```
107
- ERROR Relationship target 'send-proposal' not found in organization resources
108
- ERROR Duplicate resource ID 'score-lead' in deployment
109
- ```
110
-
111
- ### Graph Serialization
112
-
113
- The platform converts your definitions into `CommandViewNode` (one per resource) and `CommandViewEdge` (one per relationship) structures. `buildEdges()` reads your `relationships` declarations and produces edges as a pure transformation -- no runtime behavior is inferred.
114
-
115
- > **SDK takeaway:** Declare relationships in `DeploymentSpec` to keep the Command View accurate as your system grows. Update declarations whenever you add or remove `execution.trigger()` calls.
116
-
117
- ---
118
-
119
- ## Command Queue
120
-
121
- The Command Queue surfaces all pending Human-in-the-Loop (HITL) approval requests from running workflows.
122
-
123
- **What you can do here:**
124
-
125
- - View pending approval requests with context provided by the workflow
126
- - Filter by resource, status, or date
127
- - Approve or reject with an optional comment
128
- - See the history of past decisions
129
-
130
- **How it connects to your code:** Approval requests appear when a workflow step calls `approval.create()`. The workflow pauses at that step and waits for a decision.
131
-
132
- ```typescript
133
- import { approval } from '@elevasis/sdk/worker'
134
-
135
- const task = await approval.create({
136
- actions: [
137
- { id: 'approve', label: 'Approve', type: 'primary' },
138
- { id: 'reject', label: 'Reject', type: 'danger' },
139
- ],
140
- context: { dealId, proposalUrl },
141
- description: 'Approve proposal before sending',
142
- })
143
- ```
144
-
145
- > **SDK takeaway:** Use `approval.create()` to create approval gates. Provide rich `context` so reviewers have what they need to decide.
146
-
147
- ---
148
-
149
- ## Execution Logs
150
-
151
- The Execution Logs page shows the history of all executions across every deployed resource.
152
-
153
- **What you can do here:**
154
-
155
- - Search and filter by resource, status (completed/failed/running), date range
156
- - Click any execution to view full detail: input, output, step-level trace, duration
157
- - Identify failed executions and see error messages with stack traces
158
- - Navigate from a log entry directly to the resource in Command View
159
-
160
- **Filtering tips:**
161
-
162
- - Filter by resource name to debug a specific workflow
163
- - Filter by `failed` status to triage production issues
164
- - Use date range to narrow down incidents
165
-
166
- > **SDK takeaway:** Every `elevasis-sdk exec` and every scheduled run appears here. Use this page to verify behavior after deploy and to diagnose failures before opening code.
167
-
168
- ---
169
-
170
- ## Credentials
171
-
172
- The Credentials page manages encrypted API keys and OAuth tokens used by your workflows at runtime.
173
-
174
- **What you can do here:**
175
-
176
- - Create API key and webhook-secret credentials via a form
177
- - Connect OAuth providers (Google Sheets, Dropbox) via browser flow
178
- - View existing credentials (values are never shown after creation)
179
- - Delete credentials that are no longer needed
180
-
181
- **Two credential types:**
182
-
183
- | Type | Created via | Notes |
184
- | ------------------------ | -------------------------------------------- | ------------------------------------------------------ |
185
- | API key / webhook secret | CLI (`elevasis-sdk creds create`) or UI form | Either method works |
186
- | OAuth | UI only | Requires browser redirect -- cannot be created via CLI |
187
-
188
- > **SDK takeaway:** Reference credentials in your code by name (`credential: 'my-cred-name'`). Create API keys via CLI or UI; OAuth credentials require this page.
189
-
190
- ---
191
-
192
- ## Deployments
193
-
194
- The Deployments page shows the history of all deployments for your organization.
195
-
196
- **What you can do here:**
197
-
198
- - View a chronological list of past deployments
199
- - See which resources changed in each deployment
200
- - Identify the currently active version
201
- - Compare resource counts across deployments
202
-
203
- **How it connects to your code:** Each `elevasis-sdk deploy` run creates a new deployment entry. The platform activates the new version atomically -- in-flight executions complete against the previous version while new executions start against the new one.
204
-
205
- > **SDK takeaway:** Check this page after `elevasis-sdk deploy` to confirm your resources are active.
206
-
207
- ---
208
-
209
- **Last Updated:** 2026-03-06
1
+ ---
2
+ title: Command Center
3
+ description: Post-deployment UI reference -- what each page does, the resource graph model, relationships, validation, and how SDK concepts map to Command Center actions
4
+ ---
5
+
6
+ The Command Center is the browser UI for interacting with deployed resources. After you run `elevasis-sdk deploy`, this is where you run workflows, monitor executions, manage approvals, schedule tasks, and review logs.
7
+
8
+ ---
9
+
10
+ ## Quick Reference
11
+
12
+ | Task | Page | Path |
13
+ | -------------------------------------------------- | -------------- | ----------------------- |
14
+ | Browse deployed resources, view the resource graph | Command View | `/command-view` |
15
+ | Approve or reject pending HITL requests | Command Queue | `/queue` |
16
+ | Search execution history across all resources | Execution Logs | `/logs` |
17
+ | Create API key and OAuth credentials | Credentials | `/settings/credentials` |
18
+ | View deployment history and active version | Deployments | `/settings/deployments` |
19
+
20
+ ---
21
+
22
+ ## Command View
23
+
24
+ The Command View is a visual graph of your deployed resources. Each node is a resource (workflow, agent, trigger, integration). Edges are the relationships you declared in `DeploymentSpec`.
25
+
26
+ **What you can do here:**
27
+
28
+ - See all deployed resources at a glance
29
+ - Trace data flow between resources via declared relationships
30
+ - Identify which resources depend on which integrations
31
+ - Click a node to view resource details (ID, status, type)
32
+
33
+ ### Node Types
34
+
35
+ Every resource you deploy becomes a node in the graph. Some nodes are executable; others are visual-only.
36
+
37
+ **Executable nodes:**
38
+
39
+ | Type | What It Does | Deployed By |
40
+ | -------- | ------------------------------------------------- | --------------------- |
41
+ | Workflow | Runs step handlers in sequence or branching paths | `elevasis-sdk deploy` |
42
+ | Agent | Autonomous LLM-powered resource with tools | `elevasis-sdk deploy` |
43
+
44
+ **Visual-only nodes** (no runtime behavior -- exist for the graph):
45
+
46
+ | Type | What It Represents | Why It Exists |
47
+ | ----------------- | --------------------------------------------------- | --------------------------------------------- |
48
+ | Trigger | A webhook or schedule that starts a workflow | Shows how executions begin |
49
+ | Integration | A credential reference (provider + credential name) | Shows which external services a resource uses |
50
+ | External Resource | A third-party automation (n8n, Make, Zapier) | Documents automations outside the platform |
51
+ | Human Checkpoint | A point where a human makes a decision | Shows where HITL approval gates exist |
52
+
53
+ ### Relationships
54
+
55
+ Relationships are edges in the graph. Declare them in `DeploymentSpec`:
56
+
57
+ ```typescript
58
+ const org: DeploymentSpec = {
59
+ workflows: [scoreLeadWorkflow, sendProposalWorkflow],
60
+ relationships: {
61
+ 'score-lead': {
62
+ triggers: {
63
+ workflows: ['send-proposal'],
64
+ },
65
+ uses: {
66
+ integrations: ['attio-integration'],
67
+ },
68
+ },
69
+ },
70
+ };
71
+ ```
72
+
73
+ | Field | Type | Meaning |
74
+ | -------------------- | ---------- | ------------------------------------- |
75
+ | `triggers.workflows` | `string[]` | Workflows this resource starts |
76
+ | `triggers.agents` | `string[]` | Agents this resource starts |
77
+ | `uses.integrations` | `string[]` | Integrations this resource depends on |
78
+
79
+ **Relationships are declarations, not routing.** Declaring that workflow A triggers workflow B does not route A's output to B -- your handler must explicitly invoke B via the `execution` adapter. The graph can drift from reality if declarations don't match code.
80
+
81
+ ### What Is Enforced vs Decorative
82
+
83
+ | Category | Validated at Deploy | Matches Runtime | Status |
84
+ | ---------------------------------------- | ---------------------------- | --------------- | -------------- |
85
+ | Resource IDs unique | Yes | Yes | **Enforced** |
86
+ | Input schema matches execution interface | Yes | Yes | **Enforced** |
87
+ | Relationship targets exist | Yes | No | **Decorative** |
88
+ | Trigger routing | No | No | **Decorative** |
89
+ | Tool availability per agent | No | No | **Decorative** |
90
+ | Model config | Yes (provider + model valid) | No | **Decorative** |
91
+
92
+ Keep relationships in sync with your handler code. When you add an `execution.trigger()` call, add the corresponding relationship declaration.
93
+
94
+ ### Deploy-Time Validation
95
+
96
+ `elevasis-sdk deploy` and `elevasis-sdk check` both validate:
97
+
98
+ - Duplicate resource IDs
99
+ - Relationship targets must exist in the same `DeploymentSpec`
100
+ - Agent model params (provider, model name, temperature bounds)
101
+ - Workflow step chains (`next.target` must point to existing step names)
102
+
103
+ **Validation error examples:**
104
+
105
+ ```
106
+ ERROR Relationship target 'send-proposal' not found in organization resources
107
+ ERROR Duplicate resource ID 'score-lead' in deployment
108
+ ```
109
+
110
+ ### Graph Serialization
111
+
112
+ The platform converts your definitions into `CommandViewNode` (one per resource) and `CommandViewEdge` (one per relationship) structures. `buildEdges()` reads your `relationships` declarations and produces edges as a pure transformation -- no runtime behavior is inferred.
113
+
114
+ > **SDK takeaway:** Declare relationships in `DeploymentSpec` to keep the Command View accurate as your system grows. Update declarations whenever you add or remove `execution.trigger()` calls.
115
+
116
+ ---
117
+
118
+ ## Command Queue
119
+
120
+ The Command Queue surfaces all pending Human-in-the-Loop (HITL) approval requests from running workflows.
121
+
122
+ **What you can do here:**
123
+
124
+ - View pending approval requests with context provided by the workflow
125
+ - Filter by resource, status, or date
126
+ - Approve or reject with an optional comment
127
+ - See the history of past decisions
128
+
129
+ **How it connects to your code:** Approval requests appear when a workflow step calls `approval.create()`. The workflow pauses at that step and waits for a decision.
130
+
131
+ ```typescript
132
+ import { approval } from '@elevasis/sdk/worker'
133
+
134
+ const task = await approval.create({
135
+ actions: [
136
+ { id: 'approve', label: 'Approve', type: 'primary' },
137
+ { id: 'reject', label: 'Reject', type: 'danger' },
138
+ ],
139
+ context: { dealId, proposalUrl },
140
+ description: 'Approve proposal before sending',
141
+ })
142
+ ```
143
+
144
+ > **SDK takeaway:** Use `approval.create()` to create approval gates. Provide rich `context` so reviewers have what they need to decide.
145
+
146
+ ---
147
+
148
+ ## Execution Logs
149
+
150
+ The Execution Logs page shows the history of all executions across every deployed resource.
151
+
152
+ **What you can do here:**
153
+
154
+ - Search and filter by resource, status (completed/failed/running), date range
155
+ - Click any execution to view full detail: input, output, step-level trace, duration
156
+ - Identify failed executions and see error messages with stack traces
157
+ - Navigate from a log entry directly to the resource in Command View
158
+
159
+ **Filtering tips:**
160
+
161
+ - Filter by resource name to debug a specific workflow
162
+ - Filter by `failed` status to triage production issues
163
+ - Use date range to narrow down incidents
164
+
165
+ > **SDK takeaway:** Every `elevasis-sdk exec` and every scheduled run appears here. Use this page to verify behavior after deploy and to diagnose failures before opening code.
166
+
167
+ ---
168
+
169
+ ## Credentials
170
+
171
+ The Credentials page manages encrypted API keys and OAuth tokens used by your workflows at runtime.
172
+
173
+ **What you can do here:**
174
+
175
+ - Create API key and webhook-secret credentials via a form
176
+ - Connect OAuth providers (Google Sheets, Dropbox) via browser flow
177
+ - View existing credentials (values are never shown after creation)
178
+ - Delete credentials that are no longer needed
179
+
180
+ **Two credential types:**
181
+
182
+ | Type | Created via | Notes |
183
+ | ------------------------ | -------------------------------------------- | ------------------------------------------------------ |
184
+ | API key / webhook secret | CLI (`elevasis-sdk creds create`) or UI form | Either method works |
185
+ | OAuth | UI only | Requires browser redirect -- cannot be created via CLI |
186
+
187
+ > **SDK takeaway:** Reference credentials in your code by name (`credential: 'my-cred-name'`). Create API keys via CLI or UI; OAuth credentials require this page.
188
+
189
+ ---
190
+
191
+ ## Deployments
192
+
193
+ The Deployments page shows the history of all deployments for your organization.
194
+
195
+ **What you can do here:**
196
+
197
+ - View a chronological list of past deployments
198
+ - See which resources changed in each deployment
199
+ - Identify the currently active version
200
+ - Compare resource counts across deployments
201
+
202
+ **How it connects to your code:** Each `elevasis-sdk deploy` run creates a new deployment entry. The platform activates the new version atomically -- in-flight executions complete against the previous version while new executions start against the new one.
203
+
204
+ > **SDK takeaway:** Check this page after `elevasis-sdk deploy` to confirm your resources are active.
205
+
206
+ ---
207
+
208
+ **Last Updated:** 2026-03-06