Zapier code step to forward messages saved in slack to dynalist.io
- Create a new Zapier Zap
- Choose the Slack app and the "New Saved Message" trigger event
- Follow the prompts to authenticate Zapier with the apropriate Slack acccount.
- Add a "Code by Zapier" app and the "Run Javascript" action event.
- Configure the "Input Data" fields described below.
- Copy the code in
code.js
into the "Code" input.
The following input data fields must be added to the code step.
token
: Your dynalist API token
file_id
: The id of the document to send slack messsages to. This can be determined from the URL.
https://dynalist.io/d/{file_id}
parent_id
: The specific node of the document specified above to save slack messages to. This can also be determined from the URL.
https://dynalist.io/d/{file_id}#z={parent_id}
Alternatively this can be set to root
to send messages to the root of the document.
The following data fields must be added to the code step to pass data from the the saved slack message into the script.
permaLink
: The permalink to the slack message
text
: The message text
channelName
: The channel name
userName
: The message sender
timeStamp
: The timestamp the message was sent