Please add an API to know how many compatible but not authorized yet accounts there are
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Online Accounts setup for Ubuntu Touch |
Invalid
|
Undecided
|
Unassigned |
Bug Description
At the moment with AccountServiceM
To have a better workflow in apps could be useful to have also a property that says how many accounts of a provider has been added, also if they aren't authorized yet.
E.g:
in reminders app we want to show the button to switch accounts if there are at least 2 accounts, also if one is not authorized yet.
Also, to have two authorized accounts right now the user has to do the authorization from the Online Settings, because with 1 account the app does autologin.
There isn't a good workflow to add another account right now because:
- we want autologin (it's so annoying don't have it)
- we don't want an account button always visible (it's a feature that not many users would use)
- we have no idea if another account has been added in system settings
If you add the "includeDisabled: true" property to the AccountServiceM odel, it will also list the disabled accounts.
However, I'm not sure that this would help you a lot, because we don't have an API for applications to say "enable this account", but just "give me a compatible account".
This is by design, see https:/ /wiki.ubuntu. com/OnlineAccou nts#App_ access ("An app should have no idea whether you have any accounts of a particular type stored in Online Accounts").
So, I'm afraid that unless we change the design, I can't add such an API.