| Title: | Create and Manage Todolist using 'Todoist.com' API |
|---|---|
| Description: | Allows you to interact with the API of the "Todoist" platform. 'Todoist' <https://www.todoist.com/> provides an online task manager service for teams. |
| Authors: | Cervan Girard [aut] (ORCID: <https://orcid.org/0000-0002-4816-4624>, note: previous maintainer), Vincent Guyader [cre, aut] (ORCID: <https://orcid.org/0000-0003-0671-9270>), ThinkR [cph, fnd] |
| Maintainer: | Vincent Guyader <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 0.4.0 |
| Built: | 2026-05-14 08:47:02 UTC |
| Source: | https://github.com/ThinkR-open/rtodoist |
Accept a project invitation
accept_invitation( invitation_id, invitation_secret, verbose = TRUE, token = get_todoist_api_token() )accept_invitation( invitation_id, invitation_secret, verbose = TRUE, token = get_todoist_api_token() )
invitation_id |
id of the invitation |
invitation_secret |
secret of the invitation |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: accept_invitation("12345", "secret123") ## End(Not run)## Not run: accept_invitation("12345", "secret123") ## End(Not run)
Add a comment to a task or project
add_comment( content, task_id = NULL, project_id = NULL, verbose = TRUE, token = get_todoist_api_token() )add_comment( content, task_id = NULL, project_id = NULL, verbose = TRUE, token = get_todoist_api_token() )
content |
content of the comment |
task_id |
id of the task (either task_id or project_id required) |
project_id |
id of the project (either task_id or project_id required) |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the new comment
## Not run: add_comment(content = "This is a comment", task_id = "12345") add_comment(content = "Project comment", project_id = "67890") ## End(Not run)## Not run: add_comment(content = "This is a comment", task_id = "12345") add_comment(content = "Project comment", project_id = "67890") ## End(Not run)
Add a new filter
add_filter( name, query, color = NULL, is_favorite = FALSE, verbose = TRUE, token = get_todoist_api_token() )add_filter( name, query, color = NULL, is_favorite = FALSE, verbose = TRUE, token = get_todoist_api_token() )
name |
name of the filter |
query |
filter query string (e.g., "today | overdue", "p1 & #Work") |
color |
color of the filter |
is_favorite |
boolean to mark as favorite |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the new filter
## Not run: add_filter("Urgent Today", query = "today & p1") add_filter("Work Tasks", query = "#Work", color = "blue") ## End(Not run)## Not run: add_filter("Urgent Today", query = "today & p1") add_filter("Work Tasks", query = "#Work", color = "blue") ## End(Not run)
Add a new label
add_label( name, color = NULL, is_favorite = FALSE, verbose = TRUE, token = get_todoist_api_token() )add_label( name, color = NULL, is_favorite = FALSE, verbose = TRUE, token = get_todoist_api_token() )
name |
name of the label |
color |
color of the label |
is_favorite |
boolean to mark as favorite |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the new label
## Not run: add_label("urgent") add_label("work", color = "red") ## End(Not run)## Not run: add_label("urgent") add_label("work", color = "red") ## End(Not run)
Add a new project
add_project(project_name, verbose = TRUE, token = get_todoist_api_token())add_project(project_name, verbose = TRUE, token = get_todoist_api_token())
project_name |
name of the new project |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the new project
## Not run: add_project("my_proj") ## End(Not run)## Not run: add_project("my_proj") ## End(Not run)
Add a reminder to a task
add_reminder( task_id, due_date = NULL, due_datetime = NULL, minute_offset = NULL, type = "absolute", verbose = TRUE, token = get_todoist_api_token() )add_reminder( task_id, due_date = NULL, due_datetime = NULL, minute_offset = NULL, type = "absolute", verbose = TRUE, token = get_todoist_api_token() )
task_id |
id of the task |
due_date |
due date for the reminder (format: YYYY-MM-DD) |
due_datetime |
due datetime for the reminder (format: YYYY-MM-DDTHH:MM:SS) |
minute_offset |
minutes before due time to remind (for relative reminders) |
type |
type of reminder: "absolute", "relative", or "location" |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the new reminder
## Not run: add_reminder(task_id = "12345", due_datetime = "2024-12-25T09:00:00") add_reminder(task_id = "12345", minute_offset = 30, type = "relative") ## End(Not run)## Not run: add_reminder(task_id = "12345", due_datetime = "2024-12-25T09:00:00") add_reminder(task_id = "12345", minute_offset = 30, type = "relative") ## End(Not run)
Add responsible to a task
add_responsible_to_task( project_id = get_project_id(project_name = project_name, token = token), project_name, responsible, task, verbose = FALSE, all_users = get_all_users(token = token), token = get_todoist_api_token() )add_responsible_to_task( project_id = get_project_id(project_name = project_name, token = token), project_name, responsible, task, verbose = FALSE, all_users = get_all_users(token = token), token = get_todoist_api_token() )
project_id |
id of the project |
project_name |
name of the project |
responsible |
add someone to this task with mail |
task |
the full name of the task |
verbose |
boolean that make the function verbose |
all_users |
all_users |
token |
todoist API token |
http request
Add section
add_section( section_name, project_id = get_project_id(project_name = project_name, token = token), project_name, force = FALSE, token = get_todoist_api_token() )add_section( section_name, project_id = get_project_id(project_name = project_name, token = token), project_name, force = FALSE, token = get_todoist_api_token() )
section_name |
section name |
project_id |
id of the project |
project_name |
name of the project |
force |
boolean force section creation even if already exist |
token |
todoist API token |
section id (character)
Add tasks in project
add_tasks_in_project( project_id = get_project_id(project_name = project_name, token = token), tasks, project_name, verbose = FALSE, responsible = NULL, due = NULL, section_name = NULL, token = get_todoist_api_token(), all_users = get_all_users(token = token), update_only = FALSE, check_only = FALSE, que_si_necessaire = TRUE )add_tasks_in_project( project_id = get_project_id(project_name = project_name, token = token), tasks, project_name, verbose = FALSE, responsible = NULL, due = NULL, section_name = NULL, token = get_todoist_api_token(), all_users = get_all_users(token = token), update_only = FALSE, check_only = FALSE, que_si_necessaire = TRUE )
project_id |
id of the project |
tasks |
tasks to add, as character vector |
project_name |
name of the project |
verbose |
boolean that make the function verbose |
responsible |
add people in project |
due |
due date |
section_name |
section name |
token |
todoist API token |
all_users |
all_users |
update_only |
boolean if true, only update existing (not closed) todo |
check_only |
check_only |
que_si_necessaire |
que_si_necessaire |
id of project (character vector)
## Not run: add_project("my_proj") %>% add_tasks_in_project(c("First task", "Second task")) ## End(Not run)## Not run: add_project("my_proj") %>% add_tasks_in_project(c("First task", "Second task")) ## End(Not run)
Add tasks in project
add_tasks_in_project_from_df( project_id = get_project_id(project_name = project_name, token = token), tasks_as_df, project_name, verbose = FALSE, token = get_todoist_api_token(), update_only = FALSE, check_only = FALSE, que_si_necessaire = TRUE, all_users = get_all_users(token = token) )add_tasks_in_project_from_df( project_id = get_project_id(project_name = project_name, token = token), tasks_as_df, project_name, verbose = FALSE, token = get_todoist_api_token(), update_only = FALSE, check_only = FALSE, que_si_necessaire = TRUE, all_users = get_all_users(token = token) )
project_id |
id of the project |
tasks_as_df |
data.frame of tasks with c("tasks_list","responsible","due","section_name") names |
project_name |
name of the project |
verbose |
boolean that make the function verbose |
token |
todoist API token |
update_only |
boolean if true only update existing (not closed) todo |
check_only |
boolean if true only return number of task to add |
que_si_necessaire |
que_si_necessaire |
all_users |
all_users |
id of project (character vector)
[add_tasks_in_project()]
Add one user
add_user_in_project( project_id = get_project_id(project_name = project_name, token = token), mail, project_name, verbose = TRUE, token = get_todoist_api_token() )add_user_in_project( project_id = get_project_id(project_name = project_name, token = token), mail, project_name, verbose = TRUE, token = get_todoist_api_token() )
project_id |
id of the project |
mail |
mail of the user |
project_name |
name of the project |
verbose |
boolean that make the function verbose |
token |
token |
id of project (character vector)
## Not run: get_project_id("test") %>% add_user_in_project("[email protected]") ## End(Not run)## Not run: get_project_id("test") %>% add_user_in_project("[email protected]") ## End(Not run)
Add a list of users
add_users_in_project( project_id = get_project_id(project_name = project_name, token = token), users_email, project_name, verbose = TRUE, all_users = get_all_users(token = token), token = get_todoist_api_token() )add_users_in_project( project_id = get_project_id(project_name = project_name, token = token), users_email, project_name, verbose = TRUE, all_users = get_all_users(token = token), token = get_todoist_api_token() )
project_id |
id of the project |
users_email |
emails of user as character vector |
project_name |
name of the project |
verbose |
boolean that make the function verbose |
all_users |
all_users |
token |
token |
id of project (character vector)
Archive a project
archive_project( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, verbose = TRUE, token = get_todoist_api_token() )archive_project( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, verbose = TRUE, token = get_todoist_api_token() )
project_id |
id of the project |
project_name |
name of the project (for lookup if project_id not provided) |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the archived project (invisible)
## Not run: archive_project(project_name = "my_proj") ## End(Not run)## Not run: archive_project(project_name = "my_proj") ## End(Not run)
Archive a section
archive_section(section_id, verbose = TRUE, token = get_todoist_api_token())archive_section(section_id, verbose = TRUE, token = get_todoist_api_token())
section_id |
id of the section |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the archived section (invisible)
## Not run: archive_section("12345") ## End(Not run)## Not run: archive_section("12345") ## End(Not run)
Pop-up to save the token
ask_todoist_api_token(msg = "Register Todoist Api Token")ask_todoist_api_token(msg = "Register Todoist Api Token")
msg |
message to print in the pop-up |
password (character vector)
Call the Sync API
call_api(..., url = TODOIST_SYNC_URL, token = get_todoist_api_token())call_api(..., url = TODOIST_SYNC_URL, token = get_todoist_api_token())
... |
any params of POST request |
url |
url to call |
token |
todoist API token |
list
Call the REST API
call_api_rest(endpoint, token = get_todoist_api_token(), ...)call_api_rest(endpoint, token = get_todoist_api_token(), ...)
endpoint |
API endpoint (e.g., "projects", "tasks") |
token |
todoist API token |
... |
query parameters |
list
Close (complete) a task
close_task(task_id, verbose = TRUE, token = get_todoist_api_token())close_task(task_id, verbose = TRUE, token = get_todoist_api_token())
task_id |
id of the task to close |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the closed task (invisible)
## Not run: close_task("12345") ## End(Not run)## Not run: close_task("12345") ## End(Not run)
Delete a collaborator from a project
delete_collaborator( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, email, verbose = TRUE, token = get_todoist_api_token() )delete_collaborator( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, email, verbose = TRUE, token = get_todoist_api_token() )
project_id |
id of the project |
project_name |
name of the project (for lookup if project_id not provided) |
email |
email of the collaborator to remove |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the project (invisible)
## Not run: delete_collaborator(project_name = "my_proj", email = "[email protected]") ## End(Not run)## Not run: delete_collaborator(project_name = "my_proj", email = "[email protected]") ## End(Not run)
Delete a comment
delete_comment(comment_id, verbose = TRUE, token = get_todoist_api_token())delete_comment(comment_id, verbose = TRUE, token = get_todoist_api_token())
comment_id |
id of the comment |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_comment("12345") ## End(Not run)## Not run: delete_comment("12345") ## End(Not run)
Delete a filter
delete_filter( filter_id = get_filter_id(filter_name = filter_name, token = token), filter_name, verbose = TRUE, token = get_todoist_api_token() )delete_filter( filter_id = get_filter_id(filter_name = filter_name, token = token), filter_name, verbose = TRUE, token = get_todoist_api_token() )
filter_id |
id of the filter |
filter_name |
name of the filter (for lookup if filter_id not provided) |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_filter(filter_name = "Urgent Today") ## End(Not run)## Not run: delete_filter(filter_name = "Urgent Today") ## End(Not run)
Delete an invitation
delete_invitation( invitation_id, verbose = TRUE, token = get_todoist_api_token() )delete_invitation( invitation_id, verbose = TRUE, token = get_todoist_api_token() )
invitation_id |
id of the invitation |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_invitation("12345") ## End(Not run)## Not run: delete_invitation("12345") ## End(Not run)
Delete a label
delete_label( label_id = get_label_id(label_name = label_name, token = token, create = FALSE), label_name, verbose = TRUE, token = get_todoist_api_token() )delete_label( label_id = get_label_id(label_name = label_name, token = token, create = FALSE), label_name, verbose = TRUE, token = get_todoist_api_token() )
label_id |
id of the label |
label_name |
name of the label (for lookup if label_id not provided) |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_label(label_name = "urgent") ## End(Not run)## Not run: delete_label(label_name = "urgent") ## End(Not run)
Delete a project
delete_project( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, verbose = TRUE, token = get_todoist_api_token() )delete_project( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, verbose = TRUE, token = get_todoist_api_token() )
project_id |
id of the project |
project_name |
name of the project (for lookup if project_id not provided) |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_project(project_name = "my_proj") ## End(Not run)## Not run: delete_project(project_name = "my_proj") ## End(Not run)
Delete a reminder
delete_reminder(reminder_id, verbose = TRUE, token = get_todoist_api_token())delete_reminder(reminder_id, verbose = TRUE, token = get_todoist_api_token())
reminder_id |
id of the reminder |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_reminder("12345") ## End(Not run)## Not run: delete_reminder("12345") ## End(Not run)
Delete a section
delete_section(section_id, verbose = TRUE, token = get_todoist_api_token())delete_section(section_id, verbose = TRUE, token = get_todoist_api_token())
section_id |
id of the section |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_section("12345") ## End(Not run)## Not run: delete_section("12345") ## End(Not run)
Delete a task
delete_task(task_id, verbose = TRUE, token = get_todoist_api_token())delete_task(task_id, verbose = TRUE, token = get_todoist_api_token())
task_id |
id of the task to delete |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_task("12345") ## End(Not run)## Not run: delete_task("12345") ## End(Not run)
Delete todoist api token
delete_todoist_api_token()delete_todoist_api_token()
nothing, delete the api token
Delete an uploaded file
delete_upload(file_url, verbose = TRUE, token = get_todoist_api_token())delete_upload(file_url, verbose = TRUE, token = get_todoist_api_token())
file_url |
URL of the file to delete |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: delete_upload("https://...") ## End(Not run)## Not run: delete_upload("https://...") ## End(Not run)
Download a backup
download_backup( version, output_file, verbose = TRUE, token = get_todoist_api_token() )download_backup( version, output_file, verbose = TRUE, token = get_todoist_api_token() )
version |
version of the backup to download (from get_backups()) |
output_file |
path where to save the backup file |
verbose |
boolean that make the function verbose |
token |
todoist API token |
path to the saved file (invisible)
## Not run: backups <- get_backups() download_backup(backups$version[1], "backup.zip") ## End(Not run)## Not run: backups <- get_backups() download_backup(backups$version[1], "backup.zip") ## End(Not run)
Escape special characters for JSON
escape_json(x)escape_json(x)
x |
character string to escape |
escaped string
Export a project as a template
export_template( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, output_file, verbose = TRUE, token = get_todoist_api_token() )export_template( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, output_file, verbose = TRUE, token = get_todoist_api_token() )
project_id |
id of the project to export |
project_name |
name of the project (for lookup if project_id not provided) |
output_file |
path where to save the template file |
verbose |
boolean that make the function verbose |
token |
todoist API token |
path to the saved file (invisible)
## Not run: export_template(project_name = "my_proj", output_file = "template.csv") ## End(Not run)## Not run: export_template(project_name = "my_proj", output_file = "template.csv") ## End(Not run)
Get activity logs
get_activity_logs( object_type = NULL, object_id = NULL, event_type = NULL, parent_project_id = NULL, parent_item_id = NULL, initiator_id = NULL, since = NULL, until = NULL, limit = 30, offset = 0, token = get_todoist_api_token() )get_activity_logs( object_type = NULL, object_id = NULL, event_type = NULL, parent_project_id = NULL, parent_item_id = NULL, initiator_id = NULL, since = NULL, until = NULL, limit = 30, offset = 0, token = get_todoist_api_token() )
object_type |
filter by object type (e.g., "project", "item", "note") |
object_id |
filter by specific object id |
event_type |
filter by event type (e.g., "added", "updated", "completed") |
parent_project_id |
filter by parent project id |
parent_item_id |
filter by parent item id |
initiator_id |
filter by user who initiated the action |
since |
return events since this date (format: YYYY-MM-DDTHH:MM:SS) |
until |
return events until this date (format: YYYY-MM-DDTHH:MM:SS) |
limit |
maximum number of events to return (default 30, max 100) |
offset |
offset for pagination |
token |
todoist API token |
tibble of activity events
## Not run: get_activity_logs() get_activity_logs(object_type = "item", event_type = "completed") ## End(Not run)## Not run: get_activity_logs() get_activity_logs(object_type = "item", event_type = "completed") ## End(Not run)
Collect all the objects in a list. This allows you to explore your to-do list.
get_all_data(token = get_todoist_api_token())get_all_data(token = get_todoist_api_token())
token |
todoist API token |
list of all objects
## Not run: # Set API key first set_todoist_api_token() # Get all objects objects <- get_all_data() ## End(Not run)## Not run: # Set API key first set_todoist_api_token() # Get all objects objects <- get_all_data() ## End(Not run)
Get all filters
get_all_filters(token = get_todoist_api_token())get_all_filters(token = get_todoist_api_token())
token |
todoist API token |
tibble of all filters
## Not run: get_all_filters() ## End(Not run)## Not run: get_all_filters() ## End(Not run)
Get all labels
get_all_labels(token = get_todoist_api_token())get_all_labels(token = get_todoist_api_token())
token |
todoist API token |
tibble of all labels
## Not run: get_all_labels() ## End(Not run)## Not run: get_all_labels() ## End(Not run)
List of projects
get_all_projects(token = get_todoist_api_token())get_all_projects(token = get_todoist_api_token())
token |
todoist API token |
list of all projects
## Not run: # Set API key first set_todoist_api_token() # Get all projects projects <- get_all_projects() ## End(Not run)## Not run: # Set API key first set_todoist_api_token() # Get all projects projects <- get_all_projects() ## End(Not run)
Get all reminders
get_all_reminders(token = get_todoist_api_token())get_all_reminders(token = get_todoist_api_token())
token |
todoist API token |
tibble of all reminders
## Not run: get_all_reminders() ## End(Not run)## Not run: get_all_reminders() ## End(Not run)
Get all sections
get_all_sections(token = get_todoist_api_token())get_all_sections(token = get_todoist_api_token())
token |
todoist API token |
tibble of all sections
## Not run: get_all_sections() ## End(Not run)## Not run: get_all_sections() ## End(Not run)
Get a tibble with emails and ids of users
get_all_users(token = get_todoist_api_token())get_all_users(token = get_todoist_api_token())
token |
token |
tibble of users
## Not run: get_users() ## End(Not run)## Not run: get_users() ## End(Not run)
Get all workspaces
get_all_workspaces(token = get_todoist_api_token())get_all_workspaces(token = get_todoist_api_token())
token |
todoist API token |
tibble of all workspaces
## Not run: get_all_workspaces() ## End(Not run)## Not run: get_all_workspaces() ## End(Not run)
Get archived projects
get_archived_projects(token = get_todoist_api_token())get_archived_projects(token = get_todoist_api_token())
token |
todoist API token |
tibble of archived projects
## Not run: get_archived_projects() ## End(Not run)## Not run: get_archived_projects() ## End(Not run)
Get list of backups
get_backups(token = get_todoist_api_token())get_backups(token = get_todoist_api_token())
token |
todoist API token |
tibble of available backups
## Not run: get_backups() ## End(Not run)## Not run: get_backups() ## End(Not run)
Get a single comment by ID
get_comment(comment_id, token = get_todoist_api_token())get_comment(comment_id, token = get_todoist_api_token())
comment_id |
id of the comment |
token |
todoist API token |
list with comment details
## Not run: get_comment("12345") ## End(Not run)## Not run: get_comment("12345") ## End(Not run)
Get comments
get_comments( task_id = NULL, project_id = NULL, token = get_todoist_api_token() )get_comments( task_id = NULL, project_id = NULL, token = get_todoist_api_token() )
task_id |
id of the task (either task_id or project_id required) |
project_id |
id of the project (either task_id or project_id required) |
token |
todoist API token |
tibble of comments
## Not run: get_comments(task_id = "12345") get_comments(project_id = "67890") ## End(Not run)## Not run: get_comments(task_id = "12345") get_comments(project_id = "67890") ## End(Not run)
Get completed tasks
get_completed_tasks( project_id = NULL, since = NULL, until = NULL, limit = 50, token = get_todoist_api_token() )get_completed_tasks( project_id = NULL, since = NULL, until = NULL, limit = 50, token = get_todoist_api_token() )
project_id |
project id to filter by (optional) |
since |
return tasks completed since this date (optional, format: YYYY-MM-DDTHH:MM:SS) |
until |
return tasks completed until this date (optional, format: YYYY-MM-DDTHH:MM:SS) |
limit |
maximum number of tasks to return (default 50, max 200) |
token |
todoist API token |
tibble of completed tasks
## Not run: get_completed_tasks() get_completed_tasks(project_id = "12345") ## End(Not run)## Not run: get_completed_tasks() get_completed_tasks(project_id = "12345") ## End(Not run)
Get a single filter by ID
get_filter(filter_id, token = get_todoist_api_token())get_filter(filter_id, token = get_todoist_api_token())
filter_id |
id of the filter |
token |
todoist API token |
list with filter details
## Not run: get_filter("12345") ## End(Not run)## Not run: get_filter("12345") ## End(Not run)
Get filter id by name
get_filter_id( filter_name, all_filters = get_all_filters(token = token), token = get_todoist_api_token() )get_filter_id( filter_name, all_filters = get_all_filters(token = token), token = get_todoist_api_token() )
filter_name |
name of the filter |
all_filters |
result of get_all_filters (optional) |
token |
todoist API token |
id of the filter
## Not run: get_filter_id("Urgent Today") ## End(Not run)## Not run: get_filter_id("Urgent Today") ## End(Not run)
Get a single label by ID
get_label(label_id, token = get_todoist_api_token())get_label(label_id, token = get_todoist_api_token())
label_id |
id of the label |
token |
todoist API token |
list with label details
## Not run: get_label("12345") ## End(Not run)## Not run: get_label("12345") ## End(Not run)
Get label id by name
get_label_id( label_name, all_labels = get_all_labels(token = token), token = get_todoist_api_token(), create = TRUE )get_label_id( label_name, all_labels = get_all_labels(token = token), token = get_todoist_api_token(), create = TRUE )
label_name |
name of the label |
all_labels |
result of get_all_labels (optional) |
token |
todoist API token |
create |
boolean create label if needed |
id of the label
## Not run: get_label_id("urgent") ## End(Not run)## Not run: get_label_id("urgent") ## End(Not run)
Get productivity stats
get_productivity_stats(token = get_todoist_api_token())get_productivity_stats(token = get_todoist_api_token())
token |
todoist API token |
list with productivity statistics
## Not run: get_productivity_stats() ## End(Not run)## Not run: get_productivity_stats() ## End(Not run)
Get a single project by ID
get_project(project_id, token = get_todoist_api_token())get_project(project_id, token = get_todoist_api_token())
project_id |
id of the project |
token |
todoist API token |
list with project details
## Not run: get_project("12345") ## End(Not run)## Not run: get_project("12345") ## End(Not run)
This function gives you the id of a project by name, which is useful for adding tasks or people to the project.
get_project_id( project_name, all_projects = get_all_projects(token = token), token = get_todoist_api_token(), create = TRUE, verbose = FALSE )get_project_id( project_name, all_projects = get_all_projects(token = token), token = get_todoist_api_token(), create = TRUE, verbose = FALSE )
project_name |
name of the project |
all_projects |
result of get_all_projects |
token |
todoist API token |
create |
boolean create project if needed |
verbose |
boolean that make the function verbose |
id of project (character vector)
## Not run: get_all_projects() %>% get_project_id("test") ## End(Not run)## Not run: get_all_projects() %>% get_project_id("test") ## End(Not run)
Get a single section by ID
get_section(section_id, token = get_todoist_api_token())get_section(section_id, token = get_todoist_api_token())
section_id |
id of the section |
token |
todoist API token |
list with section details
## Not run: get_section("12345") ## End(Not run)## Not run: get_section("12345") ## End(Not run)
Get section id
get_section_id( project_id = get_project_id(project_name = project_name, token = token), project_name, section_name, token = get_todoist_api_token(), all_section = get_section_from_project(project_id = project_id, token = token) )get_section_id( project_id = get_project_id(project_name = project_name, token = token), project_name, section_name, token = get_todoist_api_token(), all_section = get_section_from_project(project_id = project_id, token = token) )
project_id |
id of the project |
project_name |
name of the project |
section_name |
name of the section |
token |
token |
all_section |
all_section |
section id (character). Returns 0 if section not found.
Get a single task by ID
get_task(task_id, token = get_todoist_api_token())get_task(task_id, token = get_todoist_api_token())
task_id |
id of the task |
token |
todoist API token |
list with task details
## Not run: get_task("12345") ## End(Not run)## Not run: get_task("12345") ## End(Not run)
List of tasks
get_tasks(token = get_todoist_api_token())get_tasks(token = get_todoist_api_token())
token |
todoist API token |
list of all tasks
## Not run: # Set API key first set_todoist_api_token() # Get all tasks tasks <- get_tasks() ## End(Not run)## Not run: # Set API key first set_todoist_api_token() # Get all tasks tasks <- get_tasks() ## End(Not run)
Get tasks by filter query
get_tasks_by_filter(query, token = get_todoist_api_token())get_tasks_by_filter(query, token = get_todoist_api_token())
query |
filter query string (e.g., "today", "p1 & #Work") |
token |
todoist API token |
tibble of tasks matching the filter
## Not run: get_tasks_by_filter("today") get_tasks_by_filter("p1 & #Work") ## End(Not run)## Not run: get_tasks_by_filter("today") get_tasks_by_filter("p1 & #Work") ## End(Not run)
List of tasks of project
get_tasks_of_project( project_id = get_project_id(project_name = project_name, token = token), project_name, token = get_todoist_api_token() )get_tasks_of_project( project_id = get_project_id(project_name = project_name, token = token), project_name, token = get_todoist_api_token() )
project_id |
id of the project |
project_name |
name of the project |
token |
todoist API token |
list of all tasks
Return the todoist API token. If this is the first time, you will need to setup your token.
get_todoist_api_token(ask = TRUE)get_todoist_api_token(ask = TRUE)
ask |
booleen do we have to ask if missing |
token (character vector)
## Not run: get_todoist_api_token() ## End(Not run)## Not run: get_todoist_api_token() ## End(Not run)
Get current user info
get_user_info(token = get_todoist_api_token())get_user_info(token = get_todoist_api_token())
token |
todoist API token |
list with user information
## Not run: get_user_info() ## End(Not run)## Not run: get_user_info() ## End(Not run)
Get users id
get_users_id( mails, all_users = get_all_users(token = token), token = get_todoist_api_token() )get_users_id( mails, all_users = get_all_users(token = token), token = get_todoist_api_token() )
mails |
mails of the person |
all_users |
all_users |
token |
token |
id of users
Get users in projects
get_users_in_project( project_id = get_project_id(project_name = project_name, token = token), project_name, token = get_todoist_api_token() )get_users_in_project( project_id = get_project_id(project_name = project_name, token = token), project_name, token = get_todoist_api_token() )
project_id |
id of the project |
project_name |
name of the project |
token |
token |
dataframe of users in projects
Get workspace users
get_workspace_users(token = get_todoist_api_token())get_workspace_users(token = get_todoist_api_token())
token |
todoist API token |
tibble of workspace users
## Not run: get_workspace_users() ## End(Not run)## Not run: get_workspace_users() ## End(Not run)
Import a template into a project
import_template( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, file_path, verbose = TRUE, token = get_todoist_api_token() )import_template( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, file_path, verbose = TRUE, token = get_todoist_api_token() )
project_id |
id of the project to import into |
project_name |
name of the project (for lookup if project_id not provided) |
file_path |
path to the template file (CSV format) |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: import_template(project_name = "my_proj", file_path = "template.csv") ## End(Not run)## Not run: import_template(project_name = "my_proj", file_path = "template.csv") ## End(Not run)
Invite user to workspace
invite_to_workspace( workspace_id, email, role = "member", verbose = TRUE, token = get_todoist_api_token() )invite_to_workspace( workspace_id, email, role = "member", verbose = TRUE, token = get_todoist_api_token() )
workspace_id |
id of the workspace |
email |
email of the user to invite |
role |
role for the user (e.g., "member", "admin") |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: invite_to_workspace("12345", "[email protected]") ## End(Not run)## Not run: invite_to_workspace("12345", "[email protected]") ## End(Not run)
Leave a workspace
leave_workspace(workspace_id, verbose = TRUE, token = get_todoist_api_token())leave_workspace(workspace_id, verbose = TRUE, token = get_todoist_api_token())
workspace_id |
id of the workspace |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: leave_workspace("12345") ## End(Not run)## Not run: leave_workspace("12345") ## End(Not run)
Move a section to another project
move_section( section_id, project_id, verbose = TRUE, token = get_todoist_api_token() )move_section( section_id, project_id, verbose = TRUE, token = get_todoist_api_token() )
section_id |
id of the section |
project_id |
target project id |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the moved section (invisible)
## Not run: move_section("12345", project_id = "67890") ## End(Not run)## Not run: move_section("12345", project_id = "67890") ## End(Not run)
Move a task to another project or section
move_task( task_id, project_id = NULL, section_id = NULL, parent_id = NULL, verbose = TRUE, token = get_todoist_api_token() )move_task( task_id, project_id = NULL, section_id = NULL, parent_id = NULL, verbose = TRUE, token = get_todoist_api_token() )
task_id |
id of the task to move |
project_id |
new project id (optional) |
section_id |
new section id (optional) |
parent_id |
new parent task id (optional) |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the moved task (invisible)
## Not run: move_task("12345", project_id = "67890") ## End(Not run)## Not run: move_task("12345", project_id = "67890") ## End(Not run)
Open todoist website
open_todoist_website_profile(verbose = TRUE)open_todoist_website_profile(verbose = TRUE)
verbose |
boolean that make the function verbose |
open integration webpage from todoist website
open_todoist_website_profile()open_todoist_website_profile()
Quick add a task using natural language
quick_add_task(text, verbose = TRUE, token = get_todoist_api_token())quick_add_task(text, verbose = TRUE, token = get_todoist_api_token())
text |
natural language text for the task |
verbose |
boolean that make the function verbose |
token |
todoist API token |
task object
## Not run: quick_add_task("Buy milk tomorrow at 5pm #Shopping") ## End(Not run)## Not run: quick_add_task("Buy milk tomorrow at 5pm #Shopping") ## End(Not run)
Random key
random_key()random_key()
key
random key generate with digest
Reject a project invitation
reject_invitation( invitation_id, invitation_secret, verbose = TRUE, token = get_todoist_api_token() )reject_invitation( invitation_id, invitation_secret, verbose = TRUE, token = get_todoist_api_token() )
invitation_id |
id of the invitation |
invitation_secret |
secret of the invitation |
verbose |
boolean that make the function verbose |
token |
todoist API token |
NULL (invisible)
## Not run: reject_invitation("12345", "secret123") ## End(Not run)## Not run: reject_invitation("12345", "secret123") ## End(Not run)
Reopen (uncomplete) a task
reopen_task(task_id, verbose = TRUE, token = get_todoist_api_token())reopen_task(task_id, verbose = TRUE, token = get_todoist_api_token())
task_id |
id of the task to reopen |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the reopened task (invisible)
## Not run: reopen_task("12345") ## End(Not run)## Not run: reopen_task("12345") ## End(Not run)
This function use keyring to store your token from your todoist profile. To find your token from todoist website, use open_todoist_website_profile
set_todoist_api_token(token)set_todoist_api_token(token)
token |
todoist API token |
token
Unarchive a project
unarchive_project(project_id, verbose = TRUE, token = get_todoist_api_token())unarchive_project(project_id, verbose = TRUE, token = get_todoist_api_token())
project_id |
id of the project |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the unarchived project (invisible)
## Not run: unarchive_project(project_id = "12345") ## End(Not run)## Not run: unarchive_project(project_id = "12345") ## End(Not run)
Unarchive a section
unarchive_section(section_id, verbose = TRUE, token = get_todoist_api_token())unarchive_section(section_id, verbose = TRUE, token = get_todoist_api_token())
section_id |
id of the section |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the unarchived section (invisible)
## Not run: unarchive_section("12345") ## End(Not run)## Not run: unarchive_section("12345") ## End(Not run)
Update a comment
update_comment( comment_id, content, verbose = TRUE, token = get_todoist_api_token() )update_comment( comment_id, content, verbose = TRUE, token = get_todoist_api_token() )
comment_id |
id of the comment |
content |
new content for the comment |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the updated comment (invisible)
## Not run: update_comment("12345", content = "Updated comment") ## End(Not run)## Not run: update_comment("12345", content = "Updated comment") ## End(Not run)
Update a filter
update_filter( filter_id = get_filter_id(filter_name = filter_name, token = token), filter_name, new_name = NULL, query = NULL, color = NULL, is_favorite = NULL, verbose = TRUE, token = get_todoist_api_token() )update_filter( filter_id = get_filter_id(filter_name = filter_name, token = token), filter_name, new_name = NULL, query = NULL, color = NULL, is_favorite = NULL, verbose = TRUE, token = get_todoist_api_token() )
filter_id |
id of the filter |
filter_name |
name of the filter (for lookup if filter_id not provided) |
new_name |
new name for the filter |
query |
new query string |
color |
new color |
is_favorite |
boolean to mark as favorite |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the updated filter (invisible)
## Not run: update_filter(filter_name = "Urgent Today", query = "today & p1 & #Work") ## End(Not run)## Not run: update_filter(filter_name = "Urgent Today", query = "today & p1 & #Work") ## End(Not run)
Update a label
update_label( label_id = get_label_id(label_name = label_name, token = token, create = FALSE), label_name, new_name = NULL, color = NULL, is_favorite = NULL, verbose = TRUE, token = get_todoist_api_token() )update_label( label_id = get_label_id(label_name = label_name, token = token, create = FALSE), label_name, new_name = NULL, color = NULL, is_favorite = NULL, verbose = TRUE, token = get_todoist_api_token() )
label_id |
id of the label |
label_name |
name of the label (for lookup if label_id not provided) |
new_name |
new name for the label |
color |
new color for the label |
is_favorite |
boolean to mark as favorite |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the updated label (invisible)
## Not run: update_label(label_name = "urgent", new_name = "very_urgent") ## End(Not run)## Not run: update_label(label_name = "urgent", new_name = "very_urgent") ## End(Not run)
Update a project
update_project( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, new_name = NULL, color = NULL, is_favorite = NULL, view_style = NULL, verbose = TRUE, token = get_todoist_api_token() )update_project( project_id = get_project_id(project_name = project_name, token = token, create = FALSE), project_name, new_name = NULL, color = NULL, is_favorite = NULL, view_style = NULL, verbose = TRUE, token = get_todoist_api_token() )
project_id |
id of the project |
project_name |
name of the project (for lookup if project_id not provided) |
new_name |
new name for the project |
color |
new color for the project |
is_favorite |
boolean to mark as favorite |
view_style |
view style ("list" or "board") |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the updated project (invisible)
## Not run: update_project(project_name = "my_proj", new_name = "new_name") ## End(Not run)## Not run: update_project(project_name = "my_proj", new_name = "new_name") ## End(Not run)
Update a reminder
update_reminder( reminder_id, due_date = NULL, due_datetime = NULL, minute_offset = NULL, type = NULL, verbose = TRUE, token = get_todoist_api_token() )update_reminder( reminder_id, due_date = NULL, due_datetime = NULL, minute_offset = NULL, type = NULL, verbose = TRUE, token = get_todoist_api_token() )
reminder_id |
id of the reminder |
due_date |
new due date for the reminder (format: YYYY-MM-DD) |
due_datetime |
new due datetime for the reminder (format: YYYY-MM-DDTHH:MM:SS) |
minute_offset |
new minutes before due time to remind |
type |
new type of reminder |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the updated reminder (invisible)
## Not run: update_reminder("12345", due_datetime = "2024-12-26T10:00:00") ## End(Not run)## Not run: update_reminder("12345", due_datetime = "2024-12-26T10:00:00") ## End(Not run)
Update a section
update_section( section_id, new_name, verbose = TRUE, token = get_todoist_api_token() )update_section( section_id, new_name, verbose = TRUE, token = get_todoist_api_token() )
section_id |
id of the section |
new_name |
new name for the section |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the updated section (invisible)
## Not run: update_section("12345", new_name = "New Section Name") ## End(Not run)## Not run: update_section("12345", new_name = "New Section Name") ## End(Not run)
Update a task
update_task( task_id, content = NULL, description = NULL, priority = NULL, due_string = NULL, due_date = NULL, labels = NULL, verbose = TRUE, token = get_todoist_api_token() )update_task( task_id, content = NULL, description = NULL, priority = NULL, due_string = NULL, due_date = NULL, labels = NULL, verbose = TRUE, token = get_todoist_api_token() )
task_id |
id of the task to update |
content |
new content/title for the task |
description |
new description for the task |
priority |
priority (1-4, 4 being highest) |
due_string |
due date as string (e.g., "tomorrow", "every monday") |
due_date |
due date as date (format: YYYY-MM-DD) |
labels |
vector of label names |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the updated task (invisible)
## Not run: update_task("12345", content = "Updated task name") ## End(Not run)## Not run: update_task("12345", content = "Updated task name") ## End(Not run)
Remove the old token and register a new one.
update_todoist_api_token()update_todoist_api_token()
nothing, storing your token
Update a workspace
update_workspace( workspace_id, name, verbose = TRUE, token = get_todoist_api_token() )update_workspace( workspace_id, name, verbose = TRUE, token = get_todoist_api_token() )
workspace_id |
id of the workspace |
name |
new name for the workspace |
verbose |
boolean that make the function verbose |
token |
todoist API token |
id of the updated workspace (invisible)
## Not run: update_workspace("12345", name = "New Workspace Name") ## End(Not run)## Not run: update_workspace("12345", name = "New Workspace Name") ## End(Not run)
Upload a file
upload_file( file_path, file_name = basename(file_path), verbose = TRUE, token = get_todoist_api_token() )upload_file( file_path, file_name = basename(file_path), verbose = TRUE, token = get_todoist_api_token() )
file_path |
path to the file to upload |
file_name |
name for the uploaded file (defaults to basename of file_path) |
verbose |
boolean that make the function verbose |
token |
todoist API token |
upload object with file_url
## Not run: upload <- upload_file("document.pdf") # Use upload$file_url in a comment ## End(Not run)## Not run: upload <- upload_file("document.pdf") # Use upload$file_url in a comment ## End(Not run)