@topolo/sdk 0.10.4 → 0.10.5

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
@@ -4208,6 +4208,7 @@ function normalizeActionCatalogEntry(item) {
4208
4208
  path,
4209
4209
  permissionName: pickActionString(a.permission_name) ?? pickActionString(a.permissionName) ?? "",
4210
4210
  requiredPermission: pickActionString(a.required_permission) ?? pickActionString(a.requiredPermission) ?? "",
4211
+ principalAccess: pickPrincipalAccess(a.principal_access ?? a.principalAccess),
4211
4212
  authorizationMode: pickAuthorizationMode(a.authorization_mode ?? a.authorizationMode),
4212
4213
  allowedServices: stringArray(a.allowed_services ?? a.allowedServices),
4213
4214
  inputSchema: plainObject(a.input_schema ?? a.inputSchema),
@@ -4224,6 +4225,9 @@ function normalizeActionCatalogEntry(item) {
4224
4225
  function isHttpMethod(value) {
4225
4226
  return value === "GET" || value === "POST" || value === "PUT" || value === "PATCH" || value === "DELETE";
4226
4227
  }
4228
+ function pickPrincipalAccess(value) {
4229
+ return value === "platform_admin" || value === "platform_super_admin" ? value : null;
4230
+ }
4227
4231
  function pickActionString(value) {
4228
4232
  return typeof value === "string" && value.trim() ? value.trim() : null;
4229
4233
  }
@@ -4476,6 +4480,7 @@ async function digestTopoloActionCatalog(actions, appId) {
4476
4480
  const allowedServices = [...action.allowedServices || []].map((service) => service.trim()).filter(Boolean).sort();
4477
4481
  return {
4478
4482
  actionId: action.actionId || `${appId}.${action.name}`,
4483
+ principalAccess: action.principalAccess ?? null,
4479
4484
  authorizationMode,
4480
4485
  allowedServices: authorizationMode === "service" || authorizationMode === "runtime" ? allowedServices : [],
4481
4486
  inputSchema: action.inputSchema,
package/dist/index.d.cts CHANGED
@@ -231,6 +231,7 @@ interface TopoloActionCatalogEntry {
231
231
  path: string;
232
232
  permissionName: string;
233
233
  requiredPermission: string;
234
+ principalAccess?: 'platform_admin' | 'platform_super_admin' | null;
234
235
  /** Static RBAC, contextual runtime policy, or an explicit public/service exception. */
235
236
  authorizationMode?: 'static' | 'runtime' | 'public' | 'service';
236
237
  allowedServices?: string[];
@@ -858,6 +859,7 @@ interface TopoloActionDigestInput {
858
859
  path: string;
859
860
  permission?: string | null;
860
861
  permissionName?: string | null;
862
+ principalAccess?: 'platform_admin' | 'platform_super_admin' | null;
861
863
  authorizationMode?: string | null;
862
864
  allowedServices?: string[] | null;
863
865
  target?: string | null;
package/dist/index.d.ts CHANGED
@@ -231,6 +231,7 @@ interface TopoloActionCatalogEntry {
231
231
  path: string;
232
232
  permissionName: string;
233
233
  requiredPermission: string;
234
+ principalAccess?: 'platform_admin' | 'platform_super_admin' | null;
234
235
  /** Static RBAC, contextual runtime policy, or an explicit public/service exception. */
235
236
  authorizationMode?: 'static' | 'runtime' | 'public' | 'service';
236
237
  allowedServices?: string[];
@@ -858,6 +859,7 @@ interface TopoloActionDigestInput {
858
859
  path: string;
859
860
  permission?: string | null;
860
861
  permissionName?: string | null;
862
+ principalAccess?: 'platform_admin' | 'platform_super_admin' | null;
861
863
  authorizationMode?: string | null;
862
864
  allowedServices?: string[] | null;
863
865
  target?: string | null;
package/dist/index.js CHANGED
@@ -4118,6 +4118,7 @@ function normalizeActionCatalogEntry(item) {
4118
4118
  path,
4119
4119
  permissionName: pickActionString(a.permission_name) ?? pickActionString(a.permissionName) ?? "",
4120
4120
  requiredPermission: pickActionString(a.required_permission) ?? pickActionString(a.requiredPermission) ?? "",
4121
+ principalAccess: pickPrincipalAccess(a.principal_access ?? a.principalAccess),
4121
4122
  authorizationMode: pickAuthorizationMode(a.authorization_mode ?? a.authorizationMode),
4122
4123
  allowedServices: stringArray(a.allowed_services ?? a.allowedServices),
4123
4124
  inputSchema: plainObject(a.input_schema ?? a.inputSchema),
@@ -4134,6 +4135,9 @@ function normalizeActionCatalogEntry(item) {
4134
4135
  function isHttpMethod(value) {
4135
4136
  return value === "GET" || value === "POST" || value === "PUT" || value === "PATCH" || value === "DELETE";
4136
4137
  }
4138
+ function pickPrincipalAccess(value) {
4139
+ return value === "platform_admin" || value === "platform_super_admin" ? value : null;
4140
+ }
4137
4141
  function pickActionString(value) {
4138
4142
  return typeof value === "string" && value.trim() ? value.trim() : null;
4139
4143
  }
@@ -4386,6 +4390,7 @@ async function digestTopoloActionCatalog(actions, appId) {
4386
4390
  const allowedServices = [...action.allowedServices || []].map((service) => service.trim()).filter(Boolean).sort();
4387
4391
  return {
4388
4392
  actionId: action.actionId || `${appId}.${action.name}`,
4393
+ principalAccess: action.principalAccess ?? null,
4389
4394
  authorizationMode,
4390
4395
  allowedServices: authorizationMode === "service" || authorizationMode === "runtime" ? allowedServices : [],
4391
4396
  inputSchema: action.inputSchema,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@topolo/sdk",
3
- "version": "0.10.4",
4
- "topoloPublishedVersion": "0.10.4",
3
+ "version": "0.10.5",
4
+ "topoloPublishedVersion": "0.10.5",
5
5
  "description": "Typed client SDK for the Topolo platform. Used by TopoloCli, TopoloMCP, and third-party agents.",
6
6
  "type": "module",
7
7
  "main": "./dist/index.js",