portkey-admin-mcp 0.16.2 → 0.16.4

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
@@ -19,7 +19,7 @@
19
19
  <a href="https://securityscorecards.dev/viewer/?uri=github.com/CodesWhat/portkey-admin-mcp"><img src="https://img.shields.io/ossf-scorecard/github.com/CodesWhat/portkey-admin-mcp?label=openssf+scorecard&style=flat" alt="OpenSSF Scorecard"></a>
20
20
  <a href="https://www.bestpractices.dev/projects/14031"><img src="https://www.bestpractices.dev/projects/14031/badge" alt="OpenSSF Best Practices"></a>
21
21
  <a href="https://qlty.sh/gh/CodesWhat/projects/portkey-admin-mcp"><img src="https://qlty.sh/gh/CodesWhat/projects/portkey-admin-mcp/maintainability.svg" alt="Maintainability"></a>
22
- <a href="https://qlty.sh/gh/CodesWhat/projects/portkey-admin-mcp"><img src="https://qlty.sh/gh/CodesWhat/projects/portkey-admin-mcp/coverage.svg" alt="Code Coverage"></a>
22
+ <a href="https://codecov.io/gh/CodesWhat/portkey-admin-mcp"><img src="https://codecov.io/gh/CodesWhat/portkey-admin-mcp/graph/badge.svg" alt="Code Coverage"></a>
23
23
  </p>
24
24
 
25
25
  <p align="center">
