@fluidframework/odsp-driver-definitions 2.0.0-rc.2.0.2 → 2.0.0-rc.3.0.1
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/CHANGELOG.md +23 -0
- package/api-report/odsp-driver-definitions.api.md +7 -4
- package/beta.d.ts +11 -0
- package/dist/beta.d.ts +14 -0
- package/dist/errors.d.ts +2 -1
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +2 -2
- package/dist/errors.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/legacy.d.ts +43 -0
- package/dist/odspCache.d.ts +1 -1
- package/dist/odspCache.d.ts.map +1 -1
- package/dist/odspCache.js.map +1 -1
- package/dist/public.d.ts +12 -0
- package/dist/resolvedUrl.d.ts +1 -1
- package/dist/resolvedUrl.d.ts.map +1 -1
- package/dist/resolvedUrl.js.map +1 -1
- package/dist/sessionProvider.d.ts +1 -1
- package/dist/sessionProvider.d.ts.map +1 -1
- package/dist/sessionProvider.js.map +1 -1
- package/dist/tokenFetch.d.ts +5 -1
- package/dist/tokenFetch.d.ts.map +1 -1
- package/dist/tokenFetch.js.map +1 -1
- package/internal.d.ts +11 -0
- package/legacy.d.ts +11 -0
- package/lib/beta.d.ts +14 -0
- package/lib/errors.d.ts +2 -1
- package/lib/errors.d.ts.map +1 -1
- package/lib/errors.js +1 -1
- package/lib/errors.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js.map +1 -1
- package/lib/legacy.d.ts +43 -0
- package/lib/odspCache.d.ts +1 -1
- package/lib/odspCache.d.ts.map +1 -1
- package/lib/odspCache.js.map +1 -1
- package/lib/public.d.ts +12 -0
- package/lib/resolvedUrl.d.ts +1 -1
- package/lib/resolvedUrl.d.ts.map +1 -1
- package/lib/resolvedUrl.js.map +1 -1
- package/lib/sessionProvider.d.ts +1 -1
- package/lib/sessionProvider.d.ts.map +1 -1
- package/lib/sessionProvider.js.map +1 -1
- package/lib/tokenFetch.d.ts +5 -1
- package/lib/tokenFetch.d.ts.map +1 -1
- package/lib/tokenFetch.js.map +1 -1
- package/package.json +27 -48
- package/src/errors.ts +3 -5
- package/src/index.ts +1 -0
- package/src/odspCache.ts +1 -1
- package/src/resolvedUrl.ts +1 -1
- package/src/sessionProvider.ts +1 -1
- package/src/tokenFetch.ts +9 -0
- package/api-extractor-cjs.json +0 -8
- package/dist/odsp-driver-definitions-alpha.d.ts +0 -574
- package/dist/odsp-driver-definitions-beta.d.ts +0 -92
- package/dist/odsp-driver-definitions-public.d.ts +0 -80
- package/dist/odsp-driver-definitions-untrimmed.d.ts +0 -608
- package/lib/odsp-driver-definitions-alpha.d.ts +0 -574
- package/lib/odsp-driver-definitions-beta.d.ts +0 -92
- package/lib/odsp-driver-definitions-public.d.ts +0 -80
- package/lib/odsp-driver-definitions-untrimmed.d.ts +0 -608
- /package/{dist → lib}/tsdoc-metadata.json +0 -0
package/lib/public.d.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
+
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
export {}
|
|
12
|
+
|
package/lib/resolvedUrl.d.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 { IResolvedUrl } from "@fluidframework/driver-definitions";
|
|
5
|
+
import { IResolvedUrl } from "@fluidframework/driver-definitions/internal";
|
|
6
6
|
/**
|
|
7
7
|
* @alpha
|
|
8
8
|
*/
|
package/lib/resolvedUrl.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resolvedUrl.d.ts","sourceRoot":"","sources":["../src/resolvedUrl.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"resolvedUrl.d.ts","sourceRoot":"","sources":["../src/resolvedUrl.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,6CAA6C,CAAC;AAE3E;;GAEG;AACH,MAAM,WAAW,aAAa;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;CACf;AAED;;;GAGG;AACH,oBAAY,gBAAgB;IAC3B,YAAY,iBAAiB;IAC7B,KAAK,UAAU;IACf,SAAS,cAAc;IACvB,OAAO,YAAY;CACnB;AAED;;;GAGG;AACH,oBAAY,eAAe;IAC1B,IAAI,SAAS;IACb,IAAI,SAAS;CACb;AAED;;;;GAIG;AACH,MAAM,WAAW,gBAAgB;IAChC,KAAK,EAAE,gBAAgB,CAAC;IAKxB,IAAI,CAAC,EAAE,eAAe,CAAC;CACvB;AAED;;;GAGG;AACH,MAAM,WAAW,YAAa,SAAQ,gBAAgB;IACrD,MAAM,EAAE,MAAM,CAAC;CACf;AAED;;;;;GAKG;AACH,MAAM,WAAW,iBAAiB;IACjC;;;;;;OAMG;IACH,UAAU,CAAC,EAAE;QACZ;;WAEG;QACH,IAAI,CAAC,EAAE,YAAY,CAAC;QAEpB;;WAEG;QACH,KAAK,CAAC,EAAE,GAAG,CAAC;QAEZ,OAAO,CAAC,EAAE,MAAM,CAAC;KACjB,CAAC;IAEF;;;OAGG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC7B;AACD;;GAEG;AACH,MAAM,WAAW,gBAAiB,SAAQ,YAAY,EAAE,aAAa;IACpE,IAAI,EAAE,OAAO,CAAC;IACd,eAAe,EAAE,IAAI,CAAC;IAGtB,GAAG,EAAE,MAAM,CAAC;IAGZ,gBAAgB,EAAE,MAAM,CAAC;IAEzB,SAAS,EAAE;QACV,kBAAkB,EAAE,MAAM,CAAC;QAC3B,wBAAwB,EAAE,MAAM,CAAC;QACjC,uBAAuB,EAAE,MAAM,CAAC;QAChC,eAAe,EAAE,MAAM,CAAC;KACxB,CAAC;IAIF,MAAM,EAAE,EAAE,CAAC;IAEX,QAAQ,EAAE,MAAM,CAAC;IAEjB,UAAU,EAAE,OAAO,CAAC;IAEpB,QAAQ,CAAC,EAAE;QAGV,oBAAoB,CAAC,EAAE,MAAM,CAAC;KAC9B,CAAC;IAEF,WAAW,EAAE,MAAM,GAAG,SAAS,CAAC;IAEhC,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;;OAIG;IACH,aAAa,CAAC,EAAE,iBAAiB,CAAC;IAElC,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC5B"}
|
package/lib/resolvedUrl.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resolvedUrl.js","sourceRoot":"","sources":["../src/resolvedUrl.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAaH;;;GAGG;AACH,MAAM,CAAN,IAAY,gBAKX;AALD,WAAY,gBAAgB;IAC3B,iDAA6B,CAAA;IAC7B,mCAAe,CAAA;IACf,2CAAuB,CAAA;IACvB,uCAAmB,CAAA;AACpB,CAAC,EALW,gBAAgB,KAAhB,gBAAgB,QAK3B;AAED;;;GAGG;AACH,MAAM,CAAN,IAAY,eAGX;AAHD,WAAY,eAAe;IAC1B,gCAAa,CAAA;IACb,gCAAa,CAAA;AACd,CAAC,EAHW,eAAe,KAAf,eAAe,QAG1B","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { IResolvedUrl } from \"@fluidframework/driver-definitions\";\n\n/**\n * @alpha\n */\nexport interface IOdspUrlParts {\n\tsiteUrl: string;\n\tdriveId: string;\n\titemId: string;\n}\n\n/**\n * Sharing scope of the share links created for a file.\n * @alpha\n */\nexport enum SharingLinkScope {\n\torganization = \"organization\",\n\tusers = \"users\",\n\tanonymous = \"anonymous\",\n\tdefault = \"default\",\n}\n\n/**\n * View/edit permission role for a sharing link.\n * @alpha\n */\nexport enum SharingLinkRole {\n\tview = \"view\",\n\tedit = \"edit\",\n}\n\n/**\n * Defines the permissions scope for a share link requested to be created during the creation the file in ODSP.\n * Providing these properties to the /snapshot api will also create and return the requested kind of sharing link.\n * @alpha\n */\nexport interface ISharingLinkKind {\n\tscope: SharingLinkScope;\n\t/*\n\t * If this parameter is not provided, the API will default to \"edit\" links (provided\n\t * a valid createLinkScope setting is given).\n\t */\n\trole?: SharingLinkRole;\n}\n\n/**\n * Sharing link data received from the /snapshot api response.\n * @alpha\n */\nexport interface ISharingLink extends ISharingLinkKind {\n\twebUrl: string;\n}\n\n/**\n * Sharing link data created for the ODSP item.\n * Contains information about either sharing link created while creating a new file or\n * a redeemable share link created when loading an existing file\n * @alpha\n */\nexport interface ShareLinkInfoType {\n\t/**\n\t * We create a new file in ODSP with the /snapshot api call. Applications then need to make a separate apis call to\n\t * create a sharing link for that file. To reduce the number of network calls, ODSP now provides a feature\n\t * where we can create a share link along with creating a file by passing a query parameter called\n\t * createShareLink (deprecated) or createLinkScope and createLinkRole. createLink object below saves the information\n\t * from the /snapshot api response.\n\t */\n\tcreateLink?: {\n\t\t/**\n\t\t * Share link created when the file is created for the first time with /snapshot api call.\n\t\t */\n\t\tlink?: ISharingLink;\n\n\t\t/**\n\t\t * Error message if creation of sharing link fails with /snapshot api call\n\t\t */\n\t\terror?: any;\n\n\t\tshareId?: string;\n\t};\n\n\t/**\n\t * This is used to save the network calls while doing trees/latest call as if the client does not have\n\t * permission then this link can be redeemed for the permissions in the same network call.\n\t */\n\tsharingLinkToRedeem?: string;\n}\n/**\n * @alpha\n */\nexport interface IOdspResolvedUrl extends IResolvedUrl, IOdspUrlParts {\n\ttype: \"fluid\";\n\todspResolvedUrl: true;\n\n\t// URL to send to fluid, contains the documentId and the path\n\turl: string;\n\n\t// A hashed identifier that is unique to this document\n\thashedDocumentId: string;\n\n\tendpoints: {\n\t\tsnapshotStorageUrl: string;\n\t\tattachmentPOSTStorageUrl: string;\n\t\tattachmentGETStorageUrl: string;\n\t\tdeltaStorageUrl: string;\n\t};\n\n\t// Tokens are not obtained by the ODSP driver using the resolve flow, the app must provide them.\n\t// eslint-disable-next-line @typescript-eslint/ban-types\n\ttokens: {};\n\n\tfileName: string;\n\n\tsummarizer: boolean;\n\n\tcodeHint?: {\n\t\t// containerPackageName is used for adding the package name to the request headers.\n\t\t// This may be used for preloading the container package when loading Fluid content.\n\t\tcontainerPackageName?: string;\n\t};\n\n\tfileVersion: string | undefined;\n\n\tdataStorePath?: string;\n\n\t/**\n\t * Sharing link data created for the ODSP item.\n\t * Contains information about either sharing link created while creating a new file or\n\t * a redeemable share link created when loading an existing file\n\t */\n\tshareLinkInfo?: ShareLinkInfoType;\n\n\tisClpCompliantApp?: boolean;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"resolvedUrl.js","sourceRoot":"","sources":["../src/resolvedUrl.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAaH;;;GAGG;AACH,MAAM,CAAN,IAAY,gBAKX;AALD,WAAY,gBAAgB;IAC3B,iDAA6B,CAAA;IAC7B,mCAAe,CAAA;IACf,2CAAuB,CAAA;IACvB,uCAAmB,CAAA;AACpB,CAAC,EALW,gBAAgB,KAAhB,gBAAgB,QAK3B;AAED;;;GAGG;AACH,MAAM,CAAN,IAAY,eAGX;AAHD,WAAY,eAAe;IAC1B,gCAAa,CAAA;IACb,gCAAa,CAAA;AACd,CAAC,EAHW,eAAe,KAAf,eAAe,QAG1B","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { IResolvedUrl } from \"@fluidframework/driver-definitions/internal\";\n\n/**\n * @alpha\n */\nexport interface IOdspUrlParts {\n\tsiteUrl: string;\n\tdriveId: string;\n\titemId: string;\n}\n\n/**\n * Sharing scope of the share links created for a file.\n * @alpha\n */\nexport enum SharingLinkScope {\n\torganization = \"organization\",\n\tusers = \"users\",\n\tanonymous = \"anonymous\",\n\tdefault = \"default\",\n}\n\n/**\n * View/edit permission role for a sharing link.\n * @alpha\n */\nexport enum SharingLinkRole {\n\tview = \"view\",\n\tedit = \"edit\",\n}\n\n/**\n * Defines the permissions scope for a share link requested to be created during the creation the file in ODSP.\n * Providing these properties to the /snapshot api will also create and return the requested kind of sharing link.\n * @alpha\n */\nexport interface ISharingLinkKind {\n\tscope: SharingLinkScope;\n\t/*\n\t * If this parameter is not provided, the API will default to \"edit\" links (provided\n\t * a valid createLinkScope setting is given).\n\t */\n\trole?: SharingLinkRole;\n}\n\n/**\n * Sharing link data received from the /snapshot api response.\n * @alpha\n */\nexport interface ISharingLink extends ISharingLinkKind {\n\twebUrl: string;\n}\n\n/**\n * Sharing link data created for the ODSP item.\n * Contains information about either sharing link created while creating a new file or\n * a redeemable share link created when loading an existing file\n * @alpha\n */\nexport interface ShareLinkInfoType {\n\t/**\n\t * We create a new file in ODSP with the /snapshot api call. Applications then need to make a separate apis call to\n\t * create a sharing link for that file. To reduce the number of network calls, ODSP now provides a feature\n\t * where we can create a share link along with creating a file by passing a query parameter called\n\t * createShareLink (deprecated) or createLinkScope and createLinkRole. createLink object below saves the information\n\t * from the /snapshot api response.\n\t */\n\tcreateLink?: {\n\t\t/**\n\t\t * Share link created when the file is created for the first time with /snapshot api call.\n\t\t */\n\t\tlink?: ISharingLink;\n\n\t\t/**\n\t\t * Error message if creation of sharing link fails with /snapshot api call\n\t\t */\n\t\terror?: any;\n\n\t\tshareId?: string;\n\t};\n\n\t/**\n\t * This is used to save the network calls while doing trees/latest call as if the client does not have\n\t * permission then this link can be redeemed for the permissions in the same network call.\n\t */\n\tsharingLinkToRedeem?: string;\n}\n/**\n * @alpha\n */\nexport interface IOdspResolvedUrl extends IResolvedUrl, IOdspUrlParts {\n\ttype: \"fluid\";\n\todspResolvedUrl: true;\n\n\t// URL to send to fluid, contains the documentId and the path\n\turl: string;\n\n\t// A hashed identifier that is unique to this document\n\thashedDocumentId: string;\n\n\tendpoints: {\n\t\tsnapshotStorageUrl: string;\n\t\tattachmentPOSTStorageUrl: string;\n\t\tattachmentGETStorageUrl: string;\n\t\tdeltaStorageUrl: string;\n\t};\n\n\t// Tokens are not obtained by the ODSP driver using the resolve flow, the app must provide them.\n\t// eslint-disable-next-line @typescript-eslint/ban-types\n\ttokens: {};\n\n\tfileName: string;\n\n\tsummarizer: boolean;\n\n\tcodeHint?: {\n\t\t// containerPackageName is used for adding the package name to the request headers.\n\t\t// This may be used for preloading the container package when loading Fluid content.\n\t\tcontainerPackageName?: string;\n\t};\n\n\tfileVersion: string | undefined;\n\n\tdataStorePath?: string;\n\n\t/**\n\t * Sharing link data created for the ODSP item.\n\t * Contains information about either sharing link created while creating a new file or\n\t * a redeemable share link created when loading an existing file\n\t */\n\tshareLinkInfo?: ShareLinkInfoType;\n\n\tisClpCompliantApp?: boolean;\n}\n"]}
|
package/lib/sessionProvider.d.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 { IResolvedUrl } from "@fluidframework/driver-definitions";
|
|
5
|
+
import { IResolvedUrl } from "@fluidframework/driver-definitions/internal";
|
|
6
6
|
/**
|
|
7
7
|
* Socket storage discovery api response
|
|
8
8
|
* @alpha
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sessionProvider.d.ts","sourceRoot":"","sources":["../src/sessionProvider.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"sessionProvider.d.ts","sourceRoot":"","sources":["../src/sessionProvider.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,6CAA6C,CAAC;AAE3E;;;GAGG;AACH,MAAM,WAAW,uBAAuB;IAEvC,EAAE,EAAE,MAAM,CAAC;IAIX,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,EAAE,MAAM,CAAC;IAEjB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,eAAe,EAAE,MAAM,CAAC;IAExB;;OAEG;IACH,oBAAoB,EAAE,MAAM,CAAC;IAE7B;;;;;OAKG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,6BAA6B,CAAC,EAAE,MAAM,CAAC;IAEvC;;;;OAIG;IACH,qBAAqB,CAAC,EAAE,MAAM,CAAC;CAC/B;AAED;;;;GAIG;AACH,MAAM,WAAW,iCAAiC;IACjD,QAAQ,CAAC,+BAA+B,EAAE,+BAA+B,CAAC;CAC1E;AAED;;;;GAIG;AACH,MAAM,WAAW,+BAAgC,SAAQ,iCAAiC;IACzF,0BAA0B,CACzB,WAAW,EAAE,YAAY,GACvB,OAAO,CAAC,uBAAuB,GAAG,SAAS,CAAC,CAAC;CAChD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sessionProvider.js","sourceRoot":"","sources":["../src/sessionProvider.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { IResolvedUrl } from \"@fluidframework/driver-definitions\";\n\n/**\n * Socket storage discovery api response\n * @alpha\n */\nexport interface ISocketStorageDiscovery {\n\t// The id of the web socket\n\tid: string;\n\n\t// SPO gives us runtimeTenantId, we remap it to tenantId\n\t// See getSocketStorageDiscovery\n\truntimeTenantId?: string;\n\ttenantId: string;\n\n\tsnapshotStorageUrl: string;\n\tdeltaStorageUrl: string;\n\n\t/**\n\t * PUSH URL\n\t */\n\tdeltaStreamSocketUrl: string;\n\n\t/**\n\t * The access token for PushChannel. Optionally returned, depending on implementation.\n\t * OneDrive for Consumer implementation returns it and OneDrive for Business implementation\n\t * does not return it and instead expects token to be returned via `getWebsocketToken` callback\n\t * passed as a parameter to `OdspDocumentService.create()` factory.\n\t */\n\tsocketToken?: string;\n\n\t/**\n\t * This is the time within which client has to refresh the session on (ODSP) relay service.\n\t */\n\trefreshSessionDurationSeconds?: number;\n\n\t/**\n\t * Represent the sensitivity labels info for the file. Keeping it optional for back-compat. The\n\t * response will contain empty labels when the file has no labels, so this field will be there\n\t * even if file has no labels when the service will implement this contract.\n\t */\n\tsensitivityLabelsInfo?: string;\n}\n\n/**\n * An interface that allows a concrete instance of a driver factory to interrogate itself\n * to find out if it is session aware.\n * @alpha\n */\nexport interface IProvideSessionAwareDriverFactory {\n\treadonly IRelaySessionAwareDriverFactory: IRelaySessionAwareDriverFactory;\n}\n\n/**\n * An interface that allows a concrete instance of a driver factory to call the `getRelayServiceSessionInfo`\n * function if it session aware.\n * @alpha\n */\nexport interface IRelaySessionAwareDriverFactory extends IProvideSessionAwareDriverFactory {\n\tgetRelayServiceSessionInfo(\n\t\tresolvedUrl: IResolvedUrl,\n\t): Promise<ISocketStorageDiscovery | undefined>;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"sessionProvider.js","sourceRoot":"","sources":["../src/sessionProvider.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { IResolvedUrl } from \"@fluidframework/driver-definitions/internal\";\n\n/**\n * Socket storage discovery api response\n * @alpha\n */\nexport interface ISocketStorageDiscovery {\n\t// The id of the web socket\n\tid: string;\n\n\t// SPO gives us runtimeTenantId, we remap it to tenantId\n\t// See getSocketStorageDiscovery\n\truntimeTenantId?: string;\n\ttenantId: string;\n\n\tsnapshotStorageUrl: string;\n\tdeltaStorageUrl: string;\n\n\t/**\n\t * PUSH URL\n\t */\n\tdeltaStreamSocketUrl: string;\n\n\t/**\n\t * The access token for PushChannel. Optionally returned, depending on implementation.\n\t * OneDrive for Consumer implementation returns it and OneDrive for Business implementation\n\t * does not return it and instead expects token to be returned via `getWebsocketToken` callback\n\t * passed as a parameter to `OdspDocumentService.create()` factory.\n\t */\n\tsocketToken?: string;\n\n\t/**\n\t * This is the time within which client has to refresh the session on (ODSP) relay service.\n\t */\n\trefreshSessionDurationSeconds?: number;\n\n\t/**\n\t * Represent the sensitivity labels info for the file. Keeping it optional for back-compat. The\n\t * response will contain empty labels when the file has no labels, so this field will be there\n\t * even if file has no labels when the service will implement this contract.\n\t */\n\tsensitivityLabelsInfo?: string;\n}\n\n/**\n * An interface that allows a concrete instance of a driver factory to interrogate itself\n * to find out if it is session aware.\n * @alpha\n */\nexport interface IProvideSessionAwareDriverFactory {\n\treadonly IRelaySessionAwareDriverFactory: IRelaySessionAwareDriverFactory;\n}\n\n/**\n * An interface that allows a concrete instance of a driver factory to call the `getRelayServiceSessionInfo`\n * function if it session aware.\n * @alpha\n */\nexport interface IRelaySessionAwareDriverFactory extends IProvideSessionAwareDriverFactory {\n\tgetRelayServiceSessionInfo(\n\t\tresolvedUrl: IResolvedUrl,\n\t): Promise<ISocketStorageDiscovery | undefined>;\n}\n"]}
|
package/lib/tokenFetch.d.ts
CHANGED
|
@@ -83,5 +83,9 @@ export type IdentityType = "Consumer" | "Enterprise";
|
|
|
83
83
|
/**
|
|
84
84
|
* @internal
|
|
85
85
|
*/
|
|
86
|
-
export type InstrumentedStorageTokenFetcher = (options: TokenFetchOptions, name: string, alwaysRecordTokenFetchTelemetry?: boolean) => Promise<string
|
|
86
|
+
export type InstrumentedStorageTokenFetcher = (options: TokenFetchOptions, name: string, alwaysRecordTokenFetchTelemetry?: boolean) => Promise<string>;
|
|
87
|
+
/**
|
|
88
|
+
* @internal
|
|
89
|
+
*/
|
|
90
|
+
export type InstrumentedTokenFetcher = (options: TokenFetchOptions, name: string, alwaysRecordTokenFetchTelemetry?: boolean) => Promise<string | null>;
|
|
87
91
|
//# sourceMappingURL=tokenFetch.d.ts.map
|
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;AAEH;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC7B,kBAAkB;IAClB,KAAK,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IACjC;;;OAGG;IACH,OAAO,EAAE,OAAO,CAAC;IAEjB;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CAClB;AAED;;;GAGG;AACH,MAAM,WAAW,6BAA8B,SAAQ,iBAAiB;IACvE,mDAAmD;IACnD,OAAO,EAAE,MAAM,CAAC;IAEhB,wGAAwG;IACxG,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,sGAAsG;IACtG,MAAM,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;;;;;;GAOG;AACH,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,KAAK,OAAO,CAAC,MAAM,GAAG,aAAa,GAAG,IAAI,CAAC,CAAC;AAErF;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,kBACd,MAAM,GAAG,aAAa,GAAG,IAAI,GAAG,SAAS,KACtD,MAAM,GAAG,IAKW,CAAC;AAExB;;;;;;GAMG;AACH,eAAO,MAAM,gBAAgB,kBACb,MAAM,GAAG,aAAa,GAAG,IAAI,KAC1C,OAAO,GAAG,SAGc,CAAC;AAE5B;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG,UAAU,GAAG,YAAY,CAAC;AAErD;;GAEG;AACH,MAAM,MAAM,+BAA+B,GAAG,CAC7C,OAAO,EAAE,iBAAiB,EAC1B,IAAI,EAAE,MAAM,EACZ,+BAA+B,CAAC,EAAE,OAAO,KACrC,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC"}
|
|
1
|
+
{"version":3,"file":"tokenFetch.d.ts","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC7B,kBAAkB;IAClB,KAAK,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IACjC;;;OAGG;IACH,OAAO,EAAE,OAAO,CAAC;IAEjB;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CAClB;AAED;;;GAGG;AACH,MAAM,WAAW,6BAA8B,SAAQ,iBAAiB;IACvE,mDAAmD;IACnD,OAAO,EAAE,MAAM,CAAC;IAEhB,wGAAwG;IACxG,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,sGAAsG;IACtG,MAAM,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;;;;;;GAOG;AACH,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,KAAK,OAAO,CAAC,MAAM,GAAG,aAAa,GAAG,IAAI,CAAC,CAAC;AAErF;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,kBACd,MAAM,GAAG,aAAa,GAAG,IAAI,GAAG,SAAS,KACtD,MAAM,GAAG,IAKW,CAAC;AAExB;;;;;;GAMG;AACH,eAAO,MAAM,gBAAgB,kBACb,MAAM,GAAG,aAAa,GAAG,IAAI,KAC1C,OAAO,GAAG,SAGc,CAAC;AAE5B;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG,UAAU,GAAG,YAAY,CAAC;AAErD;;GAEG;AACH,MAAM,MAAM,+BAA+B,GAAG,CAC7C,OAAO,EAAE,iBAAiB,EAC1B,IAAI,EAAE,MAAM,EACZ,+BAA+B,CAAC,EAAE,OAAO,KACrC,OAAO,CAAC,MAAM,CAAC,CAAC;AAErB;;GAEG;AACH,MAAM,MAAM,wBAAwB,GAAG,CACtC,OAAO,EAAE,iBAAiB,EAC1B,IAAI,EAAE,MAAM,EACZ,+BAA+B,CAAC,EAAE,OAAO,KACrC,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;AAmEH;;;;;GAKG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAChC,aAAwD,EACxC,EAAE,CAClB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,aAAa,KAAK,SAAS;QAC7B,CAAC,CAAC,IAAI;QACN,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC;AAExB;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAC/B,aAA4C,EACtB,EAAE,CACxB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,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 * @beta\n */\nexport interface TokenResponse {\n\t/** Token value */\n\ttoken: string;\n\n\t/**\n\t * Whether or not the token was obtained from local cache.\n\t * @remarks `undefined` indicates that it could not be determined whether or not the token was obtained this way.\n\t */\n\tfromCache?: boolean;\n}\n\n/**\n * Represents access token fetch options\n * @alpha\n */\nexport interface TokenFetchOptions {\n\t/**\n\t * Value indicating whether fresh token has to be returned.\n\t * If false then it is okay to return cached unexpired token if available.\n\t */\n\trefresh: boolean;\n\n\t/**\n\t * Claims that have to be passed with token fetch request.\n\t * These can be used to specify additional information that must be passed to token authority.\n\t */\n\tclaims?: string;\n\n\t/**\n\t * Tenant id of authority that must be handling token fetch.\n\t * If it is not specified then it is up to token fetching logic to determine which tenant authority\n\t * to use to issue access token.\n\t */\n\ttenantId?: string;\n}\n\n/**\n * Represents access token fetch options for ODSP resource\n * @alpha\n */\nexport interface OdspResourceTokenFetchOptions extends TokenFetchOptions {\n\t/** Site url representing ODSP resource location */\n\tsiteUrl: string;\n\n\t/** ODSP drive id where resource resides. Optional, used only when fetching token to access ODSP file */\n\tdriveId?: string;\n\n\t/** ODSP item id representing resource. Optional, used only when fetching token to access ODSP file */\n\titemId?: 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 * @alpha\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 * @internal\n */\nexport const tokenFromResponse = (\n\ttokenResponse: string | TokenResponse | null | undefined,\n): string | null =>\n\ttokenResponse === null || typeof tokenResponse === \"string\"\n\t\t? tokenResponse\n\t\t: tokenResponse === undefined\n\t\t? null\n\t\t: 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 * @internal\n */\nexport const isTokenFromCache = (\n\ttokenResponse: string | TokenResponse | null,\n): boolean | undefined =>\n\ttokenResponse === null || typeof tokenResponse === \"string\"\n\t\t? undefined\n\t\t: 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 * @alpha\n */\nexport type IdentityType = \"Consumer\" | \"Enterprise\";\n\n/**\n * @internal\n */\nexport type InstrumentedStorageTokenFetcher = (\n\toptions: TokenFetchOptions,\n\tname: string,\n\talwaysRecordTokenFetchTelemetry?: boolean,\n) => Promise<string | null>;\n"]}
|
|
1
|
+
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAmEH;;;;;GAKG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAChC,aAAwD,EACxC,EAAE,CAClB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,aAAa,KAAK,SAAS;QAC7B,CAAC,CAAC,IAAI;QACN,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC;AAExB;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAC/B,aAA4C,EACtB,EAAE,CACxB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,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 * @beta\n */\nexport interface TokenResponse {\n\t/** Token value */\n\ttoken: string;\n\n\t/**\n\t * Whether or not the token was obtained from local cache.\n\t * @remarks `undefined` indicates that it could not be determined whether or not the token was obtained this way.\n\t */\n\tfromCache?: boolean;\n}\n\n/**\n * Represents access token fetch options\n * @alpha\n */\nexport interface TokenFetchOptions {\n\t/**\n\t * Value indicating whether fresh token has to be returned.\n\t * If false then it is okay to return cached unexpired token if available.\n\t */\n\trefresh: boolean;\n\n\t/**\n\t * Claims that have to be passed with token fetch request.\n\t * These can be used to specify additional information that must be passed to token authority.\n\t */\n\tclaims?: string;\n\n\t/**\n\t * Tenant id of authority that must be handling token fetch.\n\t * If it is not specified then it is up to token fetching logic to determine which tenant authority\n\t * to use to issue access token.\n\t */\n\ttenantId?: string;\n}\n\n/**\n * Represents access token fetch options for ODSP resource\n * @alpha\n */\nexport interface OdspResourceTokenFetchOptions extends TokenFetchOptions {\n\t/** Site url representing ODSP resource location */\n\tsiteUrl: string;\n\n\t/** ODSP drive id where resource resides. Optional, used only when fetching token to access ODSP file */\n\tdriveId?: string;\n\n\t/** ODSP item id representing resource. Optional, used only when fetching token to access ODSP file */\n\titemId?: 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 * @alpha\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 * @internal\n */\nexport const tokenFromResponse = (\n\ttokenResponse: string | TokenResponse | null | undefined,\n): string | null =>\n\ttokenResponse === null || typeof tokenResponse === \"string\"\n\t\t? tokenResponse\n\t\t: tokenResponse === undefined\n\t\t? null\n\t\t: 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 * @internal\n */\nexport const isTokenFromCache = (\n\ttokenResponse: string | TokenResponse | null,\n): boolean | undefined =>\n\ttokenResponse === null || typeof tokenResponse === \"string\"\n\t\t? undefined\n\t\t: 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 * @alpha\n */\nexport type IdentityType = \"Consumer\" | \"Enterprise\";\n\n/**\n * @internal\n */\nexport type InstrumentedStorageTokenFetcher = (\n\toptions: TokenFetchOptions,\n\tname: string,\n\talwaysRecordTokenFetchTelemetry?: boolean,\n) => Promise<string>;\n\n/**\n * @internal\n */\nexport type InstrumentedTokenFetcher = (\n\toptions: TokenFetchOptions,\n\tname: string,\n\talwaysRecordTokenFetchTelemetry?: boolean,\n) => Promise<string | null>;\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluidframework/odsp-driver-definitions",
|
|
3
|
-
"version": "2.0.0-rc.
|
|
3
|
+
"version": "2.0.0-rc.3.0.1",
|
|
4
4
|
"description": "Socket storage implementation for SPO and ODC",
|
|
5
5
|
"homepage": "https://fluidframework.com",
|
|
6
6
|
"repository": {
|
|
@@ -15,41 +15,31 @@
|
|
|
15
15
|
"exports": {
|
|
16
16
|
".": {
|
|
17
17
|
"import": {
|
|
18
|
-
"types": "./lib/
|
|
19
|
-
"default": "./lib/index.js"
|
|
20
|
-
},
|
|
21
|
-
"require": {
|
|
22
|
-
"types": "./dist/index.d.ts",
|
|
23
|
-
"default": "./dist/index.js"
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
"./public": {
|
|
27
|
-
"import": {
|
|
28
|
-
"types": "./lib/odsp-driver-definitions-public.d.ts",
|
|
18
|
+
"types": "./lib/public.d.ts",
|
|
29
19
|
"default": "./lib/index.js"
|
|
30
20
|
},
|
|
31
21
|
"require": {
|
|
32
|
-
"types": "./dist/
|
|
22
|
+
"types": "./dist/public.d.ts",
|
|
33
23
|
"default": "./dist/index.js"
|
|
34
24
|
}
|
|
35
25
|
},
|
|
36
26
|
"./beta": {
|
|
37
27
|
"import": {
|
|
38
|
-
"types": "./lib/
|
|
28
|
+
"types": "./lib/beta.d.ts",
|
|
39
29
|
"default": "./lib/index.js"
|
|
40
30
|
},
|
|
41
31
|
"require": {
|
|
42
|
-
"types": "./dist/
|
|
32
|
+
"types": "./dist/beta.d.ts",
|
|
43
33
|
"default": "./dist/index.js"
|
|
44
34
|
}
|
|
45
35
|
},
|
|
46
|
-
"./
|
|
36
|
+
"./legacy": {
|
|
47
37
|
"import": {
|
|
48
|
-
"types": "./lib/
|
|
38
|
+
"types": "./lib/legacy.d.ts",
|
|
49
39
|
"default": "./lib/index.js"
|
|
50
40
|
},
|
|
51
41
|
"require": {
|
|
52
|
-
"types": "./dist/
|
|
42
|
+
"types": "./dist/legacy.d.ts",
|
|
53
43
|
"default": "./dist/index.js"
|
|
54
44
|
}
|
|
55
45
|
},
|
|
@@ -64,17 +54,18 @@
|
|
|
64
54
|
}
|
|
65
55
|
}
|
|
66
56
|
},
|
|
67
|
-
"main": "
|
|
68
|
-
"types": "
|
|
57
|
+
"main": "lib/index.js",
|
|
58
|
+
"types": "lib/public.d.ts",
|
|
69
59
|
"dependencies": {
|
|
70
|
-
"@fluidframework/driver-definitions": ">=2.0.0-rc.
|
|
60
|
+
"@fluidframework/driver-definitions": ">=2.0.0-rc.3.0.1 <2.0.0-rc.3.1.0"
|
|
71
61
|
},
|
|
72
62
|
"devDependencies": {
|
|
73
|
-
"@arethetypeswrong/cli": "^0.
|
|
74
|
-
"@
|
|
63
|
+
"@arethetypeswrong/cli": "^0.15.2",
|
|
64
|
+
"@biomejs/biome": "^1.6.2",
|
|
65
|
+
"@fluid-tools/build-cli": "^0.37.0",
|
|
75
66
|
"@fluidframework/build-common": "^2.0.3",
|
|
76
|
-
"@fluidframework/build-tools": "^0.
|
|
77
|
-
"@fluidframework/eslint-config-fluid": "^
|
|
67
|
+
"@fluidframework/build-tools": "^0.37.0",
|
|
68
|
+
"@fluidframework/eslint-config-fluid": "^5.1.0",
|
|
78
69
|
"@fluidframework/odsp-driver-definitions-previous": "npm:@fluidframework/odsp-driver-definitions@2.0.0-internal.8.0.0",
|
|
79
70
|
"@fluidframework/protocol-definitions": "^3.2.0",
|
|
80
71
|
"@microsoft/api-extractor": "^7.42.3",
|
|
@@ -85,18 +76,6 @@
|
|
|
85
76
|
"rimraf": "^4.4.0",
|
|
86
77
|
"typescript": "~5.1.6"
|
|
87
78
|
},
|
|
88
|
-
"fluidBuild": {
|
|
89
|
-
"tasks": {
|
|
90
|
-
"build:docs": {
|
|
91
|
-
"dependsOn": [
|
|
92
|
-
"...",
|
|
93
|
-
"api-extractor:commonjs",
|
|
94
|
-
"api-extractor:esnext"
|
|
95
|
-
],
|
|
96
|
-
"script": false
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
},
|
|
100
79
|
"typeValidation": {
|
|
101
80
|
"broken": {
|
|
102
81
|
"RemovedEnumDeclaration_OdspErrorType": {
|
|
@@ -111,27 +90,27 @@
|
|
|
111
90
|
},
|
|
112
91
|
"scripts": {
|
|
113
92
|
"api": "fluid-build . --task api",
|
|
114
|
-
"api-extractor:commonjs": "
|
|
115
|
-
"api-extractor:esnext": "
|
|
93
|
+
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
|
|
94
|
+
"api-extractor:esnext": "flub generate entrypoints --outFileAlpha legacy --outDir ./lib --node10TypeCompat",
|
|
116
95
|
"build": "fluid-build . --task build",
|
|
117
96
|
"build:commonjs": "fluid-build . --task commonjs",
|
|
118
97
|
"build:compile": "fluid-build . --task compile",
|
|
119
|
-
"build:docs": "
|
|
98
|
+
"build:docs": "api-extractor run --local",
|
|
120
99
|
"build:esnext": "tsc --project ./tsconfig.json",
|
|
121
|
-
"build:test": "npm run build:test:
|
|
100
|
+
"build:test": "npm run build:test:esm && npm run build:test:cjs",
|
|
122
101
|
"build:test:cjs": "fluid-tsc commonjs --project ./src/test/tsconfig.cjs.json",
|
|
123
102
|
"build:test:esm": "tsc --project ./src/test/tsconfig.json",
|
|
124
|
-
"check:are-the-types-wrong": "attw --pack .
|
|
103
|
+
"check:are-the-types-wrong": "attw --pack .",
|
|
104
|
+
"check:prettier": "prettier --check . --cache --ignore-path ../../../.prettierignore",
|
|
125
105
|
"check:release-tags": "api-extractor run --local --config ./api-extractor-lint.json",
|
|
126
106
|
"ci:build:docs": "api-extractor run",
|
|
127
|
-
"clean": "rimraf --glob dist lib \"**/*.tsbuildinfo\" \"**/*.build.log\" _api-extractor-temp",
|
|
107
|
+
"clean": "rimraf --glob dist lib \"*.d.ts\" \"**/*.tsbuildinfo\" \"**/*.build.log\" _api-extractor-temp",
|
|
128
108
|
"eslint": "eslint --format stylish src",
|
|
129
109
|
"eslint:fix": "eslint --format stylish src --fix --fix-type problem,suggestion,layout",
|
|
130
|
-
"format": "
|
|
131
|
-
"
|
|
132
|
-
"lint
|
|
133
|
-
"
|
|
134
|
-
"prettier:fix": "prettier --write . --cache --ignore-path ../../../.prettierignore",
|
|
110
|
+
"format": "fluid-build --task format .",
|
|
111
|
+
"format:prettier": "prettier --write . --cache --ignore-path ../../../.prettierignore",
|
|
112
|
+
"lint": "fluid-build . --task lint",
|
|
113
|
+
"lint:fix": "fluid-build . --task eslint:fix --task format",
|
|
135
114
|
"tsc": "fluid-tsc commonjs --project ./tsconfig.cjs.json && copyfiles -f ../../../common/build/build-common/src/cjs/package.json ./dist",
|
|
136
115
|
"typetests:gen": "fluid-type-test-generator",
|
|
137
116
|
"typetests:prepare": "flub typetests --dir . --reset --previous --normalize"
|
package/src/errors.ts
CHANGED
|
@@ -2,11 +2,9 @@
|
|
|
2
2
|
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
DriverErrorTypes,
|
|
9
|
-
} from "@fluidframework/driver-definitions";
|
|
5
|
+
|
|
6
|
+
import { DriverErrorTypes, IDriverErrorBase } from "@fluidframework/driver-definitions";
|
|
7
|
+
import { DriverError } from "@fluidframework/driver-definitions/internal";
|
|
10
8
|
|
|
11
9
|
/**
|
|
12
10
|
* ODSP Error types.
|
package/src/index.ts
CHANGED
package/src/odspCache.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import {
|
|
6
|
+
import { type FiveDaysMs, IResolvedUrl } from "@fluidframework/driver-definitions/internal";
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* Must be less than IDocumentStorageServicePolicies.maximumCacheDurationMs policy of 5 days.
|
package/src/resolvedUrl.ts
CHANGED
package/src/sessionProvider.ts
CHANGED
package/src/tokenFetch.ts
CHANGED
|
@@ -112,4 +112,13 @@ export type InstrumentedStorageTokenFetcher = (
|
|
|
112
112
|
options: TokenFetchOptions,
|
|
113
113
|
name: string,
|
|
114
114
|
alwaysRecordTokenFetchTelemetry?: boolean,
|
|
115
|
+
) => Promise<string>;
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* @internal
|
|
119
|
+
*/
|
|
120
|
+
export type InstrumentedTokenFetcher = (
|
|
121
|
+
options: TokenFetchOptions,
|
|
122
|
+
name: string,
|
|
123
|
+
alwaysRecordTokenFetchTelemetry?: boolean,
|
|
115
124
|
) => Promise<string | null>;
|
package/api-extractor-cjs.json
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
|
|
3
|
-
"extends": "../../../common/build/build-common/api-extractor-base.cjs.primary.json",
|
|
4
|
-
// CJS is actually secondary; so, no report.
|
|
5
|
-
"apiReport": {
|
|
6
|
-
"enabled": false
|
|
7
|
-
}
|
|
8
|
-
}
|