@muxoai/sdk 1.3.0 → 1.4.3

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 (76) hide show
  1. package/.agents/plugins/marketplace.json +2 -2
  2. package/.claude-plugin/marketplace.json +19 -4
  3. package/.codex/config.toml +9 -2
  4. package/ARCHITECTURE.md +16 -6
  5. package/README.md +69 -24
  6. package/dist/clerk.d.ts +35 -0
  7. package/dist/clerk.js +201 -0
  8. package/dist/cli.js +1677 -103
  9. package/dist/composio-catalog.d.ts +234 -0
  10. package/dist/composio-catalog.js +1894 -0
  11. package/dist/config.d.ts +16 -0
  12. package/dist/config.js +27 -1
  13. package/dist/durable-workflow.d.ts +112 -0
  14. package/dist/durable-workflow.js +284 -0
  15. package/dist/engine.d.ts +377 -6
  16. package/dist/engine.js +1919 -94
  17. package/dist/index.d.ts +3 -0
  18. package/dist/index.js +3 -0
  19. package/dist/mcp-schema.d.ts +286 -0
  20. package/dist/mcp-schema.js +2580 -0
  21. package/dist/mcp.d.ts +2 -25
  22. package/dist/mcp.js +1008 -507
  23. package/dist/memory-graph.d.ts +45 -0
  24. package/dist/memory-graph.js +293 -0
  25. package/dist/nl.js +214 -35
  26. package/dist/oauth.d.ts +32 -0
  27. package/dist/oauth.js +134 -0
  28. package/dist/oss-suite.d.ts +217 -0
  29. package/dist/oss-suite.js +836 -0
  30. package/dist/policy.d.ts +190 -0
  31. package/dist/policy.js +1597 -0
  32. package/dist/providers/composio-instant.d.ts +4 -0
  33. package/dist/providers/composio-instant.js +890 -535
  34. package/dist/providers/composio-sdk.d.ts +126 -5
  35. package/dist/providers/composio-sdk.js +902 -79
  36. package/dist/providers/microsoft-governance.d.ts +89 -3
  37. package/dist/providers/microsoft-governance.js +673 -26
  38. package/dist/providers/stripe-billing.d.ts +42 -0
  39. package/dist/providers/stripe-billing.js +244 -5
  40. package/dist/providers/stripe-projects.d.ts +459 -4
  41. package/dist/providers/stripe-projects.js +2674 -122
  42. package/dist/providers/supermemory.d.ts +102 -6
  43. package/dist/providers/supermemory.js +609 -55
  44. package/dist/provisioning-managed.d.ts +50 -0
  45. package/dist/provisioning-managed.js +155 -0
  46. package/dist/sdk.d.ts +728 -7
  47. package/dist/sdk.js +539 -10
  48. package/dist/server.js +2744 -321
  49. package/dist/store.d.ts +138 -6
  50. package/dist/store.js +932 -58
  51. package/dist/types.d.ts +330 -4
  52. package/dist/ui/console-html.d.ts +62 -0
  53. package/dist/ui/console-html.js +3742 -2228
  54. package/dist/ui/design-tokens.d.ts +177 -0
  55. package/dist/ui/design-tokens.js +210 -0
  56. package/dist/version.d.ts +1 -0
  57. package/dist/version.js +1 -0
  58. package/package.json +6 -5
  59. package/plugins/muxo/.app.json +1 -1
  60. package/plugins/muxo/.claude-plugin/plugin.json +3 -3
  61. package/plugins/muxo/.codex-plugin/plugin.json +19 -10
  62. package/plugins/muxo/.cursor-plugin/plugin.json +30 -0
  63. package/plugins/muxo/.mcp.json +1 -33
  64. package/plugins/muxo/assets/logo.png +0 -0
  65. package/plugins/muxo/hooks/session-start.sh +16 -4
  66. package/plugins/muxo/hooks/user-prompt-submit.sh +14 -1
  67. package/plugins/muxo/mcp.json +0 -10
  68. package/plugins/muxo/plugin.json +65 -8
  69. package/plugins/muxo/skills/muxo/SKILL.md +142 -14
  70. package/plugins/muxo/skills/muxo/agents/openai.yaml +12 -0
  71. package/plugins/muxo/skills/muxo/references/cli.md +9 -3
  72. package/plugins/muxo/skills/muxo/references/mcp.md +22 -10
  73. package/plugins/muxo/skills/muxo-activity-summary/SKILL.md +81 -0
  74. package/plugins/muxo/skills/setup/SKILL.md +17 -3
  75. package/plugins/muxo/skills/setup/agents/openai.yaml +12 -0
  76. package/src/catalogues/stripe-projects-catalog.json +140 -0
