@burdenoff/mcp-libs 2026.1014.1 → 2026.1014.3
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.
|
@@ -597,15 +597,19 @@ var UPDATE_CURRENT_USER_PROFILE = `
|
|
|
597
597
|
var AUTH_AUDIT_LOGS = `
|
|
598
598
|
query authAuditLogs($pagination: PaginationInput) {
|
|
599
599
|
authAuditLogs(pagination: $pagination) {
|
|
600
|
-
|
|
601
|
-
|
|
600
|
+
auditLogs {
|
|
601
|
+
id action resource resourceType resourceId description
|
|
602
|
+
ipAddress userAgent metadata createdAt
|
|
603
|
+
}
|
|
604
|
+
hasMore totalCount
|
|
602
605
|
}
|
|
603
606
|
}
|
|
604
607
|
`;
|
|
605
608
|
var ACTIVE_SESSIONS = `
|
|
606
609
|
query activeSessions($pagination: PaginationInput) {
|
|
607
610
|
activeSessions(pagination: $pagination) {
|
|
608
|
-
id status ipAddress userAgent location lastActivityAt expiresAt createdAt isCurrent
|
|
611
|
+
sessions { id status ipAddress userAgent location lastActivityAt expiresAt createdAt isCurrent }
|
|
612
|
+
hasMore totalCount
|
|
609
613
|
}
|
|
610
614
|
}
|
|
611
615
|
`;
|
|
@@ -1068,7 +1072,11 @@ function registerAuthExtraTools(server, ctx, track) {
|
|
|
1068
1072
|
const d = await ctx.gql.global.request(ACTIVE_SESSIONS, {
|
|
1069
1073
|
pagination: { limit: limit ?? 50, offset: offset ?? 0 }
|
|
1070
1074
|
});
|
|
1071
|
-
return jsonResult({
|
|
1075
|
+
return jsonResult({
|
|
1076
|
+
sessions: d.activeSessions.sessions,
|
|
1077
|
+
total: d.activeSessions.totalCount,
|
|
1078
|
+
hasMore: d.activeSessions.hasMore
|
|
1079
|
+
});
|
|
1072
1080
|
} catch (e) {
|
|
1073
1081
|
return err2(ctx, "auth_sessions_list", "Failed to list sessions", e);
|
|
1074
1082
|
}
|
|
@@ -1211,7 +1219,7 @@ function registerAuthExtraTools(server, ctx, track) {
|
|
|
1211
1219
|
inputSchema: {
|
|
1212
1220
|
name: zod.z.string().describe("Friendly name for the key"),
|
|
1213
1221
|
appId: zod.z.string().describe("Owning app id"),
|
|
1214
|
-
scopes: zod.z.array(zod.z.string()).
|
|
1222
|
+
scopes: zod.z.array(zod.z.string()).min(1).describe("Scope strings (required)"),
|
|
1215
1223
|
expiresAt: zod.z.string().optional().describe("ISO expiry date")
|
|
1216
1224
|
}
|
|
1217
1225
|
},
|
|
@@ -1285,7 +1293,11 @@ function registerAuthExtraTools(server, ctx, track) {
|
|
|
1285
1293
|
const d = await ctx.gql.global.request(AUTH_AUDIT_LOGS, {
|
|
1286
1294
|
pagination: { limit: limit ?? 50, offset: offset ?? 0 }
|
|
1287
1295
|
});
|
|
1288
|
-
return jsonResult({
|
|
1296
|
+
return jsonResult({
|
|
1297
|
+
events: d.authAuditLogs.auditLogs,
|
|
1298
|
+
total: d.authAuditLogs.totalCount,
|
|
1299
|
+
hasMore: d.authAuditLogs.hasMore
|
|
1300
|
+
});
|
|
1289
1301
|
} catch (e) {
|
|
1290
1302
|
return err2(ctx, "auth_audit_log_query", "Failed to query audit log", e);
|
|
1291
1303
|
}
|
|
@@ -1320,18 +1332,17 @@ function registerAuthExtraTools(server, ctx, track) {
|
|
|
1320
1332
|
track(mcpToolName(ctx.productName, "auth_delegations_grant")),
|
|
1321
1333
|
{
|
|
1322
1334
|
title: "Grant Delegation",
|
|
1323
|
-
description: "Grant a delegation to an app (consent on behalf of
|
|
1335
|
+
description: "Grant a delegation to an app (consent on behalf of the calling user).",
|
|
1324
1336
|
inputSchema: {
|
|
1325
1337
|
appId: zod.z.string().describe("App id receiving delegation"),
|
|
1326
|
-
|
|
1327
|
-
scopes: zod.z.array(zod.z.string()).optional(),
|
|
1338
|
+
scopes: zod.z.array(zod.z.string()).min(1).describe("Delegated scopes (required)"),
|
|
1328
1339
|
workspaceIds: zod.z.array(zod.z.string()).optional(),
|
|
1329
1340
|
expiresAt: zod.z.string().optional().describe("ISO expiry")
|
|
1330
1341
|
}
|
|
1331
1342
|
},
|
|
1332
|
-
async ({ appId,
|
|
1343
|
+
async ({ appId, scopes, workspaceIds, expiresAt }) => {
|
|
1333
1344
|
try {
|
|
1334
|
-
const input = { appId,
|
|
1345
|
+
const input = { appId, scopes };
|
|
1335
1346
|
if (scopes !== void 0) input.scopes = scopes;
|
|
1336
1347
|
if (workspaceIds !== void 0) input.workspaceIds = workspaceIds;
|
|
1337
1348
|
if (expiresAt !== void 0) input.expiresAt = expiresAt;
|