http.delete
Sends a HTTP DELETE request to any URL using Axios.
Parameters
| Parameter | Description |
|---|---|
| url: string | Target URL |
| config?: object | Axios HTTP configuration for sending HTTP headers, setting up a proxy, etc. (Optional) |
Returns
Promise that is resolved with an Axios response object.
The returned data is in the 'data' property of the response.
Examples
Deletes an entity using a REST API endpoint
module.exports = async function(payload, actions, context) {
await actions.http.delete('http://my.api.com/things/1');
console.log('deleted a thing with id=1');
}