This is a custom bot for Asana that subscribes to projects and performs specific actions on the tasks.
It is designed to be deployed in Netlify's Lambda functions. The button bellow will make your life easier but if you're keen to know more here's a getting starter guide. And if you want to start from scratch this blog post has a fantastic step-by-step guide.
Note: if deployed via Netlify, please re-deploy via the settings after adding your environment variables.
You can request a new feature or submit a bug through this form :)
- if it has no assignee, the task is assigned to the owner of the project
- if it has no due date, the task is assigned a default due date of 2 weeks from the creation date
The bot understand the following natural language if included in the task's name
Priority:
- !!! = high
- !! = medium
- ! = low
Due Dates:
- #today
- #tomorrow
- #week = a week from today
- #month = a month from today
- Marks a task as completed when moved to the Done board
- Moves the task to the Done board when marked as completed
You can use it with your own Asana account but I would recommend creating a separate one for the bot.
You will need to add the following Netlify's environment variables:
- TOKEN - the account's Access Token (format Bearer XXX). Here's how to get it
- BOT_URL - the url where the bot is deployed (format https://XYZ.netlify.com/.netlify/functions/bot)
Note: if you have deployed the bot using the Netlify's button above and created this variables afterwards, you will need to trigger a new deployment as the variables are linked in the deployment phase.
- Invite the Asana bot account to the project. He will need edit permissions
- Unfortunately Asana has no api method, subscription or webhook to get notified for those actions (invited/removed from a project) so the subscription can't be automatised. You will need to make use of the included /projects endpoint to manage such subscriptions (as per bellow)
This bot contains an endpoint at https://XYZ.netlify.com/.netlify/functions/projects to manage its projects' subscriptions. Include the TOKEN in the header.
- Method: POST
- URL: https://XYZ.netlify.com/.netlify/functions/projects
- Body:
{
project: ID
}
- Method: DELETE
- URL: https://XYZ.netlify.com/.netlify/functions/projects/WEBHOOK_ID
You can retrieve the webhook id from the GET method.