@@ -48,6 +48,7 @@
48
48
  - [Development](#development)
49
49
  - [Roadmap](#roadmap)
50
50
  - [Community](#community)
51
+ - [Star History](#star-history)
51
52
  - [Built With](#built-with)
52
53
  - [Contributing](https://github.com/CodesWhat/portkey-admin-mcp/blob/main/CONTRIBUTING.md)
53
54
  - [Governance](https://github.com/CodesWhat/portkey-admin-mcp/blob/main/GOVERNANCE.md)
@@ -400,9 +401,9 @@ line, branch, and function coverage.
400
401
  The [CI workflow](https://github.com/CodesWhat/portkey-admin-mcp/actions/workflows/ci.yml)
401
402
  also runs the standalone Qlty CLI and publishes `quality-reports` artifacts for
402
403
  each analyzed commit, including lint/security results, duplication, complexity,
403
- and metrics. The existing Qlty maintainability and coverage badges remain
404
- Cloud-generated; local analysis does not update those badges. Coverage uploads
405
- and Cloud analysis still consume Qlty analysis minutes.
404
+ and metrics. The Qlty maintainability badge remains Cloud-generated; local
405
+ analysis does not update it. Coverage is reported through Codecov, not Qlty,
406
+ and the Coverage workflow uploads it on every PR and on pushes to `main` and `codex/**`.
406
407
 
407
408
  `npm run dev:http` now requires `MCP_AUTH_MODE=bearer` or `MCP_AUTH_MODE=clerk` by default. For deliberate local-only unauthenticated testing, set `MCP_ALLOW_UNAUTHENTICATED_HTTP=true`.
408
409
 
@@ -431,6 +432,18 @@ The maintained package, registry, marketplace, and directory records are listed
431
432
  in [Distribution and directories](./docs/DISTRIBUTION.md). Treat the generated
432
433
  tool catalog in this repository as authoritative when a third-party index lags.
433
434
 
435
+ <hr>
436
+
437
+ <h2 align="center" id="star-history">Star History</h2>
438
+
439
+ <a href="https://www.star-history.com/#CodesWhat/portkey-admin-mcp&type=date">
440
+ <picture>
441
+ <source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/chart?repos=CodesWhat/portkey-admin-mcp&type=date&legend=top-left&theme=dark" />
442
+ <source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/chart?repos=CodesWhat/portkey-admin-mcp&type=date&legend=top-left" />
443
+ <img alt="Star History chart for CodesWhat/portkey-admin-mcp" src="https://api.star-history.com/chart?repos=CodesWhat/portkey-admin-mcp&type=date&legend=top-left" />
444
+ </picture>
445
+ </a>
446
+
434
447
  ---
435
448
 
436
449
  <div align="center">
package/build/index.js CHANGED
@@ -1196,7 +1196,8 @@ var HealthService = class extends BaseService {
1196
1196
  const latency_ms = Date.now() - startTime;
1197
1197
  const errorMessage = error instanceof Error ? error.message : "Unknown error";
1198
1198
  const healthError = new Error(
1199
- `Health check failed: ${errorMessage} (${latency_ms}ms)`
1199
+ `Health check failed: ${errorMessage} (${latency_ms}ms)`,
1200
+ { cause: error }
1200
1201
  );
1201
1202
  this.cachedFailure = {
1202
1203
  error: healthError,
@@ -1556,6 +1557,7 @@ var McpIntegrationsService = class extends BaseService {
1556
1557
  organisation_id: params?.organisation_id,
1557
1558
  type: params?.type,
1558
1559
  workspace_id: params?.workspace_id,
1560
+ tags: params?.tags === void 0 ? void 0 : JSON.stringify(params.tags),
1559
1561
  search: params?.search
1560
1562
  });
1561
1563
  }
@@ -1625,7 +1627,8 @@ var McpServersService = class extends BaseService {
1625
1627
  return this.get("/mcp-servers", {
1626
1628
  current_page: params?.current_page,
1627
1629
  page_size: params?.page_size,
1628
- workspace_id: params?.workspace_id
1630
+ workspace_id: params?.workspace_id,
1631
+ tags: params?.tags === void 0 ? void 0 : JSON.stringify(params.tags)
1629
1632
  });
1630
1633
  }
1631
1634
  async createMcpServer(data) {
@@ -3496,8 +3499,12 @@ var configTargetSchema = z9.object({
3496
3499
  });
3497
3500
  var CONFIGS_TOOL_SCHEMAS = {
3498
3501
  listConfigs: {
3499
- current_page: CurrentPageSchema,
3500
- page_size: PageSizeSchema.describe("Number of results per page (max 100)")
3502
+ current_page: CurrentPageSchema.describe(
3503
+ "Accepted for compatibility; Portkey ignores it for configs and GET /configs returns the full list"
3504
+ ),
3505
+ page_size: PageSizeSchema.describe(
3506
+ "Accepted for compatibility; Portkey ignores it for configs and GET /configs returns the full list"
3507
+ )
3501
3508
  },
3502
3509
  getConfig: {
3503
3510
  slug: z9.string().describe(
@@ -3505,6 +3512,9 @@ var CONFIGS_TOOL_SCHEMAS = {
3505
3512
  )
3506
3513
  },
3507
3514
  createConfig: {
3515
+ auto_caching: z9.boolean().optional().describe(
3516
+ "Automatically add Anthropic prompt caching. Set false to disable"
3517
+ ),
3508
3518
  name: z9.string().describe("Name for the new configuration"),
3509
3519
  workspace_id: z9.string().optional().describe("Workspace ID to create config in"),
3510
3520
  cache_mode: z9.enum(["simple", "semantic"]).optional().describe("Cache mode: 'simple' or 'semantic'"),
@@ -3515,6 +3525,9 @@ var CONFIGS_TOOL_SCHEMAS = {
3515
3525
  targets: z9.array(configTargetSchema).optional().describe("Array of target providers with virtual keys")
3516
3526
  },
3517
3527
  updateConfig: {
3528
+ auto_caching: z9.boolean().optional().describe(
3529
+ "Automatically add Anthropic prompt caching. Set false to disable"
3530
+ ),
3518
3531
  slug: z9.string().describe("Configuration slug to update"),
3519
3532
  name: z9.string().optional().describe("New name for the configuration"),
3520
3533
  status: z9.enum(["active", "inactive"]).optional().describe("Configuration status"),
@@ -3533,6 +3546,7 @@ var CONFIGS_TOOL_SCHEMAS = {
3533
3546
  }
3534
3547
  };
3535
3548
  var configPayloadSchema = z9.object({
3549
+ auto_caching: z9.boolean().optional(),
3536
3550
  cache_mode: z9.enum(["simple", "semantic"]).optional(),
3537
3551
  cache_max_age: z9.coerce.number().positive().optional(),
3538
3552
  retry_attempts: z9.coerce.number().positive().max(5).optional(),
@@ -3550,6 +3564,7 @@ function buildConfigPayload(params) {
3550
3564
  ...params.retry_on_status_codes !== void 0 ? { on_status_codes: params.retry_on_status_codes } : {}
3551
3565
  } : void 0;
3552
3566
  return {
3567
+ ...params.auto_caching !== void 0 ? { auto_caching: params.auto_caching } : {},
3553
3568
  cache,
3554
3569
  retry,
3555
3570
  strategy: params.strategy_mode !== void 0 ? { mode: params.strategy_mode } : void 0,
@@ -3557,13 +3572,13 @@ function buildConfigPayload(params) {
3557
3572
  };
3558
3573
  }
3559
3574
  function hasConfigSettings(config) {
3560
- return config.cache !== void 0 || config.retry !== void 0 || config.strategy !== void 0 || config.targets !== void 0;
3575
+ return config.auto_caching !== void 0 || config.cache !== void 0 || config.retry !== void 0 || config.strategy !== void 0 || config.targets !== void 0;
3561
3576
  }
3562
3577
  var createConfigSchema = z9.object(CONFIGS_TOOL_SCHEMAS.createConfig).superRefine((value, ctx) => {
3563
3578
  if (!hasConfigSettings(buildConfigPayload(value))) {
3564
3579
  ctx.addIssue({
3565
3580
  code: z9.ZodIssueCode.custom,
3566
- message: "At least one config setting (cache_mode, retry_attempts, strategy_mode, or targets) must be provided"
3581
+ message: "At least one config setting (auto_caching, cache_mode, retry_attempts, strategy_mode, or targets) must be provided"
3567
3582
  });
3568
3583
  }
3569
3584
  });
@@ -3610,6 +3625,7 @@ function registerConfigsTools(server, service) {
3610
3625
  name: response.name,
3611
3626
  status: response.status,
3612
3627
  config: {
3628
+ auto_caching: response.config.auto_caching,
3613
3629
  cache: response.config.cache && {
3614
3630
  mode: response.config.cache.mode,
3615
3631
  max_age: response.config.cache.max_age
@@ -3655,7 +3671,7 @@ function registerConfigsTools(server, service) {
3655
3671
  server.registerTool(
3656
3672
  "update_config",
3657
3673
  {
3658
- description: "Update a config by slug; every call creates a new config version rather than overwriting, so earlier versions stay recoverable via list_config_versions. Only provided fields change: name, status, and all routing/cache/retry settings (cache_mode, cache_max_age, retry_attempts, retry_on_status_codes, strategy_mode, targets) are editable, while the slug stays fixed. Changes apply immediately to every API key and prompt referencing the config. Returns the update acknowledgement and new version_id.",
3674
+ description: "Update a config by slug; every call creates a new config version rather than overwriting, so earlier versions stay recoverable via list_config_versions. Only provided fields change: name, status, and all routing/cache/retry settings (auto_caching, cache_mode, cache_max_age, retry_attempts, retry_on_status_codes, strategy_mode, targets) are editable, while the slug stays fixed. Changes apply immediately to every API key and prompt referencing the config. Returns the update acknowledgement and new version_id.",
3659
3675
  inputSchema: CONFIGS_TOOL_SCHEMAS.updateConfig,
3660
3676
  annotations: {
3661
3677
  readOnlyHint: false,
@@ -5243,6 +5259,7 @@ function formatApiKeySummary(apiKey) {
5243
5259
  expires_at: apiKey.expires_at,
5244
5260
  created_at: apiKey.created_at,
5245
5261
  last_updated_at: apiKey.last_updated_at,
5262
+ last_rotated_at: apiKey.last_rotated_at,
5246
5263
  creation_mode: apiKey.creation_mode
5247
5264
  };
5248
5265
  }
@@ -5265,6 +5282,7 @@ function formatApiKey(apiKey) {
5265
5282
  reset_usage: apiKey.reset_usage,
5266
5283
  created_at: apiKey.created_at,
5267
5284
  last_updated_at: apiKey.last_updated_at,
5285
+ last_rotated_at: apiKey.last_rotated_at,
5268
5286
  creation_mode: apiKey.creation_mode
5269
5287
  };
5270
5288
  }
@@ -5432,7 +5450,7 @@ function registerKeysTools(server, service) {
5432
5450
  server.registerTool(
5433
5451
  "list_api_keys",
5434
5452
  {
5435
- description: "List Portkey API keys for auditing access, scopes, defaults, limits, and expiration. Use this for API keys only; use list_virtual_keys for provider keys. Returns total plus id, type, status, workspace/user scope, limits, defaults, alert emails, and creation mode.",
5453
+ description: "List Portkey API keys for auditing access, scopes, defaults, limits, and expiration. Use this for API keys only; use list_virtual_keys for provider keys. Returns total plus id, type, status, workspace/user scope, limits, defaults, alert emails, creation mode, and the last rotation timestamp when available.",
5436
5454
  inputSchema: KEYS_TOOL_SCHEMAS.listApiKeys
5437
5455
  },
5438
5456
  async (params) => {
@@ -5450,7 +5468,7 @@ function registerKeysTools(server, service) {
5450
5468
  server.registerTool(
5451
5469
  "get_api_key",
5452
5470
  {
5453
- description: "Fetch one API key by UUID without revealing the secret. Use this to inspect scopes, defaults, limits, expiration, and reset state before changing access.",
5471
+ description: "Fetch one API key by UUID without revealing the secret. Use this to inspect scopes, defaults, limits, expiration, reset state, and the last rotation timestamp when available before changing access.",
5454
5472
  inputSchema: KEYS_TOOL_SCHEMAS.getApiKey
5455
5473
  },
5456
5474
  async (params) => {
@@ -6313,6 +6331,7 @@ var mcpConfigurationsSchema = z20.record(z20.string(), z20.unknown()).superRefin
6313
6331
  });
6314
6332
  var MCP_INTEGRATIONS_TOOL_SCHEMAS = {
6315
6333
  listMcpIntegrations: {
6334
+ tags: resourceTagsSchema.optional().describe("Match resources carrying all supplied tags"),
6316
6335
  current_page: CurrentPageSchema,
6317
6336
  page_size: pageSizeSchema(1e3).describe(
6318
6337
  "Number of results per page (max 1000)"
@@ -6325,6 +6344,9 @@ var MCP_INTEGRATIONS_TOOL_SCHEMAS = {
6325
6344
  search: z20.string().optional().describe("Search integrations by name")
6326
6345
  },
6327
6346
  createMcpIntegration: {
6347
+ tags: resourceTagsSchema.nullable().optional().describe(
6348
+ "Key-value tags. Replaces existing tags; pass null to clear. Keys allow letters, numbers, underscores, and hyphens"
6349
+ ),
6328
6350
  name: z20.string().describe("Display name for the MCP integration"),
6329
6351
  url: z20.string().describe("URL endpoint of the MCP server to integrate"),
6330
6352
  auth_type: z20.string().min(1).describe(
@@ -6352,6 +6374,9 @@ var MCP_INTEGRATIONS_TOOL_SCHEMAS = {
6352
6374
  id: z20.string().describe("The MCP integration ID or slug to retrieve")
6353
6375
  },
6354
6376
  updateMcpIntegration: {
6377
+ tags: resourceTagsSchema.nullable().optional().describe(
6378
+ "Key-value tags. Replaces existing tags; pass null to clear. Keys allow letters, numbers, underscores, and hyphens"
6379
+ ),
6355
6380
  id: z20.string().describe("The MCP integration ID or slug to update"),
6356
6381
  name: z20.string().optional().describe("New display name"),
6357
6382
  description: z20.string().optional().describe("New description"),
@@ -6433,6 +6458,7 @@ function formatMcpIntegration(integration) {
6433
6458
  name: integration.name,
6434
6459
  slug: integration.slug,
6435
6460
  description: integration.description,
6461
+ tags: integration.tags,
6436
6462
  owner_id: integration.owner_id,
6437
6463
  workspace_id: integration.workspace_id,
6438
6464
  status: integration.status,
@@ -6539,7 +6565,7 @@ function registerMcpIntegrationsTools(server, service) {
6539
6565
  server.registerTool(
6540
6566
  "update_mcp_integration",
6541
6567
  {
6542
- description: "Update an MCP integration's name, description, URL, auth, transport, headers, or runtime Secret Reference mappings. Only supplied fields change; URL, auth, header, and secret changes apply immediately and can break active clients, so inspect get_mcp_integration first. Use update_mcp_server when changing only a Portkey server instance's display metadata.",
6568
+ description: "Update an MCP integration's name, description, tags, URL, auth, transport, headers, or runtime Secret Reference mappings. Only supplied fields change; URL, auth, header, and secret changes apply immediately and can break active clients, so inspect get_mcp_integration first. Use update_mcp_server when changing only a Portkey server instance's display metadata.",
6543
6569
  inputSchema: MCP_INTEGRATIONS_TOOL_SCHEMAS.updateMcpIntegration,
6544
6570
  annotations: {
6545
6571
  title: "Update MCP Integration",
@@ -6678,11 +6704,15 @@ function registerMcpIntegrationsTools(server, service) {
6678
6704
  import { z as z21 } from "zod";
6679
6705
  var MCP_SERVERS_TOOL_SCHEMAS = {
6680
6706
  listMcpServers: {
6707
+ tags: resourceTagsSchema.optional().describe("Match resources carrying all supplied tags"),
6681
6708
  current_page: CurrentPageSchema,
6682
6709
  page_size: PageSizeSchema.describe("Number of results per page (max 100)"),
6683
6710
  workspace_id: z21.string().optional().describe("Filter by workspace ID")
6684
6711
  },
6685
6712
  createMcpServer: {
6713
+ tags: resourceTagsSchema.nullable().optional().describe(
6714
+ "Key-value tags. Replaces existing tags; pass null to clear. Keys allow letters, numbers, underscores, and hyphens"
6715
+ ),
6686
6716
  name: z21.string().describe("Display name for the MCP server"),
6687
6717
  mcp_integration_id: z21.string().describe("ID or slug of the MCP integration this server belongs to"),
6688
6718
  slug: z21.string().optional().describe("Custom slug. Auto-generated if omitted"),
@@ -6692,6 +6722,9 @@ var MCP_SERVERS_TOOL_SCHEMAS = {
6692
6722
  id: z21.string().describe("The MCP server ID or slug to retrieve")
6693
6723
  },
6694
6724
  updateMcpServer: {
6725
+ tags: resourceTagsSchema.nullable().optional().describe(
6726
+ "Key-value tags. Replaces existing tags; pass null to clear. Keys allow letters, numbers, underscores, and hyphens"
6727
+ ),
6695
6728
  id: z21.string().describe("The MCP server ID or slug to update"),
6696
6729
  name: z21.string().optional().describe("New display name"),
6697
6730
  description: z21.string().optional().describe("New description")
@@ -6762,6 +6795,7 @@ function formatMcpServer(server) {
6762
6795
  name: server.name,
6763
6796
  slug: server.slug,
6764
6797
  description: server.description,
6798
+ tags: server.tags,
6765
6799
  mcp_integration_id: server.mcp_integration_id,
6766
6800
  status: server.status,
6767
6801
  created_at: server.created_at
@@ -6887,7 +6921,7 @@ function registerMcpServersTools(server, service) {
6887
6921
  server.registerTool(
6888
6922
  "update_mcp_server",
6889
6923
  {
6890
- description: "Update an MCP server's name or description. Changes apply immediately, but URL and auth live on the parent integration, so use update_mcp_integration for those fields.",
6924
+ description: "Update an MCP server's name, description, or tags. Changes apply immediately, but URL and auth live on the parent integration, so use update_mcp_integration for those fields.",
6891
6925
  inputSchema: MCP_SERVERS_TOOL_SCHEMAS.updateMcpServer
6892
6926
  },
6893
6927
  async (params) => {
package/build/server.js CHANGED
@@ -1209,7 +1209,8 @@ var HealthService = class extends BaseService {
1209
1209
  const latency_ms = Date.now() - startTime;
1210
1210
  const errorMessage = error instanceof Error ? error.message : "Unknown error";
1211
1211
  const healthError = new Error(
1212
- `Health check failed: ${errorMessage} (${latency_ms}ms)`
1212
+ `Health check failed: ${errorMessage} (${latency_ms}ms)`,
1213
+ { cause: error }
1213
1214
  );
1214
1215
  this.cachedFailure = {
1215
1216
  error: healthError,
@@ -1569,6 +1570,7 @@ var McpIntegrationsService = class extends BaseService {
1569
1570
  organisation_id: params?.organisation_id,
1570
1571
  type: params?.type,
1571
1572
  workspace_id: params?.workspace_id,
1573
+ tags: params?.tags === void 0 ? void 0 : JSON.stringify(params.tags),
1572
1574
  search: params?.search
1573
1575
  });
1574
1576
  }
@@ -1638,7 +1640,8 @@ var McpServersService = class extends BaseService {
1638
1640
  return this.get("/mcp-servers", {
1639
1641
  current_page: params?.current_page,
1640
1642
  page_size: params?.page_size,
1641
- workspace_id: params?.workspace_id
1643
+ workspace_id: params?.workspace_id,
1644
+ tags: params?.tags === void 0 ? void 0 : JSON.stringify(params.tags)
1642
1645
  });
1643
1646
  }
1644
1647
  async createMcpServer(data) {
@@ -3509,8 +3512,12 @@ var configTargetSchema = z9.object({
3509
3512
  });
3510
3513
  var CONFIGS_TOOL_SCHEMAS = {
3511
3514
  listConfigs: {
3512
- current_page: CurrentPageSchema,
3513
- page_size: PageSizeSchema.describe("Number of results per page (max 100)")
3515
+ current_page: CurrentPageSchema.describe(
3516
+ "Accepted for compatibility; Portkey ignores it for configs and GET /configs returns the full list"
3517
+ ),
3518
+ page_size: PageSizeSchema.describe(
3519
+ "Accepted for compatibility; Portkey ignores it for configs and GET /configs returns the full list"
3520
+ )
3514
3521
  },
3515
3522
  getConfig: {
3516
3523
  slug: z9.string().describe(
@@ -3518,6 +3525,9 @@ var CONFIGS_TOOL_SCHEMAS = {
3518
3525
  )
3519
3526
  },
3520
3527
  createConfig: {
3528
+ auto_caching: z9.boolean().optional().describe(
3529
+ "Automatically add Anthropic prompt caching. Set false to disable"
3530
+ ),
3521
3531
  name: z9.string().describe("Name for the new configuration"),
3522
3532
  workspace_id: z9.string().optional().describe("Workspace ID to create config in"),
3523
3533
  cache_mode: z9.enum(["simple", "semantic"]).optional().describe("Cache mode: 'simple' or 'semantic'"),
@@ -3528,6 +3538,9 @@ var CONFIGS_TOOL_SCHEMAS = {
3528
3538
  targets: z9.array(configTargetSchema).optional().describe("Array of target providers with virtual keys")
3529
3539
  },
3530
3540
  updateConfig: {
3541
+ auto_caching: z9.boolean().optional().describe(
3542
+ "Automatically add Anthropic prompt caching. Set false to disable"
3543
+ ),
3531
3544
  slug: z9.string().describe("Configuration slug to update"),
3532
3545
  name: z9.string().optional().describe("New name for the configuration"),
3533
3546
  status: z9.enum(["active", "inactive"]).optional().describe("Configuration status"),
@@ -3546,6 +3559,7 @@ var CONFIGS_TOOL_SCHEMAS = {
3546
3559
  }
3547
3560
  };
3548
3561
  var configPayloadSchema = z9.object({
3562
+ auto_caching: z9.boolean().optional(),
3549
3563
  cache_mode: z9.enum(["simple", "semantic"]).optional(),
3550
3564
  cache_max_age: z9.coerce.number().positive().optional(),
3551
3565
  retry_attempts: z9.coerce.number().positive().max(5).optional(),
@@ -3563,6 +3577,7 @@ function buildConfigPayload(params) {
3563
3577
  ...params.retry_on_status_codes !== void 0 ? { on_status_codes: params.retry_on_status_codes } : {}
3564
3578
  } : void 0;
3565
3579
  return {
3580
+ ...params.auto_caching !== void 0 ? { auto_caching: params.auto_caching } : {},
3566
3581
  cache,
3567
3582
  retry,
3568
3583
  strategy: params.strategy_mode !== void 0 ? { mode: params.strategy_mode } : void 0,
@@ -3570,13 +3585,13 @@ function buildConfigPayload(params) {
3570
3585
  };
3571
3586
  }
3572
3587
  function hasConfigSettings(config) {
3573
- return config.cache !== void 0 || config.retry !== void 0 || config.strategy !== void 0 || config.targets !== void 0;
3588
+ return config.auto_caching !== void 0 || config.cache !== void 0 || config.retry !== void 0 || config.strategy !== void 0 || config.targets !== void 0;
3574
3589
  }
3575
3590
  var createConfigSchema = z9.object(CONFIGS_TOOL_SCHEMAS.createConfig).superRefine((value, ctx) => {
3576
3591
  if (!hasConfigSettings(buildConfigPayload(value))) {
3577
3592
  ctx.addIssue({
3578
3593
  code: z9.ZodIssueCode.custom,
3579
- message: "At least one config setting (cache_mode, retry_attempts, strategy_mode, or targets) must be provided"
3594
+ message: "At least one config setting (auto_caching, cache_mode, retry_attempts, strategy_mode, or targets) must be provided"
3580
3595
  });
3581
3596
  }
3582
3597
  });
@@ -3623,6 +3638,7 @@ function registerConfigsTools(server, service) {
3623
3638
  name: response.name,
3624
3639
  status: response.status,
3625
3640
  config: {
3641
+ auto_caching: response.config.auto_caching,
3626
3642
  cache: response.config.cache && {
3627
3643
  mode: response.config.cache.mode,
3628
3644
  max_age: response.config.cache.max_age
@@ -3668,7 +3684,7 @@ function registerConfigsTools(server, service) {
3668
3684
  server.registerTool(
3669
3685
  "update_config",
3670
3686
  {
3671
- description: "Update a config by slug; every call creates a new config version rather than overwriting, so earlier versions stay recoverable via list_config_versions. Only provided fields change: name, status, and all routing/cache/retry settings (cache_mode, cache_max_age, retry_attempts, retry_on_status_codes, strategy_mode, targets) are editable, while the slug stays fixed. Changes apply immediately to every API key and prompt referencing the config. Returns the update acknowledgement and new version_id.",
3687
+ description: "Update a config by slug; every call creates a new config version rather than overwriting, so earlier versions stay recoverable via list_config_versions. Only provided fields change: name, status, and all routing/cache/retry settings (auto_caching, cache_mode, cache_max_age, retry_attempts, retry_on_status_codes, strategy_mode, targets) are editable, while the slug stays fixed. Changes apply immediately to every API key and prompt referencing the config. Returns the update acknowledgement and new version_id.",
3672
3688
  inputSchema: CONFIGS_TOOL_SCHEMAS.updateConfig,
3673
3689
  annotations: {
3674
3690
  readOnlyHint: false,
@@ -5256,6 +5272,7 @@ function formatApiKeySummary(apiKey) {
5256
5272
  expires_at: apiKey.expires_at,
5257
5273
  created_at: apiKey.created_at,
5258
5274
  last_updated_at: apiKey.last_updated_at,
5275
+ last_rotated_at: apiKey.last_rotated_at,
5259
5276
  creation_mode: apiKey.creation_mode
5260
5277
  };
5261
5278
  }
@@ -5278,6 +5295,7 @@ function formatApiKey(apiKey) {
5278
5295
  reset_usage: apiKey.reset_usage,
5279
5296
  created_at: apiKey.created_at,
5280
5297
  last_updated_at: apiKey.last_updated_at,
5298
+ last_rotated_at: apiKey.last_rotated_at,
5281
5299
  creation_mode: apiKey.creation_mode
5282
5300
  };
5283
5301
  }
@@ -5445,7 +5463,7 @@ function registerKeysTools(server, service) {
5445
5463
  server.registerTool(
5446
5464
  "list_api_keys",
5447
5465
  {
5448
- description: "List Portkey API keys for auditing access, scopes, defaults, limits, and expiration. Use this for API keys only; use list_virtual_keys for provider keys. Returns total plus id, type, status, workspace/user scope, limits, defaults, alert emails, and creation mode.",
5466
+ description: "List Portkey API keys for auditing access, scopes, defaults, limits, and expiration. Use this for API keys only; use list_virtual_keys for provider keys. Returns total plus id, type, status, workspace/user scope, limits, defaults, alert emails, creation mode, and the last rotation timestamp when available.",
5449
5467
  inputSchema: KEYS_TOOL_SCHEMAS.listApiKeys
5450
5468
  },
5451
5469
  async (params) => {
@@ -5463,7 +5481,7 @@ function registerKeysTools(server, service) {
5463
5481
  server.registerTool(
5464
5482
  "get_api_key",
5465
5483
  {
5466
- description: "Fetch one API key by UUID without revealing the secret. Use this to inspect scopes, defaults, limits, expiration, and reset state before changing access.",
5484
+ description: "Fetch one API key by UUID without revealing the secret. Use this to inspect scopes, defaults, limits, expiration, reset state, and the last rotation timestamp when available before changing access.",
5467
5485
  inputSchema: KEYS_TOOL_SCHEMAS.getApiKey
5468
5486
  },
5469
5487
  async (params) => {
@@ -6326,6 +6344,7 @@ var mcpConfigurationsSchema = z20.record(z20.string(), z20.unknown()).superRefin
6326
6344
  });
6327
6345
  var MCP_INTEGRATIONS_TOOL_SCHEMAS = {
6328
6346
  listMcpIntegrations: {
6347
+ tags: resourceTagsSchema.optional().describe("Match resources carrying all supplied tags"),
6329
6348
  current_page: CurrentPageSchema,
6330
6349
  page_size: pageSizeSchema(1e3).describe(
6331
6350
  "Number of results per page (max 1000)"
@@ -6338,6 +6357,9 @@ var MCP_INTEGRATIONS_TOOL_SCHEMAS = {
6338
6357
  search: z20.string().optional().describe("Search integrations by name")
6339
6358
  },
6340
6359
  createMcpIntegration: {
6360
+ tags: resourceTagsSchema.nullable().optional().describe(
6361
+ "Key-value tags. Replaces existing tags; pass null to clear. Keys allow letters, numbers, underscores, and hyphens"
6362
+ ),
6341
6363
  name: z20.string().describe("Display name for the MCP integration"),
6342
6364
  url: z20.string().describe("URL endpoint of the MCP server to integrate"),
6343
6365
  auth_type: z20.string().min(1).describe(
@@ -6365,6 +6387,9 @@ var MCP_INTEGRATIONS_TOOL_SCHEMAS = {
6365
6387
  id: z20.string().describe("The MCP integration ID or slug to retrieve")
6366
6388
  },
6367
6389
  updateMcpIntegration: {
6390
+ tags: resourceTagsSchema.nullable().optional().describe(
6391
+ "Key-value tags. Replaces existing tags; pass null to clear. Keys allow letters, numbers, underscores, and hyphens"
6392
+ ),
6368
6393
  id: z20.string().describe("The MCP integration ID or slug to update"),
6369
6394
  name: z20.string().optional().describe("New display name"),
6370
6395
  description: z20.string().optional().describe("New description"),
@@ -6446,6 +6471,7 @@ function formatMcpIntegration(integration) {
6446
6471
  name: integration.name,
6447
6472
  slug: integration.slug,
6448
6473
  description: integration.description,
6474
+ tags: integration.tags,
6449
6475
  owner_id: integration.owner_id,
6450
6476
  workspace_id: integration.workspace_id,
6451
6477
  status: integration.status,
@@ -6552,7 +6578,7 @@ function registerMcpIntegrationsTools(server, service) {
6552
6578
  server.registerTool(
6553
6579
  "update_mcp_integration",
6554
6580
  {
6555
- description: "Update an MCP integration's name, description, URL, auth, transport, headers, or runtime Secret Reference mappings. Only supplied fields change; URL, auth, header, and secret changes apply immediately and can break active clients, so inspect get_mcp_integration first. Use update_mcp_server when changing only a Portkey server instance's display metadata.",
6581
+ description: "Update an MCP integration's name, description, tags, URL, auth, transport, headers, or runtime Secret Reference mappings. Only supplied fields change; URL, auth, header, and secret changes apply immediately and can break active clients, so inspect get_mcp_integration first. Use update_mcp_server when changing only a Portkey server instance's display metadata.",
6556
6582
  inputSchema: MCP_INTEGRATIONS_TOOL_SCHEMAS.updateMcpIntegration,
6557
6583
  annotations: {
6558
6584
  title: "Update MCP Integration",
@@ -6691,11 +6717,15 @@ function registerMcpIntegrationsTools(server, service) {
6691
6717
  import { z as z21 } from "zod";
6692
6718
  var MCP_SERVERS_TOOL_SCHEMAS = {
6693
6719
  listMcpServers: {
6720
+ tags: resourceTagsSchema.optional().describe("Match resources carrying all supplied tags"),
6694
6721
  current_page: CurrentPageSchema,
6695
6722
  page_size: PageSizeSchema.describe("Number of results per page (max 100)"),
6696
6723
  workspace_id: z21.string().optional().describe("Filter by workspace ID")
6697
6724
  },
6698
6725
  createMcpServer: {
6726
+ tags: resourceTagsSchema.nullable().optional().describe(
6727
+ "Key-value tags. Replaces existing tags; pass null to clear. Keys allow letters, numbers, underscores, and hyphens"
6728
+ ),
6699
6729
  name: z21.string().describe("Display name for the MCP server"),
6700
6730
  mcp_integration_id: z21.string().describe("ID or slug of the MCP integration this server belongs to"),
6701
6731
  slug: z21.string().optional().describe("Custom slug. Auto-generated if omitted"),
@@ -6705,6 +6735,9 @@ var MCP_SERVERS_TOOL_SCHEMAS = {
6705
6735
  id: z21.string().describe("The MCP server ID or slug to retrieve")
6706
6736
  },
6707
6737
  updateMcpServer: {
6738
+ tags: resourceTagsSchema.nullable().optional().describe(
6739
+ "Key-value tags. Replaces existing tags; pass null to clear. Keys allow letters, numbers, underscores, and hyphens"
6740
+ ),
6708
6741
  id: z21.string().describe("The MCP server ID or slug to update"),
6709
6742
  name: z21.string().optional().describe("New display name"),
6710
6743
  description: z21.string().optional().describe("New description")
@@ -6775,6 +6808,7 @@ function formatMcpServer(server) {
6775
6808
  name: server.name,
6776
6809
  slug: server.slug,
6777
6810
  description: server.description,
6811
+ tags: server.tags,
6778
6812
  mcp_integration_id: server.mcp_integration_id,
6779
6813
  status: server.status,
6780
6814
  created_at: server.created_at
@@ -6900,7 +6934,7 @@ function registerMcpServersTools(server, service) {
6900
6934
  server.registerTool(
6901
6935
  "update_mcp_server",
6902
6936
  {
6903
- description: "Update an MCP server's name or description. Changes apply immediately, but URL and auth live on the parent integration, so use update_mcp_integration for those fields.",
6937
+ description: "Update an MCP server's name, description, or tags. Changes apply immediately, but URL and auth live on the parent integration, so use update_mcp_integration for those fields.",
6904
6938
  inputSchema: MCP_SERVERS_TOOL_SCHEMAS.updateMcpServer
6905
6939
  },
6906
6940
  async (params) => {
@@ -71,7 +71,7 @@ open and awaiting maintainer review as of 2026-10-16. Its `source.commit` is the
71
71
  release pin; refresh that pin, the PR release description, and discovery evidence
72
72
  after publication. It is not listed until Docker merges it and the catalog is live.
73
73
 
74
- [Smithery](https://smithery.ai/docs/build/publish) is deferred. Its current
74
+ [Smithery](https://smithery.ai/) is deferred. Its current
75
75
  publishing paths expect a public Streamable HTTP endpoint or an MCPB bundle for a
76
76
  local server. This project intentionally supports npm-based stdio and self-hosted
77
77
  HTTP, and does not publish either Smithery artifact today.
package/package.json CHANGED
@@ -31,7 +31,7 @@
31
31
  "ci": "npm run quality && npm run lint && npm run knip && npm run typecheck && npm run typecheck:tests && npm run test:coverage && npm run build && npm run verify:tool-quality && npm run test:e2e && npm run verify:readme-tools && npm run verify:generated",
32
32
  "start:http": "node build/server.js",
33
33
  "generate:lobehub-tools": "npm run build && node scripts/generate-lobehub-tools.mjs && biome format --write lhm.plugin.json",
34
- "generate:endpoints": "node scripts/generate-endpoints.mjs",
34
+ "generate:endpoints": "node scripts/generate-endpoints.mjs && biome format --write ENDPOINTS.md",
35
35
  "update:lobehub": "npm run generate:lobehub-tools && npx -y @lobehub/market-cli@0.0.41 plugin update --dir \"$PWD\"",
36
36
  "publish:lobehub": "npm run update:lobehub",
37
37
  "prepare": "[ -n \"$CI\" ] || [ -f /.dockerenv ] || [ ! -d .git ] || lefthook install",
@@ -62,7 +62,7 @@
62
62
  },
63
63
  "name": "portkey-admin-mcp",
64
64
  "mcpName": "io.github.CodesWhat/portkey-admin-mcp",
65
- "version": "0.16.2",
65
+ "version": "0.16.4",
66
66
  "main": "build/index.js",
67
67
  "keywords": [
68
68
  "mcp",
@@ -91,13 +91,13 @@
91
91
  "url": "https://github.com/CodesWhat/portkey-admin-mcp/issues"
92
92
  },
93
93
  "devDependencies": {
94
- "@biomejs/biome": "2.5.15",
94
+ "@biomejs/biome": "2.6.3",
95
95
  "@types/cors": "2.8.19",
96
96
  "@types/express": "5.0.6",
97
97
  "@types/node": "24.19.2",
98
- "dotenv": "18.0.8",
98
+ "dotenv": "18.0.9",
99
99
  "esbuild": "0.28.2",
100
- "knip": "6.42.0",
100
+ "knip": "6.43.0",
101
101
  "lefthook": "2.2.2",
102
102
  "tsx": "4.23.15",
103
103
  "typescript": "7.0.2",