npm package diff

Package: @forge/bridge

Versions: 5.8.0-next.13 - 5.8.0-next.14

Added: package/out/object-store/utils.js

Added: package/out/object-store/utils.d.ts.map

Added: package/out/object-store/utils.d.ts

Modified: package/out/object-store/deleteObjects.js

Index: package/out/object-store/deleteObjects.js
===================================================================
--- package/out/object-store/deleteObjects.js
+++ package/out/object-store/deleteObjects.js
@@ -2,9 +2,11 @@
 Object.defineProperty(exports, "__esModule", { value: true });
 exports.deleteObjects = void 0;
 const invoke_1 = require("../invoke");
 const errors_1 = require("../errors");
+const utils_1 = require("./utils");
 const deleteObjects = async ({ functionKey, keys }) => {
+    await (0, utils_1.checkRestrictedEnvironment)();
     if (!functionKey || functionKey.length === 0) {
         throw new errors_1.BridgeAPIError('functionKey is required to delete objects');
     }
     if (!Array.isArray(keys) || keys.length === 0) {

Modified: package/out/object-store/download.js

Index: package/out/object-store/download.js
===================================================================
--- package/out/object-store/download.js
+++ package/out/object-store/download.js
@@ -2,9 +2,11 @@
 Object.defineProperty(exports, "__esModule", { value: true });
 exports.download = void 0;
 const invoke_1 = require("../invoke");
 const errors_1 = require("../errors");
+const utils_1 = require("./utils");
 const download = async ({ functionKey, keys }) => {
+    await (0, utils_1.checkRestrictedEnvironment)();
     if (!functionKey || functionKey.length === 0) {
         throw new errors_1.BridgeAPIError('functionKey is required to filter and generate download URLs');
     }
     if (!Array.isArray(keys) || keys.length === 0) {

Modified: package/out/object-store/getMetadata.js

Index: package/out/object-store/getMetadata.js
===================================================================
--- package/out/object-store/getMetadata.js
+++ package/out/object-store/getMetadata.js
@@ -2,9 +2,11 @@
 Object.defineProperty(exports, "__esModule", { value: true });
 exports.getMetadata = void 0;
 const index_1 = require("../invoke/index");
 const errors_1 = require("../errors");
+const utils_1 = require("./utils");
 const getMetadata = async ({ functionKey, keys }) => {
+    await (0, utils_1.checkRestrictedEnvironment)();
     if (!functionKey || functionKey.length === 0) {
         throw new errors_1.BridgeAPIError('functionKey is required to filter and generate object metadata');
     }
     if (!Array.isArray(keys) || keys.length === 0) {

Modified: package/out/object-store/types.js

Index: package/out/object-store/types.js
===================================================================
--- package/out/object-store/types.js
+++ package/out/object-store/types.js
@@ -1,2 +1,4 @@
 "use strict";
 Object.defineProperty(exports, "__esModule", { value: true });
+exports.BRIDGE_OBJECT_STORE_RESTRICTED_ENVIRONMENT_ERROR = void 0;
+exports.BRIDGE_OBJECT_STORE_RESTRICTED_ENVIRONMENT_ERROR = 'Object Store bridge methods are restricted to Forge apps in a non-production environment. For more information please see https://developer.atlassian.com/platform/forge/cli-reference/environments/ for reference on Forge app environments.';

Modified: package/out/object-store/upload.js

Index: package/out/object-store/upload.js
===================================================================
--- package/out/object-store/upload.js
+++ package/out/object-store/upload.js
@@ -2,8 +2,9 @@
 Object.defineProperty(exports, "__esModule", { value: true });
 exports.upload = exports.createUploadPromises = void 0;
 const invoke_1 = require("../invoke");
 const errors_1 = require("../errors");
+const utils_1 = require("./utils");
 const base64ToBlob = (base64, mimeType) => {
     const byteCharacters = atob(base64);
     const byteNumbers = new Array(byteCharacters.length);
     for (let i = 0; i < byteCharacters.length; i++) {
@@ -25,8 +26,9 @@
         checksumType
     };
 };
 const createUploadPromises = async ({ functionKey, objects }) => {
+    await (0, utils_1.checkRestrictedEnvironment)();
     if (!functionKey || functionKey.length === 0) {
         throw new errors_1.BridgeAPIError('functionKey is required to filter and generate presigned URLs');
     }
     if (!Array.isArray(objects) || objects.length === 0) {

Modified: package/package.json

Index: package/package.json
===================================================================
--- package/package.json
+++ package/package.json
@@ -1,7 +1,7 @@
 {
   "name": "@forge/bridge",
-  "version": "5.8.0-next.13",
+  "version": "5.8.0-next.14",
   "description": "Forge bridge API for custom UI apps",
   "author": "Atlassian",
   "license": "SEE LICENSE IN LICENSE.txt",
   "main": "out/index.js",

Modified: package/out/object-store/deleteObjects.d.ts.map

Index: package/out/object-store/deleteObjects.d.ts.map
===================================================================
--- package/out/object-store/deleteObjects.d.ts.map
+++ package/out/object-store/deleteObjects.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"deleteObjects.d.ts","sourceRoot":"","sources":["../../src/object-store/deleteObjects.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,aAAa;iBAAgD,MAAM;UAAQ,MAAM,EAAE;MAAK,QAAQ,IAAI,CAchH,CAAC"}
\ No newline at end of file
+{"version":3,"file":"deleteObjects.d.ts","sourceRoot":"","sources":["../../src/object-store/deleteObjects.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,aAAa;iBAAgD,MAAM;UAAQ,MAAM,EAAE;MAAK,QAAQ,IAAI,CAgBhH,CAAC"}
\ No newline at end of file

Modified: package/out/object-store/download.d.ts.map

Index: package/out/object-store/download.d.ts.map
===================================================================
--- package/out/object-store/download.d.ts.map
+++ package/out/object-store/download.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"download.d.ts","sourceRoot":"","sources":["../../src/object-store/download.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAsB,MAAM,SAAS,CAAC;AAUlE,eAAO,MAAM,QAAQ;iBAIN,MAAM;UACb,MAAM,EAAE;MACZ,QAAQ,cAAc,EAAE,CAqD3B,CAAC"}
\ No newline at end of file
+{"version":3,"file":"download.d.ts","sourceRoot":"","sources":["../../src/object-store/download.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAsB,MAAM,SAAS,CAAC;AAWlE,eAAO,MAAM,QAAQ;iBAIN,MAAM;UACb,MAAM,EAAE;MACZ,QAAQ,cAAc,EAAE,CAuD3B,CAAC"}
\ No newline at end of file

Modified: package/out/object-store/getMetadata.d.ts.map

Index: package/out/object-store/getMetadata.d.ts.map
===================================================================
--- package/out/object-store/getMetadata.d.ts.map
+++ package/out/object-store/getMetadata.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"getMetadata.d.ts","sourceRoot":"","sources":["../../src/object-store/getMetadata.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAUjD,eAAO,MAAM,WAAW;iBAIT,MAAM;UACb,MAAM,EAAE;MACZ,QAAQ,iBAAiB,EAAE,CAyB9B,CAAC"}
\ No newline at end of file
+{"version":3,"file":"getMetadata.d.ts","sourceRoot":"","sources":["../../src/object-store/getMetadata.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAWjD,eAAO,MAAM,WAAW;iBAIT,MAAM;UACb,MAAM,EAAE;MACZ,QAAQ,iBAAiB,EAAE,CA2B9B,CAAC"}
\ No newline at end of file

Modified: package/out/object-store/types.d.ts.map

Index: package/out/object-store/types.d.ts.map
===================================================================
--- package/out/object-store/types.d.ts.map
+++ package/out/object-store/types.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/object-store/types.ts"],"names":[],"mappings":"AAAA,oBAAY,cAAc,GAAG;IAC3B,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,oBAAY,YAAY,GAAG;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,oBAAY,YAAY,GAAG,IAAI,GAAG,YAAY,CAAC;AAE/C,oBAAY,YAAY,GAAG,cAAc,GAAG;IAC1C,GAAG,EAAE,MAAM,CAAC;IACZ,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF,oBAAY,YAAY,GAAG;IACzB,OAAO,EAAE,OAAO,CAAC;IACjB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,oBAAY,iBAAiB,GAAG;IAC9B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;IAC1C,GAAG,EAAE,MAAM,CAAC;IACZ,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF,oBAAY,YAAY,GAAG;IACzB,OAAO,EAAE,OAAO,CAAC;IACjB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,oBAAY,iBAAiB,GAAG;IAC9B,OAAO,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,oBAAY,cAAc,GAAG;IAC3B,OAAO,EAAE,OAAO,CAAC;IACjB,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,oBAAY,mBAAmB,GAAG;IAChC,CAAC,GAAG,EAAE,MAAM,GAAG,YAAY,CAAC;CAC7B,CAAC;AAEF,oBAAY,kBAAkB,GAAG;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;CAAE,CAAC;AAE3D,oBAAY,iBAAiB,GAAG;IAC9B,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,eAAO,MAAM,gDAAgD,kPACoL,CAAC"}
\ No newline at end of file

Modified: package/out/object-store/upload.d.ts.map

Index: package/out/object-store/upload.d.ts.map
===================================================================
--- package/out/object-store/upload.d.ts.map
+++ package/out/object-store/upload.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"upload.d.ts","sourceRoot":"","sources":["../../src/object-store/upload.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAuC,YAAY,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AA6ClH,eAAO,MAAM,oBAAoB;iBAIlB,MAAM;aACV,YAAY,EAAE;MACrB,QAAQ,iBAAiB,EAAE,CA0G9B,CAAC;AAUF,eAAO,MAAM,MAAM;iBAIJ,MAAM;aACV,YAAY,EAAE;MACrB,QAAQ,YAAY,EAAE,CAIzB,CAAC"}
\ No newline at end of file
+{"version":3,"file":"upload.d.ts","sourceRoot":"","sources":["../../src/object-store/upload.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAuC,YAAY,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AA8ClH,eAAO,MAAM,oBAAoB;iBAIlB,MAAM;aACV,YAAY,EAAE;MACrB,QAAQ,iBAAiB,EAAE,CA4G9B,CAAC;AAUF,eAAO,MAAM,MAAM;iBAIJ,MAAM;aACV,YAAY,EAAE;MACrB,QAAQ,YAAY,EAAE,CAIzB,CAAC"}
\ No newline at end of file

Modified: package/CHANGELOG.md

Index: package/CHANGELOG.md
===================================================================
--- package/CHANGELOG.md
+++ package/CHANGELOG.md
@@ -1,6 +1,13 @@
 # @forge/bridge
 
+## 5.8.0-next.14
+
+### Patch Changes
+
+- 31ea34b: block prod apps from using object store bridge methods
+- 5fe2092: Remove rovo bridge method for now
+
 ## 5.8.0-next.13
 
 ### Minor Changes

Modified: package/out/object-store/types.d.ts

Index: package/out/object-store/types.d.ts
===================================================================
--- package/out/object-store/types.d.ts
+++ package/out/object-store/types.d.ts
@@ -46,5 +46,6 @@
     createdAt?: string;
     currentVersion?: string;
     error?: string;
 };
+export declare const BRIDGE_OBJECT_STORE_RESTRICTED_ENVIRONMENT_ERROR = "Object Store bridge methods are restricted to Forge apps in a non-production environment. For more information please see https://developer.atlassian.com/platform/forge/cli-reference/environments/ for reference on Forge app environments.";
 //# sourceMappingURL=types.d.ts.map
\ No newline at end of file