@muxoai/platform 1.3.3 → 1.4.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 (54) hide show
  1. package/.agents/plugins/marketplace.json +2 -2
  2. package/.claude-plugin/marketplace.json +2 -2
  3. package/ARCHITECTURE.md +16 -6
  4. package/README.md +7 -5
  5. package/dist/cli.js +393 -13
  6. package/dist/composio-catalog.d.ts +58 -0
  7. package/dist/composio-catalog.js +474 -0
  8. package/dist/config.d.ts +10 -0
  9. package/dist/config.js +16 -0
  10. package/dist/durable-workflow.d.ts +45 -0
  11. package/dist/durable-workflow.js +90 -0
  12. package/dist/engine.d.ts +276 -5
  13. package/dist/engine.js +1261 -71
  14. package/dist/mcp-schema.d.ts +125 -0
  15. package/dist/mcp-schema.js +1076 -0
  16. package/dist/mcp.d.ts +2 -30
  17. package/dist/mcp.js +505 -539
  18. package/dist/memory-graph.d.ts +21 -0
  19. package/dist/memory-graph.js +173 -0
  20. package/dist/nl.js +155 -0
  21. package/dist/oauth.d.ts +32 -0
  22. package/dist/oauth.js +134 -0
  23. package/dist/policy.d.ts +75 -1
  24. package/dist/policy.js +1119 -0
  25. package/dist/providers/composio-instant.js +225 -5
  26. package/dist/providers/composio-sdk.d.ts +68 -5
  27. package/dist/providers/composio-sdk.js +683 -78
  28. package/dist/providers/microsoft-governance.d.ts +28 -1
  29. package/dist/providers/microsoft-governance.js +224 -11
  30. package/dist/providers/stripe-billing.d.ts +42 -0
  31. package/dist/providers/stripe-billing.js +230 -1
  32. package/dist/providers/stripe-projects.d.ts +451 -3
  33. package/dist/providers/stripe-projects.js +2106 -87
  34. package/dist/providers/supermemory.d.ts +74 -1
  35. package/dist/providers/supermemory.js +426 -0
  36. package/dist/provisioning-managed.d.ts +50 -0
  37. package/dist/provisioning-managed.js +155 -0
  38. package/dist/sdk.d.ts +538 -8
  39. package/dist/sdk.js +377 -10
  40. package/dist/server.js +1841 -232
  41. package/dist/store.d.ts +113 -6
  42. package/dist/store.js +675 -52
  43. package/dist/types.d.ts +212 -5
  44. package/dist/ui/console-html.d.ts +10 -1
  45. package/dist/ui/console-html.js +1188 -462
  46. package/dist/version.d.ts +1 -1
  47. package/dist/version.js +1 -1
  48. package/package.json +2 -2
  49. package/plugins/muxo/.claude-plugin/plugin.json +1 -1
  50. package/plugins/muxo/.codex-plugin/plugin.json +1 -1
  51. package/plugins/muxo/plugin.json +2 -2
  52. package/plugins/muxo/skills/muxo/SKILL.md +42 -1
  53. package/plugins/muxo/skills/muxo/references/mcp.md +3 -2
  54. package/plugins/muxo/skills/setup/SKILL.md +8 -0
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const MUXO_VERSION = "1.3.3";
1
+ export declare const MUXO_VERSION = "1.4.1";
package/dist/version.js CHANGED
@@ -1 +1 @@
1
- export const MUXO_VERSION = "1.3.3";
1
+ export const MUXO_VERSION = "1.4.1";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@muxoai/platform",
3
- "version": "1.3.3",
3
+ "version": "1.4.1",
4
4
  "description": "Muxo — Unified Execution, Provisioning & Governance Platform over Composio, Stripe Projects, Microsoft Agent Governance & Supermemory",
5
5
  "private": false,
6
6
  "license": "MIT",
@@ -52,7 +52,7 @@
52
52
  "ARCHITECTURE.md"
53
53
  ],
