@google-cloud/storage-mcp 0.3.3 → 0.4.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
@@ -149,7 +149,7 @@ ones. They will never modify or delete existing data in GCS.
149
149
  | `list_objects` | Lists objects in a GCS bucket. |
150
150
  | `read_object_metadata` | Reads comprehensive metadata for a specific object. |
151
151
  | `read_object_content` | Reads the content of a specific object. |
152
- | `download_object` | Downloads an object from GCS to a local file. |
152
+ | `download_object_safe` | Downloads an object from GCS to a local file. Fails if the destination file already exists. |
153
153
  | `write_object_new` | Writes a new object. Fails if the object already exists. |
154
154
  | `upload_object_new` | Uploads a file to a new object. Fails if the object already exists. |
155
155
  | `copy_object_new` | Copies an object to a new destination. Fails if the destination already exists. |
@@ -173,6 +173,7 @@ counterparts (e.g., `write_object` is registered instead of `write_object_new`).
173
173
  | `update_bucket_labels` | **Modifies** labels for a bucket. |
174
174
  | `delete_object` | **Deletes** a specific object from a bucket. |
175
175
  | `update_object_metadata` | **Modifies** the custom metadata of an existing object. |
176
+ | `download_object` | Downloads an object, **overwriting** the destination file. |
176
177
  | `move_object` | **Moves** an object (copies then deletes the original). |
177
178
  | `write_object` | Writes an object, **overwriting** it if it already exists. |
178
179
  | `upload_object` | Uploads a file, **overwriting** the destination object. |
