MCPcopy Index your code
hub / github.com/OneNoteDev/WebClipper / post

Method post

src/scripts/http/http.ts:21–26  ·  view source on GitHub ↗
(url: string, data: any, headers?: any, expectedCodes = [200], timeout = Http.defaultTimeout)

Source from the content-addressed store, hash-verified

19 }
20
21 public static post(url: string, data: any, headers?: any, expectedCodes = [200], timeout = Http.defaultTimeout): Promise<XMLHttpRequest> {
22 if (ObjectUtils.isNullOrUndefined(data)) {
23 throw new Error("data must be a non-undefined object, but was: " + data);
24 }
25 return Http.createAndSendRequest("POST", url, headers, expectedCodes, timeout, data);
26 }
27
28 protected static createAndSendRequest(method: string, url: string, headers?: any, expectedCodes = [200], timeout = Http.defaultTimeout, data?: any): Promise<XMLHttpRequest> {
29 if (!url) {

Callers 4

getFullPageScreenshotMethod · 0.45
testsMethod · 0.45

Calls 1

createAndSendRequestMethod · 0.80

Tested by

no test coverage detected