I like this action for sending a task to Things 3 - https://actions.getdrafts.com/a/1HS. What I am missing is adding a link back to the draft. I couldnt figure a way how to amend the script to automatically add the link into the note section of the task. Could somebody please help me with that (I am completely new to Drafts …)?
This is the line in the script which creates the “note” value which is sent to Things:
const notes = (prompt.fieldValues.notes || '').trim();
That could be altered to the following to append the link to the current draft at the end of the notes:
let notes = (prompt.fieldValues.notes || '').trim(); notes = notes + "\n" + draft.permalink;
A couple of minor notes:
- Be sure to change the
letso that the value can be changed.
- More properties of the draft as documented on the reference site
Thanks Had to add the “s” to notes = notes + “\n” + draft.permalink; and it works
Oops. Coding without a net. Fixed.