Skip to content

Commit 2caba83

Browse files
committed
feat(automation): Setup → Integrations → Connector Connections, gated on manage_connector_connections
Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 0466f27 commit 2caba83

7 files changed

Lines changed: 34 additions & 5 deletions

File tree

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
---
22
'@object-ui/app-shell': patch
33
'@object-ui/i18n': patch
4+
'@objectstack/service-automation': patch
5+
'@objectstack/platform-objects': patch
46
---
57

68
feat(console): Connector connections, a Setup page to connect, reconnect or disconnect each OAuth connector instance and see its status
79

810
Clause-②: no
911
Metadata-protocol: none
1012

11-
A connector instance declared with `auth: { type: 'oauth2', grant: 'authorization_code' }` needs an administrator to sign in to the vendor once for their organization. The Console now has a page for that (`automation:connector-connections`, linked from Connector credentials). It lists every such instance with the organization's connection status as the server answers it (Not connected, Connected, or Reconnect required with the reason the server recorded), the granted scopes, who connected it and when, and when the access token renews. A `degraded` instance shows the server's reason in the same row as the connection that caused it.
13+
A connector instance declared with `auth: { type: 'oauth2', grant: 'authorization_code' }` needs an administrator to sign in to the vendor once for their organization. The Console now has a page for that (`automation:connector-connections`). `@objectstack/service-automation` contributes its Setup → Integrations entry, **Connector Connections**, gated on `manage_connector_connections`, the organization-scoped capability the connection door asks, so an organization administrator sees it; `@objectstack/platform-objects` carries the entry's label in its four Setup translation packs. The page lists every such instance with the organization's connection status as the server answers it (Not connected, Connected, or Reconnect required with the reason the server recorded), the granted scopes, who connected it and when, and when the access token renews. A `degraded` instance shows the server's reason in the same row as the connection that caused it.
1214

1315
**Connect** and **Reconnect** open the vendor's sign-in in its own window, detached from the page, and send it to the authorization URL the server answered. The page re-reads the status until the connect lands, then closes the window and shows the new status. **Disconnect** removes the connection after a confirmation. No token, code or authorization URL is ever rendered.

‎content/docs/automation/connectors.mdx‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -640,14 +640,14 @@ a rotating refresh token is never spent twice.
640640
DELETE /api/v1/automation/connectors/:name/connection → revoke
641641
```
642642

643-
**In the Console**, the **Connector connections** page drives these calls.
643+
**In the Console**, **Setup → Integrations → Connector Connections** drives
644+
these calls; the entry is shown to holders of `manage_connector_connections`.
644645
It lists each `authorization_code` instance with the organization's status,
645646
the reason the server recorded and, for a `degraded` instance, the server's
646647
reason beside the connection that caused it. **Connect** and **Reconnect**
647648
open the vendor's sign-in in its own window, detached from the page, and the
648649
page shows the new status once the callback has stored it; **Disconnect**
649-
revokes after a confirmation. No Setup navigation entry names the page yet:
650-
it is reached from the link on **Connector Credentials**.
650+
revokes after a confirmation.
651651

652652
`GET …/:name/connection` answers the organization's status
653653
(`not_connected`, `connected`, `reconnect_required`), never a token. The

‎packages/platform-objects/src/apps/translations/en.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,7 @@ export const en: TranslationData = {
161161
nav_http_deliveries: { label: 'HTTP Deliveries' },
162162
nav_datasources: { label: 'Datasources' },
163163
nav_connector_credentials: { label: 'Connector Credentials' },
164+
nav_connector_connections: { label: 'Connector Connections' },
164165

165166
// Advanced
166167
//

‎packages/platform-objects/src/apps/translations/es-ES.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ export const esES: TranslationData = {
109109
nav_http_deliveries: { label: 'Entregas HTTP' },
110110
nav_datasources: { label: 'Fuentes de datos' },
111111
nav_connector_credentials: { label: 'Credenciales de conectores' },
112+
nav_connector_connections: { label: 'Conexiones de conectores' },
112113

113114
nav_oauth_apps: { label: 'Aplicaciones OAuth' },
114115
},

‎packages/platform-objects/src/apps/translations/ja-JP.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ export const jaJP: TranslationData = {
109109
nav_http_deliveries: { label: 'HTTP 配信' },
110110
nav_datasources: { label: 'データソース' },
111111
nav_connector_credentials: { label: 'コネクタ認証情報' },
112+
nav_connector_connections: { label: 'コネクタ接続' },
112113

113114
nav_oauth_apps: { label: 'OAuth アプリケーション' },
114115
},

‎packages/platform-objects/src/apps/translations/zh-CN.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,7 @@ export const zhCN: TranslationData = {
119119
nav_http_deliveries: { label: 'HTTP 投递' },
120120
nav_datasources: { label: '数据源' },
121121
nav_connector_credentials: { label: '连接器凭据' },
122+
nav_connector_connections: { label: '连接器连接' },
122123

123124
nav_oauth_apps: { label: 'OAuth 应用' },
124125
},

‎packages/services/service-automation/src/connector-credentials-ui.ts‎

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,15 @@
1717
* declares the door's own capability, `manage_metadata`, which every one of its
1818
* three routes asks before anything else: the rule the page's routes enforce
1919
* is stated by the plugin that enforces it, not borrowed from the group.
20+
*
21+
* ADR-0143 D5 — the same contribution carries Setup → Integrations →
22+
* "Connector Connections": the console's `automation:connector-connections`
23+
* page, which reads and drives the connector connection door
24+
* (`/api/v1/automation/connectors/:name/connection`). That door asks the
25+
* organization-scoped `manage_connector_connections` and nothing else, so the
26+
* entry asks it too: an organization administrator holds it and not
27+
* `manage_metadata`, and must see the page that connects their organization's
28+
* vendors.
2029
*/
2130

2231
/** The console component the entry opens. */
@@ -25,6 +34,12 @@ export const CONNECTOR_CREDENTIALS_COMPONENT_REF = 'automation:connector-credent
2534
/** The capability the credential door asks on all three routes. */
2635
export const CONNECTOR_CREDENTIALS_NAV_CAPABILITY = 'manage_metadata';
2736

37+
/** The console component the connections entry opens (ADR-0143 D5). */
38+
export const CONNECTOR_CONNECTIONS_COMPONENT_REF = 'automation:connector-connections';
39+
40+
/** The organization-scoped capability the connector connection door asks on every route. */
41+
export const CONNECTOR_CONNECTIONS_NAV_CAPABILITY = 'manage_connector_connections';
42+
2843
/**
2944
* `priority` orders contributions within a group, lowest first. The group's
3045
* other contributors, read where they are declared: Webhooks / HTTP Deliveries
@@ -40,7 +55,7 @@ export const CONNECTOR_CREDENTIALS_UI_BUNDLE = {
4055
type: 'plugin',
4156
scope: 'system',
4257
name: 'Connector Credentials UI',
43-
description: 'Setup navigation for the connector credentials the installed apps declare: set, replace or clear each one.',
58+
description: 'Setup navigation for the connector credentials the installed apps declare (set, replace or clear each one) and for the OAuth connections an organization administrator connects.',
4459
navigationContributions: [
4560
{
4661
app: 'setup',
@@ -55,6 +70,14 @@ export const CONNECTOR_CREDENTIALS_UI_BUNDLE = {
5570
icon: 'key-round',
5671
requiredPermissions: [CONNECTOR_CREDENTIALS_NAV_CAPABILITY],
5772
},
73+
{
74+
id: 'nav_connector_connections',
75+
type: 'component',
76+
label: 'Connector Connections',
77+
componentRef: CONNECTOR_CONNECTIONS_COMPONENT_REF,
78+
icon: 'plug',
79+
requiredPermissions: [CONNECTOR_CONNECTIONS_NAV_CAPABILITY],
80+
},
5881
],
5982
},
6083
],

0 commit comments

Comments
 (0)