Skip to content

Add workspace support for full scans (v1.x)#1096

Open
lelia wants to merge 2 commits intov1.xfrom
lelia/add-workspace-support-v1x
Open

Add workspace support for full scans (v1.x)#1096
lelia wants to merge 2 commits intov1.xfrom
lelia/add-workspace-support-v1x

Conversation

@lelia
Copy link

@lelia lelia commented Feb 27, 2026

Summary

Adds --workspace support to socket scan create so scans can be associated with the correct Socket workspace (API workspace query param on CreateOrgFullScan). Also allows persisting a default workspace via socket scan setup.

💡 Note: This PR was previously filed as #1095, but due to targeting main instead of v1.x, it was easier to simply re-create as a fresh PR.

Changes

  • CLI flag: socket scan create --workspace <string> (optional)
  • Config: socket scan setup can persist defaults.scan.create.workspace in .socket/socket.json
  • API plumbing: forwards workspace through handleCreateNewScanfetchCreateOrgFullScan → SDK createFullScan(..., { workspace })

refs: SocketDev/socket-python-cli#164 + SocketDev/socket-sdk-python#68


Note

Medium Risk
Adds a new optional CLI/config parameter that is forwarded into the scan-creation API call; risk is mainly around incorrect workspace association or API compatibility when the param is present/absent.

Overview
socket scan create now accepts --workspace (and can default it from .socket/socket.json), and forwards it through handleCreateNewScan into fetchCreateOrgFullScan, which conditionally includes workspace in the CreateOrgFullScan API request.

socket scan setup is extended to prompt for and persist defaults.scan.create.workspace (defaulting to the git remote owner when available), and the scan create --help snapshot test is updated to include the new flag.

Written by Cursor Bugbot for commit 5c333ad. This will update automatically on new commits. Configure here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant