@agentium/transport 2.7.0 → 3.0.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.
package/dist/index.cjs CHANGED
@@ -396,7 +396,7 @@ function handleTasksCancel(res, body, store) {
396
396
 
397
397
  // src/express/admin-router.ts
398
398
  var import_node_module2 = require("module");
399
- var import_core2 = require("@agentium/core");
399
+ var import_toolkits = require("@agentium/core/toolkits");
400
400
 
401
401
  // src/express/mcp-manager.ts
402
402
  var import_core = require("@agentium/core");
@@ -635,16 +635,16 @@ function createAdminRouter(opts) {
635
635
  }
636
636
  });
637
637
  router.get("/toolkits", (_req, res) => {
638
- res.json(import_core2.toolkitCatalog.list());
638
+ res.json(import_toolkits.toolkitCatalog.list());
639
639
  });
640
640
  router.get("/toolkits/:id", (req, res) => {
641
- const meta = import_core2.toolkitCatalog.get(req.params.id);
641
+ const meta = import_toolkits.toolkitCatalog.get(req.params.id);
642
642
  if (!meta) return res.status(404).json({ error: `Toolkit "${req.params.id}" not found` });
643
643
  res.json(meta);
644
644
  });
645
645
  router.post("/toolkits/:id", (req, res) => {
646
646
  try {
647
- const toolkit = import_core2.toolkitCatalog.create(req.params.id, req.body ?? {});
647
+ const toolkit = import_toolkits.toolkitCatalog.create(req.params.id, req.body ?? {});
648
648
  const tools = toolkit.getTools().map((t) => ({
649
649
  name: t.name,
650
650
  description: t.description
@@ -978,7 +978,7 @@ function routeMatches(actual, pattern) {
978
978
 
979
979
  // src/express/router-factory.ts
980
980
  var import_node_module7 = require("module");
981
- var import_core3 = require("@agentium/core");
981
+ var import_core2 = require("@agentium/core");
982
982
 
983
983
  // src/express/swagger.ts
984
984
  var import_node_module6 = require("module");
@@ -1586,7 +1586,7 @@ function extractApiKey(req, agent) {
1586
1586
  }
1587
1587
  function createAgentRouter(opts) {
1588
1588
  if (opts.serve?.length) {
1589
- const discovered = (0, import_core3.classifyServables)(opts.serve);
1589
+ const discovered = (0, import_core2.classifyServables)(opts.serve);
1590
1590
  opts = {
1591
1591
  ...opts,
1592
1592
  agents: { ...discovered.agents, ...opts.agents },
@@ -1594,7 +1594,7 @@ function createAgentRouter(opts) {
1594
1594
  workflows: { ...discovered.workflows, ...opts.workflows }
1595
1595
  };
1596
1596
  }
1597
- const reg = opts.registry === false ? null : opts.registry ?? import_core3.registry;
1597
+ const reg = opts.registry === false ? null : opts.registry ?? import_core2.registry;
1598
1598
  let express;
1599
1599
  try {
1600
1600
  express = _require7("express");
@@ -2123,11 +2123,11 @@ function createAgentRouter(opts) {
2123
2123
  });
2124
2124
  router.use("/admin", adminRouter);
2125
2125
  }
2126
- const fromToolkits = opts.toolkits ? (0, import_core3.collectToolkitTools)(opts.toolkits) : {};
2126
+ const fromToolkits = opts.toolkits ? (0, import_core2.collectToolkitTools)(opts.toolkits) : {};
2127
2127
  const mergedTools = { ...fromToolkits, ...opts.toolLibrary ?? {} };
2128
2128
  if (Object.keys(mergedTools).length > 0) {
2129
2129
  router.get("/tools", (_req, res) => {
2130
- res.json((0, import_core3.describeToolLibrary)(mergedTools));
2130
+ res.json((0, import_core2.describeToolLibrary)(mergedTools));
2131
2131
  });
2132
2132
  router.get("/tools/:name", (req, res) => {
2133
2133
  const tool = mergedTools[req.params.name];
@@ -2393,7 +2393,7 @@ function createBrowserGateway(opts) {
2393
2393
  }
2394
2394
 
2395
2395
  // src/socketio/gateway.ts
2396
- var import_core4 = require("@agentium/core");
2396
+ var import_core3 = require("@agentium/core");
2397
2397
  function createSocketRateLimiter(maxPerMinute = 60) {
2398
2398
  return () => {
2399
2399
  let count = 0;
@@ -2411,14 +2411,14 @@ function createSocketRateLimiter(maxPerMinute = 60) {
2411
2411
  }
2412
2412
  function createAgentGateway(opts) {
2413
2413
  if (opts.serve?.length) {
2414
- const discovered = (0, import_core4.classifyServables)(opts.serve);
2414
+ const discovered = (0, import_core3.classifyServables)(opts.serve);
2415
2415
  opts = {
2416
2416
  ...opts,
2417
2417
  agents: { ...discovered.agents, ...opts.agents },
2418
2418
  teams: { ...discovered.teams, ...opts.teams }
2419
2419
  };
2420
2420
  }
2421
- const reg = opts.registry === false ? null : opts.registry ?? import_core4.registry;
2421
+ const reg = opts.registry === false ? null : opts.registry ?? import_core3.registry;
2422
2422
  const ns = opts.io.of(opts.namespace ?? "/agentium");
2423
2423
  if (opts.authMiddleware) {
2424
2424
  ns.use(opts.authMiddleware);
@@ -2508,10 +2508,10 @@ function createAgentGateway(opts) {
2508
2508
  });
2509
2509
  }
2510
2510
  });
2511
- const fromToolkits = opts.toolkits ? (0, import_core4.collectToolkitTools)(opts.toolkits) : {};
2511
+ const fromToolkits = opts.toolkits ? (0, import_core3.collectToolkitTools)(opts.toolkits) : {};
2512
2512
  const mergedTools = { ...fromToolkits, ...opts.toolLibrary ?? {} };
2513
2513
  socket.on("tools.list", (_data, ack) => {
2514
- ack?.((0, import_core4.describeToolLibrary)(mergedTools));
2514
+ ack?.((0, import_core3.describeToolLibrary)(mergedTools));
2515
2515
  });
2516
2516
  socket.on("tools.get", (data, ack) => {
2517
2517
  const tool = mergedTools[data?.name];
package/dist/index.js CHANGED
@@ -343,7 +343,7 @@ function handleTasksCancel(res, body, store) {
343
343
 
344
344
  // src/express/admin-router.ts
345
345
  import { createRequire as createRequire2 } from "module";
346
- import { toolkitCatalog } from "@agentium/core";
346
+ import { toolkitCatalog } from "@agentium/core/toolkits";
347
347
 
348
348
  // src/express/mcp-manager.ts
349
349
  import { MCPToolProvider } from "@agentium/core";
package/package.json CHANGED
@@ -1,8 +1,11 @@
1
1
  {
2
2
  "name": "@agentium/transport",
3
- "version": "2.7.0",
3
+ "version": "3.0.1",
4
4
  "description": "HTTP and WebSocket transport layer for Agentium agents",
5
5
  "license": "MIT",
6
+ "publishConfig": {
7
+ "access": "public"
8
+ },
6
9
  "repository": {
7
10
  "type": "git",
8
11
  "url": "https://github.com/agentiumOS/agentium.git",
@@ -42,7 +45,7 @@
42
45
  "typescript": "^5.6.0"
43
46
  },
44
47
  "peerDependencies": {
45
- "@agentium/core": "^2.7.0",
48
+ "@agentium/core": "^3.0.1",
46
49
  "@types/express": "^4.0.0 || ^5.0.0",
47
50
  "express": "^4.0.0 || ^5.0.0",
48
51
  "multer": ">=2.0.0",