Expand description
Accounts elsewhere a person links to who they are in a workspace: their Discord account in a workspace bridged to a Discord server, say.
A connector keeps the workspace’s record (the bridged server) and publishes
actions on it that any member may ask the workspace’s host to run for
themselves (tilo_actions::MEMBER_OWN_TAG), which the profile card and
Settings use the same way for every service:
- a read,
READ_ACTION, answering aReading: whether the workspace is connected to the service at all, the reader’s linked account if any, and the actions below; - the connect action, when the host offers signing in with the service,
answering a
LinkStart: the service’s consent page, which sends the person back to the workspace’s host and from there to Tilo with a one-time link token; - the offer read and the accept action, which take such a token (from
the consent page’s return, or from a button the service’s side
handed out): the read answers the account it offers (
OfferReading), the accept links it; - the unlink action.
The workspace’s host runs them: the connector’s code stays there, and the
page or shell only asks, through a host’s WorkspaceRecordActions.
WorkspaceAccounts asks the workspace’s connectors (connector_apps) for the
read and keeps what it learns as LinkedAccounts; a host lends it to
the panels that show them as LinkedAccounts.
Structs§
- Account
Name - How a service names an account: its unique name, and the name it shows when that is another.
- Link
Start - What the connect action answers: the service’s consent page to go to.
- Linked
Account - One service the workspace is connected to, and the person’s account there.
- Linked
Accounts - A host’s
LinkedAccountsHost, as it lends it to a panel. The default has none: no service, and asking does nothing. - Linking
Recheck - Asks again while a panel shows the accounts:
- Offer
Reading - What the offer read answers: the account a link token offers.
- Profile
Link - A linked account as the person’s profile names it to everyone: the service, the handle there, and the account’s picture when the service has one for it.
- Reading
- A connector’s answer to
READ_ACTION. - Workspace
Accounts - Linked accounts read from a workspace’s records by its host, through a
WorkspaceRecordActions. A link token the page came with is kept here, on this device, until it is used up or declined.
Enums§
- Link
State - Where a person’s account with one service stands.
Constants§
- LINKING_
RECHECK - How often a panel waiting on the workspace’s host asks again.
- OFFER_
TRIES - How many times a link token’s offer is asked for before the panel says why it found none. Coming back from a consent page, the workspace’s host records the offer a moment after the page arrives.
- READ_
ACTION - The read action a connector’s workspace record publishes, answering a
Readingfor the person who reads it. - UNANSWERED_
RETRIES - How many times a shown panel that knows no service yet asks again, at
LINKING_RECHECKdoubling each time, before it waits to be opened anew.
Traits§
- Linked
Accounts Host - What shows and changes a person’s linked accounts in a workspace. Asking
never waits: what comes of it shows in
Self::accountsonce the workspace’s host answered, andSelf::revisionmoves. - Workspace
Record Actions - How a host asks the workspace’s host to run an action of a workspace record for the person, on the web and natively alike.
Functions§
- connector_
apps - Of
workspace_apps, the apps whose workspace record the workspace holds, those that may publish the read (READ_ACTION): connectors, which bridge a service elsewhere and so run on the workspace’s host (its secret store, its worker), never in the person’s desktop. An app the desktop runs itself (runs_here) publishes no reading, and asking its record would only have the host open it to answer that it has no such action. - service_
icon - The mark a connected service’s buttons carry, by its connector’s app id: Discord’s own, a link for any other.
- service_
name_ icon - The glyph of a service by the name a profile gives it (“Discord”).
Type Aliases§
- Action
Answer - The answer to one action the workspace’s host ran.