package/dist/sdk.d.ts CHANGED
@@ -1,10 +1,87 @@
1
- import type { ActionPlan, ByokKeyRecord, ConnectionRecord, ExecutionReceipt, ExecutionRun, MuxoTool, ProviderLane, ProvisionedResource, RiskLevel, SupplierSettlementSummary, Workspace, WorkspaceMemoryRecord } from "./types.js";
1
+ import type { ActionPlan, ByokKeyRecord, ConnectionRecord, ExecutionReceipt, ExecutionRun, GovernancePolicy, HumanFriendlyExplanation, HumanHandoff, LlmGuidance, MemoryKnowledgeGraph, MuxoTool, ProviderLane, ProvisionedResource, RiskLevel, SupplierSettlementSummary, TeamOnboardingKit, TemporalGraphFact, Workspace, WorkspaceMemoryRecord, WorkspaceRole, WorkspaceSummary } from "./types.js";
2
+ export interface MuxoTrustScore {
3
+ overall: number;
4
+ tier: string;
5
+ reliability?: number;
6
+ consistency?: number;
7
+ }
2
8
  export interface MuxoClientOptions {
3
9
  baseUrl?: string;
4
10
  apiKey?: string | (() => string | Promise<string>);
5
11
  fetch?: typeof fetch;
6
12
  timeoutMs?: number;
7
13
  }
