Visible credential target selector for secret writes; SDK Result import cleanup#512
Draft
RhysSullivan wants to merge 1 commit intors/cloud-workspaces-11-source-targetfrom
Draft
Conversation
…rt cleanup
Adds `CredentialTargetSelector` to the secret-create dialog, exposing the
full URL-context stack with the labels the plan in
`notes/cloud-workspaces-and-global-sources-plan.md` calls for:
- Only me in this workspace → user-workspace
- Everyone in <workspace name> → workspace
- Only me across this org → user-org
- Everyone in <org name> → org
Default selection is the URL context's active write scope (workspace in
workspace context, org in global). Local CLI hosts run a single-scope
stack and the selector renders one disabled option labeled with that
scope.
Server side, `assertScopedWrite` already rejects writes whose scope_id
is outside the URL-resolved stack as a typed `StorageError`; the new
`credential-target.node.test.ts` exercises both halves of the contract:
- All four legal targets in workspace context succeed and list back
tagged with the correct scope id.
- A cross-org write from workspace context is rejected.
Connection writes in v1 still default to the source-add form's
configured `tokenScope` and `bindingScope` (per-user); a future change
can layer this selector into the OAuth setup flow without changing the
server contract.
This was referenced May 4, 2026
Owner
Author
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
executor-marketing | 5b7d768 | Commit Preview URL Branch Preview URL |
May 04 2026, 05:12 PM |
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
executor-cloud | 5b7d768 | May 04 2026, 05:13 PM |
@executor-js/codemode-core
@executor-js/runtime-quickjs
@executor-js/cli
@executor-js/config
@executor-js/execution
@executor-js/sdk
@executor-js/storage-core
@executor-js/plugin-file-secrets
@executor-js/plugin-google-discovery
@executor-js/plugin-graphql
@executor-js/plugin-keychain
@executor-js/plugin-mcp
@executor-js/plugin-onepassword
@executor-js/plugin-openapi
executor
commit: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Adds
CredentialTargetSelectorto the secret-create dialog, exposing thefull URL-context stack with the labels the plan in
notes/cloud-workspaces-and-global-sources-plan.mdcalls for:Default selection is the URL context's active write scope (workspace in
workspace context, org in global). Local CLI hosts run a single-scope
stack and the selector renders one disabled option labeled with that
scope.
Server side,
assertScopedWritealready rejects writes whose scope_idis outside the URL-resolved stack as a typed
StorageError; the newcredential-target.node.test.tsexercises both halves of the contract:tagged with the correct scope id.
Connection writes in v1 still default to the source-add form's
configured
tokenScopeandbindingScope(per-user); a future changecan layer this selector into the OAuth setup flow without changing the
server contract.