Widget delete
Endpoint DELETE /widgets/:id
Delete a user's widget.
Path Parameters
Required
id
- The widget's id.
Query parameters:
permanent
-false
by default. Iftrue
, the widget will be permanently deleted and cannot be restored.
Example Request:
- curl
- Node.js
curl -X DELETE -H "Authorization: Bearer ACCESS_TOKEN" "https://api.commoninja.com/platform/api/v1/widgets/894f5aed-29f5-46c5-9f26-022bfccc5292"
const axios = require('axios');
async function getData() {
const response = await axios.delete('https://api.commoninja.com/platform/api/v1/widgets/894f5aed-29f5-46c5-9f26-022bfccc5292', {
headers: {
'Authorization': 'Bearer ACCESS_TOKEN'
}
});
return response.data;
}
getData();
Example Response:
{}