54
54
  "scripts": {
55
- "build": "tsc",
55
+ "build": "tsc && tsc --noEmit -p worker/tsconfig.json",
56
56
  "start": "node --no-warnings dist/server.js",
57
57
  "dev": "tsx watch src/server.ts",
58
58
  "cli": "tsx src/cli.ts",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "muxo",
3
- "version": "1.3.1",
3
+ "version": "1.4.1",
4
4
  "description": "Governed agent execution across 1,000+ Connected Apps (managed OAuth handoff), Instant Tools (search, scrape, crawl, SEO audit), live Cloud Infrastructure provisioning, Workspace Memory recall, and verifiable audit records.",
5
5
  "author": {
6
6
  "name": "Muxo",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "muxo",
3
- "version": "1.3.1",
3
+ "version": "1.4.1",
4
4
  "description": "Your agent decides what to do — Muxo governs, provisions, remembers, and executes it. Unified access to 1,000+ Connected Apps (managed OAuth handoff), Instant Tools (search, scrape, crawl, SEO audit), live Cloud Infrastructure provisioning (Postgres, Redis, SQLite, Storage), Workspace Memory recall, and verifiable audit records through the hosted app or local CLI.",
5
5
  "author": {
6
6
  "name": "Muxo",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json",
3
3
  "name": "muxo",
4
- "version": "1.3.1",
4
+ "version": "1.4.1",
5
5
  "description": "Your agent decides what to do — Muxo governs, provisions, remembers, and executes it. Unified access to 1,000+ Connected Apps (managed OAuth handoff), Instant Tools (search, scrape, crawl, SEO audit), live Cloud Infrastructure provisioning (Postgres, Redis, SQLite, Storage), Workspace Memory recall, and verifiable audit records.",
6
6
  "author": {
7
7
  "name": "Muxo",
@@ -109,7 +109,7 @@
109
109
  "commerce_description": "This plugin does not sell retail products or process consumer checkout inside ChatGPT."
110
110
  },
111
111
  "publication": {
112
- "release_notes": "Muxo v1.3.1: Unified governed execution across 1,000+ Connected Apps, Instant web/SEO tools, Cloud Infrastructure provisioning, and Workspace Memory."
112
+ "release_notes": "Muxo v1.4.1: Unified governed execution across 1,000+ Connected Apps, Instant web/SEO tools, Cloud Infrastructure provisioning, and Workspace Memory."
113
113
  }
114
114
  }
115
115
  }
@@ -77,7 +77,7 @@ Supports 1,000+ SaaS toolkits dynamically via `search_tools({ query: "...", lane
77
77
  - **Salesforce**: `app.salesforce.query_records` (`{"soql": "SELECT Id, Name FROM Account LIMIT 5"}`, `execute_read`)
78
78
  - **External User OAuth Handoff**:
79
79
  1. Call `plan_action` for the `app.*` tool (or call `start_connection({ provider: "<provider>" })` directly).
80
- 2. When `authHandoff.required: true` is returned, present `authHandoff.redirectUrl` (or `connection.redirectUrl`) to the user so they can authorize in their browser.
80
+ 2. When `authHandoff.required: true` is returned, present `authHandoff.redirectUrl` (or `connection.redirectUrl`) to the user so they can authorize in their browser. Plan responses also carry a user-facing `humanHandoff` block (kind `"oauth"`: `{ url, ctaLabel: "Connect <Provider>", headline, instructions, provider }`, same URL as `authHandoff.redirectUrl`) — show `humanHandoff.url` and stop until the user confirms.
81
81
  3. Poll `wait_for_connection({ provider: "<provider>" })` (or `connection_status({ provider: "<provider>" })`) until `ready: true` (`status === "active"`).
82
82
  4. Resume the original `plan.id` with `execute_read` or `execute_write`.
83
83
 
@@ -101,3 +101,44 @@ Provision live cloud databases, caches, auth, sandboxes, and hosting through Mux
101
101
  - **Single-Execution & Safety Guardrails**: Every mutation or provisioning call creates a governed `plan_*` evaluated against workspace safety rules. Execute each confirmed plan exactly once on its matching risk lane (`execute_read`, `execute_write`, `execute_admin`, `execute_financial`, `execute_provisioning`, `execute_destructive`).
102
102
  - **Uncertain Write Boundary**: After a timeout or unclear write/provisioning result, check `get_run` or `get_receipt` before doing anything else.
103
103
  - **Secret Custody**: Provisioned infrastructure credentials are encrypted in the Muxo AES-256-GCM Vault and redacted from Workspace Memory. Never expose raw tokens or connection secrets in chat responses.
104
+
105
+ ## Plan Guidance & Human Handoffs (`llmGuidance` / `humanHandoff`)
106
+
107
+ Every `plan_action` response (MCP and REST) includes `llmGuidance` — `{ summary, nextToolCalls: [{ tool, input, when }] }` — describing exactly what to call next. When a person must act, a `humanHandoff` block is attached:
108
+
109
+ - **kind `"oauth"`**: `{ url, ctaLabel: "Connect <Provider>", headline, instructions, provider }` — the same URL as `authHandoff.redirectUrl`.
110
+ - **kind `"approval"`**: when `plan.approvalStatus` is `"pending_approval"`, `{ url: "<baseUrl>/approve/<plan_id>", ctaLabel: "Review & approve", headline, instructions, planId }`. The `/approve/:planId` URL opens a one-click "Review & approve" page (Clerk sign-in on hosted, console key on self-hosted) where the owner sees the action, risk, cost, reason, and input, and can "Approve and run", "Approve only", or "Reject" (reject = `POST /api/v1/plans/:id/approve` with `{"decision": "rejected"}`).
111
+
112
+ **Rule**: when `humanHandoff` is present, show the user `humanHandoff.url` and STOP; only continue with `llmGuidance.nextToolCalls` after the user confirms.
113
+
114
+ ## Natural-Language Control Plane (Memory, Governance, Policy, Context, Receipts)
115
+
116
+ Users can operate every Muxo pillar in plain English through `POST /api/v1/do` (or `muxo do "<prompt>"` locally). The router recognizes these control-plane intents automatically and answers with a `humanMessage` plus a structured `explanation` object:
117
+
118
+ ### Memory
119
+ - **Remember**: "Remember our default region is us-east-1", "Hey Muxo, remember our default GitHub repo is acme/api and default region is us-east-1" — saves the fact, extracts auto-fill defaults, and upserts bi-temporal memory facts (`status: "memory_saved"`).
120
+ - **Recall**: "What do you remember?", "Show my saved memories", "What are our default settings?" — returns `memoryOverview` with learned defaults and an explanation (`status: "memory_recalled"`).
121
+ - **Forget**: "Forget our staging redis", "Hey Muxo, forget ...", "Delete memory mem_abc123" — deletes the matching memory and retires its temporal facts (`status: "memory_forgotten"`).
122
+ - **Active recall during planning**: `plan_action` recalls workspace memory BEFORE governance checks and auto-fills missing/default tool inputs, reporting `memoryContext.autoFilledInput` and `activeDefaults`.
123
+ - REST equivalents: `POST /api/v1/memory` (`{"prompt": "Remember ..."}`), `GET /api/v1/memory`, `POST /api/v1/memory/forget` (`{"query": "..."}`), `GET /api/v1/memory/facts`.
124
+
125
+ ### Governance & Policy
126
+ - **Set guardrails in plain English**: "Hey Muxo, don't go over 25 credits per run", "Hey Muxo, don't use resource.projects.deprovision", "Hey Muxo, ask me before changing anything", "Hey Muxo, read-only mode", "Never send emails", "Block destructive SQL", "Free tools only" — via `POST /api/v1/do` (returns `status: "guardrail_applied"`) or `POST /api/v1/guardrails` with `{"prompt": "..."}` (also accepts `rule`, `instruction`, or `naturalLanguageRule`). Responses include `guardrail` + `plainEnglishGuardrails` (human-readable rules, headline, and posture label). `{"reset": true}` restores the Safe Default; `GET /api/v1/guardrails` lists active rules.
127
+ - **Inspect**: "What are our current guardrails?", "Explain governance status" — returns policy, kill-switch state, and trust score in plain language.
128
+ - **Emergency stop / resume**: "Emergency stop because we saw anomalous spend", "Pause all agents", "Resume all agents".
129
+ - **Prompt-injection scan**: "Scan this text for prompt injection: <text>" — runs the OWASP ASI-06 context-poisoning detector.
130
+ - REST equivalents: `GET/POST /api/v1/policy`, `GET/POST /api/v1/guardrails`, `GET /api/v1/governance`, `POST /api/v1/governance/kill-switch`, `POST /api/v1/governance/scan-context`.
131
+
132
+ ### Context
133
+ - **Inspect**: "Show my workspace context", "Explain current run context" — returns credits, learned defaults, active guardrails, provisioned resources, and a ready-to-use `llmSystemPrompt` block.
134
+ - REST equivalent: `GET/POST /api/v1/context`.
135
+
136
+ ### Receipts
137
+ - **Explain / verify**: "Explain my latest receipt", "Verify receipt rcpt_...", "Show recent receipts" — returns the tamper-proof receipt with signature status and a plain-English explanation of action, cost, and funding mode.
138
+ - REST equivalents: `GET /api/v1/receipts`, `GET /api/v1/receipts/{id}`.
139
+
140
+ ### Customizable Language Modes
141
+ Every explanation ships in three forms: `nonTechnical` (plain human language), `technical` (IDs, hashes, and metrics), and `preferred` (chosen by the workspace language mode). Users control the style in plain English:
142
+ - "Use non-technical language" / "Explain in technical detail" / "Use hybrid language" — sets `policy.languageMode` (`non_technical` | `technical` | `hybrid`).
143
+ - "Custom instruction: always show costs in USD" — appends to `policy.customInstructions`, which is then applied to every explanation.
144
+ - CLI equivalents: `muxo policy`, `muxo policy "<rule>"`, `muxo guardrails`, `muxo guardrails set "<rule>"`, `muxo guardrails reset`, `muxo context [query]`, `muxo receipts [id]`.
@@ -9,12 +9,13 @@ Use this path in ChatGPT web/app, when no usable terminal exists, or when the us
9
9
  2. **Discovery & Schema Inspection**:
10
10
  - Call `search_tools({ query, lane, toolkit })` across:
11
11
  - **Instant Tools (`lane: "composio_instant"`)**: `instant.seo.audit`, `instant.web.crawl`, `instant.web.scrape`, `instant.web.search`, `instant.dns.lookup`, `instant.github.repo_intel`, `instant.hackernews.top_stories`
12
- - **Composio Connected Apps (`lane: "composio_sdk"`)**: 1,000+ SaaS apps (`app.github.*`, `app.gmail.*`, `app.slack.*`, `app.notion.*`, `app.linear.*`, `app.googlecalendar.*`, `app.jira.*`, `app.hubspot.*`, `app.discord.*`, `app.googledrive.*`, `app.airtable.*`, `app.salesforce.*`, plus live Composio `/api/v3/tools` search)
12
+ - **Composio Connected Apps (`lane: "composio_sdk"`)**: 1,000+ SaaS apps (`app.github.*`, `app.gmail.*`, `app.slack.*`, `app.notion.*`, `app.linear.*`, `app.googlecalendar.*`, `app.jira.*`, `app.hubspot.*`, `app.discord.*`, `app.googledrive.*`, `app.airtable.*`, `app.salesforce.*`, `app.zendesk.*`, `app.shopify.*`, `app.pagerduty.*`, `app.sentry.*`, plus live Composio `/api/v3/tools` search)
13
13
  - **Stripe Projects Cloud Infrastructure (`lane: "stripe_projects"`)**: 36+ infrastructure providers (`resource.turso.database`, `resource.neon.postgres`, `resource.supabase.project`, `resource.upstash.redis`, `resource.cloudflare.worker`, `resource.vercel.project`, `resource.prisma.database`, `resource.clerk.auth`, `resource.workos.auth`, `resource.auth0.client`, `resource.planetscale.postgresql`, `resource.clickhouse.clickhouse`, `resource.chroma.database`, `resource.e2b.sandboxes`, `resource.daytona.sandbox`, `resource.browserbase.project`, `resource.steel.browser`, `resource.exa.search`, `resource.firecrawl.api`, `resource.perplexity.api`, `resource.openrouter.api`, `resource.supermemory.memory`, `resource.resend.email`, `resource.sentry.project`, `resource.posthog.analytics`, `resource.datadog.observability`, `resource.inngest.app`, `resource.railway.hosting`, `resource.flyio.app`, `resource.render.static_site`, `resource.netlify.project`, `resource.herenow.hosting`, `resource.cloudinary.media`, `resource.elevenlabs.tts`, `resource.agentmail.api`, `resource.agentphone.number`, `resource.twilio.email`, `resource.shopify.store`, `resource.spaceship.domain`)
14
14
  - **Stripe Billing (`lane: "stripe_billing"`)**: `billing.credits.topup`, `billing.subscription.upgrade`, `billing.checkout.create`
15
15
  - Call `inspect_tool({ tool_slug })` to inspect the JSON input schema, `riskLevel`, and `creditCost`.
16
- 3. **Governed Planning**:
16
+ 3. **Governed Planning & Human Approval Polling**:
17
17
  - Call `plan_action({ tool_slug, input, reason })` to evaluate workspace safety policy, scan inputs, recall workspace context, and receive `plan.id`.
18
+ - If `plan.approvalStatus === "pending_approval"`, present `humanHandoff.url` (`/approve/<plan.id>`) to the user and poll `get_plan({ plan_id: plan.id, wait_seconds: 15 })` until approved before executing.
18
19
  4. **External User OAuth Handoff & Recovery (`composio_sdk` / `app.*`)**:
19
20
  - If `plan_action` returns `authHandoff.required: true` (or a connection is missing), share `authHandoff.redirectUrl` (or call `start_connection({ provider })`) so the user can authorize in their browser.
20
21
  - Poll `wait_for_connection({ provider, timeout_seconds: 15 })` or `connection_status({ provider })` until `connected: true` (`status: "active"`), then resume the original `plan.id`.
@@ -32,3 +32,11 @@ Welcome to **Muxo** — the unified execution, cloud provisioning, contextual me
32
32
  - If the app is not connected yet, `plan_action` returns `authHandoff.redirectUrl`. Open that link to authorize, then call `wait_for_connection({ provider })` to resume.
33
33
  - **Cloud Infrastructure (`resource.*`)** provisions live databases and services through Muxo Cloud Infrastructure:
34
34
  - Provision Turso SQLite (`resource.turso.database`), Neon Postgres (`resource.neon.postgres`), Supabase (`resource.supabase.project`), or Upstash Redis (`resource.upstash.redis`) and pull encrypted `.env` credentials via `muxo env pull`.
35
+
36
+ ## Step 3: Set guardrails, teach memory, and handle approvals
37
+
38
+ Once connected, you can govern and personalize the workspace in plain English:
39
+
40
+ - **Guardrails**: "Hey Muxo, don't go over 25 credits per run", "Hey Muxo, read-only mode", "Hey Muxo, ask me before changing anything" (`POST /api/v1/do` returns `status: "guardrail_applied"`; `POST /api/v1/guardrails` with `{"prompt": "..."}` or `{"reset": true}` also works). Responses include human-readable `plainEnglishGuardrails`.
41
+ - **Memory**: "Hey Muxo, remember our default GitHub repo is acme/api and default region is us-east-1" (`status: "memory_saved"`). `plan_action` recalls memory before governance checks and auto-fills defaults (`memoryContext.autoFilledInput`). Ask "What do you remember?" or say "Hey Muxo, forget ..." anytime.
42
+ - **Human handoffs**: Every `plan_action` returns `llmGuidance` with next steps. When a person must act — OAuth connect (`humanHandoff` kind `"oauth"`) or plan approval (`kind: "approval"`, one-click `/approve/<plan_id>` page) — show `humanHandoff.url` to the user and wait for their confirmation before continuing.