n8n-nodes-feishu-lark
Version:
n8n custom nodes for n8n to interact with Feishu/Lark, including Lark Bot, Lark MCP, and Lark Trigger.
32 lines • 1.06 kB
JavaScript
;
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const RequestUtils_1 = __importDefault(require("../../../help/utils/RequestUtils"));
exports.default = {
name: 'Delete Task | 删除任务',
value: 'delete',
order: 100,
options: [
{
displayName: 'Task ID(任务ID)',
name: 'task_guid',
type: 'string',
required: true,
default: '',
},
],
async call(index) {
const task_guid = this.getNodeParameter('task_guid', index);
const { code, msg } = await RequestUtils_1.default.request.call(this, {
method: 'DELETE',
url: `/open-apis/task/v2/tasks/${task_guid}`,
});
if (code !== 0) {
throw new Error(`Delete task failed, code: ${code}, message: ${msg}`);
}
return {};
},
};
//# sourceMappingURL=Delete.operation.js.map