Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Outlook - tasks (todo) #52

Open
jaleds opened this issue May 8, 2021 · 1 comment
Open

Outlook - tasks (todo) #52

jaleds opened this issue May 8, 2021 · 1 comment
Labels
enhancement New feature or request

Comments

@jaleds
Copy link

jaleds commented May 8, 2021

Very nice work for Outlook with emails :-)

Any ideas of how to get access to tasks (todos) from Outlook?

As I understand the same data that is stored as tasks in Outlook Exchange server can also be found in the new todo app, refer to using-microsoft-to-do-with-outlook-tasks

First attempt is to access the data using Outlook API to get tasks - however as I read - this is deprecated,
task-rest-operation

The way forward might be to use the new todo-concept, refer to todo-concept-overview as the same data is stored at the exchange server and using the same credentials.

However, I cannot figure out how to use the API graph to access the todos.

@hongooi73 hongooi73 added the enhancement New feature or request label May 8, 2021
@hongooi73
Copy link
Collaborator

hongooi73 commented May 9, 2021

To work with tasks, you need to have the "Tasks.readwrite" permission. This isn't set for the app registration that Microsoft365R uses, or any of the alternatives mentioned in #5.

If you want to play around with the todo API, you can try something like this.

perms <- c("user.read", "files.readwrite", "groups.readwrite.all", "tasks.readwrite")
perms <- paste0("https://graph.microsoft.com/", perms)
token <- AzureAuth::get_azure_token(
  c(perms, "openid", "offline_access"),
  tenant="yourtenant",  # or "consumers" for your personal account
  app=Microsoft365R:::.microsoft365r_app_id
)

gr <- AzureGraph::ms_graph$new(token=token)
me <- gr$get_user()

me$do_operation("todo/lists")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants