Process Journal todoist and fantastical

Hello,
I use drafts on a daily basis and I like ist so far. At the moment i am working on an action that can process todoist and fantastical. I am writing one note per day and at the end of the day i want to put events in fantastical todos in todoist. For todoist i use this action
// Process Meeting Notes

// Scan for lines with tasks and send them to Todoist
var d = draft.content;
var lines = d.split("\n");
var n = ‘’;
let todoist = Todoist.create();
for (var line of lines) {
if (line.includes("- [ ]")) {
// Todoist Action
var task = line.replace("- [ ]","");
task = task.trim();
var credential = Credential.create(“Todoist”, “Todoist API”);
credential.addTextField(“token”, “Token”);
credential.authorize();
let success = todoist.quickAdd(task);
if (success) {
console.log("Todoist task created: " + task);
}
else {
ctErrors++;
console.log("Todoist error: " + todoist.lastError);
}
}
else {
n += line + “\n”;
}
}
draft.content = n;
draft.update();
And it works great. How can I do the same with events? Is there a possibility to do so?
Thanks in advance!
Inge