microsoft-graph 2.10.0 → 2.11.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.
Files changed (33) hide show
  1. package/dist/cjs/graphApi.d.ts.map +1 -1
  2. package/dist/cjs/graphApi.js +2 -17
  3. package/dist/cjs/models/GraphOperation.d.ts +1 -1
  4. package/dist/cjs/models/GraphOperation.d.ts.map +1 -1
  5. package/dist/cjs/operations/driveItem/createDriveItem.d.ts +15 -0
  6. package/dist/cjs/operations/driveItem/createDriveItem.d.ts.map +1 -0
  7. package/dist/cjs/operations/driveItem/createDriveItem.js +34 -0
  8. package/dist/cjs/operations/driveItem/existsDriveItem.d.ts.map +1 -1
  9. package/dist/cjs/operations/driveItem/existsDriveItem.js +2 -5
  10. package/dist/cjs/operations/driveItem/getDriveItemContent.d.ts.map +1 -1
  11. package/dist/cjs/operations/driveItem/getDriveItemContent.js +2 -5
  12. package/dist/cjs/services/http.d.ts +3 -0
  13. package/dist/cjs/services/http.d.ts.map +1 -0
  14. package/dist/cjs/services/http.js +27 -0
  15. package/dist/cjs/services/workbookWorksheet.d.ts +2 -1
  16. package/dist/cjs/services/workbookWorksheet.d.ts.map +1 -1
  17. package/dist/esm/graphApi.d.ts.map +1 -1
  18. package/dist/esm/graphApi.js +2 -17
  19. package/dist/esm/models/GraphOperation.d.ts +1 -1
  20. package/dist/esm/models/GraphOperation.d.ts.map +1 -1
  21. package/dist/esm/operations/driveItem/createDriveItem.d.ts +15 -0
  22. package/dist/esm/operations/driveItem/createDriveItem.d.ts.map +1 -0
  23. package/dist/esm/operations/driveItem/createDriveItem.js +31 -0
  24. package/dist/esm/operations/driveItem/existsDriveItem.d.ts.map +1 -1
  25. package/dist/esm/operations/driveItem/existsDriveItem.js +2 -2
  26. package/dist/esm/operations/driveItem/getDriveItemContent.d.ts.map +1 -1
  27. package/dist/esm/operations/driveItem/getDriveItemContent.js +2 -2
  28. package/dist/esm/services/http.d.ts +3 -0
  29. package/dist/esm/services/http.d.ts.map +1 -0
  30. package/dist/esm/services/http.js +21 -0
  31. package/dist/esm/services/workbookWorksheet.d.ts +2 -1
  32. package/dist/esm/services/workbookWorksheet.d.ts.map +1 -1
  33. package/package.json +21 -1
