Skip to content

Commit

Permalink
doc: Add dedicated token page to docs
Browse files Browse the repository at this point in the history
  • Loading branch information
RogerSelwyn committed May 5, 2024
1 parent 041c1a8 commit de7529b
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/authentication.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ After setting up configuration.yaml with the key set to _True_ and restarting Ho
If you are using Multi-factor Authentication (MFA), you may find you also need to add `https://login.microsoftonline.com/organizations/oauth2/v2.0/authorize` to your redirect URIs.

## Re-authentication
If you need to re-authenticate for any reason, for instance if you have changed features (such as enabling update) and haven't had the repair notification, you should delete the relevant token from the `<config>/o365_storage/.O365-token-cache` directory. When you restart HA, you will then be prompted to re-authenticate with O365 which will store a new token.
If you need to re-authenticate for any reason, for instance if you have changed features (such as enabling update) and haven't had the repair notification, you should delete the token as described on the [token page](./token.md).
4 changes: 2 additions & 2 deletions docs/errors.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ nav_order: 19
* For other items, it means you have changed your configuration to require new permissions. You will likely need to delete your token and reauthenticate. Please check the [permissions page](./permissions.md) for more details.

* **The user could not be authenticated as the grant is expired. The user must sign in again.**
* Create a new secret and update your O365 configuration. Then delete your token and reauthenticate. Please check the [permissions page](./permissions.md) for more details.
* Create a new secret and update your O365 configuration. Then delete your token and reauthenticate. Please check the [token page](./token.md) for more details.

* **Client secret expired for account: xxxxxxxx. Create new client id in Azure App.**
* The Client Secret on your Azure App has expired. Create a new secret and update your O365 configuration.
Expand All @@ -30,7 +30,7 @@ nav_order: 19
* Ensure the configured secret is the client secret __value__, not the client secret ID

* **Token corrupt for account - please delete and re-authenticate.**
* You will need to delete your token and reauthenticate. Please check the [permissions page](./permissions.md) for more details.
* You will need to delete your token and reauthenticate. Please check the [token page](./token.md) for more details.

* **O365 config requests permission: 'xxxxxx.xxxxxxx'. Not available in token 'o365_xxxxxxxx.token' for account 'xxxxxxxx'**
Validate your Azure permissions match those required as detailed on the [permissions page](./permissions.md). If they are correct, you will need to delete your token and reauthenticate as described on the same page.
Expand Down
2 changes: 1 addition & 1 deletion docs/permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,4 @@ If you decide to enable new features in the integration, or decide to change fro

`Minimum required permissions not granted: ['Tasks.Read', ['Tasks.ReadWrite']]`

You will need to delete the relevant token from the `<config>/o365_storage/.O365-token-cache` directory. When you restart HA, you will then be prompted to re-authenticate with O365 which will store a new token with the new permission.
You will need to delete as detailed on the [token page](./token.md)
9 changes: 9 additions & 0 deletions docs/token.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
title: Token
nav_order: 20
---

# Token
At some point you are very likely need to delete your token so that you re-authenticate to Office 365. This may be because you have added new features to your configuration or your secret has expired.

To do this delete the relevant token file (according to the account name in your config) from the `<config>/o365_storage/.O365-token-cache` directory. When you restart HA, you will then be prompted to re-authenticate with O365 which will store a new token.

0 comments on commit de7529b

Please sign in to comment.