@elevasis/sdk 0.5.12 → 0.5.14
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 +144 -118
- package/dist/index.d.ts +19 -253
- package/dist/index.js +20 -9
- package/dist/templates.js +62 -59
- package/dist/types/worker/adapters/index.d.ts +0 -1
- package/dist/worker/index.js +47 -53
- package/package.json +1 -1
- package/reference/_navigation.md +13 -57
- package/reference/{cli/index.mdx → cli.mdx} +568 -505
- package/reference/concepts.mdx +164 -0
- package/reference/deployment/api.mdx +297 -297
- package/reference/deployment/command-center.mdx +226 -0
- package/reference/deployment/index.mdx +158 -153
- package/reference/framework/agent.mdx +156 -151
- package/reference/framework/index.mdx +182 -103
- package/reference/{developer → framework}/interaction-guidance.mdx +182 -182
- package/reference/framework/memory.mdx +326 -347
- package/reference/framework/project-structure.mdx +277 -298
- package/reference/framework/tutorial-system.mdx +222 -0
- package/reference/{getting-started/index.mdx → getting-started.mdx} +152 -148
- package/reference/index.mdx +131 -114
- package/reference/platform-tools/adapters.mdx +868 -929
- package/reference/platform-tools/index.mdx +354 -195
- package/reference/resources/index.mdx +339 -336
- package/reference/resources/patterns.mdx +355 -354
- package/reference/resources/types.mdx +207 -207
- package/reference/{roadmap/index.mdx → roadmap.mdx} +163 -147
- package/reference/{runtime/index.mdx → runtime.mdx} +173 -141
- package/reference/{troubleshooting/common-errors.mdx → troubleshooting.mdx} +223 -210
- package/dist/types/worker/adapters/trello.d.ts +0 -14
- package/reference/concepts/index.mdx +0 -203
- package/reference/deployment/command-center-ui.mdx +0 -151
- package/reference/deployment/command-view.mdx +0 -154
- package/reference/framework/documentation.mdx +0 -92
- package/reference/platform-tools/examples.mdx +0 -170
- package/reference/runtime/limits.mdx +0 -75
- package/reference/security/credentials.mdx +0 -141
package/dist/cli.cjs
CHANGED
|
@@ -43302,6 +43302,7 @@ var ResourceRegistry = class {
|
|
|
43302
43302
|
version: def.config.version,
|
|
43303
43303
|
type: def.config.type,
|
|
43304
43304
|
status: def.config.status,
|
|
43305
|
+
domains: def.config.domains,
|
|
43305
43306
|
origin: this.remoteResources.has(`${organizationName}/${def.config.resourceId}`) ? "remote" : "local"
|
|
43306
43307
|
})).filter((resource) => !environment || resource.status === environment);
|
|
43307
43308
|
const agents = (orgResources.agents || []).map((def) => ({
|
|
@@ -43311,6 +43312,7 @@ var ResourceRegistry = class {
|
|
|
43311
43312
|
version: def.config.version,
|
|
43312
43313
|
type: def.config.type,
|
|
43313
43314
|
status: def.config.status,
|
|
43315
|
+
domains: def.config.domains,
|
|
43314
43316
|
sessionCapable: def.config.sessionCapable ?? false,
|
|
43315
43317
|
origin: this.remoteResources.has(`${organizationName}/${def.config.resourceId}`) ? "remote" : "local"
|
|
43316
43318
|
})).filter((resource) => !environment || resource.status === environment);
|
|
@@ -43357,9 +43359,7 @@ var ResourceRegistry = class {
|
|
|
43357
43359
|
const seen = /* @__PURE__ */ new Set();
|
|
43358
43360
|
for (const id of incomingIds) {
|
|
43359
43361
|
if (seen.has(id)) {
|
|
43360
|
-
throw new Error(
|
|
43361
|
-
`Duplicate resource ID '${id}' in deployment. Each resource must have a unique ID.`
|
|
43362
|
-
);
|
|
43362
|
+
throw new Error(`Duplicate resource ID '${id}' in deployment. Each resource must have a unique ID.`);
|
|
43363
43363
|
}
|
|
43364
43364
|
seen.add(id);
|
|
43365
43365
|
}
|
|
@@ -43418,12 +43418,8 @@ var ResourceRegistry = class {
|
|
|
43418
43418
|
if (remoteIds.size === 0) return;
|
|
43419
43419
|
const orgResources = this.registry[orgName];
|
|
43420
43420
|
if (!orgResources) return;
|
|
43421
|
-
orgResources.workflows = (orgResources.workflows ?? []).filter(
|
|
43422
|
-
|
|
43423
|
-
);
|
|
43424
|
-
orgResources.agents = (orgResources.agents ?? []).filter(
|
|
43425
|
-
(a) => !remoteIds.has(a.config.resourceId)
|
|
43426
|
-
);
|
|
43421
|
+
orgResources.workflows = (orgResources.workflows ?? []).filter((w) => !remoteIds.has(w.config.resourceId));
|
|
43422
|
+
orgResources.agents = (orgResources.agents ?? []).filter((a) => !remoteIds.has(a.config.resourceId));
|
|
43427
43423
|
if (orgResources.relationships) {
|
|
43428
43424
|
for (const id of remoteIds) {
|
|
43429
43425
|
delete orgResources.relationships[id];
|
|
@@ -43482,6 +43478,21 @@ var ResourceRegistry = class {
|
|
|
43482
43478
|
}
|
|
43483
43479
|
return null;
|
|
43484
43480
|
}
|
|
43481
|
+
/**
|
|
43482
|
+
* Get statistics about remotely-deployed resources
|
|
43483
|
+
* Used by the health endpoint for platform-wide deployment visibility.
|
|
43484
|
+
*/
|
|
43485
|
+
getRemoteStats() {
|
|
43486
|
+
const orgs = /* @__PURE__ */ new Set();
|
|
43487
|
+
for (const key of this.remoteResources.keys()) {
|
|
43488
|
+
const orgName = key.split("/")[0];
|
|
43489
|
+
orgs.add(orgName);
|
|
43490
|
+
}
|
|
43491
|
+
return {
|
|
43492
|
+
activeOrgs: orgs.size,
|
|
43493
|
+
totalResources: this.remoteResources.size
|
|
43494
|
+
};
|
|
43495
|
+
}
|
|
43485
43496
|
// ============================================================================
|
|
43486
43497
|
// Resource Manifest Accessors
|
|
43487
43498
|
// ============================================================================
|
|
@@ -43787,7 +43798,7 @@ async function apiDelete(endpoint, apiUrl = resolveApiUrl()) {
|
|
|
43787
43798
|
// package.json
|
|
43788
43799
|
var package_default = {
|
|
43789
43800
|
name: "@elevasis/sdk",
|
|
43790
|
-
version: "0.5.
|
|
43801
|
+
version: "0.5.14",
|
|
43791
43802
|
description: "SDK for building Elevasis organization resources",
|
|
43792
43803
|
type: "module",
|
|
43793
43804
|
bin: {
|
|
@@ -45228,26 +45239,30 @@ pnpm exec elevasis-sdk exec echo --input '{"message": "hello"}'
|
|
|
45228
45239
|
|
|
45229
45240
|
// src/cli/commands/templates/core/claude.ts
|
|
45230
45241
|
function claudeSettingsTemplate() {
|
|
45231
|
-
return JSON.stringify(
|
|
45232
|
-
|
|
45233
|
-
|
|
45234
|
-
|
|
45235
|
-
|
|
45242
|
+
return JSON.stringify(
|
|
45243
|
+
{
|
|
45244
|
+
autoCompact: false,
|
|
45245
|
+
statusLine: {
|
|
45246
|
+
type: "command",
|
|
45247
|
+
command: "node .claude/scripts/statusline-command.js"
|
|
45248
|
+
},
|
|
45249
|
+
hooks: {
|
|
45250
|
+
PreToolUse: [
|
|
45251
|
+
{
|
|
45252
|
+
matcher: "Write|Edit|MultiEdit|Bash",
|
|
45253
|
+
hooks: [
|
|
45254
|
+
{
|
|
45255
|
+
type: "command",
|
|
45256
|
+
command: "node .claude/hooks/enforce-sdk-boundary.mjs"
|
|
45257
|
+
}
|
|
45258
|
+
]
|
|
45259
|
+
}
|
|
45260
|
+
]
|
|
45261
|
+
}
|
|
45236
45262
|
},
|
|
45237
|
-
|
|
45238
|
-
|
|
45239
|
-
|
|
45240
|
-
matcher: "Write|Edit|MultiEdit|Bash",
|
|
45241
|
-
hooks: [
|
|
45242
|
-
{
|
|
45243
|
-
type: "command",
|
|
45244
|
-
command: "node .claude/hooks/enforce-sdk-boundary.mjs"
|
|
45245
|
-
}
|
|
45246
|
-
]
|
|
45247
|
-
}
|
|
45248
|
-
]
|
|
45249
|
-
}
|
|
45250
|
-
}, null, 2) + "\n";
|
|
45263
|
+
null,
|
|
45264
|
+
2
|
|
45265
|
+
) + "\n";
|
|
45251
45266
|
}
|
|
45252
45267
|
function claudeStatuslineScriptTemplate() {
|
|
45253
45268
|
return `#!/usr/bin/env node
|
|
@@ -45450,16 +45465,16 @@ proactivity -- to their assessed levels.
|
|
|
45450
45465
|
|
|
45451
45466
|
| Resource | Location | When to Load |
|
|
45452
45467
|
| --- | --- | --- |
|
|
45453
|
-
| Workspace concepts | \`reference/concepts
|
|
45468
|
+
| Workspace concepts | \`reference/concepts.mdx\` | User asks "what is...?" or needs conceptual grounding |
|
|
45454
45469
|
| SDK patterns and examples | \`reference/resources/patterns.mdx\` | Building or modifying a workflow |
|
|
45455
45470
|
| Platform tool catalog | \`reference/platform-tools/index.mdx\` | Connecting to external services |
|
|
45456
|
-
| CLI reference | \`reference/cli
|
|
45457
|
-
| Credential model | \`reference/
|
|
45458
|
-
| Interaction guidance | \`reference/
|
|
45471
|
+
| CLI reference | \`reference/cli.mdx\` | Running execution/platform operations |
|
|
45472
|
+
| Credential model | \`reference/platform-tools/index.mdx\` | Setting up integrations or credential security |
|
|
45473
|
+
| Interaction guidance | \`reference/framework/interaction-guidance.mdx\` | Unsure how to adapt for a skill combination |
|
|
45459
45474
|
| Error history | \`.claude/memory/errors/index.md\` | Debugging errors, checking past fixes |
|
|
45460
|
-
| Command View model | \`reference/deployment/command-
|
|
45461
|
-
| Command Center UI reference | \`reference/deployment/command-center
|
|
45462
|
-
| SDK error reference | \`reference/troubleshooting
|
|
45475
|
+
| Command View model | \`reference/deployment/command-center.mdx\` | Deploying or building resources that invoke other resources |
|
|
45476
|
+
| Command Center UI reference | \`reference/deployment/command-center.mdx\` | User asks about post-deployment UI or Command Center navigation |
|
|
45477
|
+
| SDK error reference | \`reference/troubleshooting.mdx\` | Unknown error not in workspace memory |
|
|
45463
45478
|
| Project map | \`docs/project-map.mdx\` | Session start, project orientation |
|
|
45464
45479
|
| Resource inventory | \`docs/resource-map.mdx\` | Finding a specific resource by name or ID |
|
|
45465
45480
|
| Project priorities | \`docs/priorities.mdx\` | Deciding what to work on next |
|
|
@@ -45485,7 +45500,7 @@ Use \`pnpm exec elevasis-sdk\` for runtime commands (resolves the locally instal
|
|
|
45485
45500
|
- \`pnpm exec elevasis-sdk execution <resource-id> <execution-id>\` -- inspect execution detail
|
|
45486
45501
|
|
|
45487
45502
|
Organization is derived from your API key -- no org prefix needed in the resource ID.
|
|
45488
|
-
For full CLI reference: \`reference/cli
|
|
45503
|
+
For full CLI reference: \`reference/cli.mdx\`
|
|
45489
45504
|
|
|
45490
45505
|
## Rules
|
|
45491
45506
|
|
|
@@ -45500,8 +45515,8 @@ SDK patterns (imports, source structure, platform tools) are auto-loaded from
|
|
|
45500
45515
|
|
|
45501
45516
|
When an error occurs:
|
|
45502
45517
|
1. Check \`.claude/memory/errors/\` first for past fixes
|
|
45503
|
-
2. If new, check \`reference/troubleshooting
|
|
45504
|
-
3. After resolving, record in
|
|
45518
|
+
2. If new, check \`reference/troubleshooting.mdx\`
|
|
45519
|
+
3. After resolving, record in \`.claude/memory/errors/\` with context and fix
|
|
45505
45520
|
4. If an error recurs 3+ times, add a rule to \`.claude/rules/workspace-patterns.md\`${ctx.hasUI ? `
|
|
45506
45521
|
|
|
45507
45522
|
### UI App (\`ui/\`)
|
|
@@ -45510,7 +45525,8 @@ When an error occurs:
|
|
|
45510
45525
|
- Import from \`@elevasis/sdk-ui\`, never from \`@elevasis/sdk\` or \`@repo/ui\`
|
|
45511
45526
|
- Dev server runs on port 5100: \`cd ui && pnpm dev\`
|
|
45512
45527
|
- Set \`VITE_WORKOS_CLIENT_ID\` in \`ui/.env\` before running
|
|
45513
|
-
- \`
|
|
45528
|
+
- \`ElevasisCoreProvider\` (headless, no Mantine dependency) is pre-configured in \`ui/src/App.tsx\` with \`auth={{ mode: 'oauth', clientId, redirectUri }}\`, \`apiUrl="http://localhost:5170"\`, and \`theme={{ colorScheme: 'dark', preset: 'default' }}\`
|
|
45529
|
+
- To use pre-built Mantine components from \`@elevasis/sdk-ui\`, switch to \`ElevasisUIProvider\` and install \`@mantine/core\` and \`@mantine/hooks\`
|
|
45514
45530
|
- OAuth redirect is handled by the \`AuthRedirect\` component at \`/auth-redirect\` -- it uses \`useAuthContext()\` from \`@elevasis/sdk-ui/auth\` and navigates home once \`user\` is set
|
|
45515
45531
|
- API must be running on port 5170 for the UI to work (\`pnpm --filter api dev\` from the platform monorepo)` : ""}
|
|
45516
45532
|
|
|
@@ -45532,7 +45548,7 @@ based on what you find.
|
|
|
45532
45548
|
- When growth is observed, note it in the skills.md Growth Log.
|
|
45533
45549
|
|
|
45534
45550
|
For detailed per-dimension adaptation rules, read
|
|
45535
|
-
\`reference/
|
|
45551
|
+
\`reference/framework/interaction-guidance.mdx\`.
|
|
45536
45552
|
|
|
45537
45553
|
## Commands
|
|
45538
45554
|
|
|
@@ -45541,7 +45557,7 @@ For detailed per-dimension adaptation rules, read
|
|
|
45541
45557
|
| \`/meta\` | Project lifecycle: init, status, fix, deploy, health |
|
|
45542
45558
|
| \`/docs\` | Browse, create, and verify permanent documentation |
|
|
45543
45559
|
| \`/work\` | Task tracking: create, save, resume, complete |
|
|
45544
|
-
| \`/tutorial\` | Progressive learning path (
|
|
45560
|
+
| \`/tutorial\` | Progressive learning path (21 items across 4 sections) |
|
|
45545
45561
|
|
|
45546
45562
|
## Skills
|
|
45547
45563
|
|
|
@@ -45574,7 +45590,7 @@ Do not store in \`.claude/memory/\`:
|
|
|
45574
45590
|
|
|
45575
45591
|
### Structure
|
|
45576
45592
|
|
|
45577
|
-
-
|
|
45593
|
+
- \`.claude/memory/index.md\` is the root -- maps to topic files and subdirectories
|
|
45578
45594
|
- Every subdirectory has its own \`index.md\` mapping to children
|
|
45579
45595
|
- Start at the root index and drill down
|
|
45580
45596
|
- When a file outgrows a single document, split into a subdirectory
|
|
@@ -45598,14 +45614,14 @@ Read \`.claude/memory/profile/skills.md\` first. The \`automation\` skill level
|
|
|
45598
45614
|
controls which docs you load and which lesson variant you deliver.
|
|
45599
45615
|
|
|
45600
45616
|
**automation: none**
|
|
45601
|
-
- Load from \`reference/concepts
|
|
45617
|
+
- Load from \`reference/concepts.mdx\`: Glossary, What is a Workflow,
|
|
45602
45618
|
Platform Tools Overview only. Skip Zod, Execution Model, Design Decisions.
|
|
45603
|
-
- Load \`reference/deployment/command-center
|
|
45619
|
+
- Load \`reference/deployment/command-center.mdx\` for UI-first teaching.
|
|
45604
45620
|
- Do NOT load \`reference/resources/patterns.mdx\` or
|
|
45605
45621
|
\`reference/platform-tools/adapters.mdx\` during core lessons.
|
|
45606
45622
|
|
|
45607
45623
|
**automation: low-code**
|
|
45608
|
-
- Load all sections of \`reference/concepts
|
|
45624
|
+
- Load all sections of \`reference/concepts.mdx\`.
|
|
45609
45625
|
- Load \`reference/resources/patterns.mdx\` with Zapier/Make mapping in mind.
|
|
45610
45626
|
- Load \`reference/platform-tools/adapters.mdx\` on-demand (when tools are used).
|
|
45611
45627
|
|
|
@@ -45693,7 +45709,7 @@ Each lesson follows this flow:
|
|
|
45693
45709
|
|
|
45694
45710
|
When automation is none:
|
|
45695
45711
|
Skip the file tour. Start with what Elevasis does for their business -- use analogies
|
|
45696
|
-
from \`reference/
|
|
45712
|
+
from \`reference/framework/interaction-guidance.mdx\` (recipe, assembly line, kitchen
|
|
45697
45713
|
appliance). Explain deployment plainly: "You write the recipe here, then deploy it so
|
|
45698
45714
|
it's live." Deploy the starter echo workflow (\`elevasis-sdk check\` + \`elevasis-sdk deploy\`),
|
|
45699
45715
|
THEN tour the Command Center so the user sees populated pages, not empty ones. Tour:
|
|
@@ -45941,14 +45957,14 @@ Each module follows this flow:
|
|
|
45941
45957
|
## Modules
|
|
45942
45958
|
|
|
45943
45959
|
**Module: hitl -- Human-in-the-Loop**
|
|
45944
|
-
Read: \`reference/deployment/command-center
|
|
45960
|
+
Read: \`reference/deployment/command-center.mdx\` (Command Queue section).
|
|
45945
45961
|
Build: Add an approval gate using \`approval.requestApproval()\`. Test full lifecycle:
|
|
45946
45962
|
trigger, see pending in Command Queue, approve/reject, observe resume.
|
|
45947
45963
|
Key concepts: approval adapter, pending state, Command Queue UI, resume on decision.
|
|
45948
45964
|
Verify: Trigger workflow, open Command Queue, approve, confirm completion.
|
|
45949
45965
|
|
|
45950
45966
|
**Module: schedules -- Task Scheduling**
|
|
45951
|
-
Read: \`reference/deployment/command-center
|
|
45967
|
+
Read: \`reference/deployment/command-center.mdx\` (Task Scheduler section).
|
|
45952
45968
|
Build: Create all three schedule types (Recurring cron, Relative delay, Absolute
|
|
45953
45969
|
datetime). Use \`scheduler\` adapter for in-workflow scheduling.
|
|
45954
45970
|
Key concepts: schedule types, cron syntax, scheduler adapter, Task Scheduler UI.
|
|
@@ -45962,7 +45978,7 @@ Verify: Run workflow, check notification in Command Center, confirm email receiv
|
|
|
45962
45978
|
|
|
45963
45979
|
**Module: integrations -- Real-World Integrations**
|
|
45964
45980
|
Read: \`reference/platform-tools/index.mdx\`, \`reference/platform-tools/adapters.mdx\`,
|
|
45965
|
-
\`reference/
|
|
45981
|
+
\`reference/platform-tools/index.mdx\`.
|
|
45966
45982
|
Build: Pick a real integration adapter based on user's goals (read \`identity.md\`).
|
|
45967
45983
|
Set up credential (OAuth via UI, API key via CLI). Build end-to-end integration workflow.
|
|
45968
45984
|
Key concepts: adapter pattern, credential scoping, error handling for external calls.
|
|
@@ -45971,7 +45987,7 @@ handling with invalid credential.
|
|
|
45971
45987
|
|
|
45972
45988
|
**Module: error-handling -- Error Handling Mastery**
|
|
45973
45989
|
Read: \`reference/resources/patterns.mdx\` (error handling),
|
|
45974
|
-
\`reference/troubleshooting
|
|
45990
|
+
\`reference/troubleshooting.mdx\`.
|
|
45975
45991
|
Build: Create a workflow demonstrating all three error types. Add try/catch,
|
|
45976
45992
|
\`context.logger\`, and error recovery.
|
|
45977
45993
|
Key concepts: ExecutionError, PlatformToolError, ToolingError, recovery patterns.
|
|
@@ -45987,7 +46003,7 @@ Key concepts: context.store, context.logger, domain organization, schema depth.
|
|
|
45987
46003
|
Verify: Run workflow, confirm store values in step output, check logs in Execution Logs.
|
|
45988
46004
|
|
|
45989
46005
|
**Module: composition -- Resource Composition**
|
|
45990
|
-
Read: \`reference/deployment/command-
|
|
46006
|
+
Read: \`reference/deployment/command-center.mdx\`, \`reference/resources/patterns.mdx\`.
|
|
45991
46007
|
Build: Create two workflows where the first triggers the second using
|
|
45992
46008
|
\`execution.trigger()\`. Declare the relationship.
|
|
45993
46009
|
Key concepts: execution.trigger, relationship declarations, Command View graph edges.
|
|
@@ -46135,7 +46151,7 @@ Last Session: {today's date}
|
|
|
46135
46151
|
\`\`\`
|
|
46136
46152
|
|
|
46137
46153
|
Update rules:
|
|
46138
|
-
- \`Current\`: free-form, e.g. "
|
|
46154
|
+
- \`Current\`: free-form, e.g. "7: Using Platform Tools" or "M:integrations" or "20: Rules, Memory, and Customization"
|
|
46139
46155
|
- \`Last Session\`: update to today's date on each \`/tutorial\` invocation
|
|
46140
46156
|
- Completed Lessons: add a row when any numbered item (1-10, 20-21) finishes
|
|
46141
46157
|
- Completed Modules: add a row when any module (items 11-19) finishes
|
|
@@ -46231,9 +46247,9 @@ by the \`<!-- initialized: false -->\` flag in CLAUDE.md, or run manually.
|
|
|
46231
46247
|
- Create \`.claude/memory/profile/preferences.md\` (verbosity, guidance)
|
|
46232
46248
|
|
|
46233
46249
|
4. **Git check**
|
|
46234
|
-
- If \`.git/\` exists: note git is configured in memory/profile/preferences.md
|
|
46250
|
+
- If \`.git/\` exists: note git is configured in .claude/memory/profile/preferences.md
|
|
46235
46251
|
- If \`.git/\` does not exist: suggest \`git init\` and optionally GitHub
|
|
46236
|
-
- If git remote exists: note remote URL in memory/profile/preferences.md
|
|
46252
|
+
- If git remote exists: note remote URL in .claude/memory/profile/preferences.md
|
|
46237
46253
|
|
|
46238
46254
|
5. **Verify project**
|
|
46239
46255
|
Run \`elevasis-sdk check\` to confirm the starter resource is valid.
|
|
@@ -46254,9 +46270,9 @@ by the \`<!-- initialized: false -->\` flag in CLAUDE.md, or run manually.
|
|
|
46254
46270
|
|
|
46255
46271
|
Display a project health summary:
|
|
46256
46272
|
1. Template version (from elevasis.config.ts) and installed SDK version (from package.json). Suggest \`elevasis-sdk update\` to check for updates
|
|
46257
|
-
|
|
46258
|
-
|
|
46259
|
-
|
|
46273
|
+
2. Profile summary (from .claude/memory/profile/skills.md)
|
|
46274
|
+
3. Quick drift check: count of missing managed files, missing gitignore entries
|
|
46275
|
+
4. Last deployment status (from .claude/memory/deployment-state.md if it exists)
|
|
46260
46276
|
|
|
46261
46277
|
### \`/meta fix\` -- Maintenance and Upgrade
|
|
46262
46278
|
|
|
@@ -46274,9 +46290,9 @@ Detect and repair all drift. Optionally upgrades the SDK first.
|
|
|
46274
46290
|
3. **CLAUDE.md sections:** Add missing sections in correct position
|
|
46275
46291
|
4. **Memory structure:** Create base structure if missing, then verify index consistency.
|
|
46276
46292
|
If \`.claude/memory/\` does not exist or is empty:
|
|
46277
|
-
- Create
|
|
46278
|
-
- Create
|
|
46279
|
-
- Create
|
|
46293
|
+
- Create \`.claude/memory/index.md\` (root index with placeholder entries)
|
|
46294
|
+
- Create \`.claude/memory/errors/index.md\` (error category summary, empty tables)
|
|
46295
|
+
- Create \`.claude/memory/errors/deploy.md\`, \`.claude/memory/errors/runtime.md\`, \`.claude/memory/errors/typescript.md\`
|
|
46280
46296
|
If memory exists, verify: every file referenced in an index exists; every file
|
|
46281
46297
|
without an index entry gets one added; broken references are removed.
|
|
46282
46298
|
5. **Documentation verification:** For each file in docs/:
|
|
@@ -46287,7 +46303,7 @@ Detect and repair all drift. Optionally upgrades the SDK first.
|
|
|
46287
46303
|
e. Report discrepancies with suggested fixes
|
|
46288
46304
|
Note: \`/docs verify\` is available for standalone interactive verification outside this pipeline.
|
|
46289
46305
|
6. **Settings consistency:** Verify expected fields
|
|
46290
|
-
7. **Rules health:** Scan
|
|
46306
|
+
7. **Rules health:** Scan \`.claude/memory/errors/\` -- flag any entry that has recurred
|
|
46291
46307
|
3+ times and is not yet in \`.claude/rules/workspace-patterns.md\`.
|
|
46292
46308
|
If \`workspace-patterns.md\` has no rules yet and 5+ resources exist in \`src/\`,
|
|
46293
46309
|
suggest adding patterns. Surface suggestions only -- do not auto-generate.
|
|
@@ -46300,7 +46316,7 @@ Each step reports its result. Steps 1-8 run even if step 0 is skipped.
|
|
|
46300
46316
|
|
|
46301
46317
|
### \`/meta deploy\` -- Full Deploy Pipeline
|
|
46302
46318
|
|
|
46303
|
-
0. Read \`reference/deployment/command-
|
|
46319
|
+
0. Read \`reference/deployment/command-center.mdx\` -- understand the Command View
|
|
46304
46320
|
model, relationship declarations, and what deploy-time validation checks.
|
|
46305
46321
|
This context is essential for diagnosing validation failures in steps 1-2.
|
|
46306
46322
|
1. Run \`elevasis-sdk check\` (validation)
|
|
@@ -46310,18 +46326,18 @@ Each step reports its result. Steps 1-8 run even if step 0 is skipped.
|
|
|
46310
46326
|
5. Run \`elevasis-sdk deploy\`
|
|
46311
46327
|
6. \`docs/project-map.mdx\` is auto-regenerated by deploy (no manual bump needed)
|
|
46312
46328
|
7. Verify deployment via platform
|
|
46313
|
-
8. Update
|
|
46329
|
+
8. Update \`.claude/memory/deployment-state.md\` with count, timestamp, inventory
|
|
46314
46330
|
9. If git configured and remote exists: optionally push
|
|
46315
46331
|
|
|
46316
46332
|
Each step reports its result. Pipeline stops on failure with suggested fix.
|
|
46317
|
-
If validation fails with relationship errors, re-read \`reference/deployment/command-
|
|
46333
|
+
If validation fails with relationship errors, re-read \`reference/deployment/command-center.mdx\`
|
|
46318
46334
|
for the enforcement model and common fixes.
|
|
46319
46335
|
|
|
46320
46336
|
### \`/meta health\` -- Execution Debugging
|
|
46321
46337
|
|
|
46322
46338
|
Diagnose runtime failures and environment issues:
|
|
46323
46339
|
- Show recent executions with status (completed/failed)
|
|
46324
|
-
- For failed executions: analyze logs, cross-reference with memory/errors/
|
|
46340
|
+
- For failed executions: analyze logs, cross-reference with .claude/memory/errors/
|
|
46325
46341
|
- Check resource deployment status (deployed, outdated, never deployed)
|
|
46326
46342
|
- Verify environment: API key valid, credentials accessible, DB connected
|
|
46327
46343
|
|
|
@@ -46692,7 +46708,6 @@ Your \`ELEVASIS_PLATFORM_KEY\` in \`.env\` determines the organization.
|
|
|
46692
46708
|
| --- | --- | --- |
|
|
46693
46709
|
| \`api-key\` | \`{"apiKey": "sk-..."}\` | Stripe, Resend, Apify, Attio, Instantly |
|
|
46694
46710
|
| \`webhook-secret\` | \`{"signingSecret": "whsec_..."}\` | Cal.com, Stripe webhooks |
|
|
46695
|
-
| \`trello\` | \`{"apiKey": "...", "token": "..."}\` | Trello |
|
|
46696
46711
|
| \`oauth\` | N/A (browser flow only) | Notion, Google Sheets, Dropbox |
|
|
46697
46712
|
|
|
46698
46713
|
OAuth credentials **cannot** be created via CLI. Redirect the user to the Command Center UI.
|
|
@@ -46715,12 +46730,11 @@ elevasis-sdk creds list
|
|
|
46715
46730
|
Display the output. Note which are \`oauth\` (not modifiable via CLI).
|
|
46716
46731
|
|
|
46717
46732
|
**\`create\`:** Guided credential creation flow:
|
|
46718
|
-
1. Ask credential type (\`api-key
|
|
46733
|
+
1. Ask credential type (\`api-key\` or \`webhook-secret\`). Not \`oauth\`.
|
|
46719
46734
|
2. Ask credential name. Validate naming rules before proceeding.
|
|
46720
46735
|
3. Ask the user to paste the credential value directly in chat.
|
|
46721
46736
|
- For \`api-key\`: ask for the API key, construct \`{"apiKey": "..."}\`
|
|
46722
46737
|
- For \`webhook-secret\`: ask for the signing secret, construct \`{"signingSecret": "..."}\`
|
|
46723
|
-
- For \`trello\`: ask for API key AND user token, construct \`{"apiKey": "...", "token": "..."}\`
|
|
46724
46738
|
4. Pipe to CLI: \`echo '{"apiKey":"..."}' | elevasis-sdk creds create --name {name} --type {type}\`
|
|
46725
46739
|
5. Confirm success. **NEVER echo the credential value back.**
|
|
46726
46740
|
|
|
@@ -46830,7 +46844,7 @@ This file is yours. The other \`.claude/rules/\` files are SDK-owned and updated
|
|
|
46830
46844
|
|
|
46831
46845
|
## When to Add a Rule
|
|
46832
46846
|
|
|
46833
|
-
- An error has recurred 3+ times (CLAUDE.md instructs you to promote from
|
|
46847
|
+
- An error has recurred 3+ times (CLAUDE.md instructs you to promote from \`.claude/memory/errors/\`)
|
|
46834
46848
|
- A pattern appears across 3+ resources and is worth documenting for consistency
|
|
46835
46849
|
- A naming or structural convention exists that future sessions would likely get wrong
|
|
46836
46850
|
|
|
@@ -47158,31 +47172,33 @@ function getUIFiles(orgSlug) {
|
|
|
47158
47172
|
};
|
|
47159
47173
|
}
|
|
47160
47174
|
function uiPackageJsonTemplate(orgSlug) {
|
|
47161
|
-
return JSON.stringify(
|
|
47162
|
-
|
|
47163
|
-
|
|
47164
|
-
|
|
47165
|
-
|
|
47166
|
-
|
|
47167
|
-
|
|
47168
|
-
|
|
47169
|
-
|
|
47170
|
-
|
|
47171
|
-
|
|
47172
|
-
|
|
47173
|
-
|
|
47174
|
-
|
|
47175
|
-
|
|
47176
|
-
|
|
47175
|
+
return JSON.stringify(
|
|
47176
|
+
{
|
|
47177
|
+
name: `${orgSlug}-ui`,
|
|
47178
|
+
private: true,
|
|
47179
|
+
type: "module",
|
|
47180
|
+
scripts: {
|
|
47181
|
+
dev: "vite",
|
|
47182
|
+
build: "tsc && vite build",
|
|
47183
|
+
preview: "vite preview"
|
|
47184
|
+
},
|
|
47185
|
+
dependencies: {
|
|
47186
|
+
"@elevasis/sdk-ui": "latest",
|
|
47187
|
+
react: "^19.0.0",
|
|
47188
|
+
"react-dom": "^19.0.0",
|
|
47189
|
+
"react-router-dom": "^7.0.0"
|
|
47190
|
+
},
|
|
47191
|
+
devDependencies: {
|
|
47192
|
+
"@types/react": "^19.0.0",
|
|
47193
|
+
"@types/react-dom": "^19.0.0",
|
|
47194
|
+
"@vitejs/plugin-react": "^4.0.0",
|
|
47195
|
+
typescript: "^5.7.0",
|
|
47196
|
+
vite: "^6.0.0"
|
|
47197
|
+
}
|
|
47177
47198
|
},
|
|
47178
|
-
|
|
47179
|
-
|
|
47180
|
-
|
|
47181
|
-
"@vitejs/plugin-react": "^4.0.0",
|
|
47182
|
-
"typescript": "^5.7.0",
|
|
47183
|
-
"vite": "^6.0.0"
|
|
47184
|
-
}
|
|
47185
|
-
}, null, 2) + "\n";
|
|
47199
|
+
null,
|
|
47200
|
+
2
|
|
47201
|
+
) + "\n";
|
|
47186
47202
|
}
|
|
47187
47203
|
function uiIndexHtmlTemplate() {
|
|
47188
47204
|
return `<!doctype html>
|
|
@@ -47212,22 +47228,26 @@ export default defineConfig({
|
|
|
47212
47228
|
`;
|
|
47213
47229
|
}
|
|
47214
47230
|
function uiTsconfigTemplate() {
|
|
47215
|
-
return JSON.stringify(
|
|
47216
|
-
|
|
47217
|
-
|
|
47218
|
-
|
|
47219
|
-
|
|
47220
|
-
|
|
47221
|
-
|
|
47222
|
-
|
|
47223
|
-
|
|
47224
|
-
|
|
47225
|
-
|
|
47226
|
-
|
|
47227
|
-
|
|
47231
|
+
return JSON.stringify(
|
|
47232
|
+
{
|
|
47233
|
+
compilerOptions: {
|
|
47234
|
+
target: "ES2022",
|
|
47235
|
+
lib: ["ES2022", "DOM", "DOM.Iterable"],
|
|
47236
|
+
module: "ESNext",
|
|
47237
|
+
moduleResolution: "bundler",
|
|
47238
|
+
jsx: "react-jsx",
|
|
47239
|
+
strict: true,
|
|
47240
|
+
esModuleInterop: true,
|
|
47241
|
+
skipLibCheck: true,
|
|
47242
|
+
forceConsistentCasingInFileNames: true,
|
|
47243
|
+
isolatedModules: true,
|
|
47244
|
+
noEmit: true
|
|
47245
|
+
},
|
|
47246
|
+
include: ["src"]
|
|
47228
47247
|
},
|
|
47229
|
-
|
|
47230
|
-
|
|
47248
|
+
null,
|
|
47249
|
+
2
|
|
47250
|
+
) + "\n";
|
|
47231
47251
|
}
|
|
47232
47252
|
function uiMainTsxTemplate() {
|
|
47233
47253
|
return `import { StrictMode } from 'react'
|
|
@@ -47245,23 +47265,29 @@ createRoot(document.getElementById('root')!).render(
|
|
|
47245
47265
|
`;
|
|
47246
47266
|
}
|
|
47247
47267
|
function uiAppTsxTemplate() {
|
|
47248
|
-
return `import {
|
|
47249
|
-
import {
|
|
47268
|
+
return `import { ElevasisCoreProvider } from '@elevasis/sdk-ui'
|
|
47269
|
+
import { Routes, Route } from 'react-router-dom'
|
|
47250
47270
|
import { AuthRedirect } from './AuthRedirect'
|
|
47251
47271
|
|
|
47252
47272
|
export function App() {
|
|
47253
47273
|
return (
|
|
47254
|
-
<
|
|
47255
|
-
|
|
47256
|
-
|
|
47257
|
-
|
|
47274
|
+
<ElevasisCoreProvider
|
|
47275
|
+
auth={{
|
|
47276
|
+
mode: 'oauth',
|
|
47277
|
+
clientId: import.meta.env.VITE_WORKOS_CLIENT_ID,
|
|
47278
|
+
redirectUri: 'http://localhost:5100/auth-redirect',
|
|
47279
|
+
}}
|
|
47258
47280
|
apiUrl="http://localhost:5170"
|
|
47281
|
+
theme={{
|
|
47282
|
+
colorScheme: 'dark',
|
|
47283
|
+
preset: 'default',
|
|
47284
|
+
}}
|
|
47259
47285
|
>
|
|
47260
47286
|
<Routes>
|
|
47261
47287
|
<Route path="/" element={<h1>Home</h1>} />
|
|
47262
47288
|
<Route path="/auth-redirect" element={<AuthRedirect />} />
|
|
47263
47289
|
</Routes>
|
|
47264
|
-
</
|
|
47290
|
+
</ElevasisCoreProvider>
|
|
47265
47291
|
)
|
|
47266
47292
|
}
|
|
47267
47293
|
`;
|
|
@@ -47754,7 +47780,7 @@ Credentials (${data.credentials.length}):
|
|
|
47754
47780
|
|
|
47755
47781
|
// src/cli/commands/creds/creds-create.ts
|
|
47756
47782
|
var CREDENTIAL_NAME_REGEX = /^[a-z0-9]+(-[a-z0-9]+)*$/;
|
|
47757
|
-
var VALID_TYPES = ["api-key", "webhook-secret"
|
|
47783
|
+
var VALID_TYPES = ["api-key", "webhook-secret"];
|
|
47758
47784
|
async function createCreds(apiUrl, name, type, valueJson) {
|
|
47759
47785
|
if (!name || name.length < 1 || name.length > 100) {
|
|
47760
47786
|
throw new Error("Credential name must be 1-100 characters");
|
|
@@ -47923,7 +47949,7 @@ function registerCredsCommand(program3) {
|
|
|
47923
47949
|
creds.command("list").description("List all credentials (metadata only, no secrets)").option("--api-url <url>", "API URL").option("--json", "Output as JSON").action(wrapAction("creds list", async (options2) => {
|
|
47924
47950
|
await listCreds(resolveApiUrl(options2.apiUrl), options2.json);
|
|
47925
47951
|
}));
|
|
47926
|
-
creds.command("create").description("Create a new credential").requiredOption("--name <name>", "Credential name (lowercase, digits, hyphens)").requiredOption("--type <type>", "Credential type (api-key, webhook-secret
|
|
47952
|
+
creds.command("create").description("Create a new credential").requiredOption("--name <name>", "Credential name (lowercase, digits, hyphens)").requiredOption("--type <type>", "Credential type (api-key, webhook-secret)").option("--value <json>", "Credential value as JSON string").option("--api-url <url>", "API URL").action(wrapAction("creds create", async (options2) => {
|
|
47927
47953
|
await createCreds(resolveApiUrl(options2.apiUrl), options2.name, options2.type, options2.value);
|
|
47928
47954
|
}));
|
|
47929
47955
|
creds.command("update <name>").description("Update a credential value").requiredOption("--value <json>", "New credential value as JSON string").option("--api-url <url>", "API URL").action(wrapAction("creds update", async (name, options2) => {
|