@loomcycle/client 0.13.0 → 0.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -492,6 +492,36 @@ class LoomcycleClient {
492
492
  async a2aAgentDef(input, opts) {
493
493
  return (0, fetch_helpers_js_1.postJSON)(this.ctx, "/v1/_a2aagentdef", input, opts);
494
494
  }
495
+ /** Invoke the v1.x RFC H WebhookDef substrate tool over HTTP.
496
+ * Author + fork + retire inbound webhook definitions at runtime.
497
+ * Mirror of {@link LoomcycleClient.a2aAgentDef} for inbound webhooks.
498
+ *
499
+ * Operator-admin-only: this endpoint requires the bearer token.
500
+ *
501
+ * Op-discriminated input: `{op: "create" | "fork" | "get" |
502
+ * "list" | "retire", ...}`.
503
+ *
504
+ * Raises {@link SubstrateToolRefusedError} on tool-level refusals;
505
+ * {@link InvalidArgumentError} on 400 (malformed JSON);
506
+ * {@link AuthError} on 401. */
507
+ async webhookDef(input, opts) {
508
+ return (0, fetch_helpers_js_1.postJSON)(this.ctx, "/v1/_webhookdef", input, opts);
509
+ }
510
+ /** Invoke the RFC I MR-3a MemoryBackendDef substrate tool over HTTP.
511
+ * Author + fork + retire named memory backend definitions at runtime.
512
+ * Mirror of {@link LoomcycleClient.webhookDef} for memory backends.
513
+ *
514
+ * Operator-admin-only: this endpoint requires the bearer token.
515
+ *
516
+ * Op-discriminated input: `{op: "create" | "fork" | "get" |
517
+ * "list" | "retire", ...}`.
518
+ *
519
+ * Raises {@link SubstrateToolRefusedError} on tool-level refusals;
520
+ * {@link InvalidArgumentError} on 400 (malformed JSON);
521
+ * {@link AuthError} on 401. */
522
+ async memoryBackendDef(input, opts) {
523
+ return (0, fetch_helpers_js_1.postJSON)(this.ctx, "/v1/_memorybackenddef", input, opts);
524
+ }
495
525
  // ---- v0.10.3 Library v2 enumeration (read-only, merged yaml+substrate) ----
496
526
  /** List every agent the runtime knows about — yaml-static + dynamic
497
527
  * AgentDefs merged into one envelope per name. Each entry carries
package/dist/client.d.ts CHANGED
@@ -351,6 +351,36 @@ export declare class LoomcycleClient {
351
351
  a2aAgentDef(input: SubstrateToolInput, opts?: {
352
352
  signal?: AbortSignal;
353
353
  }): Promise<SubstrateToolResponse>;
354
+ /** Invoke the v1.x RFC H WebhookDef substrate tool over HTTP.
355
+ * Author + fork + retire inbound webhook definitions at runtime.
356
+ * Mirror of {@link LoomcycleClient.a2aAgentDef} for inbound webhooks.
357
+ *
358
+ * Operator-admin-only: this endpoint requires the bearer token.
359
+ *
360
+ * Op-discriminated input: `{op: "create" | "fork" | "get" |
361
+ * "list" | "retire", ...}`.
362
+ *
363
+ * Raises {@link SubstrateToolRefusedError} on tool-level refusals;
364
+ * {@link InvalidArgumentError} on 400 (malformed JSON);
365
+ * {@link AuthError} on 401. */
366
+ webhookDef(input: SubstrateToolInput, opts?: {
367
+ signal?: AbortSignal;
368
+ }): Promise<SubstrateToolResponse>;
369
+ /** Invoke the RFC I MR-3a MemoryBackendDef substrate tool over HTTP.
370
+ * Author + fork + retire named memory backend definitions at runtime.
371
+ * Mirror of {@link LoomcycleClient.webhookDef} for memory backends.
372
+ *
373
+ * Operator-admin-only: this endpoint requires the bearer token.
374
+ *
375
+ * Op-discriminated input: `{op: "create" | "fork" | "get" |
376
+ * "list" | "retire", ...}`.
377
+ *
378
+ * Raises {@link SubstrateToolRefusedError} on tool-level refusals;
379
+ * {@link InvalidArgumentError} on 400 (malformed JSON);
380
+ * {@link AuthError} on 401. */
381
+ memoryBackendDef(input: SubstrateToolInput, opts?: {
382
+ signal?: AbortSignal;
383
+ }): Promise<SubstrateToolResponse>;
354
384
  /** List every agent the runtime knows about — yaml-static + dynamic
355
385
  * AgentDefs merged into one envelope per name. Each entry carries
356
386
  * `source: "static-only" | "dynamic-only" | "both"` so callers can
package/dist/client.js CHANGED
@@ -489,6 +489,36 @@ export class LoomcycleClient {
489
489
  async a2aAgentDef(input, opts) {
490
490
  return postJSON(this.ctx, "/v1/_a2aagentdef", input, opts);
491
491
  }
492
+ /** Invoke the v1.x RFC H WebhookDef substrate tool over HTTP.
493
+ * Author + fork + retire inbound webhook definitions at runtime.
494
+ * Mirror of {@link LoomcycleClient.a2aAgentDef} for inbound webhooks.
495
+ *
496
+ * Operator-admin-only: this endpoint requires the bearer token.
497
+ *
498
+ * Op-discriminated input: `{op: "create" | "fork" | "get" |
499
+ * "list" | "retire", ...}`.
500
+ *
501
+ * Raises {@link SubstrateToolRefusedError} on tool-level refusals;
502
+ * {@link InvalidArgumentError} on 400 (malformed JSON);
503
+ * {@link AuthError} on 401. */
504
+ async webhookDef(input, opts) {
505
+ return postJSON(this.ctx, "/v1/_webhookdef", input, opts);
506
+ }
507
+ /** Invoke the RFC I MR-3a MemoryBackendDef substrate tool over HTTP.
508
+ * Author + fork + retire named memory backend definitions at runtime.
509
+ * Mirror of {@link LoomcycleClient.webhookDef} for memory backends.
510
+ *
511
+ * Operator-admin-only: this endpoint requires the bearer token.
512
+ *
513
+ * Op-discriminated input: `{op: "create" | "fork" | "get" |
514
+ * "list" | "retire", ...}`.
515
+ *
516
+ * Raises {@link SubstrateToolRefusedError} on tool-level refusals;
517
+ * {@link InvalidArgumentError} on 400 (malformed JSON);
518
+ * {@link AuthError} on 401. */
519
+ async memoryBackendDef(input, opts) {
520
+ return postJSON(this.ctx, "/v1/_memorybackenddef", input, opts);
521
+ }
492
522
  // ---- v0.10.3 Library v2 enumeration (read-only, merged yaml+substrate) ----
493
523
  /** List every agent the runtime knows about — yaml-static + dynamic
494
524
  * AgentDefs merged into one envelope per name. Each entry carries
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loomcycle/client",
3
- "version": "0.13.0",
3
+ "version": "0.15.0",
4
4
  "description": "TypeScript client for the loomcycle sidecar (HTTP+SSE). 46 methods covering run streaming, agent metadata, pause/resume/state, snapshot lifecycle, memory admin (incl. v0.9.0 Vector Memory embed_stats + reembed AND v0.11.5 setMemoryEntry + deleteMemoryEntry), interruption resolve, hook management, v0.8.22 substrate admin (agentDef + skillDef), v0.9.x n8n Phase 0 (listChannels + streamUserRunStates), v0.9.x Channel CRUD (publishChannel + subscribeChannel + peekChannel + ackChannel), v0.11.5 Channel admin CRUD (createChannel + updateChannel + deleteChannel — runtime substrate; yaml channels refuse mutation with HTTP 409), v0.9.x content_sha256 verify, v0.9.1 transcript first-cycle, v0.9.x dynamic MCP server registration (mcpServerDef + MCPServerDefVerifyResult), v0.10.3 Library v2 enumeration (listLibraryAgents + listLibrarySkills + listLibraryMcpServers), and v0.11.0 LLM Gateway (llmChat + llmStream — direct provider routing without agent overhead; primary target is n8n's LoomCycleChatModel AI Agent sub-node and any LangChain-compatible consumer). v0.10.1 — dual ESM + CommonJS distribution (additive — ESM consumers unchanged; CJS consumers like n8n's community-node loader now work).",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",