UNPKG

@microsoft/msgraph-sdk-core

Version:
41 lines 1.84 kB
import { ErrorMappings, RequestAdapter } from "@microsoft/kiota-abstractions"; import { BatchResponseContent } from "./BatchResponseContent.js"; import { BatchRequestContent } from "./BatchRequestContent.js"; import { BatchRequestContentCollection } from "./BatchRequestContentCollection.js"; import { BatchResponseContentCollection } from "./BatchResponseContentCollection.js"; export declare class BatchRequestBuilder { /** * @private * @static * Executes the requests in the batch request content */ private readonly requestAdapter; /** * @private * @static * Error mappings to be used while deserializing the response */ private readonly errorMappings; /** * Creates an instance of BatchRequestContent. * @param {RequestAdapter} requestAdapter - The request adapter to be used for executing the requests. * @param {ErrorMappings} errorMappings - The error mappings to be used while deserializing the response. * @throws {Error} If the request adapter is undefined. * @throws {Error} If the error mappings are undefined. */ constructor(requestAdapter: RequestAdapter, errorMappings: ErrorMappings); /** * @public * @async * Executes the batch request */ postBatchResponseContentAsync(batchRequestContent: BatchRequestContent): Promise<BatchResponseContent | undefined>; /** * Executes the batch requests asynchronously. * * @returns {Promise<BatchResponseContent | undefined>} A promise that resolves to the batch response content or undefined. * @throws {Error} If the batch limit is exceeded. */ postBatchRequestContentCollectionAsync(collection: BatchRequestContentCollection): Promise<BatchResponseContentCollection | undefined>; } //# sourceMappingURL=BatchRequestBuilder.d.ts.map