hello. i want to use a external task to upload pdf file to camunda and set it as a process variable using nodejs with help of camunda-external-task-client-js
client.subscribe("generatepdf", async function ({ task, taskService }) {
const processVariables = new Variables();
const file = await new File({
localPath: "./assets/a.pdf",
mimetype: "application/pdf",
}).load();
processVariables.set("doc", file);
await taskService.complete(task, processVariables);
});
I already try this with no luck,
i want to upload file as pdf file to camunda variable (variable with type “File”)