@@ -1 +1 @@
1
- {"version":3,"file":"graphApi.d.ts","sourceRoot":"","sources":["../../src/graphApi.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAgB,cAAc,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AACzG,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAO/C,eAAO,MAAM,mBAAmB,EAA6C,KAAK,CAAC;AACnF,eAAO,MAAM,QAAQ,qCAAqC,CAAC;AAC3D,eAAO,MAAM,aAAa,4CAAuB,CAAC;AAElD,8KAA8K;AAC9K,wBAAgB,SAAS,CAAC,CAAC,EAAE,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAQvF;AAED,6LAA6L;AAC7L,wBAAsB,QAAQ,CAAC,CAAC,SAAS,cAAc,CAAC,OAAO,CAAC,EAAE,EAAE,GAAG,UAAU,EAAE,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAInH;AAED,2DAA2D;AAC3D,wBAAsB,UAAU,CAAC,CAAC,SAAS,cAAc,CAAC,OAAO,CAAC,EAAE,EAAE,GAAG,UAAU,EAAE,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAOrH;AAoBD,KAAK,iBAAiB,CAAC,CAAC,IAAI;KAC1B,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,cAAc,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,GAAG,KAAK;CAChE,CAAC"}
1
+ {"version":3,"file":"graphApi.d.ts","sourceRoot":"","sources":["../../src/graphApi.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAgB,cAAc,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AACzG,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAQ/C,eAAO,MAAM,mBAAmB,EAA6C,KAAK,CAAC;AACnF,eAAO,MAAM,QAAQ,qCAAqC,CAAC;AAC3D,eAAO,MAAM,aAAa,4CAAuB,CAAC;AAElD,8KAA8K;AAC9K,wBAAgB,SAAS,CAAC,CAAC,EAAE,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAQvF;AAED,6LAA6L;AAC7L,wBAAsB,QAAQ,CAAC,CAAC,SAAS,cAAc,CAAC,OAAO,CAAC,EAAE,EAAE,GAAG,UAAU,EAAE,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAInH;AAED,2DAA2D;AAC3D,wBAAsB,UAAU,CAAC,CAAC,SAAS,cAAc,CAAC,OAAO,CAAC,EAAE,EAAE,GAAG,UAAU,EAAE,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAOrH;AAoBD,KAAK,iBAAiB,CAAC,CAAC,IAAI;KAC1B,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,cAAc,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,GAAG,KAAK;CAChE,CAAC"}
@@ -8,7 +8,6 @@ exports.operation = operation;
8
8
  exports.parallel = parallel;
9
9
  exports.sequential = sequential;
10
10
  const axios_1 = __importDefault(require("axios"));
11
- const https_proxy_agent_1 = require("https-proxy-agent");
12
11
  const InconsistentContextError_ts_1 = __importDefault(require("./errors/InconsistentContextError.js"));
13
12
  const InvalidArgumentError_ts_1 = __importDefault(require("./errors/InvalidArgumentError.js"));
14
13
  const NeverError_ts_1 = __importDefault(require("./errors/NeverError.js"));
@@ -19,6 +18,7 @@ const context_ts_1 = require("./services/context.js");
19
18
  const httpStatus_ts_1 = require("./services/httpStatus.js");
20
19
  const operationId_ts_1 = require("./services/operationId.js");
21
20
  const sleep_ts_1 = require("./services/sleep.js");
21
+ const http_ts_1 = require("./services/http.js");
22
22
  exports.authenticationScope = "https://graph.microsoft.com/.default";
23
23
  exports.endpoint = "https://graph.microsoft.com/v1.0";
24
24
  exports.batchEndpoint = `${exports.endpoint}/$batch`;
@@ -128,24 +128,9 @@ async function innerFetch(args) {
128
128
  let retryAfterMilliseconds = defaultRetryDelayMilliseconds;
129
129
  let response = null;
130
130
  let attempts = 0; // Track the number of attempts
131
- // TODO: Tidy this proxy work-around:
132
- let instance;
133
- // biome-ignore lint/complexity/useLiteralKeys: <explanation>
134
- const httpsProxy = process.env["HTTPS_PROXY"];
135
- if (httpsProxy) {
136
- instance = axios_1.default.create({
137
- proxy: false,
138
- httpsAgent: new https_proxy_agent_1.HttpsProxyAgent(httpsProxy),
139
- });
140
- }
141
- else {
142
- instance = axios_1.default.create({
143
- httpsAgent: options.httpAgent,
144
- });
145
- }
146
131
  while (attempts < maxRetries) {
147
132
  try {
148
- response = await instance({
133
+ response = await (0, http_ts_1.executeHttpRequest)({
149
134
  url,
150
135
  ...options,
151
136
  });
@@ -6,7 +6,7 @@ export type GraphPath = string & {
6
6
  };
7
7
  export type GraphHeaders = {
8
8
  "workbook-session-id"?: WorkbookSessionId | undefined;
9
- "content-type"?: "application/json" | "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" | undefined;
9
+ "content-type"?: string | undefined;
10
10
  };
11
11
  export type GraphOperationDefinition<T> = {
12
12
  /** Context to match the operation to. Used for authentication etc. */
@@ -1 +1 @@
1
- {"version":3,"file":"GraphOperation.d.ts","sourceRoot":"","sources":["../../../src/models/GraphOperation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAEhE,MAAM,MAAM,WAAW,GAAG,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,CAAC;AACtE,MAAM,MAAM,SAAS,GAAG,MAAM,GAAG;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AACrD,MAAM,MAAM,YAAY,GAAG;IAC1B,qBAAqB,CAAC,EAAE,iBAAiB,GAAG,SAAS,CAAC;IACtD,cAAc,CAAC,EAAE,kBAAkB,GAAG,mEAAmE,GAAG,SAAS,CAAC;CACtH,CAAC;AAGF,MAAM,MAAM,wBAAwB,CAAC,CAAC,IAAI;IACzC,sEAAsE;IACtE,SAAS,EAAE,SAAS,CAAC;IACrB,8BAA8B;IAC9B,MAAM,EAAE,WAAW,CAAC;IACpB,oJAAoJ;IACpJ,IAAI,EAAE,SAAS,CAAC;IAChB,kGAAkG;IAClG,OAAO,EAAE,YAAY,CAAC;IACtB,6LAA6L;IAC7L,IAAI,EAAE,OAAO,CAAC;IACd,wDAAwD;IACxD,iBAAiB,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,CAAC,CAAC;CAC5C,CAAC;AAEF,MAAM,MAAM,cAAc,CAAC,CAAC,IAAI,OAAO,CAAC,CAAC,CAAC,GAAG;IAC5C,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,CAAC;CACxC,CAAC"}
1
+ {"version":3,"file":"GraphOperation.d.ts","sourceRoot":"","sources":["../../../src/models/GraphOperation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAEhE,MAAM,MAAM,WAAW,GAAG,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,CAAC;AACtE,MAAM,MAAM,SAAS,GAAG,MAAM,GAAG;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AACrD,MAAM,MAAM,YAAY,GAAG;IAC1B,qBAAqB,CAAC,EAAE,iBAAiB,GAAG,SAAS,CAAC;IACtD,cAAc,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACpC,CAAC;AAGF,MAAM,MAAM,wBAAwB,CAAC,CAAC,IAAI;IACzC,sEAAsE;IACtE,SAAS,EAAE,SAAS,CAAC;IACrB,8BAA8B;IAC9B,MAAM,EAAE,WAAW,CAAC;IACpB,oJAAoJ;IACpJ,IAAI,EAAE,SAAS,CAAC;IAChB,kGAAkG;IAClG,OAAO,EAAE,YAAY,CAAC;IACtB,6LAA6L;IAC7L,IAAI,EAAE,OAAO,CAAC;IACd,wDAAwD;IACxD,iBAAiB,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,CAAC,CAAC;CAC5C,CAAC;AAEF,MAAM,MAAM,cAAc,CAAC,CAAC,IAAI,OAAO,CAAC,CAAC,CAAC,GAAG;IAC5C,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,CAAC;CACxC,CAAC"}
@@ -0,0 +1,15 @@
1
+ import type { DriveItem } from "@microsoft/microsoft-graph-types";
2
+ import type { DriveItemPath } from "../../models/DriveItemPath.ts";
3
+ import type { DriveItemRef } from "../../models/DriveItemRef.ts";
4
+ import type { DriveRef } from "../../models/DriveRef.ts";
5
+ import type { GraphOperation } from "../../models/GraphOperation.ts";
6
+ /**
7
+ * Creates new drive item in the specified parent drive or folder. If the file already exists, it will be replaced.
8
+ *
9
+ * @param parentRef - A reference to the parent drive or folder where the workbook will be created.
10
+ * @param itemPath - The path (including the filename) for the new workbook.
11
+ * @returns The newly created workbook, including its metadata and reference information.
12
+ * @see https://learn.microsoft.com/en-us/graph/api/driveitem-put-content
13
+ */
14
+ export default function createDriveItem(parentRef: DriveRef | DriveItemRef, itemPath: DriveItemPath, contextType: string, content: ArrayBuffer): GraphOperation<DriveItem & DriveItemRef>;
15
+ //# sourceMappingURL=createDriveItem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createDriveItem.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/createDriveItem.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAGlE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAIrE;;;;;;;GAOG;AACH,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,SAAS,EAAE,QAAQ,GAAG,YAAY,EAAE,QAAQ,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,EAAE,OAAO,EAAE,WAAW,GAAG,cAAc,CAAC,SAAS,GAAG,YAAY,CAAC,CAsBxL"}
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = createDriveItem;
4
+ const graphApi_ts_1 = require("../../graphApi.js");
5
+ const driveItem_ts_1 = require("../../services/driveItem.js");
6
+ const templatedPaths_ts_1 = require("../../services/templatedPaths.js");
7
+ /**
8
+ * Creates new drive item in the specified parent drive or folder. If the file already exists, it will be replaced.
9
+ *
10
+ * @param parentRef - A reference to the parent drive or folder where the workbook will be created.
11
+ * @param itemPath - The path (including the filename) for the new workbook.
12
+ * @returns The newly created workbook, including its metadata and reference information.
13
+ * @see https://learn.microsoft.com/en-us/graph/api/driveitem-put-content
14
+ */
15
+ function createDriveItem(parentRef, itemPath, contextType, content) {
16
+ const pathSegment = parentRef.itemId ? "items/{item-id}" : "root";
17
+ return (0, graphApi_ts_1.operation)({
18
+ contextId: parentRef.contextId,
19
+ method: "PUT",
20
+ path: (0, templatedPaths_ts_1.generatePath)(`/sites/{site-id}/drives/{drive-id}/${pathSegment}:/${itemPath}:/content`, parentRef),
21
+ headers: {
22
+ "content-type": contextType,
23
+ },
24
+ body: content,
25
+ responseTransform: (response) => {
26
+ const driveItem = response;
27
+ const itemRef = (0, driveItem_ts_1.createDriveItemRef)(parentRef, driveItem.id);
28
+ return {
29
+ ...driveItem,
30
+ ...itemRef,
31
+ };
32
+ },
33
+ });
34
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"existsDriveItem.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/existsDriveItem.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAMzD;;;;;GAKG;AACH,wBAA8B,eAAe,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,aAAa,GAAG,OAAO,CAAC,OAAO,CAAC,CAwB3G"}
1
+ {"version":3,"file":"existsDriveItem.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/existsDriveItem.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAOzD;;;;;GAKG;AACH,wBAA8B,eAAe,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,aAAa,GAAG,OAAO,CAAC,OAAO,CAAC,CAwB3G"}
@@ -1,13 +1,10 @@
1
1
  "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
2
  Object.defineProperty(exports, "__esModule", { value: true });
6
3
  exports.default = existsDriveItem;
7
- const axios_1 = __importDefault(require("axios"));
8
4
  const graphApi_ts_1 = require("../../graphApi.js");
9
5
  const accessToken_ts_1 = require("../../services/accessToken.js");
10
6
  const context_ts_1 = require("../../services/context.js");
7
+ const http_ts_1 = require("../../services/http.js");
11
8
  const httpStatus_ts_1 = require("../../services/httpStatus.js");
12
9
  const templatedPaths_ts_1 = require("../../services/templatedPaths.js");
13
10
  /**
@@ -21,7 +18,7 @@ async function existsDriveItem(driveRef, itemPath) {
21
18
  const url = `${graphApi_ts_1.endpoint}${(0, templatedPaths_ts_1.generatePath)(`/sites/{site-id}/drives/{drive-id}/root:${itemPath}`, driveRef)}`;
22
19
  const context = (0, context_ts_1.getContext)(driveRef.contextId);
23
20
  const accessToken = await (0, accessToken_ts_1.getCurrentAccessToken)(context.tenantId, context.clientId, context.clientSecret, graphApi_ts_1.authenticationScope);
24
- const response = await (0, axios_1.default)({
21
+ const response = await (0, http_ts_1.executeHttpRequest)({
25
22
  url,
26
23
  method: "GET",
27
24
  headers: {
@@ -1 +1 @@
1
- {"version":3,"file":"getDriveItemContent.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/getDriveItemContent.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAMjE;;;;;;;GAOG;AACH,wBAA8B,mBAAmB,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,WAAW,CAAC,CA8B7F"}
1
+ {"version":3,"file":"getDriveItemContent.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/getDriveItemContent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAOjE;;;;;;;GAOG;AACH,wBAA8B,mBAAmB,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,WAAW,CAAC,CA8B7F"}
@@ -1,13 +1,10 @@
1
1
  "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
2
  Object.defineProperty(exports, "__esModule", { value: true });
6
3
  exports.default = getDriveItemContent;
7
- const axios_1 = __importDefault(require("axios"));
8
4
  const graphApi_ts_1 = require("../../graphApi.js");
9
5
  const accessToken_ts_1 = require("../../services/accessToken.js");
10
6
  const context_ts_1 = require("../../services/context.js");
7
+ const http_ts_1 = require("../../services/http.js");
11
8
  const httpStatus_ts_1 = require("../../services/httpStatus.js");
12
9
  const templatedPaths_ts_1 = require("../../services/templatedPaths.js");
13
10
  /**
@@ -23,7 +20,7 @@ async function getDriveItemContent(itemRef) {
23
20
  const url = `${graphApi_ts_1.endpoint}${(0, templatedPaths_ts_1.generatePath)("/sites/{site-id}/drives/{drive-id}/items/{item-id}/content", itemRef)}`;
24
21
  const context = (0, context_ts_1.getContext)(itemRef.contextId);
25
22
  const accessToken = await (0, accessToken_ts_1.getCurrentAccessToken)(context.tenantId, context.clientId, context.clientSecret, graphApi_ts_1.authenticationScope);
26
- const response = await (0, axios_1.default)({
23
+ const response = await (0, http_ts_1.executeHttpRequest)({
27
24
  url,
28
25
  method: "GET",
29
26
  headers: {
@@ -0,0 +1,3 @@
1
+ import { type AxiosRequestConfig } from "axios";
2
+ export declare function executeHttpRequest(config: AxiosRequestConfig): Promise<import("axios").AxiosResponse<any, any>>;
3
+ //# sourceMappingURL=http.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../../src/services/http.ts"],"names":[],"mappings":"AAAA,OAAc,EAAsB,KAAK,kBAAkB,EAA4B,MAAM,OAAO,CAAC;AAKrG,wBAAsB,kBAAkB,CAAC,MAAM,EAAE,kBAAkB,oDAMlE"}
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.executeHttpRequest = executeHttpRequest;
7
+ const axios_1 = __importDefault(require("axios"));
8
+ const https_proxy_agent_1 = require("https-proxy-agent");
9
+ let instance = null;
10
+ async function executeHttpRequest(config) {
11
+ if (!instance) {
12
+ instance = createAxiosInstance();
13
+ }
14
+ return await instance(config);
15
+ }
16
+ function createAxiosInstance() {
17
+ const config = {
18
+ validateStatus: () => true,
19
+ };
20
+ // biome-ignore lint/complexity/useLiteralKeys: Accessing env
21
+ const httpsProxy = process.env["HTTPS_PROXY"];
22
+ if (httpsProxy) {
23
+ config.proxy = false;
24
+ config.httpsAgent = new https_proxy_agent_1.HttpsProxyAgent(httpsProxy);
25
+ }
26
+ return axios_1.default.create(config);
27
+ }
@@ -1,10 +1,11 @@
1
1
  import type { WorkbookRef } from "../models/WorkbookRef.ts";
2
2
  import type { WorkbookWorksheetId } from "../models/WorkbookWorksheetId.ts";
3
+ import type { WorkbookWorksheetName } from "../models/WorkbookWorksheetName.ts";
3
4
  import type { WorkbookWorksheetRef } from "../models/WorkbookWorksheetRef.ts";
4
5
  /** ID of the initial worksheet that is included in a new workbook. */
5
6
  export declare const defaultWorkbookWorksheetId: WorkbookWorksheetId;
6
7
  /** Name of the initial worksheet that is included in a new workbook. */
7
- export declare const defaultWorkbookWorksheetName = "Sheet1";
8
+ export declare const defaultWorkbookWorksheetName: WorkbookWorksheetName;
8
9
  /**
9
10
  * Creates a reference to a workbook worksheet.
10
11
  * @param workbookRef - The reference to the workbook.
@@ -1 +1 @@
1
- {"version":3,"file":"workbookWorksheet.d.ts","sourceRoot":"","sources":["../../../src/services/workbookWorksheet.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,mCAAmC,CAAC;AAE9E,sEAAsE;AACtE,eAAO,MAAM,0BAA0B,EAA+C,mBAAmB,CAAC;AAE1G,wEAAwE;AACxE,eAAO,MAAM,4BAA4B,WAAW,CAAC;AAErD;;;;;;GAMG;AACH,wBAAgB,0BAA0B,CAAC,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,mBAAmB,GAAG,SAAS,GAAG,oBAAoB,CAavI;AAED;;;;GAIG;AACH,wBAAgB,iCAAiC,CAAC,WAAW,EAAE,WAAW,GAAG,oBAAoB,CAEhG"}
1
+ {"version":3,"file":"workbookWorksheet.d.ts","sourceRoot":"","sources":["../../../src/services/workbookWorksheet.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAC;AAChF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,mCAAmC,CAAC;AAE9E,sEAAsE;AACtE,eAAO,MAAM,0BAA0B,EAA+C,mBAAmB,CAAC;AAE1G,wEAAwE;AACxE,eAAO,MAAM,4BAA4B,EAAe,qBAAqB,CAAC;AAE9E;;;;;;GAMG;AACH,wBAAgB,0BAA0B,CAAC,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,mBAAmB,GAAG,SAAS,GAAG,oBAAoB,CAavI;AAED;;;;GAIG;AACH,wBAAgB,iCAAiC,CAAC,WAAW,EAAE,WAAW,GAAG,oBAAoB,CAEhG"}
@@ -1 +1 @@
1
- {"version":3,"file":"graphApi.d.ts","sourceRoot":"","sources":["../../src/graphApi.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAgB,cAAc,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AACzG,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAO/C,eAAO,MAAM,mBAAmB,EAA6C,KAAK,CAAC;AACnF,eAAO,MAAM,QAAQ,qCAAqC,CAAC;AAC3D,eAAO,MAAM,aAAa,4CAAuB,CAAC;AAElD,8KAA8K;AAC9K,wBAAgB,SAAS,CAAC,CAAC,EAAE,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAQvF;AAED,6LAA6L;AAC7L,wBAAsB,QAAQ,CAAC,CAAC,SAAS,cAAc,CAAC,OAAO,CAAC,EAAE,EAAE,GAAG,UAAU,EAAE,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAInH;AAED,2DAA2D;AAC3D,wBAAsB,UAAU,CAAC,CAAC,SAAS,cAAc,CAAC,OAAO,CAAC,EAAE,EAAE,GAAG,UAAU,EAAE,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAOrH;AAoBD,KAAK,iBAAiB,CAAC,CAAC,IAAI;KAC1B,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,cAAc,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,GAAG,KAAK;CAChE,CAAC"}
1
+ {"version":3,"file":"graphApi.d.ts","sourceRoot":"","sources":["../../src/graphApi.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAgB,cAAc,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AACzG,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAQ/C,eAAO,MAAM,mBAAmB,EAA6C,KAAK,CAAC;AACnF,eAAO,MAAM,QAAQ,qCAAqC,CAAC;AAC3D,eAAO,MAAM,aAAa,4CAAuB,CAAC;AAElD,8KAA8K;AAC9K,wBAAgB,SAAS,CAAC,CAAC,EAAE,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAQvF;AAED,6LAA6L;AAC7L,wBAAsB,QAAQ,CAAC,CAAC,SAAS,cAAc,CAAC,OAAO,CAAC,EAAE,EAAE,GAAG,UAAU,EAAE,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAInH;AAED,2DAA2D;AAC3D,wBAAsB,UAAU,CAAC,CAAC,SAAS,cAAc,CAAC,OAAO,CAAC,EAAE,EAAE,GAAG,UAAU,EAAE,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAOrH;AAoBD,KAAK,iBAAiB,CAAC,CAAC,IAAI;KAC1B,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,cAAc,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,GAAG,KAAK;CAChE,CAAC"}
@@ -1,5 +1,4 @@
1
1
  import axios from "axios";
2
- import { HttpsProxyAgent } from "https-proxy-agent";
3
2
  import InconsistentContextError from "./errors/InconsistentContextError.js";
4
3
  import InvalidArgumentError from "./errors/InvalidArgumentError.js";
5
4
  import NeverError from "./errors/NeverError.js";
@@ -10,6 +9,7 @@ import { getContext } from "./services/context.js";
10
9
  import { isGatewayTimeout, isHttpSuccess, isHttpTooManyRequests, isServiceUnavailable } from "./services/httpStatus.js";
11
10
  import { operationIdToIndex, operationIndexToId } from "./services/operationId.js";
12
11
  import { sleep } from "./services/sleep.js";
12
+ import { executeHttpRequest } from "./services/http.js";
13
13
  export const authenticationScope = "https://graph.microsoft.com/.default";
14
14
  export const endpoint = "https://graph.microsoft.com/v1.0";
15
15
  export const batchEndpoint = `${endpoint}/$batch`;
@@ -119,24 +119,9 @@ async function innerFetch(args) {
119
119
  let retryAfterMilliseconds = defaultRetryDelayMilliseconds;
120
120
  let response = null;
121
121
  let attempts = 0; // Track the number of attempts
122
- // TODO: Tidy this proxy work-around:
123
- let instance;
124
- // biome-ignore lint/complexity/useLiteralKeys: <explanation>
125
- const httpsProxy = process.env["HTTPS_PROXY"];
126
- if (httpsProxy) {
127
- instance = axios.create({
128
- proxy: false,
129
- httpsAgent: new HttpsProxyAgent(httpsProxy),
130
- });
131
- }
132
- else {
133
- instance = axios.create({
134
- httpsAgent: options.httpAgent,
135
- });
136
- }
137
122
  while (attempts < maxRetries) {
138
123
  try {
139
- response = await instance({
124
+ response = await executeHttpRequest({
140
125
  url,
141
126
  ...options,
142
127
  });
@@ -6,7 +6,7 @@ export type GraphPath = string & {
6
6
  };
7
7
  export type GraphHeaders = {
8
8
  "workbook-session-id"?: WorkbookSessionId | undefined;
9
- "content-type"?: "application/json" | "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" | undefined;
9
+ "content-type"?: string | undefined;
10
10
  };
11
11
  export type GraphOperationDefinition<T> = {
12
12
  /** Context to match the operation to. Used for authentication etc. */
@@ -1 +1 @@
1
- {"version":3,"file":"GraphOperation.d.ts","sourceRoot":"","sources":["../../../src/models/GraphOperation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAEhE,MAAM,MAAM,WAAW,GAAG,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,CAAC;AACtE,MAAM,MAAM,SAAS,GAAG,MAAM,GAAG;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AACrD,MAAM,MAAM,YAAY,GAAG;IAC1B,qBAAqB,CAAC,EAAE,iBAAiB,GAAG,SAAS,CAAC;IACtD,cAAc,CAAC,EAAE,kBAAkB,GAAG,mEAAmE,GAAG,SAAS,CAAC;CACtH,CAAC;AAGF,MAAM,MAAM,wBAAwB,CAAC,CAAC,IAAI;IACzC,sEAAsE;IACtE,SAAS,EAAE,SAAS,CAAC;IACrB,8BAA8B;IAC9B,MAAM,EAAE,WAAW,CAAC;IACpB,oJAAoJ;IACpJ,IAAI,EAAE,SAAS,CAAC;IAChB,kGAAkG;IAClG,OAAO,EAAE,YAAY,CAAC;IACtB,6LAA6L;IAC7L,IAAI,EAAE,OAAO,CAAC;IACd,wDAAwD;IACxD,iBAAiB,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,CAAC,CAAC;CAC5C,CAAC;AAEF,MAAM,MAAM,cAAc,CAAC,CAAC,IAAI,OAAO,CAAC,CAAC,CAAC,GAAG;IAC5C,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,CAAC;CACxC,CAAC"}
1
+ {"version":3,"file":"GraphOperation.d.ts","sourceRoot":"","sources":["../../../src/models/GraphOperation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAEhE,MAAM,MAAM,WAAW,GAAG,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,CAAC;AACtE,MAAM,MAAM,SAAS,GAAG,MAAM,GAAG;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AACrD,MAAM,MAAM,YAAY,GAAG;IAC1B,qBAAqB,CAAC,EAAE,iBAAiB,GAAG,SAAS,CAAC;IACtD,cAAc,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACpC,CAAC;AAGF,MAAM,MAAM,wBAAwB,CAAC,CAAC,IAAI;IACzC,sEAAsE;IACtE,SAAS,EAAE,SAAS,CAAC;IACrB,8BAA8B;IAC9B,MAAM,EAAE,WAAW,CAAC;IACpB,oJAAoJ;IACpJ,IAAI,EAAE,SAAS,CAAC;IAChB,kGAAkG;IAClG,OAAO,EAAE,YAAY,CAAC;IACtB,6LAA6L;IAC7L,IAAI,EAAE,OAAO,CAAC;IACd,wDAAwD;IACxD,iBAAiB,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,CAAC,CAAC;CAC5C,CAAC;AAEF,MAAM,MAAM,cAAc,CAAC,CAAC,IAAI,OAAO,CAAC,CAAC,CAAC,GAAG;IAC5C,UAAU,EAAE,wBAAwB,CAAC,CAAC,CAAC,CAAC;CACxC,CAAC"}
@@ -0,0 +1,15 @@
1
+ import type { DriveItem } from "@microsoft/microsoft-graph-types";
2
+ import type { DriveItemPath } from "../../models/DriveItemPath.ts";
3
+ import type { DriveItemRef } from "../../models/DriveItemRef.ts";
4
+ import type { DriveRef } from "../../models/DriveRef.ts";
5
+ import type { GraphOperation } from "../../models/GraphOperation.ts";
6
+ /**
7
+ * Creates new drive item in the specified parent drive or folder. If the file already exists, it will be replaced.
8
+ *
9
+ * @param parentRef - A reference to the parent drive or folder where the workbook will be created.
10
+ * @param itemPath - The path (including the filename) for the new workbook.
11
+ * @returns The newly created workbook, including its metadata and reference information.
12
+ * @see https://learn.microsoft.com/en-us/graph/api/driveitem-put-content
13
+ */
14
+ export default function createDriveItem(parentRef: DriveRef | DriveItemRef, itemPath: DriveItemPath, contextType: string, content: ArrayBuffer): GraphOperation<DriveItem & DriveItemRef>;
15
+ //# sourceMappingURL=createDriveItem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createDriveItem.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/createDriveItem.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAGlE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAIrE;;;;;;;GAOG;AACH,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,SAAS,EAAE,QAAQ,GAAG,YAAY,EAAE,QAAQ,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,EAAE,OAAO,EAAE,WAAW,GAAG,cAAc,CAAC,SAAS,GAAG,YAAY,CAAC,CAsBxL"}
@@ -0,0 +1,31 @@
1
+ import { operation } from "../../graphApi.js";
2
+ import { createDriveItemRef } from "../../services/driveItem.js";
3
+ import { generatePath } from "../../services/templatedPaths.js";
4
+ /**
5
+ * Creates new drive item in the specified parent drive or folder. If the file already exists, it will be replaced.
6
+ *
7
+ * @param parentRef - A reference to the parent drive or folder where the workbook will be created.
8
+ * @param itemPath - The path (including the filename) for the new workbook.
9
+ * @returns The newly created workbook, including its metadata and reference information.
10
+ * @see https://learn.microsoft.com/en-us/graph/api/driveitem-put-content
11
+ */
12
+ export default function createDriveItem(parentRef, itemPath, contextType, content) {
13
+ const pathSegment = parentRef.itemId ? "items/{item-id}" : "root";
14
+ return operation({
15
+ contextId: parentRef.contextId,
16
+ method: "PUT",
17
+ path: generatePath(`/sites/{site-id}/drives/{drive-id}/${pathSegment}:/${itemPath}:/content`, parentRef),
18
+ headers: {
19
+ "content-type": contextType,
20
+ },
21
+ body: content,
22
+ responseTransform: (response) => {
23
+ const driveItem = response;
24
+ const itemRef = createDriveItemRef(parentRef, driveItem.id);
25
+ return {
26
+ ...driveItem,
27
+ ...itemRef,
28
+ };
29
+ },
30
+ });
31
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"existsDriveItem.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/existsDriveItem.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAMzD;;;;;GAKG;AACH,wBAA8B,eAAe,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,aAAa,GAAG,OAAO,CAAC,OAAO,CAAC,CAwB3G"}
1
+ {"version":3,"file":"existsDriveItem.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/existsDriveItem.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAOzD;;;;;GAKG;AACH,wBAA8B,eAAe,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,aAAa,GAAG,OAAO,CAAC,OAAO,CAAC,CAwB3G"}
@@ -1,7 +1,7 @@
1
- import axios from "axios";
2
1
  import { authenticationScope, endpoint } from "../../graphApi.js";
3
2
  import { getCurrentAccessToken } from "../../services/accessToken.js";
4
3
  import { getContext } from "../../services/context.js";
4
+ import { executeHttpRequest } from "../../services/http.js";
5
5
  import { isHttpNotFound, isHttpOk } from "../../services/httpStatus.js";
6
6
  import { generatePath } from "../../services/templatedPaths.js";
7
7
  /**
@@ -15,7 +15,7 @@ export default async function existsDriveItem(driveRef, itemPath) {
15
15
  const url = `${endpoint}${generatePath(`/sites/{site-id}/drives/{drive-id}/root:${itemPath}`, driveRef)}`;
16
16
  const context = getContext(driveRef.contextId);
17
17
  const accessToken = await getCurrentAccessToken(context.tenantId, context.clientId, context.clientSecret, authenticationScope);
18
- const response = await axios({
18
+ const response = await executeHttpRequest({
19
19
  url,
20
20
  method: "GET",
21
21
  headers: {
@@ -1 +1 @@
1
- {"version":3,"file":"getDriveItemContent.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/getDriveItemContent.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAMjE;;;;;;;GAOG;AACH,wBAA8B,mBAAmB,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,WAAW,CAAC,CA8B7F"}
1
+ {"version":3,"file":"getDriveItemContent.d.ts","sourceRoot":"","sources":["../../../../src/operations/driveItem/getDriveItemContent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAOjE;;;;;;;GAOG;AACH,wBAA8B,mBAAmB,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,WAAW,CAAC,CA8B7F"}
@@ -1,7 +1,7 @@
1
- import axios from "axios";
2
1
  import { authenticationScope, endpoint } from "../../graphApi.js";
3
2
  import { getCurrentAccessToken } from "../../services/accessToken.js";
4
3
  import { getContext } from "../../services/context.js";
4
+ import { executeHttpRequest } from "../../services/http.js";
5
5
  import { isHttpSuccess } from "../../services/httpStatus.js";
6
6
  import { generatePath } from "../../services/templatedPaths.js";
7
7
  /**
@@ -17,7 +17,7 @@ export default async function getDriveItemContent(itemRef) {
17
17
  const url = `${endpoint}${generatePath("/sites/{site-id}/drives/{drive-id}/items/{item-id}/content", itemRef)}`;
18
18
  const context = getContext(itemRef.contextId);
19
19
  const accessToken = await getCurrentAccessToken(context.tenantId, context.clientId, context.clientSecret, authenticationScope);
20
- const response = await axios({
20
+ const response = await executeHttpRequest({
21
21
  url,
22
22
  method: "GET",
23
23
  headers: {
@@ -0,0 +1,3 @@
1
+ import { type AxiosRequestConfig } from "axios";
2
+ export declare function executeHttpRequest(config: AxiosRequestConfig): Promise<import("axios").AxiosResponse<any, any>>;
3
+ //# sourceMappingURL=http.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../../src/services/http.ts"],"names":[],"mappings":"AAAA,OAAc,EAAsB,KAAK,kBAAkB,EAA4B,MAAM,OAAO,CAAC;AAKrG,wBAAsB,kBAAkB,CAAC,MAAM,EAAE,kBAAkB,oDAMlE"}
@@ -0,0 +1,21 @@
1
+ import axios from "axios";
2
+ import { HttpsProxyAgent } from "https-proxy-agent";
3
+ let instance = null;
4
+ export async function executeHttpRequest(config) {
5
+ if (!instance) {
6
+ instance = createAxiosInstance();
7
+ }
8
+ return await instance(config);
9
+ }
10
+ function createAxiosInstance() {
11
+ const config = {
12
+ validateStatus: () => true,
13
+ };
14
+ // biome-ignore lint/complexity/useLiteralKeys: Accessing env
15
+ const httpsProxy = process.env["HTTPS_PROXY"];
16
+ if (httpsProxy) {
17
+ config.proxy = false;
18
+ config.httpsAgent = new HttpsProxyAgent(httpsProxy);
19
+ }
20
+ return axios.create(config);
21
+ }
@@ -1,10 +1,11 @@
1
1
  import type { WorkbookRef } from "../models/WorkbookRef.ts";
2
2
  import type { WorkbookWorksheetId } from "../models/WorkbookWorksheetId.ts";
3
+ import type { WorkbookWorksheetName } from "../models/WorkbookWorksheetName.ts";
3
4
  import type { WorkbookWorksheetRef } from "../models/WorkbookWorksheetRef.ts";
4
5
  /** ID of the initial worksheet that is included in a new workbook. */
5
6
  export declare const defaultWorkbookWorksheetId: WorkbookWorksheetId;
6
7
  /** Name of the initial worksheet that is included in a new workbook. */
7
- export declare const defaultWorkbookWorksheetName = "Sheet1";
8
+ export declare const defaultWorkbookWorksheetName: WorkbookWorksheetName;
8
9
  /**
9
10
  * Creates a reference to a workbook worksheet.
10
11
  * @param workbookRef - The reference to the workbook.
@@ -1 +1 @@
1
- {"version":3,"file":"workbookWorksheet.d.ts","sourceRoot":"","sources":["../../../src/services/workbookWorksheet.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,mCAAmC,CAAC;AAE9E,sEAAsE;AACtE,eAAO,MAAM,0BAA0B,EAA+C,mBAAmB,CAAC;AAE1G,wEAAwE;AACxE,eAAO,MAAM,4BAA4B,WAAW,CAAC;AAErD;;;;;;GAMG;AACH,wBAAgB,0BAA0B,CAAC,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,mBAAmB,GAAG,SAAS,GAAG,oBAAoB,CAavI;AAED;;;;GAIG;AACH,wBAAgB,iCAAiC,CAAC,WAAW,EAAE,WAAW,GAAG,oBAAoB,CAEhG"}
1
+ {"version":3,"file":"workbookWorksheet.d.ts","sourceRoot":"","sources":["../../../src/services/workbookWorksheet.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAC;AAChF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,mCAAmC,CAAC;AAE9E,sEAAsE;AACtE,eAAO,MAAM,0BAA0B,EAA+C,mBAAmB,CAAC;AAE1G,wEAAwE;AACxE,eAAO,MAAM,4BAA4B,EAAe,qBAAqB,CAAC;AAE9E;;;;;;GAMG;AACH,wBAAgB,0BAA0B,CAAC,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,mBAAmB,GAAG,SAAS,GAAG,oBAAoB,CAavI;AAED;;;;GAIG;AACH,wBAAgB,iCAAiC,CAAC,WAAW,EAAE,WAAW,GAAG,oBAAoB,CAEhG"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "microsoft-graph",
3
- "version": "2.10.0",
3
+ "version": "2.11.1",
4
4
  "description": "Microsoft GraphAPI SDK for NodeJS",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/esm/index.js",
@@ -312,6 +312,11 @@
312
312
  "require": "./dist/cjs/operations/drive/listDrives.js",
313
313
  "types": "./dist/esm/operations/drive/listDrives.d.ts"
314
314
  },
315
+ "./operations/driveItem/createDriveItem": {
316
+ "import": "./dist/esm/operations/driveItem/createDriveItem.js",
317
+ "require": "./dist/cjs/operations/driveItem/createDriveItem.js",
318
+ "types": "./dist/esm/operations/driveItem/createDriveItem.d.ts"
319
+ },
315
320
  "./operations/driveItem/deleteDriveItem": {
316
321
  "import": "./dist/esm/operations/driveItem/deleteDriveItem.js",
317
322
  "require": "./dist/cjs/operations/driveItem/deleteDriveItem.js",
@@ -612,6 +617,11 @@
612
617
  "require": "./dist/cjs/services/environmentVariable.js",
613
618
  "types": "./dist/esm/services/environmentVariable.d.ts"
614
619
  },
620
+ "./services/http": {
621
+ "import": "./dist/esm/services/http.js",
622
+ "require": "./dist/cjs/services/http.js",
623
+ "types": "./dist/esm/services/http.d.ts"
624
+ },
615
625
  "./services/httpStatus": {
616
626
  "import": "./dist/esm/services/httpStatus.js",
617
627
  "require": "./dist/cjs/services/httpStatus.js",
@@ -1012,6 +1022,11 @@
1012
1022
  "import": "./dist/esm/operations/drive/listDrives.js",
1013
1023
  "types": "./dist/esm/operations/drive/listDrives.d.ts"
1014
1024
  },
1025
+ "./dist/cjs/operations/driveItem/createDriveItem.js": {
1026
+ "require": "./dist/cjs/operations/driveItem/createDriveItem.js",
1027
+ "import": "./dist/esm/operations/driveItem/createDriveItem.js",
1028
+ "types": "./dist/esm/operations/driveItem/createDriveItem.d.ts"
1029
+ },
1015
1030
  "./dist/cjs/operations/driveItem/deleteDriveItem.js": {
1016
1031
  "require": "./dist/cjs/operations/driveItem/deleteDriveItem.js",
1017
1032
  "import": "./dist/esm/operations/driveItem/deleteDriveItem.js",
@@ -1312,6 +1327,11 @@
1312
1327
  "import": "./dist/esm/services/environmentVariable.js",
1313
1328
  "types": "./dist/esm/services/environmentVariable.d.ts"
1314
1329
  },
1330
+ "./dist/cjs/services/http.js": {
1331
+ "require": "./dist/cjs/services/http.js",
1332
+ "import": "./dist/esm/services/http.js",
1333
+ "types": "./dist/esm/services/http.d.ts"
1334
+ },
1315
1335
  "./dist/cjs/services/httpStatus.js": {
1316
1336
  "require": "./dist/cjs/services/httpStatus.js",
1317
1337
  "import": "./dist/esm/services/httpStatus.js",