@agentium/admin

中文文档
4.11.0发布于 2026/10/24MITTypeScriptESM + CJS零依赖近 30 天下载 1850

Admin CRUD API for dynamically creating, updating, and deleting Agentium agents, teams, and workflows at runtime

原始使用文档
文档目录8 节
  1. Install
  2. Quick Start
  3. Endpoints
  4. Socket.IO Gateway
  5. Documentation
  6. Community
  7. License
  8. Provider configuration privacy

@agentium/admin

Admin CRUD API for dynamically creating, updating, and deleting Agentium agents, teams, and workflows at runtime — backed by the same global Registry used by @agentium/transport.

Install

npm install @agentium/admin express

Quick Start

import express from "express";
import { InMemoryStorage } from "@agentium/core";
import { createAdminRouter } from "@agentium/admin";

const app = express();
app.use(express.json());

const { router, hydrate } = createAdminRouter({
  storage: new InMemoryStorage(),
  // Optional: pre-baked toolkits & raw tools that admin-created agents can reference by name
  toolkits: [],
  toolLibrary: {},
});

// Restore previously persisted agents / teams / workflows / toolkit configs.
await hydrate();

app.use("/admin", router);
app.listen(4000);

Endpoints

The router exposes REST CRUD over the live registry. Entities are persisted to the supplied storage driver and rehydrated by hydrate() on startup.

MethodPathDescription
POST/agentsCreate an agent from a blueprint
GET/agentsList all admin-created agents
GET/agents/:nameInspect one agent
PUT/agents/:nameReplace an agent
DELETE/agents/:nameRemove from registry + storage
POST/teams · GET /teams · GET/PUT/DELETE /teams/:nameTeam CRUD
POST/workflows · GET /workflows · GET/PUT/DELETE /workflows/:nameWorkflow CRUD
POST/toolkitsRegister a toolkit config (e.g. GitHub, Slack) with credentials
GET/toolkitsList configured toolkits (credentials masked)
DELETE/toolkits/:nameDeactivate a toolkit
GET/toolsList every tool currently available (from toolkits + static library + dynamic configs)

Socket.IO Gateway

For real-time admin UIs:

import { Server } from "socket.io";
import { createAdminGateway } from "@agentium/admin";

const io = new Server(httpServer);
createAdminGateway({ io, storage });

Documentation

Full docs at docs.agentium.in

Community

Join the conversation on Discord.

License

MIT

Provider configuration privacy

Agent and Team providerConfig is write-only through public CRUD responses and Socket.IO acknowledgements/broadcasts. The entire object is omitted, including custom provider fields. Updates may supply new configuration; omitting it preserves the private stored configuration for hydration. The host must protect the backing ConfigStore and its backups; this change does not encrypt them or authorize standalone admin routes.

Agent and Team creation/update prepare the replacement without registering it, persist its blueprint, then register it. Invalid configuration or a failed storage write leaves the previous live entity available. Concurrent admin writers still require host-level serialization when backed by shared storage.

版本与发布记录

@agentium/admin 共发布 40 个版本,首次发布于 2026/05/22;过去 12 个月发布了 40 个版本。

版本发布日期距今
4.11.0latest2026/10/2415 天前
4.10.02026/10/2415 天前
4.9.02026/10/1326 天前
4.8.32026/10/1227 天前
4.8.22026/10/1029 天前
4.8.12026/10/1029 天前

关于 @agentium/admin 的常见问题

@agentium/admin 是什么?

Admin CRUD API for dynamically creating, updating, and deleting Agentium agents, teams, and workflows at runtime

如何安装 @agentium/admin?

在项目目录运行 npm install @agentium/admin,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:@agentium/core(^4.11.0)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@agentium/admin 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@agentium/admin 支持 ESM 还是 CommonJS?

同时提供 ES Module 与 CommonJS 入口,import 和 require() 都可以使用,打包工具会自动选择合适的版本。

@agentium/admin 需要什么版本的 Node.js?

package.json 的 engines 字段要求 Node.js ^22.18.0 || ^24.11.0。版本不符时 npm 默认只给出警告,开启 engine-strict 后会拒绝安装。

@agentium/admin 可以商用吗?

@agentium/admin 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@agentium/admin 的下载量有多少?

根据 npm 官方下载统计,@agentium/admin 在 2026/10/05 – 2026/11/03 这 30 天内被下载 1,850 次,日均约 62 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@agentium/admin 还在维护吗?

最新版本 4.11.0 发布于 2026/10/24(15 天前);至今共发布 40 个版本,其中过去 12 个月发布了 40 个;首次发布于 2026/05/22。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。