MCPcopy Index your code
hub / github.com/codeceptjs/CodeceptJS / sendDeleteRequest

Method sendDeleteRequest

lib/helper/REST.js:438–446  ·  view source on GitHub ↗

* Sends DELETE request to API. * * ```js * I.sendDeleteRequest('/api/users/1'); * ``` * * @param {*} url * @param {object} [headers={}] - the headers object to be sent. By default, it is sent as an empty object * * @returns {Promise<*>} response

(url, headers = {})

Source from the content-addressed store, hash-verified

436 * @returns {Promise<*>} response
437 */
438 async sendDeleteRequest(url, headers = {}) {
439 const request = {
440 baseURL: this._url(url),
441 method: 'DELETE',
442 headers,
443 }
444
445 return this._executeRequest(request)
446 }
447
448 /**
449 * Sends DELETE request to API with payload.

Callers 1

REST_test.jsFile · 0.80

Calls 2

_urlMethod · 0.95
_executeRequestMethod · 0.95

Tested by

no test coverage detected