14
+ /** Error thrown for any non-OK Muxo API response. Carries the machine-readable code and payload. */
15
+ export declare class MuxoApiError extends Error {
16
+ readonly status: number;
17
+ readonly code?: string;
18
+ readonly url?: string;
19
+ readonly checkoutUrl?: string;
20
+ readonly data: Record<string, unknown>;
21
+ constructor(status: number, payload: Record<string, unknown>);
22
+ }
23
+ export interface BillingPlanInfo {
24
+ tier: "free" | "starter" | "pro";
25
+ name: string;
26
+ tagline: string;
27
+ monthlyActions: number;
28
+ monthlyCredits: number;
29
+ prices: {
30
+ month: {
31
+ cents: number;
32
+ label: string;
33
+ };
34
+ year: {
35
+ cents: number;
36
+ label: string;
37
+ perMonthLabel: string;
38
+ };
39
+ };
40
+ features: string[];
41
+ }
42
+ export interface PlanCatalog {
43
+ plans: BillingPlanInfo[];
44
+ yearlyDiscount: string;
45
+ creditPriceCents: number;
46
+ creditPacks: Array<{
47
+ credits: number;
48
+ cents: number;
49
+ label: string;
50
+ }>;
51
+ minCheckoutCredits: number;
52
+ }
53
+ export type UpgradePlanResult = {
54
+ ok: true;
55
+ unchanged: true;
56
+ tier: string;
57
+ message: string;
58
+ workspace?: Workspace;
59
+ } | {
60
+ ok: true;
61
+ mode: "portal";
62
+ action: "billing_portal";
63
+ tier: string;
64
+ interval: string;
65
+ portalUrl: string;
66
+ url: string;
67
+ nextStep: string;
68
+ } | {
69
+ ok: false;
70
+ code: "payment_required";
71
+ paymentRequired: true;
72
+ checkoutUrl: string;
73
+ sessionId: string;
74
+ kind: string;
75
+ tier: string;
76
+ interval: string;
77
+ credits: number;
78
+ error: string;
79
+ } | {
80
+ ok: false;
81
+ code: "human_required";
82
+ url: string;
83
+ error: string;
84
+ };
8
85
  export declare class MuxoClient {
9
86
  readonly baseUrl: string;
10
87
  private readonly apiKeyResolver?;
@@ -28,6 +105,54 @@ export declare class MuxoClient {
28
105
  governanceDid: string;
29
106
  supermemoryNamespace: string;
30
107
  }>;
108
+ static register(params: {
109
+ email: string;
110
+ password: string;
111
+ name?: string;
112
+ workspaceName?: string;
113
+ }, baseUrl?: string): Promise<{
114
+ ok: true;
115
+ user: Record<string, unknown>;
116
+ workspace: Workspace;
117
+ apiKey: string;
118
+ sessionToken: string;
119
+ token: string;
120
+ }>;
121
+ static login(params: {
122
+ email: string;
123
+ password: string;
124
+ }, baseUrl?: string): Promise<{
125
+ ok: true;
126
+ user: Record<string, unknown>;
127
+ workspace: Workspace;
128
+ apiKey: string;
129
+ sessionToken: string;
130
+ token: string;
131
+ }>;
132
+ register(params: {
133
+ email: string;
134
+ password: string;
135
+ name?: string;
136
+ workspaceName?: string;
137
+ }): Promise<{
138
+ ok: true;
139
+ user: Record<string, unknown>;
140
+ workspace: Workspace;
141
+ apiKey: string;
142
+ sessionToken: string;
143
+ token: string;
144
+ }>;
145
+ login(params: {
146
+ email: string;
147
+ password: string;
148
+ }): Promise<{
149
+ ok: true;
150
+ user: Record<string, unknown>;
151
+ workspace: Workspace;
152
+ apiKey: string;
153
+ sessionToken: string;
154
+ token: string;
155
+ }>;
31
156
  signupAgent(params: {
32
157
  agentName?: string;
33
158
  harness?: string;
@@ -65,6 +190,7 @@ export declare class MuxoClient {
65
190
  toolSlug: string;
66
191
  input: Record<string, unknown>;
67
192
  reason?: string;
193
+ fundingMode?: "muxo_funded" | "byok";
68
194
  }): Promise<{
69
195
  ok: true;
70
196
  plan: ActionPlan;
@@ -78,8 +204,31 @@ export declare class MuxoClient {
78
204
  waitTool: string;
79
205
  instructions: string;
80
206
  };
207
+ humanHandoff?: HumanHandoff;
208
+ llmGuidance?: LlmGuidance;
209
+ }>;
210
+ getPlan(planId: string, options?: {
211
+ waitForApproval?: boolean;
212
+ timeoutSeconds?: number;
213
+ }): Promise<{
214
+ ok: true;
215
+ plan: ActionPlan;
216
+ approved?: boolean;
217
+ rejected?: boolean;
218
+ timedOut?: boolean;
219
+ humanHandoff?: HumanHandoff;
220
+ llmGuidance?: LlmGuidance;
81
221
  }>;
82
- approvePlan(planId: string): Promise<{
222
+ waitForPlanApproval(planId: string, timeoutSeconds?: number): Promise<{
223
+ ok: true;
224
+ plan: ActionPlan;
225
+ approved: boolean;
226
+ rejected: boolean;
227
+ timedOut: boolean;
228
+ humanHandoff?: HumanHandoff;
229
+ llmGuidance?: LlmGuidance;
230
+ }>;
231
+ approvePlan(planId: string, decision?: "approved" | "rejected"): Promise<{
83
232
  ok: true;
84
233
  plan: ActionPlan;
85
234
  }>;
@@ -88,9 +237,19 @@ export declare class MuxoClient {
88
237
  run: ExecutionRun;
89
238
  receipt: ExecutionReceipt;
90
239
  }>;
240
+ getRun(runId: string): Promise<{
241
+ ok: true;
242
+ run: ExecutionRun;
243
+ }>;
244
+ cancelRun(runId: string, reason?: string): Promise<{
245
+ ok: true;
246
+ run: ExecutionRun;
247
+ receipt: ExecutionReceipt;
248
+ }>;
91
249
  exec(toolSlug: string, input?: Record<string, unknown>, options?: {
92
250
  reason?: string;
93
251
  approve?: boolean;
252
+ fundingMode?: "muxo_funded" | "byok";
94
253
  }): Promise<{
95
254
  ok: true;
96
255
  plan: ActionPlan;
@@ -103,7 +262,33 @@ export declare class MuxoClient {
103
262
  valid: boolean;
104
263
  verified: boolean;
105
264
  receipt: ExecutionReceipt;
265
+ agenticReceiptValid?: boolean;
266
+ explanation?: HumanFriendlyExplanation;
267
+ }>;
268
+ verifyReceiptChain(limit?: number): Promise<{
269
+ ok: boolean;
270
+ valid: boolean;
271
+ workspaceId: string;
272
+ totalChecked: number;
273
+ validCount: number;
274
+ brokenLinks: Array<{
275
+ receiptId: string;
276
+ runId: string;
277
+ reason: string;
278
+ }>;
279
+ headReceiptHash: string;
280
+ agentDid: string;
281
+ publicKeyHex: string;
282
+ explanation: HumanFriendlyExplanation;
106
283
  }>;
284
+ getMemoryGraph(queryOrOptions?: string | {
285
+ query?: string;
286
+ asOf?: string;
287
+ focalEntity?: string;
288
+ maxHops?: number;
289
+ }): Promise<{
290
+ ok: true;
291
+ } & MemoryKnowledgeGraph>;
107
292
  startConnection(paramsOrProvider: string | {
108
293
  provider: string;
109
294
  lane?: ProviderLane;
@@ -152,6 +337,11 @@ export declare class MuxoClient {
152
337
  }>;
153
338
  getBillingStatus(): Promise<{
154
339
  ok: true;
340
+ workspace?: Workspace;
341
+ creditsBalance?: number;
342
+ creditBalance?: number;
343
+ tier?: string;
344
+ byokKeys?: ByokKeyRecord[];
155
345
  settlementSummary: SupplierSettlementSummary & {
156
346
  totalCustomerChargedCredits?: number;
157
347
  };
@@ -173,11 +363,202 @@ export declare class MuxoClient {
173
363
  ok: true;
174
364
  namespace: string;
175
365
  records: WorkspaceMemoryRecord[];
366
+ recentMemories?: WorkspaceMemoryRecord[];
367
+ memories?: WorkspaceMemoryRecord[];
368
+ }>;
369
+ addMemory(paramsOrContent: string | {
370
+ title?: string;
371
+ content: string;
372
+ kind?: WorkspaceMemoryRecord["kind"];
373
+ subject?: string;
374
+ predicate?: string;
375
+ object?: string;
376
+ confidence?: number;
377
+ metadata?: Record<string, unknown>;
378
+ }): Promise<{
379
+ ok: true;
380
+ memory: WorkspaceMemoryRecord;
381
+ temporalFacts?: Array<Record<string, unknown>>;
382
+ fundingSource?: string;
383
+ }>;
384
+ deleteMemory(id: string): Promise<{
385
+ ok: true;
386
+ deleted: boolean;
387
+ record: WorkspaceMemoryRecord | null;
388
+ }>;
389
+ getMemoryFacts(options?: boolean | {
390
+ includeHistorical?: boolean;
391
+ query?: string;
392
+ subject?: string;
393
+ predicate?: string;
394
+ limit?: number;
395
+ }): Promise<{
396
+ ok: true;
397
+ activeFacts: TemporalGraphFact[];
398
+ historicalFacts: TemporalGraphFact[];
399
+ facts: TemporalGraphFact[];
400
+ }>;
401
+ listTemporalFacts(options?: Parameters<MuxoClient["getMemoryFacts"]>[0]): Promise<{
402
+ ok: true;
403
+ activeFacts: TemporalGraphFact[];
404
+ historicalFacts: TemporalGraphFact[];
405
+ facts: TemporalGraphFact[];
406
+ }>;
407
+ forgetMemory(queryOrParams: string | {
408
+ query: string;
409
+ }): Promise<{
410
+ ok: true;
411
+ query: string;
412
+ deletedLocalCount: number;
413
+ invalidatedFactsCount: number;
414
+ deletedRemoteIds: string[];
415
+ deletedMemories: WorkspaceMemoryRecord[];
416
+ invalidatedFacts: TemporalGraphFact[];
417
+ }>;
418
+ getGovernanceStatus(): Promise<{
419
+ ok: true;
420
+ governance: Record<string, unknown> & {
421
+ modules?: unknown;
422
+ trustScore?: MuxoTrustScore;
423
+ killSwitch?: Record<string, unknown> | null;
424
+ auditChain?: Record<string, unknown>;
425
+ };
426
+ workspacePolicy: GovernancePolicy;
427
+ plainEnglishGuardrails?: {
428
+ headline: string;
429
+ postureLabel: string;
430
+ rules: string[];
431
+ badges: Array<{
432
+ label: string;
433
+ tone: "safe" | "warn" | "strict";
434
+ }>;
435
+ };
436
+ activeMemoryDefaults?: Record<string, unknown>;
437
+ activeGuardrails?: string[];
438
+ }>;
439
+ getGuardrails(): Promise<{
440
+ ok: true;
441
+ workspaceId: string;
442
+ policy: GovernancePolicy;
443
+ plainEnglish: {
444
+ headline: string;
445
+ postureLabel: string;
446
+ rules: string[];
447
+ badges: Array<{
448
+ label: string;
449
+ tone: "safe" | "warn" | "strict";
450
+ }>;
451
+ };
452
+ activeDefaults: Record<string, unknown>;
453
+ activeGuardrails: string[];
454
+ }>;
455
+ setGuardrail(promptOrParams: string | {
456
+ prompt: string;
457
+ }): Promise<{
458
+ ok: true;
459
+ workspace: Workspace;
460
+ guardrail: Record<string, unknown>;
461
+ plainEnglish: {
462
+ headline: string;
463
+ postureLabel: string;
464
+ rules: string[];
465
+ badges: Array<{
466
+ label: string;
467
+ tone: "safe" | "warn" | "strict";
468
+ }>;
469
+ };
470
+ humanMessage: string;
471
+ }>;
472
+ resetGuardrails(): Promise<{
473
+ ok: true;
474
+ workspace: Workspace;
475
+ plainEnglish: {
476
+ headline: string;
477
+ postureLabel: string;
478
+ rules: string[];
479
+ badges: Array<{
480
+ label: string;
481
+ tone: "safe" | "warn" | "strict";
482
+ }>;
483
+ };
484
+ humanMessage: string;
485
+ }>;
486
+ setKillSwitch(action: "quarantine" | "terminate" | "suspend" | "resume", reason?: string): Promise<{
487
+ ok: true;
488
+ activated?: boolean;
489
+ resumed?: boolean;
490
+ killSwitch?: Record<string, unknown>;
491
+ policy: GovernancePolicy;
492
+ trustScore: MuxoTrustScore;
493
+ }>;
494
+ scanContext(contentOrParams: string | {
495
+ content: string;
496
+ sessionId?: string;
497
+ role?: "user" | "assistant" | "tool" | "system";
498
+ }): Promise<{
499
+ ok: true;
500
+ scan: {
501
+ safe: boolean;
502
+ riskLevel: "none" | "low" | "medium" | "high" | "critical";
503
+ findingsCount: number;
504
+ findings: Array<{
505
+ patternId: string;
506
+ patternName: string;
507
+ severity: string;
508
+ description: string;
509
+ }>;
510
+ integrityValid: boolean;
511
+ };
512
+ }>;
513
+ updatePolicy(policy: Partial<Omit<GovernancePolicy, "killSwitchActive" | "killSwitchReason">>): Promise<{
514
+ ok: true;
515
+ workspace: Workspace;
516
+ }>;
517
+ getPolicy(): Promise<{
518
+ ok: true;
519
+ policy: GovernancePolicy;
520
+ plainEnglish: Record<string, unknown>;
521
+ explanation?: HumanFriendlyExplanation;
522
+ activeDefaults: Record<string, unknown>;
523
+ activeGuardrails: string[];
524
+ }>;
525
+ getContext(query?: string): Promise<{
526
+ ok: true;
527
+ workspaceId: string;
528
+ workspaceSlug: string;
529
+ policy: GovernancePolicy;
530
+ plainEnglishPolicy?: Record<string, unknown>;
531
+ languageMode?: string;
532
+ customInstructions?: string[];
533
+ activeDefaults?: Record<string, unknown>;
534
+ activeGuardrails?: string[];
535
+ creditsBalance: number;
536
+ llmSystemPrompt?: string;
537
+ explanation?: HumanFriendlyExplanation;
538
+ supermemoryBrain?: Record<string, unknown>;
539
+ [key: string]: unknown;
540
+ }>;
541
+ listReceipts(limit?: number): Promise<{
542
+ ok: true;
543
+ receipts: Array<ExecutionReceipt & {
544
+ explanation?: HumanFriendlyExplanation;
545
+ }>;
546
+ total: number;
547
+ explanation?: HumanFriendlyExplanation;
548
+ }>;
549
+ remember(instruction: string): Promise<{
550
+ ok: true;
551
+ memory: WorkspaceMemoryRecord;
552
+ activeDefaults?: Record<string, unknown>;
553
+ explanation?: HumanFriendlyExplanation;
554
+ humanMessage?: string;
176
555
  }>;
177
556
  do(prompt: string, options?: {
178
557
  input?: Record<string, unknown>;
179
558
  autoApprove?: boolean;
180
559
  dryRun?: boolean;
560
+ planOnly?: boolean;
561
+ fundingMode?: "muxo_funded" | "byok";
181
562
  }): Promise<{
182
563
  ok: boolean;
183
564
  executed: boolean;
@@ -199,6 +580,8 @@ export declare class MuxoClient {
199
580
  input?: Record<string, unknown>;
200
581
  autoApprove?: boolean;
201
582
  dryRun?: boolean;
583
+ planOnly?: boolean;
584
+ fundingMode?: "muxo_funded" | "byok";
202
585
  }): Promise<{
203
586
  ok: boolean;
204
587
  executed: boolean;
@@ -232,17 +615,41 @@ export declare class MuxoClient {
232
615
  provider: string;
233
616
  keys: ByokKeyRecord[];
234
617
  }>;
235
- upgradePlan(): Promise<{
618
+ /** Lists plans, prices, and credit packs. No auth required. */
619
+ getPlans(): Promise<{
236
620
  ok: true;
237
- tier: string;
238
- workspace: Workspace;
239
- settlementSummary: SupplierSettlementSummary;
621
+ } & PlanCatalog>;
622
+ /**
623
+ * Moves the workspace to a plan. A first subscription returns a Stripe checkout URL
624
+ * (`payment_required`); changing an existing subscription returns a billing-portal URL.
625
+ * Plan changes are confirmed by a signed-in person; API keys get `human_required`.
626
+ */
627
+ upgradePlan(options?: {
628
+ tier?: "starter" | "pro";
629
+ interval?: "month" | "year";
630
+ }): Promise<UpgradePlanResult>;
631
+ /**
632
+ * Opens the Stripe billing portal to manage payment details, switch plans, or cancel.
633
+ * Signed-in people only; API keys get a `human_required` MuxoApiError.
634
+ */
635
+ openBillingPortal(): Promise<{
636
+ ok: true;
637
+ url: string;
638
+ portalUrl: string;
240
639
  }>;
241
- createCheckoutSession(kind?: "starter_subscription" | "credit_topup"): Promise<{
640
+ createCheckoutSession(kind?: "subscription" | "starter_subscription" | "credit_topup", optionsOrCredits?: number | {
641
+ credits?: number;
642
+ tier?: "starter" | "pro";
643
+ interval?: "month" | "year";
644
+ }): Promise<{
242
645
  ok: true;
243
646
  sessionId: string;
244
647
  url: string;
245
648
  mode?: string;
649
+ kind?: string;
650
+ credits?: number;
651
+ tier?: string;
652
+ interval?: string;
246
653
  }>;
247
654
  verifyCheckoutSession(sessionId: string): Promise<{
248
655
  ok: true;
@@ -250,4 +657,318 @@ export declare class MuxoClient {
250
657
  workspace: Workspace | null;
251
658
  kind: string;
252
659
  }>;
660
+ createProvisioningConnectedAccount(params?: {
661
+ contact_email?: string;
662
+ display_name?: string;
663
+ country?: string;
664
+ entity_type?: "individual" | "company";
665
+ }): Promise<{
666
+ ok: true;
667
+ apiVersion: string;
668
+ id: string;
669
+ object: "v2.core.account";
670
+ contact_email?: string;
671
+ display_name?: string;
672
+ configuration?: Record<string, unknown>;
673
+ requirements?: Record<string, unknown>;
674
+ livemode?: boolean;
675
+ }>;
676
+ getProvisioningConnectedAccount(accountId?: string): Promise<any>;
677
+ createProvisioningConnectedAccountLink(params?: {
678
+ account?: string;
679
+ type?: "account_onboarding" | "account_update";
680
+ fields?: "currently_due" | "eventually_due";
681
+ future_requirements?: "include" | "omit";
682
+ refresh_url?: string;
683
+ return_url?: string;
684
+ auto_create?: boolean;
685
+ }): Promise<{
686
+ ok: true;
687
+ apiVersion: string;
688
+ object: "v2.core.account_link";
689
+ account: string;
690
+ url: string;
691
+ expires_at?: string;
692
+ livemode?: boolean;
693
+ }>;
694
+ createProvisioningConnectedAccountSession(params?: {
695
+ account?: string;
696
+ enable_account_management?: boolean;
697
+ disable_stripe_user_authentication?: boolean;
698
+ external_account_collection?: boolean;
699
+ fields?: "currently_due" | "eventually_due";
700
+ future_requirements?: "include" | "omit";
701
+ auto_create?: boolean;
702
+ }): Promise<{
703
+ ok: true;
704
+ apiVersion: string;
705
+ object: "account_session";
706
+ account: string;
707
+ client_secret: string;
708
+ publishable_key: string | null;
709
+ embedded_component: "account-onboarding";
710
+ collection_options: {
711
+ fields: "currently_due" | "eventually_due";
712
+ future_requirements: "include" | "omit";
713
+ };
714
+ components: Record<string, unknown>;
715
+ expires_at: number;
716
+ livemode: boolean;
717
+ }>;
718
+ checkProvisioningEligibility(): Promise<{
719
+ ok: true;
720
+ apiVersion: string;
721
+ object: "v2.provisioning.eligibility";
722
+ is_eligible: boolean;
723
+ livemode: boolean;
724
+ requirements: string[];
725
+ ready?: boolean;
726
+ platform_action?: string;
727
+ source: string;
728
+ }>;
729
+ listProvisioningProviders(params?: {
730
+ catalog?: "dev" | "prod" | "testing";
731
+ limit?: number;
732
+ page?: string;
733
+ }): Promise<{
734
+ ok: true;
735
+ apiVersion: string;
736
+ object: "v2.list";
737
+ data: Array<Record<string, unknown>>;
738
+ next_page_url: string | null;
739
+ previous_page_url: string | null;
740
+ source: string;
741
+ }>;
742
+ listProvisioningServices(params?: {
743
+ catalog?: "dev" | "prod" | "testing";
744
+ provider_name?: string;
745
+ provider_id?: string;
746
+ limit?: number;
747
+ page?: string;
748
+ }): Promise<{
749
+ ok: true;
750
+ apiVersion: string;
751
+ object: "v2.list";
752
+ data: Array<Record<string, unknown>>;
753
+ next_page_url: string | null;
754
+ previous_page_url: string | null;
755
+ source: string;
756
+ }>;
757
+ getProvisioningPaymentProfile(params?: {
758
+ provider?: string;
759
+ livemode?: boolean;
760
+ }): Promise<{
761
+ ok: true;
762
+ apiVersion: string;
763
+ object: "v2.provisioning.payment_profile";
764
+ card_last4: string | null;
765
+ usage_limits: Record<string, unknown> | null;
766
+ providers: Array<Record<string, unknown>>;
767
+ payment_method_owner: string | null;
768
+ livemode: boolean;
769
+ has_payment_method?: boolean;
770
+ source: string;
771
+ }>;
772
+ createProvisioningPaymentMethodRequest(params?: {
773
+ usage_limits?: Record<string, unknown>;
774
+ livemode?: boolean;
775
+ }): Promise<Record<string, unknown>>;
776
+ listProvisioningProviderConnections(params?: {
777
+ provider?: string;
778
+ limit?: number;
779
+ page?: string;
780
+ }): Promise<{
781
+ ok: true;
782
+ apiVersion: string;
783
+ object: "list";
784
+ data: Array<Record<string, unknown>>;
785
+ has_more?: boolean;
786
+ }>;
787
+ createProvisioningProviderConnectionRequest(params: {
788
+ provider: string;
789
+ configuration?: Record<string, string>;
790
+ project?: string;
791
+ }): Promise<Record<string, unknown>>;
792
+ listProvisioningProjects(params?: {
793
+ limit?: number;
794
+ page?: string;
795
+ }): Promise<{
796
+ ok: true;
797
+ apiVersion: string;
798
+ object: "list";
799
+ data: Array<Record<string, unknown>>;
800
+ has_more?: boolean;
801
+ }>;
802
+ createProvisioningProject(params: {
803
+ name: string;
804
+ catalog?: "dev" | "prod" | "testing";
805
+ project_profile?: string;
806
+ }): Promise<Record<string, unknown>>;
807
+ listProvisioningResources(params?: {
808
+ project?: string;
809
+ provider?: string;
810
+ limit?: number;
811
+ page?: string;
812
+ }): Promise<{
813
+ ok: true;
814
+ apiVersion: string;
815
+ object: "list";
816
+ data: Array<Record<string, unknown>>;
817
+ has_more?: boolean;
818
+ }>;
819
+ createProvisioningResource(params: {
820
+ provider: string;
821
+ service_ref: string;
822
+ configuration?: Record<string, unknown>;
823
+ name?: string;
824
+ project?: string;
825
+ environment?: "dev" | "prod";
826
+ catalog?: "dev" | "prod" | "testing";
827
+ livemode?: boolean;
828
+ }): Promise<Record<string, unknown>>;
829
+ revealResourceAccessConfiguration(resourceId: string): Promise<{
830
+ ok: true;
831
+ apiVersion: string;
832
+ object: string;
833
+ resource: string;
834
+ configuration: Record<string, string>;
835
+ created: string;
836
+ expires_at?: string | null;
837
+ livemode: boolean;
838
+ source: string;
839
+ }>;
840
+ getResourceSecrets(resourceId: string): Promise<{
841
+ ok: true;
842
+ resourceId: string;
843
+ resourceName: string;
844
+ workspaceId: string;
845
+ envVarKeys: string[];
846
+ secrets: Record<string, string>;
847
+ }>;
848
+ listWorkspaces(): Promise<{
849
+ ok: true;
850
+ currentWorkspaceId: string;
851
+ workspaces: WorkspaceSummary[];
852
+ }>;
853
+ createWorkspace(params: {
854
+ name: string;
855
+ teamName?: string;
856
+ environment?: "live" | "test";
857
+ }): Promise<{
858
+ ok: true;
859
+ workspace: Workspace;
860
+ apiKey: string;
861
+ workspaces: WorkspaceSummary[];
862
+ }>;
863
+ switchWorkspace(workspaceId: string): Promise<{
864
+ ok: true;
865
+ workspace: Workspace;
866
+ workspaces: WorkspaceSummary[];
867
+ }>;
868
+ joinWorkspaceWithApiKey(apiKey: string): Promise<{
869
+ ok: true;
870
+ mode: "api_key_join";
871
+ workspace: Workspace;
872
+ apiKey: string;
873
+ sessionToken: string | null;
874
+ keyRecord: {
875
+ id: string;
876
+ name: string;
877
+ keyPrefix: string;
878
+ teamName: string | null;
879
+ role: WorkspaceRole;
880
+ environment: "live" | "test";
881
+ };
882
+ workspaces: WorkspaceSummary[];
883
+ message: string;
884
+ }>;
885
+ onboardTeam(params: {
886
+ teamName: string;
887
+ role?: WorkspaceRole;
888
+ mode?: "shared_workspace" | "dedicated_workspace";
889
+ environment?: "live" | "test";
890
+ scopes?: string[];
891
+ }): Promise<{
892
+ ok: true;
893
+ kit: TeamOnboardingKit;
894
+ workspace: Workspace;
895
+ apiKey: string;
896
+ workspaces: WorkspaceSummary[];
897
+ }>;
898
+ updateProvisioningSpendLimit(params: {
899
+ max_amount: string | number;
900
+ currency?: string;
901
+ recurring_interval?: string;
902
+ provider?: string;
903
+ }): Promise<Record<string, unknown>>;
904
+ createProvisioningEventDestination(params: {
905
+ name?: string;
906
+ url: string;
907
+ events?: string[];
908
+ }): Promise<Record<string, unknown>>;
909
+ recordBillingMeterEvent(params: {
910
+ event_name?: string;
911
+ value: number;
912
+ lane?: string;
913
+ tool_slug?: string;
914
+ identifier?: string;
915
+ }): Promise<Record<string, unknown>>;
916
+ listBillingMeterEvents(limit?: number): Promise<Record<string, unknown>>;
917
+ listToolkits(params?: {
918
+ category?: string;
919
+ search?: string;
920
+ }): Promise<Record<string, unknown>>;
921
+ createCustomAuthConfig(params: {
922
+ toolkitSlug: string;
923
+ authScheme: "OAUTH2" | "API_KEY";
924
+ scopeMode?: "read_only" | "full_access";
925
+ customScopes?: string[];
926
+ credentials?: Record<string, string>;
927
+ }): Promise<Record<string, unknown>>;
928
+ listTriggers(provider?: string): Promise<Record<string, unknown>>;
929
+ enableTrigger(params: {
930
+ triggerSlug: string;
931
+ providerSlug: string;
932
+ webhookUrl?: string;
933
+ config?: Record<string, unknown>;
934
+ }): Promise<Record<string, unknown>>;
935
+ ingestTriggerWebhook(params: {
936
+ triggerSlug: string;
937
+ providerSlug?: string;
938
+ payload: Record<string, unknown>;
939
+ }): Promise<Record<string, unknown>>;
940
+ executeBatchPlans(params: {
941
+ items: Array<{
942
+ toolSlug: string;
943
+ input: Record<string, unknown>;
944
+ reason: string;
945
+ }>;
946
+ autoApprove?: boolean;
947
+ }): Promise<Record<string, unknown>>;
948
+ searchMemoryHybrid(query: string, limit?: number): Promise<Record<string, unknown>>;
949
+ startDurableWorkflow(params: {
950
+ provider?: string;
951
+ serviceRef?: string;
952
+ region?: string;
953
+ }): Promise<Record<string, unknown>>;
954
+ advanceDurableWorkflow(workflowId: string, eventPayload?: Record<string, unknown>): Promise<Record<string, unknown>>;
955
+ exportGovernanceArchive(): Promise<Record<string, unknown>>;
956
+ getWorkflowHistory(workflowId: string): Promise<Record<string, unknown>>;
957
+ signalDurableWorkflow(workflowId: string, signalName: string, payload?: Record<string, unknown>): Promise<Record<string, unknown>>;
958
+ rollbackDurableWorkflow(workflowId: string, params?: {
959
+ reason?: string;
960
+ failedStep?: string;
961
+ }): Promise<Record<string, unknown>>;
962
+ getCedarPolicy(): Promise<Record<string, unknown>>;
963
+ evaluateCedarPolicy(params: {
964
+ toolSlug: string;
965
+ input?: Record<string, unknown>;
966
+ riskLevel?: RiskLevel;
967
+ creditCost?: number;
968
+ lane?: string;
969
+ }): Promise<Record<string, unknown>>;
970
+ getOtelTraces(limit?: number): Promise<Record<string, unknown>>;
971
+ listPlaybooks(): Promise<Record<string, unknown>>;
972
+ runPlaybook(slug: string, input?: Record<string, unknown>): Promise<Record<string, unknown>>;
973
+ getRoiAnalytics(): Promise<Record<string, unknown>>;
253
974
  }