Skip to content
This repository has been archived by the owner on Aug 27, 2021. It is now read-only.

A little confused about how to configure the integration #86

Open
jayscovill opened this issue Sep 19, 2020 · 1 comment
Open

A little confused about how to configure the integration #86

jayscovill opened this issue Sep 19, 2020 · 1 comment

Comments

@jayscovill
Copy link

jayscovill commented Sep 19, 2020

I believe I have the integration configured and authenticated as my O365 calendars events are showing up in the Home Assistant Calendar section.

But I'm not getting any email sensors and I'm not sure if I've configured it correctly. It's not clear in the documentation how emails sensors will appear as entity IDs. My config is:

client_secret: !secret o365_client_secret
client_id: !secret o365_application_id
query_sensors:

  • name: "Package Delivering"
    folder: "Inbox"
    from: "[email protected]"
    subject_contains: "is on the way!"
    #has_attachment: True
    #max_items: 2
    #is_unread: True
  • name: "Package Delivered"
    folder: "Inbox"
    from: "[email protected]"
    subject_contains: "has been delivered!"

But I don't see any sensors resembling the name I've given the query sensor. What entityID will the query sensors be given in this case?

@jayscovill
Copy link
Author

To add to this looking through the HASS logs I see these errors when trying to query my mailbox for the query sensors:

2020-09-19 11:01:37 ERROR (SyncWorker_13) [O365.connection] Client Error: 400 Client Error: Bad Request for url: https://graph.microsoft.com/v1.0/me/mailFolders/AQMkADIyADE3YTFiNC1hMDliLTQ4NDYtOWEzNi02YWI2YjNiZjNiZTUALgAAA4BRbJ8zkGBNvy0ODV0H0TgBAHICqaHdqEBOgxtZ10GOmkwAAAIBDAAAAA==/messages?%24top=5&%24filter=contains%28subject%2C+%27is+on+the+way%21%27%29+and+from%2FemailAddress%2Faddress+eq+%27noreply%40intelcomexpress.com%27&%24orderby=receivedDateTime+desc | Error Message: The restriction or sort order is too complex for this operation.

Again, calendars show up so the authentication looks good. But there's some kind of problem with the query sensors.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant