@personaai/runtime 0.11.0 → 0.13.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.
package/README.md CHANGED
@@ -427,7 +427,7 @@ genuine unclosed gap or an intentional package boundary, not an oversight:
427
427
  per mount; anything finer belongs in `resolveUser` or a hook, not the runtime.
428
428
  - Framework adapters beyond the shipped ones (`@personaai/node`, `@personaai/fastify`,
429
429
  `@personaai/hono`) — **by design**, not a gap: this package is the foundation they're meant to
430
- wrap, not a replacement for them. `@personaai/adapters` (unified `express`/`nextjs`/`nestjs` via subpaths, Wave 3) has shipped — legacy names `@personaai/nextjs`/`@personaai/express`/`@personaai/nestjs` are deprecated shims.
430
+ wrap, not a replacement for them. `@personaai/adapters` (unified `express`/`nextjs`/`nestjs` via subpaths, Wave 3) has shipped — the legacy standalone `@personaai/nextjs`/`@personaai/express`/`@personaai/nestjs` packages were removed from the repo (2026-09-14); their last-published versions are frozen and deprecated on the registry.
431
431
 
432
432
  ## Roadmap
433
433
 
@@ -0,0 +1 @@
1
+ TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false.
package/dist/index.cjs CHANGED
@@ -857,6 +857,27 @@ var resetThread = async (_request, ctx) => {
857
857
  const thread = await ctx.client.threads.reset(requireParam(ctx.params, "id"));
858
858
  return json(200, thread);
859
859
  };
860
+ var listThreadFiles = async (_request, ctx) => {
861
+ const files = await ctx.client.threads.listFiles(requireParam(ctx.params, "id"));
862
+ return json(200, files);
863
+ };
864
+ var getThreadFile = async (request, ctx) => {
865
+ const path = requireQueryParam(request.query, "path");
866
+ const file = await ctx.client.threads.getFile(requireParam(ctx.params, "id"), path);
867
+ return json(200, file);
868
+ };
869
+ var writeThreadFile = async (request, ctx) => {
870
+ const body = requireBodyObject(request.body);
871
+ const path = requireStringField(body, "path");
872
+ const content = requireStringField(body, "content");
873
+ const file = await ctx.client.threads.writeFile(requireParam(ctx.params, "id"), path, content);
874
+ return json(200, file);
875
+ };
876
+ var deleteThreadFile = async (request, ctx) => {
877
+ const path = requireQueryParam(request.query, "path");
878
+ await ctx.client.threads.deleteFile(requireParam(ctx.params, "id"), path);
879
+ return noContent();
880
+ };
860
881
 
861
882
  // src/routes/voice.ts
