Using Todoist with Drafts

guide
todoist

#1

app-icon

Todoist is a task management platform. Drafts supports direct integration with Todoist via a number of methods, including those listed below.

Todoist Share Extension and URL actions

If you have the Todoist app installed on the device, you can take advantage of integration methods provided by the app. These include an iOS Share extension for quick add of individual tasks, and URL schemes which can open the app ready to add a task.

  • Example Actions:

    • Share: This action comes in the default “Basic” action group and opens a system share sheet. It is not specific to Todoist, but will pass the text to the system share sheet and the Todoist share extension can be selected.
    • Task in Todoist App: URL-based action which opens the Todoist app. This version opens Todoist with the text of the current draft as the task content in a new task creation view.
  • Pros:

    • These actions work locally with the Todoist app, so they work offline and the Todoist app will sync the changes when it is reconnected.
    • Both these methods allow flexible selection of options (like project, labels, etc.) through the familiar Todoist interface when used.
  • Cons:

    • Require the Todoist app be installed.
    • Require additional taps to complete creation of tasks.
    • Can only create a single tasks at a time.
    • URL based steps leave you in the Todoist app when completed.

Todoist Action Step

Drafts provides a Todoist Action Step which can create tasks communicating directly with the Todoist REST API. The first time you use an action using Todoist direct integration, you will be directed to Todoist’s website to authorize the Drafts access.

  • Examples Actions:

    • Task in Todoist: Uses first line of draft as the task, additional lines as a comment attached to the task, and supports Todoist quick add syntax for markup like #projectname, @label, etc.
    • Task in Todoist Shopping List: Example is the same as the one above, but with the task content template set to #shopping [[title]]. This automatically adds the project syntax to assign the task to a specific project (Project must already exist in Todoist). This example could be edited to create actions which target specific projects, labels without having to type the text by including the quick add syntax in the template.
  • Pros:

    • One tap creation of task without leaving Drafts.
    • Uses Todoist quick add syntax to allow assignment of projects, labels, etc.
    • Easy to combine with other Drafts action steps.
    • Templates to control task content, attached comments and the creation of reminders.
  • Cons:

    • Requires network connection.

Scripted Actions

Drafts also provides a scripting wrapper for the entire Todoist REST API via the Todoist object. It provides access to the entire REST API and has convenience methods for reading and writing tasks, projects, labels and comments. This means it is possible to create complete projects from Drafts - or also import projects from Todoist.

Below we provide several example actions which are ready to use as-is, but also demonstrate those possibilities. Likely the most useful case it to create tasks in bulk, as in the Tasks in Todoist example action, demonstrated in the video below:

  • Example Actions:
    • Tasks in Todoist: Takes each line of a draft and sends each to Todoist as a separate task. Fully supports Todoist quick add syntax so each line can specify priorities, projects, labels, etc. This action is demonstrated in the video above and provides a great, powerful way to do bulk entry of tasks.
    • Import Todoist Project: Prompts to select an existing Todoist project and imports tasks from the project into a new draft, in a basic Markdown format. Useful for grabbing a snapshot of a project to share. More values are possible to import via the API, this is only meant as a starting point.
    • Task in Todoist with options: This example reads current project and labels from Todoist, then prompts the user to selection options before creating a task.

Users may create other examples, so be sure to search the Action Directory for other Todoist integration examples.


Drafts 5.3 Released - Todoist integration, new icons and more