@fluidframework/odsp-driver-definitions 0.56.5 → 0.57.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/dist/errors.d.ts.map +1 -1
- package/dist/errors.js.map +1 -1
- package/dist/packageVersion.d.ts +1 -1
- package/dist/packageVersion.js +1 -1
- package/dist/packageVersion.js.map +1 -1
- package/dist/tokenFetch.d.ts.map +1 -1
- package/dist/tokenFetch.js.map +1 -1
- package/lib/errors.d.ts.map +1 -1
- package/lib/errors.js.map +1 -1
- package/lib/packageVersion.d.ts +1 -1
- package/lib/packageVersion.js +1 -1
- package/lib/packageVersion.js.map +1 -1
- package/lib/tokenFetch.d.ts.map +1 -1
- package/lib/tokenFetch.js.map +1 -1
- package/package.json +2 -2
- package/src/errors.ts +1 -1
- package/src/packageVersion.ts +1 -1
- package/src/tokenFetch.ts +0 -2
package/dist/errors.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,WAAW,EAAE,MAAM,oCAAoC,CAAC;AAEjE,oBAAY,aAAa;IACrB;;OAEG;IACH,iBAAiB,sBAAsB;IAEvC;;OAEG;IACH,oBAAoB,yBAAyB;IAE7C;;;;OAIG;IACH,cAAc,mBAAmB;IAOjC,YAAY,iBAAiB;IAK7B,eAAe,oBAAoB;IAEnC,eAAe,oBAAoB;IAOnC,aAAa,kBAAkB;IAI/B,eAAe,oBAAoB;CACtC;AAED;;;GAGG;AACH,MAAM,WAAW,UAAU;IACvB,QAAQ,CAAC,SAAS,EAAE,aAAa,CAAC;IAClC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,oBAAY,SAAS,GACf,WAAW,GACX,UAAU,CAAC"}
|
package/dist/errors.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":";;;AAMA,IAAY,aA0CX;AA1CD,WAAY,aAAa;IACrB;;OAEG;IACH,wDAAuC,CAAA;IAEvC;;OAEG;IACH,8DAA6C,CAAA;IAE7C;;;;OAIG;IACH,kDAAiC,CAAA;IAEjC;;;;OAIG;IACH,8CAA6B,CAAA;IAE7B;;UAEM;IACN,oDAAmC,CAAA;IAEnC,oDAAmC,CAAA;IAEnC,+EAA+E;IAC/E,4GAA4G;IAC5G,mEAAmE;IACnE,qGAAqG;IACrG,4BAA4B;IAC5B,gDAA+B,CAAA;IAE/B,mHAAmH;IACnH,mEAAmE;IACnE,oDAAmC,CAAA;AACvC,CAAC,EA1CW,aAAa,GAAb,qBAAa,KAAb,qBAAa,QA0CxB","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\nimport
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":";;;AAMA,IAAY,aA0CX;AA1CD,WAAY,aAAa;IACrB;;OAEG;IACH,wDAAuC,CAAA;IAEvC;;OAEG;IACH,8DAA6C,CAAA;IAE7C;;;;OAIG;IACH,kDAAiC,CAAA;IAEjC;;;;OAIG;IACH,8CAA6B,CAAA;IAE7B;;UAEM;IACN,oDAAmC,CAAA;IAEnC,oDAAmC,CAAA;IAEnC,+EAA+E;IAC/E,4GAA4G;IAC5G,mEAAmE;IACnE,qGAAqG;IACrG,4BAA4B;IAC5B,gDAA+B,CAAA;IAE/B,mHAAmH;IACnH,mEAAmE;IACnE,oDAAmC,CAAA;AACvC,CAAC,EA1CW,aAAa,GAAb,qBAAa,KAAb,qBAAa,QA0CxB","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\nimport { DriverError } from \"@fluidframework/driver-definitions\";\n\nexport enum OdspErrorType {\n /**\n * Storage is out of space\n */\n outOfStorageError = \"outOfStorageError\",\n\n /**\n * Invalid file name (at creation of the file)\n */\n invalidFileNameError = \"invalidFileNameError\",\n\n /**\n * Snapshot is too big. Host application specified limit for snapshot size, and snapshot was bigger\n * that that limit, thus request failed. Hosting application is expected to have fall-back behavior for\n * such case.\n */\n snapshotTooBig = \"snapshotTooBig\",\n\n /*\n * Maximum time limit to fetch reached. Host application specified limit for fetching of snapshot, when\n * that limit is reached, request fails. Hosting application is expected to have fall-back behavior for\n * such case.\n */\n fetchTimeout = \"fetchTimeout\",\n\n /*\n * SPO admin toggle: fluid service is not enabled.\n */\n fluidNotEnabled = \"fluidNotEnabled\",\n\n fetchTokenError = \"fetchTokenError\",\n\n // This error will be raised when client is too behind with no way to catch up.\n // This condition will happen when user was offline for too long, resulting in old ops / blobs being deleted\n // by storage, and thus removing an ability for client to catch up.\n // This condition will result in any local changes being lost (i.e. only way to save state is by user\n // copying it over manually)\n cannotCatchUp = \"cannotCatchUp\",\n\n // SPO can occasionally return 403 for r/w operations on document when there is a fail over to another data center.\n // So to preserve integrity of the data, the data becomes readonly.\n serviceReadOnly = \"serviceReadOnly\",\n}\n\n/**\n * Base interface for all errors and warnings\n * Superset of IDriverErrorBase, but with Odsp-specific errorType\n */\nexport interface IOdspError {\n readonly errorType: OdspErrorType;\n readonly message: string;\n canRetry: boolean;\n online?: string;\n serverEpoch?: string;\n}\n\nexport type OdspError =\n | DriverError\n | IOdspError;\n"]}
|
package/dist/packageVersion.d.ts
CHANGED
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY
|
|
6
6
|
*/
|
|
7
7
|
export declare const pkgName = "@fluidframework/odsp-driver-definitions";
|
|
8
|
-
export declare const pkgVersion = "0.
|
|
8
|
+
export declare const pkgVersion = "0.57.0";
|
|
9
9
|
//# sourceMappingURL=packageVersion.d.ts.map
|
package/dist/packageVersion.js
CHANGED
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
9
|
exports.pkgVersion = exports.pkgName = void 0;
|
|
10
10
|
exports.pkgName = "@fluidframework/odsp-driver-definitions";
|
|
11
|
-
exports.pkgVersion = "0.
|
|
11
|
+
exports.pkgVersion = "0.57.0";
|
|
12
12
|
//# sourceMappingURL=packageVersion.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"packageVersion.js","sourceRoot":"","sources":["../src/packageVersion.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEU,QAAA,OAAO,GAAG,yCAAyC,CAAC;AACpD,QAAA,UAAU,GAAG,QAAQ,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n *\n * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY\n */\n\nexport const pkgName = \"@fluidframework/odsp-driver-definitions\";\nexport const pkgVersion = \"0.
|
|
1
|
+
{"version":3,"file":"packageVersion.js","sourceRoot":"","sources":["../src/packageVersion.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEU,QAAA,OAAO,GAAG,yCAAyC,CAAC;AACpD,QAAA,UAAU,GAAG,QAAQ,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n *\n * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY\n */\n\nexport const pkgName = \"@fluidframework/odsp-driver-definitions\";\nexport const pkgVersion = \"0.57.0\";\n"]}
|
package/dist/tokenFetch.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokenFetch.d.ts","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"tokenFetch.d.ts","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,MAAM,WAAW,aAAa;IAC1B,kBAAkB;IAClB,KAAK,EAAE,MAAM,CAAC;IAEd,kEAAkE;IAClE,SAAS,CAAC,EAAE,OAAO,CAAC;CACvB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAC9B;;;OAGG;IACH,OAAO,EAAE,OAAO,CAAC;IAEjB;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,6BAA8B,SAAQ,iBAAiB;IACpE,mDAAmD;IACnD,OAAO,EAAE,MAAM,CAAC;IAEhB,wGAAwG;IACxG,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,sGAAsG;IACtG,MAAM,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;;;;GAMG;AACH,oBAAY,YAAY,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,KAAK,OAAO,CAAC,MAAM,GAAG,aAAa,GAAG,IAAI,CAAC,CAAC;AAErF;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,kBAAmB,MAAM,GAAG,aAAa,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,GAAG,IAGpC,CAAC;AAEnE;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,kBAAmB,MAAM,GAAG,aAAa,GAAG,IAAI,KAAG,OAAO,GAAG,SAGzD,CAAC;AAElC;;;;GAIG;AACH,oBAAY,YAAY,GAAG,UAAU,GAAG,YAAY,CAAC;AAErD,oBAAY,+BAA+B,GAAG,CAC1C,OAAO,EAAE,iBAAiB,EAC1B,IAAI,EAAE,MAAM,EACZ,+BAA+B,CAAC,EAAE,OAAO,KAAK,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC"}
|
package/dist/tokenFetch.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;
|
|
1
|
+
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AA4DH;;;;GAIG;AACI,MAAM,iBAAiB,GAAG,CAAC,aAAwD,EAAiB,EAAE,CACzG,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IACvD,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,aAAa,KAAK,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC;AAHtD,QAAA,iBAAiB,qBAGqC;AAEnE;;;;;GAKG;AACI,MAAM,gBAAgB,GAAG,CAAC,aAA4C,EAAuB,EAAE,CAClG,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IACvD,CAAC,CAAC,SAAS;IACX,CAAC,CAAC,aAAa,CAAC,SAAS,CAAC;AAHrB,QAAA,gBAAgB,oBAGK","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * Represents token response\n */\nexport interface TokenResponse {\n /** Token value */\n token: string;\n\n /** Flag indicating whether token was obtained from local cache */\n fromCache?: boolean;\n}\n\n/**\n * Represents access token fetch options\n */\nexport interface TokenFetchOptions {\n /**\n * Value indicating whether fresh token has to be returned.\n * If false then it is okay to return cached unexpired token if available.\n */\n refresh: boolean;\n\n /**\n * Claims that have to be passed with token fetch request.\n * These can be used to specify additional information that must be passed to token authority.\n */\n claims?: string;\n\n /**\n * Tenant id of authority that must be handling token fetch.\n * If it is not specified then it is up to token fetching logic to determine which tenant authority\n * to use to issue access token.\n */\n tenantId?: string;\n}\n\n/**\n * Represents access token fetch options for ODSP resource\n */\nexport interface OdspResourceTokenFetchOptions extends TokenFetchOptions {\n /** Site url representing ODSP resource location */\n siteUrl: string;\n\n /** ODSP drive id where resource resides. Optional, used only when fetching token to access ODSP file */\n driveId?: string;\n\n /** ODSP item id representing resource. Optional, used only when fetching token to access ODSP file */\n itemId?: string;\n}\n\n/**\n * Method signature for callback method used to fetch access token\n * @param options - token fetch options\n * @returns If successful, TokenResponse object representing token value along with flag indicating\n * whether token came from cache. Legacy implementation may return a string for token value;\n * in this case it should be assumes that fromCache signal is undefined. Null is returned in case of failure.\n */\nexport type TokenFetcher<T> = (options: T) => Promise<string | TokenResponse | null>;\n\n/**\n * Helper method which transforms return value for TokenFetcher method to token string\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Token value\n */\nexport const tokenFromResponse = (tokenResponse: string | TokenResponse | null | undefined): string | null =>\n tokenResponse === null || typeof tokenResponse === \"string\"\n ? tokenResponse\n : tokenResponse === undefined ? null : tokenResponse.token;\n\n/**\n * Helper method which returns flag indicating whether token response comes from local cache\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Value indicating whether response came from cache.\n * Undefined is returned when we could not determine the source of token.\n */\nexport const isTokenFromCache = (tokenResponse: string | TokenResponse | null): boolean | undefined =>\n tokenResponse === null || typeof tokenResponse === \"string\"\n ? undefined\n : tokenResponse.fromCache;\n\n/**\n * Identity types supported by ODSP driver.\n * Consumer represents user authenticated with Microsoft Account (MSA)\n * Enterprise represents user authenticated with M365 tenant account\n */\nexport type IdentityType = \"Consumer\" | \"Enterprise\";\n\nexport type InstrumentedStorageTokenFetcher = (\n options: TokenFetchOptions,\n name: string,\n alwaysRecordTokenFetchTelemetry?: boolean) => Promise<string | null>;\n"]}
|
package/lib/errors.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,WAAW,EAAE,MAAM,oCAAoC,CAAC;AAEjE,oBAAY,aAAa;IACrB;;OAEG;IACH,iBAAiB,sBAAsB;IAEvC;;OAEG;IACH,oBAAoB,yBAAyB;IAE7C;;;;OAIG;IACH,cAAc,mBAAmB;IAOjC,YAAY,iBAAiB;IAK7B,eAAe,oBAAoB;IAEnC,eAAe,oBAAoB;IAOnC,aAAa,kBAAkB;IAI/B,eAAe,oBAAoB;CACtC;AAED;;;GAGG;AACH,MAAM,WAAW,UAAU;IACvB,QAAQ,CAAC,SAAS,EAAE,aAAa,CAAC;IAClC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,oBAAY,SAAS,GACf,WAAW,GACX,UAAU,CAAC"}
|
package/lib/errors.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAMA,MAAM,CAAN,IAAY,aA0CX;AA1CD,WAAY,aAAa;IACrB;;OAEG;IACH,wDAAuC,CAAA;IAEvC;;OAEG;IACH,8DAA6C,CAAA;IAE7C;;;;OAIG;IACH,kDAAiC,CAAA;IAEjC;;;;OAIG;IACH,8CAA6B,CAAA;IAE7B;;UAEM;IACN,oDAAmC,CAAA;IAEnC,oDAAmC,CAAA;IAEnC,+EAA+E;IAC/E,4GAA4G;IAC5G,mEAAmE;IACnE,qGAAqG;IACrG,4BAA4B;IAC5B,gDAA+B,CAAA;IAE/B,mHAAmH;IACnH,mEAAmE;IACnE,oDAAmC,CAAA;AACvC,CAAC,EA1CW,aAAa,KAAb,aAAa,QA0CxB","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\nimport
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAMA,MAAM,CAAN,IAAY,aA0CX;AA1CD,WAAY,aAAa;IACrB;;OAEG;IACH,wDAAuC,CAAA;IAEvC;;OAEG;IACH,8DAA6C,CAAA;IAE7C;;;;OAIG;IACH,kDAAiC,CAAA;IAEjC;;;;OAIG;IACH,8CAA6B,CAAA;IAE7B;;UAEM;IACN,oDAAmC,CAAA;IAEnC,oDAAmC,CAAA;IAEnC,+EAA+E;IAC/E,4GAA4G;IAC5G,mEAAmE;IACnE,qGAAqG;IACrG,4BAA4B;IAC5B,gDAA+B,CAAA;IAE/B,mHAAmH;IACnH,mEAAmE;IACnE,oDAAmC,CAAA;AACvC,CAAC,EA1CW,aAAa,KAAb,aAAa,QA0CxB","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\nimport { DriverError } from \"@fluidframework/driver-definitions\";\n\nexport enum OdspErrorType {\n /**\n * Storage is out of space\n */\n outOfStorageError = \"outOfStorageError\",\n\n /**\n * Invalid file name (at creation of the file)\n */\n invalidFileNameError = \"invalidFileNameError\",\n\n /**\n * Snapshot is too big. Host application specified limit for snapshot size, and snapshot was bigger\n * that that limit, thus request failed. Hosting application is expected to have fall-back behavior for\n * such case.\n */\n snapshotTooBig = \"snapshotTooBig\",\n\n /*\n * Maximum time limit to fetch reached. Host application specified limit for fetching of snapshot, when\n * that limit is reached, request fails. Hosting application is expected to have fall-back behavior for\n * such case.\n */\n fetchTimeout = \"fetchTimeout\",\n\n /*\n * SPO admin toggle: fluid service is not enabled.\n */\n fluidNotEnabled = \"fluidNotEnabled\",\n\n fetchTokenError = \"fetchTokenError\",\n\n // This error will be raised when client is too behind with no way to catch up.\n // This condition will happen when user was offline for too long, resulting in old ops / blobs being deleted\n // by storage, and thus removing an ability for client to catch up.\n // This condition will result in any local changes being lost (i.e. only way to save state is by user\n // copying it over manually)\n cannotCatchUp = \"cannotCatchUp\",\n\n // SPO can occasionally return 403 for r/w operations on document when there is a fail over to another data center.\n // So to preserve integrity of the data, the data becomes readonly.\n serviceReadOnly = \"serviceReadOnly\",\n}\n\n/**\n * Base interface for all errors and warnings\n * Superset of IDriverErrorBase, but with Odsp-specific errorType\n */\nexport interface IOdspError {\n readonly errorType: OdspErrorType;\n readonly message: string;\n canRetry: boolean;\n online?: string;\n serverEpoch?: string;\n}\n\nexport type OdspError =\n | DriverError\n | IOdspError;\n"]}
|
package/lib/packageVersion.d.ts
CHANGED
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY
|
|
6
6
|
*/
|
|
7
7
|
export declare const pkgName = "@fluidframework/odsp-driver-definitions";
|
|
8
|
-
export declare const pkgVersion = "0.
|
|
8
|
+
export declare const pkgVersion = "0.57.0";
|
|
9
9
|
//# sourceMappingURL=packageVersion.d.ts.map
|
package/lib/packageVersion.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"packageVersion.js","sourceRoot":"","sources":["../src/packageVersion.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,OAAO,GAAG,yCAAyC,CAAC;AACjE,MAAM,CAAC,MAAM,UAAU,GAAG,QAAQ,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n *\n * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY\n */\n\nexport const pkgName = \"@fluidframework/odsp-driver-definitions\";\nexport const pkgVersion = \"0.
|
|
1
|
+
{"version":3,"file":"packageVersion.js","sourceRoot":"","sources":["../src/packageVersion.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,OAAO,GAAG,yCAAyC,CAAC;AACjE,MAAM,CAAC,MAAM,UAAU,GAAG,QAAQ,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n *\n * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY\n */\n\nexport const pkgName = \"@fluidframework/odsp-driver-definitions\";\nexport const pkgVersion = \"0.57.0\";\n"]}
|
package/lib/tokenFetch.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokenFetch.d.ts","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"tokenFetch.d.ts","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,MAAM,WAAW,aAAa;IAC1B,kBAAkB;IAClB,KAAK,EAAE,MAAM,CAAC;IAEd,kEAAkE;IAClE,SAAS,CAAC,EAAE,OAAO,CAAC;CACvB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAC9B;;;OAGG;IACH,OAAO,EAAE,OAAO,CAAC;IAEjB;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,6BAA8B,SAAQ,iBAAiB;IACpE,mDAAmD;IACnD,OAAO,EAAE,MAAM,CAAC;IAEhB,wGAAwG;IACxG,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,sGAAsG;IACtG,MAAM,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;;;;GAMG;AACH,oBAAY,YAAY,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,KAAK,OAAO,CAAC,MAAM,GAAG,aAAa,GAAG,IAAI,CAAC,CAAC;AAErF;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,kBAAmB,MAAM,GAAG,aAAa,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,GAAG,IAGpC,CAAC;AAEnE;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,kBAAmB,MAAM,GAAG,aAAa,GAAG,IAAI,KAAG,OAAO,GAAG,SAGzD,CAAC;AAElC;;;;GAIG;AACH,oBAAY,YAAY,GAAG,UAAU,GAAG,YAAY,CAAC;AAErD,oBAAY,+BAA+B,GAAG,CAC1C,OAAO,EAAE,iBAAiB,EAC1B,IAAI,EAAE,MAAM,EACZ,+BAA+B,CAAC,EAAE,OAAO,KAAK,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC"}
|
package/lib/tokenFetch.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA4DH;;;;GAIG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,aAAwD,EAAiB,EAAE,CACzG,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IACvD,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,aAAa,KAAK,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC;AAEnE;;;;;GAKG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,aAA4C,EAAuB,EAAE,CAClG,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IACvD,CAAC,CAAC,SAAS;IACX,CAAC,CAAC,aAAa,CAAC,SAAS,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * Represents token response\n */\nexport interface TokenResponse {\n /** Token value */\n token: string;\n\n /** Flag indicating whether token was obtained from local cache */\n fromCache?: boolean;\n}\n\n/**\n * Represents access token fetch options\n */\nexport interface TokenFetchOptions {\n /**\n * Value indicating whether fresh token has to be returned.\n * If false then it is okay to return cached unexpired token if available.\n */\n refresh: boolean;\n\n /**\n * Claims that have to be passed with token fetch request.\n * These can be used to specify additional information that must be passed to token authority.\n */\n claims?: string;\n\n /**\n * Tenant id of authority that must be handling token fetch.\n * If it is not specified then it is up to token fetching logic to determine which tenant authority\n * to use to issue access token.\n */\n tenantId?: string;\n}\n\n/**\n * Represents access token fetch options for ODSP resource\n */\nexport interface OdspResourceTokenFetchOptions extends TokenFetchOptions {\n /** Site url representing ODSP resource location */\n siteUrl: string;\n\n /** ODSP drive id where resource resides. Optional, used only when fetching token to access ODSP file */\n driveId?: string;\n\n /** ODSP item id representing resource. Optional, used only when fetching token to access ODSP file */\n itemId?: string;\n}\n\n/**\n * Method signature for callback method used to fetch access token\n * @param options - token fetch options\n * @returns If successful, TokenResponse object representing token value along with flag indicating\n * whether token came from cache. Legacy implementation may return a string for token value;\n * in this case it should be assumes that fromCache signal is undefined. Null is returned in case of failure.\n */\nexport type TokenFetcher<T> = (options: T) => Promise<string | TokenResponse | null>;\n\n/**\n * Helper method which transforms return value for TokenFetcher method to token string\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Token value\n */\nexport const tokenFromResponse = (tokenResponse: string | TokenResponse | null | undefined): string | null =>\n tokenResponse === null || typeof tokenResponse === \"string\"\n ? tokenResponse\n : tokenResponse === undefined ? null : tokenResponse.token;\n\n/**\n * Helper method which returns flag indicating whether token response comes from local cache\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Value indicating whether response came from cache.\n * Undefined is returned when we could not determine the source of token.\n */\nexport const isTokenFromCache = (tokenResponse: string | TokenResponse | null): boolean | undefined =>\n tokenResponse === null || typeof tokenResponse === \"string\"\n ? undefined\n : tokenResponse.fromCache;\n\n/**\n * Identity types supported by ODSP driver.\n * Consumer represents user authenticated with Microsoft Account (MSA)\n * Enterprise represents user authenticated with M365 tenant account\n */\nexport type IdentityType = \"Consumer\" | \"Enterprise\";\n\nexport type InstrumentedStorageTokenFetcher = (\n options: TokenFetchOptions,\n name: string,\n alwaysRecordTokenFetchTelemetry?: boolean) => Promise<string | null>;\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluidframework/odsp-driver-definitions",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.57.0",
|
|
4
4
|
"description": "Socket storage implementation for SPO and ODC",
|
|
5
5
|
"homepage": "https://fluidframework.com",
|
|
6
6
|
"repository": "https://github.com/microsoft/FluidFramework",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
36
|
"@fluidframework/build-common": "^0.23.0",
|
|
37
|
-
"@fluidframework/eslint-config-fluid": "^0.
|
|
37
|
+
"@fluidframework/eslint-config-fluid": "^0.26.0",
|
|
38
38
|
"@fluidframework/protocol-definitions": "^0.1026.0",
|
|
39
39
|
"@microsoft/api-extractor": "^7.16.1",
|
|
40
40
|
"@rushstack/eslint-config": "^2.5.1",
|
package/src/errors.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
|
-
import
|
|
5
|
+
import { DriverError } from "@fluidframework/driver-definitions";
|
|
6
6
|
|
|
7
7
|
export enum OdspErrorType {
|
|
8
8
|
/**
|
package/src/packageVersion.ts
CHANGED