package/dist/bundle.js CHANGED
@@ -4725,6 +4725,7 @@ var require_pattern = __commonJS({
4725
4725
  "use strict";
4726
4726
  Object.defineProperty(exports, "__esModule", { value: true });
4727
4727
  var code_1 = require_code2();
4728
+ var util_1 = require_util();
4728
4729
  var codegen_1 = require_codegen();
4729
4730
  var error2 = {
4730
4731
  message: ({ schemaCode }) => (0, codegen_1.str)`must match pattern "${schemaCode}"`,
@@ -4737,10 +4738,18 @@ var require_pattern = __commonJS({
4737
4738
  $data: true,
4738
4739
  error: error2,
4739
4740
  code(cxt) {
4740
- const { data, $data, schema, schemaCode, it } = cxt;
4741
+ const { gen, data, $data, schema, schemaCode, it } = cxt;
4741
4742
  const u = it.opts.unicodeRegExp ? "u" : "";
4742
- const regExp = $data ? (0, codegen_1._)`(new RegExp(${schemaCode}, ${u}))` : (0, code_1.usePattern)(cxt, schema);
4743
- cxt.fail$data((0, codegen_1._)`!${regExp}.test(${data})`);
4743
+ if ($data) {
4744
+ const { regExp } = it.opts.code;
4745
+ const regExpCode = regExp.code === "new RegExp" ? (0, codegen_1._)`new RegExp` : (0, util_1.useFunc)(gen, regExp);
4746
+ const valid = gen.let("valid");
4747
+ gen.try(() => gen.assign(valid, (0, codegen_1._)`${regExpCode}(${schemaCode}, ${u}).test(${data})`), () => gen.assign(valid, false));
4748
+ cxt.fail$data((0, codegen_1._)`!${valid}`);
4749
+ } else {
4750
+ const regExp = (0, code_1.usePattern)(cxt, schema);
4751
+ cxt.fail$data((0, codegen_1._)`!${regExp}.test(${data})`);
4752
+ }
4744
4753
  }
4745
4754
  };
4746
4755
  exports.default = def;
@@ -10614,6 +10623,7 @@ var require_pattern2 = __commonJS({
10614
10623
  "use strict";
10615
10624
  Object.defineProperty(exports, "__esModule", { value: true });
10616
10625
  var code_1 = require_code4();
10626
+ var util_1 = require_util2();
10617
10627
  var codegen_1 = require_codegen2();
10618
10628
  var error2 = {
10619
10629
  message: ({ schemaCode }) => (0, codegen_1.str)`must match pattern "${schemaCode}"`,
@@ -10626,10 +10636,18 @@ var require_pattern2 = __commonJS({
10626
10636
  $data: true,
10627
10637
  error: error2,
10628
10638
  code(cxt) {
10629
- const { data, $data, schema, schemaCode, it } = cxt;
10639
+ const { gen, data, $data, schema, schemaCode, it } = cxt;
10630
10640
  const u = it.opts.unicodeRegExp ? "u" : "";
10631
- const regExp = $data ? (0, codegen_1._)`(new RegExp(${schemaCode}, ${u}))` : (0, code_1.usePattern)(cxt, schema);
10632
- cxt.fail$data((0, codegen_1._)`!${regExp}.test(${data})`);
10641
+ if ($data) {
10642
+ const { regExp } = it.opts.code;
10643
+ const regExpCode = regExp.code === "new RegExp" ? (0, codegen_1._)`new RegExp` : (0, util_1.useFunc)(gen, regExp);
10644
+ const valid = gen.let("valid");
10645
+ gen.try(() => gen.assign(valid, (0, codegen_1._)`${regExpCode}(${schemaCode}, ${u}).test(${data})`), () => gen.assign(valid, false));
10646
+ cxt.fail$data((0, codegen_1._)`!${valid}`);
10647
+ } else {
10648
+ const regExp = (0, code_1.usePattern)(cxt, schema);
10649
+ cxt.fail$data((0, codegen_1._)`!${regExp}.test(${data})`);
10650
+ }
10633
10651
  }
10634
10652
  };
10635
10653
  exports.default = def;
@@ -12462,12 +12480,12 @@ var require_dist = __commonJS({
12462
12480
  throw new Error(`Unknown format "${name}"`);
12463
12481
  return f;
12464
12482
  };
12465
- function addFormats(ajv, list, fs3, exportName) {
12483
+ function addFormats(ajv, list, fs4, exportName) {
12466
12484
  var _a2;
12467
12485
  var _b2;
12468
12486
  (_a2 = (_b2 = ajv.opts.code).formats) !== null && _a2 !== void 0 ? _a2 : _b2.formats = (0, codegen_1._)`require("ajv-formats/dist/formats").${exportName}`;
12469
12487
  for (const f of list)
12470
- ajv.addFormat(f, fs3[f]);
12488
+ ajv.addFormat(f, fs4[f]);
12471
12489
  }
12472
12490
  module.exports = exports = formatsPlugin;
12473
12491
  Object.defineProperty(exports, "__esModule", { value: true });
@@ -26316,12 +26334,12 @@ var McpServer = class {
26316
26334
  }
26317
26335
  return registeredPrompt;
26318
26336
  }
26319
- _createRegisteredTool(name, title, description, inputSchema25, outputSchema, annotations, execution, _meta, handler) {
26337
+ _createRegisteredTool(name, title, description, inputSchema26, outputSchema, annotations, execution, _meta, handler) {
26320
26338
  validateAndWarnToolName(name);
26321
26339
  const registeredTool = {
26322
26340
  title,
26323
26341
  description,
26324
- inputSchema: getZodSchemaObject(inputSchema25),
26342
+ inputSchema: getZodSchemaObject(inputSchema26),
26325
26343
  outputSchema: getZodSchemaObject(outputSchema),
26326
26344
  annotations,
26327
26345
  execution,
@@ -26372,7 +26390,7 @@ var McpServer = class {
26372
26390
  throw new Error(`Tool ${name} is already registered`);
26373
26391
  }
26374
26392
  let description;
26375
- let inputSchema25;
26393
+ let inputSchema26;
26376
26394
  let outputSchema;
26377
26395
  let annotations;
26378
26396
  if (typeof rest[0] === "string") {
@@ -26381,7 +26399,7 @@ var McpServer = class {
26381
26399
  if (rest.length > 1) {
26382
26400
  const firstArg = rest[0];
26383
26401
  if (isZodRawShapeCompat(firstArg)) {
26384
- inputSchema25 = rest.shift();
26402
+ inputSchema26 = rest.shift();
26385
26403
  if (rest.length > 1 && typeof rest[0] === "object" && rest[0] !== null && !isZodRawShapeCompat(rest[0])) {
26386
26404
  annotations = rest.shift();
26387
26405
  }
@@ -26390,7 +26408,7 @@ var McpServer = class {
26390
26408
  }
26391
26409
  }
26392
26410
  const callback = rest[0];
26393
- return this._createRegisteredTool(name, void 0, description, inputSchema25, outputSchema, annotations, { taskSupport: "forbidden" }, void 0, callback);
26411
+ return this._createRegisteredTool(name, void 0, description, inputSchema26, outputSchema, annotations, { taskSupport: "forbidden" }, void 0, callback);
26394
26412
  }
26395
26413
  /**
26396
26414
  * Registers a tool with a config object and callback.
@@ -26399,8 +26417,8 @@ var McpServer = class {
26399
26417
  if (this._registeredTools[name]) {
26400
26418
  throw new Error(`Tool ${name} is already registered`);
26401
26419
  }
26402
- const { title, description, inputSchema: inputSchema25, outputSchema, annotations, _meta } = config2;
26403
- return this._createRegisteredTool(name, title, description, inputSchema25, outputSchema, annotations, { taskSupport: "forbidden" }, _meta, cb);
26420
+ const { title, description, inputSchema: inputSchema26, outputSchema, annotations, _meta } = config2;
26421
+ return this._createRegisteredTool(name, title, description, inputSchema26, outputSchema, annotations, { taskSupport: "forbidden" }, _meta, cb);
26404
26422
  }
26405
26423
  prompt(name, ...rest) {
26406
26424
  if (this._registeredPrompts[name]) {
@@ -27427,8 +27445,71 @@ var registerDownloadObjectTool = (server) => {
27427
27445
  );
27428
27446
  };
27429
27447
 
27430
- // src/tools/objects/list_objects.ts
27448
+ // src/tools/objects/download_object_safe.ts
27449
+ import fs from "fs";
27431
27450
  var inputSchema13 = {
27451
+ bucket_name: external_exports.string().describe("The name of the GCS bucket."),
27452
+ object_name: external_exports.string().describe("The name of the object to download."),
27453
+ file_path: external_exports.string().describe("The local path to save the downloaded file to.")
27454
+ };
27455
+ async function downloadObjectSafe(params) {
27456
+ try {
27457
+ if (fs.existsSync(params.file_path)) {
27458
+ return {
27459
+ content: [
27460
+ {
27461
+ type: "text",
27462
+ text: JSON.stringify({
27463
+ success: false,
27464
+ error: `File already exists at path: ${params.file_path}`,
27465
+ error_type: "AlreadyExists"
27466
+ })
27467
+ }
27468
+ ]
27469
+ };
27470
+ }
27471
+ const storage = apiClientFactory.getStorageClient();
27472
+ await storage.bucket(params.bucket_name).file(params.object_name).download({ destination: params.file_path });
27473
+ return {
27474
+ content: [
27475
+ {
27476
+ type: "text",
27477
+ text: JSON.stringify({
27478
+ success: true,
27479
+ message: `Object ${params.object_name} from bucket ${params.bucket_name} downloaded to ${params.file_path}.`
27480
+ })
27481
+ }
27482
+ ]
27483
+ };
27484
+ } catch (e) {
27485
+ const error2 = e;
27486
+ logger.error(error2.message);
27487
+ return {
27488
+ content: [
27489
+ {
27490
+ type: "text",
27491
+ text: JSON.stringify({
27492
+ success: false,
27493
+ error: error2.message
27494
+ })
27495
+ }
27496
+ ]
27497
+ };
27498
+ }
27499
+ }
27500
+ var registerDownloadObjectSafeTool = (server) => {
27501
+ server.registerTool(
27502
+ "download_object_safe",
27503
+ {
27504
+ description: "Downloads an object from GCS to a local file. Fails if the destination file already exists.",
27505
+ inputSchema: inputSchema13
27506
+ },
27507
+ downloadObjectSafe
27508
+ );
27509
+ };
27510
+
27511
+ // src/tools/objects/list_objects.ts
27512
+ var inputSchema14 = {
27432
27513
  bucket_name: external_exports.string().describe("The name of the GCS bucket."),
27433
27514
  prefix: external_exports.string().optional().describe("Filters results to objects whose names begin with this prefix."),
27434
27515
  delimiter: external_exports.string().optional().describe(
@@ -27505,14 +27586,14 @@ var registerListObjectsTool = (server) => {
27505
27586
  "list_objects",
27506
27587
  {
27507
27588
  description: "Lists the names of objects in a Google Cloud Storage (GCS) bucket. Supports filtering by prefix, directory-like listing with a delimiter, pagination, and listing object versions.",
27508
- inputSchema: inputSchema13
27589
+ inputSchema: inputSchema14
27509
27590
  },
27510
27591
  listObjects
27511
27592
  );
27512
27593
  };
27513
27594
 
27514
27595
  // src/tools/objects/move_object.ts
27515
- var inputSchema14 = {
27596
+ var inputSchema15 = {
27516
27597
  source_bucket_name: external_exports.string().describe("The name of the source GCS bucket."),
27517
27598
  source_object_name: external_exports.string().describe("The name of the source object."),
27518
27599
  destination_bucket_name: external_exports.string().describe("The name of the destination GCS bucket."),
@@ -27566,7 +27647,7 @@ var registerMoveObjectTool = (server) => {
27566
27647
  "move_object",
27567
27648
  {
27568
27649
  description: "Moves an object from one bucket to another or renames it within the same bucket by copying and deleting the original.",
27569
- inputSchema: inputSchema14
27650
+ inputSchema: inputSchema15
27570
27651
  },
27571
27652
  moveObject
27572
27653
  );
@@ -27709,7 +27790,7 @@ function detectBufferType(buffer, contentType, fileName) {
27709
27790
 
27710
27791
  // src/tools/objects/read_object_content.ts
27711
27792
  var { decode } = iconv;
27712
- var inputSchema15 = {
27793
+ var inputSchema16 = {
27713
27794
  bucket_name: external_exports.string().describe("The name of the GCS bucket."),
27714
27795
  object_name: external_exports.string().describe("The name of the object.")
27715
27796
  };
@@ -27844,14 +27925,14 @@ var registerReadObjectContentTool = (server) => {
27844
27925
  "read_object_content",
27845
27926
  {
27846
27927
  description: "Reads the content of a specific object.",
27847
- inputSchema: inputSchema15
27928
+ inputSchema: inputSchema16
27848
27929
  },
27849
27930
  readObjectContent
27850
27931
  );
27851
27932
  };
27852
27933
 
27853
27934
  // src/tools/objects/read_object_metadata.ts
27854
- var inputSchema16 = {
27935
+ var inputSchema17 = {
27855
27936
  bucket_name: external_exports.string().describe("The name of the GCS bucket."),
27856
27937
  object_name: external_exports.string().describe("The name of the object.")
27857
27938
  };
@@ -27908,14 +27989,14 @@ var registerReadObjectMetadataTool = (server) => {
27908
27989
  "read_object_metadata",
27909
27990
  {
27910
27991
  description: "Reads metadata for a specific object.",
27911
- inputSchema: inputSchema16
27992
+ inputSchema: inputSchema17
27912
27993
  },
27913
27994
  readObjectMetadata
27914
27995
  );
27915
27996
  };
27916
27997
 
27917
27998
  // src/tools/objects/update_object_metadata.ts
27918
- var inputSchema17 = {
27999
+ var inputSchema18 = {
27919
28000
  bucket_name: external_exports.string().describe("The name of the GCS bucket."),
27920
28001
  object_name: external_exports.string().describe("The name of the object to update."),
27921
28002
  metadata: external_exports.record(external_exports.string()).describe("A dictionary of metadata to set on the object.")
@@ -27969,16 +28050,16 @@ var registerUpdateObjectMetadataTool = (server) => {
27969
28050
  "update_object_metadata",
27970
28051
  {
27971
28052
  description: "Updates the metadata of an existing object.",
27972
- inputSchema: inputSchema17
28053
+ inputSchema: inputSchema18
27973
28054
  },
27974
28055
  updateObjectMetadata
27975
28056
  );
27976
28057
  };
27977
28058
 
27978
28059
  // src/tools/objects/upload_object.ts
27979
- import * as fs from "fs";
28060
+ import * as fs2 from "fs";
27980
28061
  import * as path2 from "path";
27981
- var inputSchema18 = {
28062
+ var inputSchema19 = {
27982
28063
  bucket_name: external_exports.string().describe("The name of the GCS bucket."),
27983
28064
  file_path: external_exports.string().describe("The local path of the file to upload."),
27984
28065
  object_name: external_exports.string().optional().describe(
@@ -27989,7 +28070,7 @@ var inputSchema18 = {
27989
28070
  async function uploadObject(params) {
27990
28071
  try {
27991
28072
  logger.info(`Uploading file: ${params.file_path} to bucket: ${params.bucket_name}`);
27992
- if (!fs.existsSync(params.file_path)) {
28073
+ if (!fs2.existsSync(params.file_path)) {
27993
28074
  return {
27994
28075
  content: [
27995
28076
  {
@@ -28051,15 +28132,15 @@ var registerUploadObjectTool = (server) => {
28051
28132
  "upload_object",
28052
28133
  {
28053
28134
  description: "Uploads a file to a GCS bucket.",
28054
- inputSchema: inputSchema18
28135
+ inputSchema: inputSchema19
28055
28136
  },
28056
28137
  uploadObject
28057
28138
  );
28058
28139
  };
28059
28140
 
28060
28141
  // src/tools/objects/upload_object_safe.ts
28061
- import * as fs2 from "fs";
28062
- var inputSchema19 = {
28142
+ import * as fs3 from "fs";
28143
+ var inputSchema20 = {
28063
28144
  bucket_name: external_exports.string().describe("The name of the GCS bucket."),
28064
28145
  file_path: external_exports.string().describe("The local path of the file to upload."),
28065
28146
  object_name: external_exports.string().optional().describe(
@@ -28070,7 +28151,7 @@ var inputSchema19 = {
28070
28151
  async function uploadObjectSafe(params) {
28071
28152
  try {
28072
28153
  logger.info(`Uploading safe file: ${params.file_path} to bucket: ${params.bucket_name}`);
28073
- if (!fs2.existsSync(params.file_path)) {
28154
+ if (!fs3.existsSync(params.file_path)) {
28074
28155
  const errorMsg = `File not found at path: ${params.file_path}`;
28075
28156
  logger.error(errorMsg);
28076
28157
  return {
@@ -28093,7 +28174,7 @@ async function uploadObjectSafe(params) {
28093
28174
  }
28094
28175
  const file = bucket.file(objectName, { generation: 0 });
28095
28176
  const contentType = params.content_type || getContentType(params.file_path);
28096
- await file.save(fs2.readFileSync(params.file_path), {
28177
+ await file.save(fs3.readFileSync(params.file_path), {
28097
28178
  contentType
28098
28179
  });
28099
28180
  const [metadata] = await file.getMetadata();
@@ -28138,14 +28219,14 @@ var registerUploadObjectSafeTool = (server) => {
28138
28219
  "upload_object_safe",
28139
28220
  {
28140
28221
  description: "Uploads a file to a GCS bucket. Fails if the object already exists.",
28141
- inputSchema: inputSchema19
28222
+ inputSchema: inputSchema20
28142
28223
  },
28143
28224
  uploadObjectSafe
28144
28225
  );
28145
28226
  };
28146
28227
 
28147
28228
  // src/tools/objects/write_object.ts
28148
- var inputSchema20 = {
28229
+ var inputSchema21 = {
28149
28230
  bucket_name: external_exports.string().describe("The name of the GCS bucket."),
28150
28231
  object_name: external_exports.string().describe("The name of the object to write."),
28151
28232
  content: external_exports.string().describe("The content to write to the object, encoded in base64."),
@@ -28217,14 +28298,14 @@ var registerWriteObjectTool = (server) => {
28217
28298
  "write_object",
28218
28299
  {
28219
28300
  description: "Writes a new object to the bucket.",
28220
- inputSchema: inputSchema20
28301
+ inputSchema: inputSchema21
28221
28302
  },
28222
28303
  writeObject
28223
28304
  );
28224
28305
  };
28225
28306
 
28226
28307
  // src/tools/objects/write_object_safe.ts
28227
- var inputSchema21 = {
28308
+ var inputSchema22 = {
28228
28309
  bucket_name: external_exports.string().describe("The name of the GCS bucket."),
28229
28310
  object_name: external_exports.string().describe("The name of the object to write."),
28230
28311
  content: external_exports.string().describe("The content to write to the object, encoded in base64."),
@@ -28303,7 +28384,7 @@ var registerWriteObjectSafeTool = (server) => {
28303
28384
  "write_object_safe",
28304
28385
  {
28305
28386
  description: "Writes a new object to the bucket. Fails if the object already exists.",
28306
- inputSchema: inputSchema21
28387
+ inputSchema: inputSchema22
28307
28388
  },
28308
28389
  writeObjectSafe
28309
28390
  );
@@ -28311,7 +28392,7 @@ var registerWriteObjectSafeTool = (server) => {
28311
28392
 
28312
28393
  // src/tools/insights/get_metadata_table_schema.ts
28313
28394
  var serviceName = "storageinsights.googleapis.com";
28314
- var inputSchema22 = {
28395
+ var inputSchema23 = {
28315
28396
  datasetConfigName: external_exports.string().describe("The name of the dataset configuration."),
28316
28397
  datasetConfigLocation: external_exports.string().describe("The location of the dataset configuration."),
28317
28398
  projectId: external_exports.string().optional().describe("The project ID to check Storage Insights availability for.")
@@ -28545,14 +28626,14 @@ var registerGetMetadataTableSchemaTool = (server) => {
28545
28626
  "get_metadata_table_schema",
28546
28627
  {
28547
28628
  description: "Checks if GCS insights service is enabled and returns the BigQuery table schema for a given insights dataset configuration in JSON format. Also returns hints for each column in the table",
28548
- inputSchema: inputSchema22
28629
+ inputSchema: inputSchema23
28549
28630
  },
28550
28631
  getMetadataTableSchema
28551
28632
  );
28552
28633
  };
28553
28634
 
28554
28635
  // src/tools/insights/execute_insights_query.ts
28555
- var inputSchema23 = {
28636
+ var inputSchema24 = {
28556
28637
  config: external_exports.string().describe(
28557
28638
  "The JSON object of the BigQuery table schema for a given insights dataset configuration."
28558
28639
  ),
@@ -28664,7 +28745,7 @@ var registerExecuteInsightsQueryTool = (server) => {
28664
28745
  "execute_insights_query",
28665
28746
  {
28666
28747
  description: "Executes a BigQuery SQL query against an insights dataset and returns the result.",
28667
- inputSchema: inputSchema23
28748
+ inputSchema: inputSchema24
28668
28749
  },
28669
28750
  executeInsightsQuery
28670
28751
  );
@@ -28672,7 +28753,7 @@ var registerExecuteInsightsQueryTool = (server) => {
28672
28753
 
28673
28754
  // src/tools/insights/list_insights_configs.ts
28674
28755
  var serviceName2 = "storageinsights.googleapis.com";
28675
- var inputSchema24 = {
28756
+ var inputSchema25 = {
28676
28757
  projectId: external_exports.string().optional().describe("The project ID to list Storage Insights dataset configurations for.")
28677
28758
  };
28678
28759
  async function listInsightsConfigs(params) {
@@ -28737,7 +28818,7 @@ var registerListInsightsConfigsTool = (server) => {
28737
28818
  "list_insights_configs",
28738
28819
  {
28739
28820
  description: "Lists the names of all Storage Insights dataset configurations for a given project.",
28740
- inputSchema: inputSchema24
28821
+ inputSchema: inputSchema25
28741
28822
  },
28742
28823
  listInsightsConfigs
28743
28824
  );
@@ -28754,7 +28835,7 @@ var commonSafeTools = [
28754
28835
  registerListObjectsTool,
28755
28836
  registerReadObjectContentTool,
28756
28837
  registerReadObjectMetadataTool,
28757
- registerDownloadObjectTool,
28838
+ registerDownloadObjectSafeTool,
28758
28839
  registerDeleteObjectTool,
28759
28840
  registerGetMetadataTableSchemaTool,
28760
28841
  registerExecuteInsightsQueryTool,
@@ -28774,7 +28855,8 @@ var otherDestructiveTools = [
28774
28855
  registerDeleteBucketTool,
28775
28856
  registerUpdateBucketLabelsTool,
28776
28857
  registerMoveObjectTool,
28777
- registerUpdateObjectMetadataTool
28858
+ registerUpdateObjectMetadataTool,
28859
+ registerDownloadObjectTool
28778
28860
  ];
28779
28861
 
28780
28862
  // ../../node_modules/@modelcontextprotocol/sdk/dist/esm/server/stdio.js
@@ -28872,7 +28954,7 @@ var StdioServerTransport = class {
28872
28954
  // package.json
28873
28955
  var package_default = {
28874
28956
  name: "@google-cloud/storage-mcp",
28875
- version: "0.3.3",
28957
+ version: "0.4.0",
28876
28958
  type: "module",
28877
28959
  main: "dist/bundle.js",
28878
28960
  bin: {
@@ -28922,7 +29004,7 @@ var package_default = {
28922
29004
  eslint: "^9.32.0",
28923
29005
  "eslint-config-prettier": "^10.1.8",
28924
29006
  "eslint-plugin-import": "^2.32.0",
28925
- "eslint-plugin-license-header": "^0.8.0",
29007
+ "eslint-plugin-license-header": "^0.9.0",
28926
29008
  "eslint-plugin-prettier": "^5.5.4",
28927
29009
  prettier: "^3.6.2",
28928
29010
  turbo: "latest",
@@ -28933,7 +29015,7 @@ var package_default = {
28933
29015
  dependencies: {
28934
29016
  "@google-cloud/bigquery": "^8.0.0",
28935
29017
  "@google-cloud/service-usage": "^4.2.0",
28936
- "@google-cloud/storage": "^7.17.1",
29018
+ "@google-cloud/storage": "^7.19.0",
28937
29019
  "@google-cloud/storageinsights": "^2.2.0",
28938
29020
  "@modelcontextprotocol/sdk": "^1.26.0",
28939
29021
  "@types/yargs": "^17.0.33",
@@ -34314,10 +34396,10 @@ For example, you can use the tools to:
34314
34396
  ## GCS Reference Documentation
34315
34397
 
34316
34398
  If additional context or information is needed on GCS, reference documentation can be found at https://cloud.google.com/storage/docs.`;
34317
- var initializeGeminiCLI = async (local = false, enableDestructiveTools = false, fs3 = { mkdir, writeFile: writeFile2 }) => {
34399
+ var initializeGeminiCLI = async (local = false, enableDestructiveTools = false, fs4 = { mkdir, writeFile: writeFile2 }) => {
34318
34400
  try {
34319
34401
  const extensionDir = join2(os.homedir(), ".gemini", "extensions", "storage-mcp");
34320
- await fs3.mkdir(extensionDir, { recursive: true });
34402
+ await fs4.mkdir(extensionDir, { recursive: true });
34321
34403
  const extensionFile = join2(extensionDir, "gemini-extension.json");
34322
34404
  const commandArgs = local ? ["-y", "storage-mcp"] : ["-y", "@google-cloud/storage-mcp"];
34323
34405
  if (enableDestructiveTools) {
@@ -34335,10 +34417,10 @@ var initializeGeminiCLI = async (local = false, enableDestructiveTools = false,
34335
34417
  }
34336
34418
  }
34337
34419
  };
34338
- await fs3.writeFile(extensionFile, JSON.stringify(extensionJson, null, 2));
34420
+ await fs4.writeFile(extensionFile, JSON.stringify(extensionJson, null, 2));
34339
34421
  console.log(`Created: ${extensionFile}`);
34340
34422
  const geminiMdDestPath = join2(extensionDir, "GEMINI.md");
34341
- await fs3.writeFile(geminiMdDestPath, geminiMdContent);
34423
+ await fs4.writeFile(geminiMdDestPath, geminiMdContent);
34342
34424
  console.log(`Created: ${geminiMdDestPath}`);
34343
34425
  console.log(`\u{1F331} storage-mcp Gemini CLI extension initialized.`);
34344
34426
  } catch (err) {