Skip to content

feat(ui): surface app-connection envMappings in Configure Agent dialog#282

Merged
Tomas2D merged 2 commits intomainfrom
feat/app-env-in-configure-dialog
Apr 23, 2026
Merged

feat(ui): surface app-connection envMappings in Configure Agent dialog#282
Tomas2D merged 2 commits intomainfrom
feat/app-env-in-configure-dialog

Conversation

@Tomas2D
Copy link
Copy Markdown
Contributor

@Tomas2D Tomas2D commented Apr 22, 2026

Problem

Granting an app connection (GitHub, Google Drive, etc.) in the Configure Agent dialog silently injects env vars into the agent pod, but the dialog never said so:

  • App rows in the Connections tab showed the label and identity only — no hint that enabling the connection sets a pod env.
  • The Environment tab's "Inherited · managed elsewhere" list only iterated granted secrets, not granted apps. Connector-declared envs were invisible unless they happened to be copied into the editable env via the grant-time populate path.

Users had to kubectl exec into a pod to discover what env the agent would see.

Changes

  • ConnectionsPicker: each app row now renders its declared env names (env: FOO, BAR) under the label — same affordance secret rows already have.
  • EditAgentSecretsDialog: granted-app envMappings contribute to the Environment tab's "Inherited" list alongside granted-secret envs. Entries already present in the user's editable list are skipped so the "Custom" override path still wins.

Both paths read from AppConnectionView.envMappings, which the API server passes through verbatim from OneCLI's app registry — no per-provider code in Humr.

Depends on

kagenti/onecli#18 — makes envMappings required on every app definition and populates it for GitHub, GitHub Enterprise, YouTube, Resend, and Spotify. Until that ships, this UI correctly shows env info for Google Workspace only (the one family that currently declares a mapping). After it ships, every connection lights up automatically.

Test plan

  • mise run check (lint + types + Go vet/build + helm lint/render)
  • mise run test (60 Go + 41 TS passing)
  • With a cluster running the new OneCLI: open Configure Agent, toggle GitHub, confirm env: GH_TOKEN on the app row and an "Inherited" row on the Environment tab
  • Google Drive (works on current OneCLI): toggle, confirm GOOGLE_WORKSPACE_CLI_TOKEN appears in both places

When a user granted an app connection (GitHub, Google, etc.), there was
no indication in the dialog that doing so would inject env vars into
the agent pod — only granted *secrets* contributed to the "Inherited"
list, and app rows didn't show their declared env names at all. Users
had to exec into the pod to discover the contract.

- ConnectionsPicker: app rows now render their declared env names
  under the label, matching how secret rows display them.
- EditAgentSecretsDialog: granted-app envMappings flow into the
  Environment tab's "Inherited · managed elsewhere" list, deduped
  against user-edited entries so the "Custom" override path still wins.

Depends on kagenti/onecli#18 — once that ships, every app connection
returns a non-null envMappings array and the UI lights up for all of
them (not just Google Workspace).

Signed-off-by: Tomas Dvorak <toomas2d@gmail.com>
@Tomas2D Tomas2D force-pushed the feat/app-env-in-configure-dialog branch from 969ef9b to eba7ba1 Compare April 22, 2026 15:29
Copy link
Copy Markdown
Contributor

@matoushavlena matoushavlena left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know it doesn't directnly depends on the oneCLI PR, but still it would be good to bump the onecli version in helm.

Ships the required envMappings for every app — GitHub, GitHub
Enterprise, YouTube, Resend, Spotify — so the Configure Agent dialog
now surfaces env info for every connection, not just Google Workspace.

Signed-off-by: Tomas Dvorak <toomas2d@gmail.com>
@Tomas2D Tomas2D merged commit 92cf72e into main Apr 23, 2026
11 checks passed
@Tomas2D Tomas2D deleted the feat/app-env-in-configure-dialog branch April 23, 2026 07:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants