n8n-nodes-placid
Version:
n8n node to interact with Placid API for creative generation
26 lines • 799 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.execute = execute;
async function execute(i) {
const imageId = this.getNodeParameter('imageId', i);
if (!imageId) {
throw new Error('Image ID is required');
}
const options = {
method: 'DELETE',
url: `https://api.placid.app/api/rest/images/${imageId}`,
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json',
},
};
await this.helpers.httpRequestWithAuthentication.call(this, 'placidApi', options);
return {
json: {
success: true,
message: `Image ${imageId} deleted successfully`,
id: imageId,
},
};
}
//# sourceMappingURL=delete.operation.js.map