@forge/object-store 2.0.0-next.2 → 2.0.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/out/types.d.ts CHANGED
@@ -21,10 +21,10 @@ export interface PresignedUrlResponse {
21
21
  export interface BaseOptions {
22
22
  cdn?: boolean;
23
23
  }
24
- export declare type GetOptions = BaseOptions;
25
- export declare type DeleteOptions = BaseOptions;
26
- export declare type CreateDownloadUrlOptions = BaseOptions;
27
- export declare type CDNOptions = {
24
+ export type GetOptions = BaseOptions;
25
+ export type DeleteOptions = BaseOptions;
26
+ export type CreateDownloadUrlOptions = BaseOptions;
27
+ export type CDNOptions = {
28
28
  ttlSeconds?: number;
29
29
  };
30
30
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,eAAe;IAC9B,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,aAAa;IAC5B,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,QAAQ,CAAC;IACrD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,MAAM,WAAW,oBAAoB;IACnC,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,WAAW;IAC1B,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,oBAAY,UAAU,GAAG,WAAW,CAAC;AACrC,oBAAY,aAAa,GAAG,WAAW,CAAC;AACxC,oBAAY,wBAAwB,GAAG,WAAW,CAAC;AAEnD,oBAAY,UAAU,GAAG;IAEvB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,eAAe;IAC9B,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,aAAa;IAC5B,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,QAAQ,CAAC;IACrD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,MAAM,WAAW,oBAAoB;IACnC,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,WAAW;IAC1B,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,MAAM,MAAM,UAAU,GAAG,WAAW,CAAC;AACrC,MAAM,MAAM,aAAa,GAAG,WAAW,CAAC;AACxC,MAAM,MAAM,wBAAwB,GAAG,WAAW,CAAC;AAEnD,MAAM,MAAM,UAAU,GAAG;IAEvB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC"}
@@ -1,12 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.checkResponseError = exports.extractTraceId = exports.safeGetParsedBody = exports.isForgeError = void 0;
3
+ exports.isForgeError = isForgeError;
4
+ exports.safeGetParsedBody = safeGetParsedBody;
5
+ exports.extractTraceId = extractTraceId;
6
+ exports.checkResponseError = checkResponseError;
4
7
  const errors_1 = require("../errors");
5
8
  const errorCodes_1 = require("../errorCodes");
6
9
  function isForgeError(body) {
7
10
  return typeof body === 'object' && body !== null && 'code' in body && 'message' in body;
8
11
  }
9
- exports.isForgeError = isForgeError;
10
12
  function safeGetParsedBody(text) {
11
13
  try {
12
14
  return JSON.parse(text);
@@ -15,11 +17,9 @@ function safeGetParsedBody(text) {
15
17
  return undefined;
16
18
  }
17
19
  }
18
- exports.safeGetParsedBody = safeGetParsedBody;
19
20
  function extractTraceId(response) {
20
21
  return (response.headers.get('x-b3-traceid') || response.headers.get('x-trace-id') || response.headers.get('atl-traceid'));
21
22
  }
22
- exports.extractTraceId = extractTraceId;
23
23
  async function checkResponseError(response, message) {
24
24
  if (response.ok) {
25
25
  return;
@@ -46,4 +46,3 @@ async function checkResponseError(response, message) {
46
46
  context: { responseText }
47
47
  });
48
48
  }
49
- exports.checkResponseError = checkResponseError;
@@ -1,3 +1,3 @@
1
1
  import { APIResponse } from '@forge/api';
2
- export declare type Response = Pick<APIResponse, 'text' | 'ok' | 'status'>;
2
+ export type Response = Pick<APIResponse, 'text' | 'ok' | 'status'>;
3
3
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/utils/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,oBAAY,QAAQ,GAAG,IAAI,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,CAAC,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/utils/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,MAAM,MAAM,QAAQ,GAAG,IAAI,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forge/object-store",
3
- "version": "2.0.0-next.2",
3
+ "version": "2.0.0",
4
4
  "description": "Forge Object Store SDK",
5
5
  "author": "Atlassian",
6
6
  "license": "SEE LICENSE IN LICENSE.txt",
@@ -21,7 +21,7 @@
21
21
  "typescript": "5.9.2"
22
22
  },
23
23
  "dependencies": {
24
- "@forge/api": "^8.0.0-next.2"
24
+ "@forge/api": "^8.0.0"
25
25
  },
26
26
  "publishConfig": {
27
27
  "registry": "https://packages.atlassian.com/api/npm/npm-public/"