862
883
  var createVoiceSession = async (request, ctx) => {
@@ -1382,6 +1403,57 @@ var deleteStoreFile = async (request, ctx) => {
1382
1403
  return noContent();
1383
1404
  };
1384
1405
 
1406
+ // src/routes/rcpSources.ts
1407
+ var listRcpSources = async (request, ctx) => {
1408
+ const items = await ctx.client.rcpSources.list({
1409
+ page: toInt(request.query.page),
1410
+ limit: toInt(request.query.limit),
1411
+ search: request.query.search
1412
+ });
1413
+ return json(200, items);
1414
+ };
1415
+ var createRcpSource = async (request, ctx) => {
1416
+ const body = requireBodyObject(request.body);
1417
+ const input = {
1418
+ name: requireStringField(body, "name"),
1419
+ url: requireStringField(body, "url"),
1420
+ description: typeof body.description === "string" ? body.description : void 0,
1421
+ authType: body.authType,
1422
+ secretRef: typeof body.secretRef === "string" ? body.secretRef : void 0,
1423
+ isEnabled: typeof body.isEnabled === "boolean" ? body.isEnabled : void 0,
1424
+ paramContextMap: Array.isArray(body.paramContextMap) ? body.paramContextMap : void 0
1425
+ };
1426
+ const source = await ctx.client.rcpSources.create(input);
1427
+ return json(201, source);
1428
+ };
1429
+ var getRcpSource = async (_request, ctx) => {
1430
+ const source = await ctx.client.rcpSources.get(requireParam(ctx.params, "id"));
1431
+ return json(200, source);
1432
+ };
1433
+ var updateRcpSource = async (request, ctx) => {
1434
+ const body = request.body ?? {};
1435
+ const source = await ctx.client.rcpSources.update(requireParam(ctx.params, "id"), body);
1436
+ return json(200, source);
1437
+ };
1438
+ var deleteRcpSource = async (_request, ctx) => {
1439
+ await ctx.client.rcpSources.delete(requireParam(ctx.params, "id"));
1440
+ return noContent();
1441
+ };
1442
+ var bulkDeleteRcpSources = async (request, ctx) => {
1443
+ const body = requireBodyObject(request.body);
1444
+ const ids = Array.isArray(body.ids) ? body.ids : [];
1445
+ const result = await ctx.client.rcpSources.bulkDelete(ids);
1446
+ return json(200, result);
1447
+ };
1448
+ var getRcpSourceUsage = async (_request, ctx) => {
1449
+ const usage = await ctx.client.rcpSources.getUsage(requireParam(ctx.params, "id"));
1450
+ return json(200, usage);
1451
+ };
1452
+ var testRcpSourceConnection = async (_request, ctx) => {
1453
+ const result = await ctx.client.rcpSources.testConnection(requireParam(ctx.params, "id"));
1454
+ return json(200, result);
1455
+ };
1456
+
1385
1457
  // src/routes/auditLogs.ts
1386
1458
  var listAuditLogs = async (request, ctx) => {
1387
1459
  const items = await ctx.client.auditLogs.list({
@@ -1553,6 +1625,7 @@ function resolveCapabilities(capabilities) {
1553
1625
  skills: capabilities?.skills ?? false,
1554
1626
  knowledge: capabilities?.knowledge ?? false,
1555
1627
  stores: capabilities?.stores ?? false,
1628
+ rcpSources: capabilities?.rcpSources ?? false,
1556
1629
  auditLogs: capabilities?.auditLogs ?? false,
1557
1630
  architect: capabilities?.architect ?? false,
1558
1631
  workflowsWrite: capabilities?.workflowsWrite ?? false
@@ -1573,6 +1646,10 @@ function buildRoutes(capabilities) {
1573
1646
  { method: "DELETE", pattern: ["threads", ":id"], handler: deleteThread },
1574
1647
  { method: "GET", pattern: ["threads", ":id", "messages"], handler: getThreadMessages },
1575
1648
  { method: "POST", pattern: ["threads", ":id", "reset"], handler: resetThread },
1649
+ { method: "GET", pattern: ["threads", ":id", "files"], handler: listThreadFiles },
1650
+ { method: "GET", pattern: ["threads", ":id", "file"], handler: getThreadFile },
1651
+ { method: "PUT", pattern: ["threads", ":id", "file"], handler: writeThreadFile },
1652
+ { method: "DELETE", pattern: ["threads", ":id", "file"], handler: deleteThreadFile },
1576
1653
  // Voice — always on, end-user-scoped real-time voice sessions
1577
1654
  // (powered by Gemini Live). Mints a ticket only; the host's own
1578
1655
  // frontend opens the WebSocket directly, this runtime never proxies it.
@@ -1731,6 +1808,18 @@ function buildRoutes(capabilities) {
1731
1808
  { method: "DELETE", pattern: ["stores", ":id", "file"], handler: deleteStoreFile }
1732
1809
  );
1733
1810
  }
1811
+ if (capabilities.rcpSources) {
1812
+ routes.push(
1813
+ { method: "GET", pattern: ["rcp-sources"], handler: listRcpSources },
1814
+ { method: "POST", pattern: ["rcp-sources"], handler: createRcpSource },
1815
+ { method: "POST", pattern: ["rcp-sources", "bulk-delete"], handler: bulkDeleteRcpSources },
1816
+ { method: "GET", pattern: ["rcp-sources", ":id"], handler: getRcpSource },
1817
+ { method: "PATCH", pattern: ["rcp-sources", ":id"], handler: updateRcpSource },
1818
+ { method: "DELETE", pattern: ["rcp-sources", ":id"], handler: deleteRcpSource },
1819
+ { method: "GET", pattern: ["rcp-sources", ":id", "usage"], handler: getRcpSourceUsage },
1820
+ { method: "POST", pattern: ["rcp-sources", ":id", "test"], handler: testRcpSourceConnection }
1821
+ );
1822
+ }
1734
1823
  if (capabilities.auditLogs) {
1735
1824
  routes.push({ method: "GET", pattern: ["audit-logs"], handler: listAuditLogs });
1736
1825
  }