You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit fa26b98
Browse filesBrowse the repository at this point in the historyBrowse files
fix(credential-groups): final audit follow-ups for connect links and Access (#10766)
* fix(credential-groups): require verified email, send queued request emails, honest expiry copy
- Claiming a request for an address again requires user.emailVerified everywhere, including on
deployments that cannot verify email: drop verified-email.ts and the relaxed credentials query.
- Verify email state sends a code when opened (/verify?sendCode=true); where no code can be sent
it asks the person to sign in with Google or Microsoft instead of looping through /verify.
- A connection request email is sent while the enrollment is still a pending workflow request,
no longer pinned to the latest workflow and integration, so a later request for another
integration no longer drops the first email. providerId leaves the outbox payload.
- An expired non-Slack OAuth attempt shows the generic expired message.
* fix(credential-groups): tidy the connect link code paths
- Link cleanup cron returns 500 when a table's drain fails, after both tables run
- One active-options-for-provider helper and one Access-tab provider predicate for the
request path and the admin policy's in-effect check
- Connect, start, OAuth start and MCP start URLs come from connect-url builders; enrollment
links hand back their token instead of being parsed (enrollment-links.ts removed)
- Invitation tokens hash through hashInvitationToken everywhere
- requestExpiresAt(now) replaces five copies of the renewal arithmetic
- Link OAuth origins come from one const array the contract and types derive from
- pendingWorkflowRequestCondition lives with the request email event; static import of the
email handlers ends the cycle
- Drop an unread link-record field, file-local exports, a restating TSDoc, and the duplicated
connection-status/request input; reuse hasOrganizationSetup in canSelfEnroll
- Connect route test: drop the declaration test and the six identical outcome cases
- README: MCP attempts live ten minutes, Send email vs Send reminder, outbox wording
- A first workflow-request email sent from People no longer reads as a reminder
- Policy and Access refusals name the setting they come from
* fix(credential-groups): clearer connect states, reconnect wording, and request docs
* fix(credential-groups): open the Access tab for organizations with more than 1000 workspaces
The Access read loaded every active workspace in the organization and refused once there were
more than the grant cap, so large organizations saw only "Workspace access supports at most 1000
workspaces" and could not use Access or Workflow connection requests.
The read now names only the granted workspaces (bounded by the grant cap), and Add workspace
searches the organization's workspaces without access on the server: a bounded, wildcard-escaped
name search behind the same admin read operation, exposed to the settings UI and to Copilot
(search_workspaces). The grant cap itself is unchanged.
* fix(credential-groups): honest verify fallback, active-only access grants, review follow-ups
* improvement(credential-groups): simplify connect errors, verify cooldown and access helpers
* chore(credential-groups): cleanup pass on comments and tests
* fix(credential-groups): first request email keeps every reminder, hide unmatched picker selection
Copy file name to clipboardExpand all lines: apps/docs/content/docs/platform/connected-accounts.mdx
+10-2Lines changed: 10 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -60,6 +60,8 @@ Use the invitation email for workflow lookups. For example, inviting `alex@examp
60
60
61
61
On first use, the invitation email must match the signed-in user's verified Sim email. Sim binds the invitation to that user account. Opening the link as another person cannot take it over, and a later email change does not transfer it to another Sim user. The invitation email remains the workflow lookup key.
62
62
63
+
A person whose Sim email is not verified cannot connect until they verify it. Where your deployment cannot send verification codes, they sign in again with Google or GitHub, if configured, to confirm the address.
64
+
63
65
The verified Sim user who starts authorization must complete it. The provider account may have a different email; its contribution belongs to the bound Sim user. Managed MCP connections use that person's authorization too. Search separately checks current provider identity and source-specific access requirements.
64
66
65
67
Each person shows one status:
@@ -69,15 +71,15 @@ Each person shows one status:
69
71
|**Invited**| Sim emailed a request the person has not accepted yet |
70
72
|**Requested**| A workflow asked, but Sim did not email the person |
71
73
|**Expired**| The request went unaccepted for 7 days; send a reminder to renew it |
72
-
|**Email failed**| Sim could not deliver the request email |
74
+
|**Email failed**| Sim could not deliver the request email, and the person has not accepted it|
73
75
|**Not connected**| The person accepted but has no connected account |
74
76
|**Connected**| At least one account is connected |
75
77
|**Needs reconnect**| An account stopped working and must be reconnected |
76
78
|**Revoked**| An admin revoked the person |
77
79
78
80
People asked by a workflow are also marked **Requested by workflow**.
79
81
80
-
Use **Send reminder** in a person's menu while any integration they were asked for is not connected; it also renews an expired request. A reminder for a workflow's request stays attributed to the workflow. **Revoke** stops the organization from using their contributions. They cannot undo an administrator's revocation by reconnecting themselves; use **Re-invite** to ask them again.
82
+
Use **Send email** in a person's menu, or **Send reminder** once Sim has emailed them, while any integration they were asked for is not connected; it also renews an expired request. A reminder for a workflow's request stays attributed to the workflow. **Revoke** stops the organization from using their contributions. They cannot undo an administrator's revocation by reconnecting themselves; use **Re-invite** to ask them again.
81
83
82
84
### 3. Grant workspace access
83
85
@@ -96,6 +98,10 @@ For example, allowing Gmail in the Support workspace lets its authorized workflo
96
98
97
99
Changes apply to subsequent calls. Removing access cannot recall a provider request already in flight or erase data already received. Standalone Chat continues to use each person's own connections; the workspace grant does not give Chat other people's accounts.
98
100
101
+
### Workflow connection requests
102
+
103
+
Workflows cannot ask people to connect until an admin turns on **Allow workflow requests** under **Workflow connection requests** on **Access**, choosing workspaces, email domains, integrations, a daily limit, and whether to **Also email the person**. The workspace must also have the integration on **Access**. Once on, any run of a workflow in a chosen workspace can use **Request Connection** to ask people at those domains, and Sim emails them when that option is on. See [Connection status and requests](/workflows/blocks/credential#connection-requests).
104
+
99
105
## Use account references in workflows
100
106
101
107
In an eligible workspace, use the Credential block's organization operations:
@@ -106,6 +112,8 @@ In an eligible workspace, use the Credential block's organization operations:
106
112
|**List Organization Accounts**| A page of OAuth accounts, optionally filtered by email and providers |
107
113
|**Find Organization MCP Connection**| One managed MCP connection matching the invitation email and MCP provider |
108
114
|**List Organization MCP Connections**| A page of managed MCP connections, optionally filtered by email and provider |
115
+
|**Get Connection Status**| Whether a person has a usable account for an integration, and their link to connect it |
116
+
|**Request Connection**| Asks a person to connect an integration, when workflow connection requests allow it |
109
117
110
118
The workflow's workspace determines the organization. You do not enter a credential group or organization ID.
Copy file name to clipboardExpand all lines: apps/docs/content/docs/workflows/blocks/credential.mdx
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -101,15 +101,15 @@ For example, name the block **Account**, choose Find Organization Account, set E
101
101
|`credentialId`| The account Find Organization Account would return, or `null` unless connected |
102
102
|`connectUrl`| A link the person opens to sign in to Sim and connect this integration |
103
103
104
-
The status never says whether the person was invited, removed, or never asked. `connectUrl` carries no secret: the page checks that the signed-in person is the one with that email before anything is connected, so it is safe to post, for example as a Slack button.
104
+
The status never says whether the person was invited, removed, or never asked. `connectUrl`is that person's link and carries no secret: the page checks that the signed-in person has that email before anything is connected, and tells anyone else the link was sent to a different email. So it is safe to post, for example as a Slack button.
105
105
106
106
A `connectUrl` from Get Connection Status alone works only for members of your organization. Anyone else must be asked first, by **Request Connection** or by an admin in **People**; otherwise the page tells them no connection was requested. So when `connected` is false, call **Request Connection** first, then show `connectUrl`.
107
107
108
108
Set **Return to** to **Slack** when the person starts in Slack: once their account is connected, the page offers a **Return to Slack** button. It opens the Slack app, so someone using Slack in a browser instead closes the tab, and the page says so. With **None** the page tells them they can close the tab. Someone who opens the link again after connecting is told the account is already connected.
109
109
110
-
**Request Connection** returns `requested` and `connectUrl`. It works only when an admin turns on **Allow workflow requests** under **Workflow connection requests** in **Settings → Credential Groups → Access**, for the workflow's workspace, the person's email domain, and the integration. That setting is the only gate: any run of the workflow can request a connection, including a manual run by a workspace member with read access. A request outside those settings, or past the daily limit, fails with an error. Otherwise the result is the same whether the person was already asked, already connected, or removed; a removed person is never re-invited. Use the person's primary address: an address with a `+` alias is refused.
110
+
**Request Connection** returns `requested` and `connectUrl`. It works only when an admin turns on **Allow workflow requests** under **Workflow connection requests** in **Settings → Credential Groups → Access**, for the workflow's workspace, the person's email domain, and the integration, and the workspace has that integration on **Access**. Nothing else gates a request: any run of the workflow can request a connection, including a manual run by a workspace member with read access. A request outside those settings, or past the daily limit, fails with an error. Otherwise the result is the same whether the person was already asked, already connected, or removed; a removed person is never re-invited. Use the person's primary address: an address with a `+` alias is refused.
111
111
112
-
The daily limit counts each new person asked per day, across all workspaces; below the limit, asking again for someone already asked that day does not count. Once the limit is reached, every request fails, including one for someone already asked that day. A request the person has not accepted expires after 7 days; asking again renews it.
112
+
The daily limit counts distinct people asked in the last 24 hours, a rolling window, across all workspaces. Everyone asked counts, including people asked or connected before; asking again for someone already counted in the window does not count again. Once the limit is reached, every request fails, including one for someone already counted. A request the person has not accepted expires after 7 days; asking again renews it.
113
113
114
114
Sim emails the person only when the admin turned on **Also email the person**. The email carries the link and the workflow's name. Sim sends up to 3 reminders, each only when a workflow asks again after a day with no request for that person, and none after 30 days. Runs from the workflow editor are real: they send real emails and count toward the daily limit.
0 commit comments