CLI: Update SDK to 12b3ec6 and add new commands/flags#140
Merged
Conversation
…issing flags Keep the CLI aligned with the latest kernel-go-sdk release while exposing browser process env/TTY options and browser pool chrome policy support that were already present in the SDK. Tested: go test ./cmd/... && go build ./... Tested: kernel browsers process exec --env Tested: kernel browsers process spawn --allocate-tty --cols --rows --env Tested: kernel browser-pools create/update --chrome-policy Made-with: Cursor
…issing flags Align the CLI with the latest kernel-go-sdk by exposing browser default stealth proxy control and the new proxy health check URL parameter. This also updates the CLI dependency to the SDK release that includes these API changes. Tested: go test ./cmd ./cmd/proxies -run 'TestBrowsersUpdate_|TestProxyCheck_' Tested: go build ./... Tested: /tmp/kernel-cli/bin/kernel browsers create --headless --stealth -t 30 -o json Tested: /tmp/kernel-cli/bin/kernel browsers update <session_id> --disable-default-proxy -o json Tested: /tmp/kernel-cli/bin/kernel proxies create --type datacenter --country US --name <name> -o json Tested: /tmp/kernel-cli/bin/kernel proxies check <proxy_id> --url https://example.com -o json Made-with: Cursor
Bring the CLI onto the latest kernel-go-sdk release so it stays aligned with the updated SDK. A full SDK/CLI coverage audit found no missing commands or flags; tested with `go build ./...`. Made-with: Cursor
…roject commands Add CLI coverage for the hidden-but-supported project and project-limit endpoints while bumping the Go SDK to the latest release containing this revision. Tested: go test ./cmd/..., go build ./..., kernel projects create/get/update/list/limits get/limits update/delete Made-with: Cursor
A full SDK and CLI coverage enumeration found no missing commands or flags, so this updates the dependency to the v0.49.0 SDK release for commit c04f920b6dc5892ae2e2188f57a9df5373caa5cd. Tested: go build ./... Tested: go build -o /tmp/kernel-cli/bin/kernel ./cmd/kernel Made-with: Cursor
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
Bump the CLI to kernel-go-sdk v0.50.0 from commit c42a036c30ae4d319c5a11e00fe41106ba10ab33. A full SDK and CLI enumeration found no missing command or flag coverage to add in this update. Tested: go build ./..., go build -o /tmp/kernel-cli/bin/kernel ./cmd/kernel Made-with: Cursor
Bumps kernel-go-sdk from v0.79.0 to
v0.83.1-0.20260724213320-12b3ec62f63e (12b3ec6).
The branch did not compile before this change: the earlier "Merge main
into cli-coverage-update" commit dropped several branch-side lines while
keeping their callers. Those are repaired first, then the SDK diff and a
full api.md enumeration are covered.
Merge repairs (broken on this branch independent of the SDK bump):
- cmd/browsers.go: restore parseStringMapFlag, which two call sites used
- cmd/browser_pools.go: drop the stale 1-arg parseChromePolicy that
collided with the 2-arg version in browsers.go
- cmd/browsers.go: restore BrowsersUpdateInput.DisableDefaultProxy and
count it in hasProxyChange so --disable-default-proxy works again
- cmd/proxies: register the missing --url flag on `proxies check` and
actually forward it into ProxyCheckParams
- cmd/root.go: drop the duplicate rootCmd.AddCommand(projectsCmd)
New flags for SDK params added since v0.79.0:
- `profiles download --format tar.zst|tar` for ProfileDownloadParams.Format;
extraction now skips zstd when the server already decompressed
- `auth connections create/update/login --telemetry` for the new
browser_telemetry configs on ManagedAuthCreateRequest,
ManagedAuthUpdateRequest, and AuthConnectionLoginParams
- `auth connections submit --field-value` and `--choice-id` for the
canonical SubmitFieldsRequest.FieldValues / SelectedChoiceID, which
supersede the legacy fields/mfa-option/sso selectors
- `auth connections get` and `follow` now render canonical Fields and
Choices, plus Browser Session ID and Browser Telemetry
New commands closing pre-existing api.md gaps:
- `auth connections timeline` for Auth.Connections.Timeline, with the
page/per-page +1 pagination UX
- `profiles update` for Profiles.Update
- `projects update` for Projects.Update
- `org limits get` / `org limits set` for Organization.Limits.Get/Update
A full enumeration of api.md against the CLI now shows every SDK method
covered; /auth/connections/{id}/exchange stays out (x-cli-skip).
Tested against the live API: profiles create/update/get/delete; profiles
download (default tar.zst and --format tar produce identical trees,
--format zip rejected); auth connections create --telemetry
console,network, update --telemetry all/off, login --telemetry
screenshot, get (telemetry + browser session rows), timeline (real login
event with browser_session_id, --type login, --type bogus rejected),
submit --choice-id and --field-value (payloads accepted by the API);
projects update --name by ID and --status archived by name, plus both
validation errors; org limits get/set (set 50, verified, restored to no
default); proxies check --url; browsers update --disable-default-proxy
on stealth and non-stealth browsers. go build, go vet, and go test all
pass; new unit tests cover each addition.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
… env/tty flags
A concurrent run of this workflow landed the SDK bump and most of the
coverage in the parent commit. A fresh enumeration of api.md against the
resulting command tree still showed uncovered surface, which this adds.
SDK methods that had no CLI command:
- `api-keys rotate` for client.APIKeys.Rotate, with --days-to-expire,
--expire-in-days, and a confirmation prompt (the rotated key stops
working after its grace period, so this is not freely reversible)
- `proxies update` for client.Proxies.Update
SDK params that had no CLI flag:
- `api-keys get --include-deleted` for APIKeyGetParams.IncludeDeleted
- `browsers process exec --env` and `browsers process spawn --env
--allocate-tty --cols --rows`. The parent commit restored the code that
reads these, but the flags were never registered, so cobra returned
zero values and the plumbing was unreachable: --env could not set an
environment variable and --allocate-tty could not request a PTY.
Also fixes `auth connections get`/`follow` reporting an enabled
connection as telemetry "disabled". The API preserves the create-browser
config verbatim instead of resolving it, so enabling telemetry without
naming categories comes back as {"enabled": true} with no category
object. formatManagedAuthTelemetry only inspected the categories, so that
response rendered as "disabled" -- the opposite of the truth. It now
reports "enabled (default categories)"; telemetry that is genuinely off
still omits the row.
Reworded the spawn TTY validation error to lead with a word rather than a
flag, since the error renderer uppercases the first letter and printed
"--Cols and --rows require --allocate-tty".
Tested against the live API on top of the parent commit: proxies create/
update/delete; api-keys create/rotate --expire-in-days 0/get
--include-deleted/delete (both keys cleaned up); browsers process exec
--env (verified the variable reached the process), spawn --allocate-tty
--cols --rows --env, and the --cols-without-tty rejection; auth
connections update --telemetry all then get (now "enabled (default
categories)"), --telemetry console,network (lists categories), and
--telemetry off (row omitted). go build, go vet, and go test pass.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
There are 2 total unresolved issues (including 1 from previous review).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 9f76db7. Configure here.
…projects empty name) - browsers process exec/spawn flags (--env, --allocate-tty, --cols, --rows): already registered on the Cobra commands in the previous commit; verified against the run logic and --help output. - auth connections timeline --output json now prints a JSON envelope with events, page, per_page, and has_more (matching the telemetry events envelope pattern) instead of a bare array; table output unchanged. - projects update rejects an empty/whitespace --name client-side, mirroring the profiles update validation.
rgarcia
approved these changes
Jul 25, 2026
This was referenced Jul 25, 2026
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.

This PR updates the Go SDK to 12b3ec62f63ee66d3cd8d83d9c2b9584696dd15f and adds CLI commands/flags for new SDK methods.
SDK Update
v0.83.1-0.20260724213320-12b3ec62f63e), from v0.79.0Coverage Analysis
This PR was generated by performing a full enumeration of SDK methods and CLI commands.
/tmp/sdk-diff.patchwas empty for this run, so the v0.79.0..12b3ec6 diff was regenerated directly from the SDK repo.api.mdgained no new methods in that range — the changes are new request params plus one changed signature. A full enumeration of everyapi.mdmethod against the CLI then surfaced four resources that had never been wired up; those are covered here too./auth/connections/{id}/exchangeremains excluded (x-cli-skip: true).Important
This branch did not compile before this PR, independent of the SDK bump. The earlier
Merge main into cli-coverage-updatecommit (8aca3c1) dropped several branch-side lines while keeping the code that called them.go buildfailed onmain-merged HEAD with the old SDK too. Those repairs are included below and are worth a careful look, since they restore behavior that silently disappeared.Merge Repairs
cmd/browsers.go— restoredparseStringMapFlag, which two call sites still referencedcmd/browser_pools.go— removed the stale 1-argparseChromePolicythat collided with the 2-arg version inbrowsers.go(all call sites already pass 2 args)cmd/browsers.go— restoredBrowsersUpdateInput.DisableDefaultProxyand included it inhasProxyChange, sobrowsers update --disable-default-proxyworks again instead of failing the "must specify at least one of" guardcmd/proxies— registered the missing--urlflag onproxies checkand forwarded it intoProxyCheckParams(it was read from the flag set and threaded through the input struct, but never registered or sent)cmd/root.go— removed the duplicaterootCmd.AddCommand(projectsCmd)that listedprojectstwice in--helpNew Flags
--formatforProfileDownloadParams.Formatonprofiles download(tar.zstdefault, ortarto have the server decompress). Extraction skips zstd whentaris requested.--telemetryforManagedAuthCreateRequestParam.BrowserTelemetry,ManagedAuthUpdateRequestParam.BrowserTelemetry, andAuthConnectionLoginParams.BrowserTelemetryonauth connections create/update/login. Reuses the existingall/off/ comma-separated-category grammar frombrowsersandbrowser-pools.--field-valueforSubmitFieldsRequestParam.FieldValuesand--choice-idforSubmitFieldsRequestParam.SelectedChoiceIDonauth connections submit. These are the canonical replacements for the legacy--field/--mfa-option-id/--sso-*selectors; all seven are mutually exclusive, and legacyfieldsis now omitted entirely when empty so the API never sees"fields": {}as a second submit mode.auth connections getandfollownow renderManagedAuth.Fieldsand.Choices(with the IDs--field-value/--choice-idneed), plus.BrowserSessionIDand.BrowserTelemetry.New Commands
kernel auth connections timeline <id>forclient.Auth.Connections.Timeline()—--type,--page,--per-page, using the+1pagination trick and footer fromapp list/profiles list. Shows the newManagedAuthTimelineEvent.BrowserSessionID.kernel profiles update <id-or-name> --nameforclient.Profiles.Update()kernel projects update <id-or-name> [--name] [--status]forclient.Projects.Update()kernel org limits get/kernel org limits setforclient.Organization.Limits.Get()/.Update()Testing
Smoke tested against the live API; every resource created was cleaned up and the org's limits were restored to their original state.
profiles— create,update --name, get (rename verified), deleteprofiles download— defaulttar.zstand--format taragainst a profile with real saved data produce identical extracted trees (diff -rqclean);--format ziprejected client-side; the202 no data yetpath still handledauth connections—create --telemetry console,network(round-trips inbrowser_telemetry),update --telemetry alland--telemetry off,login --telemetry screenshot,get(renders Browser Telemetry + Browser Session ID rows)auth connections timeline— realloginevent withbrowser_session_id,--type loginfilter,--type bogusrejected, empty-timeline and past-the-end pagesauth connections submit—--choice-idand--field-valuepayloads accepted by the API's request parser (rejected only on flow state,no_active_flow, not schema); mutual exclusion andKEY=valueparsing verifiedprojects update—--nameby ID,--status archivedby name (name→ID resolution), plus both validation errorsorg limits—get,set 50, verified viaget, restored to no default withset 0; missing-flag and negative-value errorsproxies check --url https://example.com,browsers update --disable-default-proxyon both a stealth browser (succeeds) and a non-stealth one (API rejects with a meaningful error rather than the CLI's own guard), singleprojectsentry in--helpgo build ./...,go vet ./..., andgo test ./...all pass. New unit tests accompany every addition, including the timelinehasMorepath that the live API could not produce (the connection only ever had one timeline event).Follow-up commit: remaining api.md gaps
A concurrent run of this workflow landed the SDK bump and most of the coverage above. Re-running the enumeration against the resulting command tree surfaced uncovered surface that the first pass missed, added in
9f76db7on top of it (no force push — the earlier work is preserved).New Commands
kernel api-keys rotate <id>forclient.APIKeys.Rotate()—--days-to-expire,--expire-in-days, and a confirmation prompt (-yto skip). The rotated key stops working once its grace period elapses, so it is not freely reversible;--expire-in-days 0revokes it immediately.kernel proxies update <id> --nameforclient.Proxies.Update()New Flags
--include-deletedforAPIKeyGetParams.IncludeDeletedonapi-keys get--envforBrowserProcessExecParams.Envonbrowsers process exec, and--env,--allocate-tty,--cols,--rowsforBrowserProcessSpawnParams.Env/.AllocateTty/.Cols/.Rowsonbrowsers process spawn. The code that reads these was restored by the first commit, but the flags themselves were never registered, so cobra returned zero values and the plumbing was unreachable:--envcould not set a variable and--allocate-ttycould not request a PTY.Bug Fix: telemetry state reported backwards
auth connections getandfollowreported an enabled connection as telemetrydisabled. The API preserves the create-browser config verbatim instead of resolving it, so enabling telemetry without naming categories comes back as{"enabled": true}with no category object.formatManagedAuthTelemetryonly inspected the categories, so that response rendered asdisabled— the opposite of the truth. It now reportsenabled (default categories); telemetry that is genuinely off still omits the row entirely.Also reworded the spawn TTY validation error to lead with a word rather than a flag: the error renderer uppercases the first letter and was printing
--Cols and --rows require --allocate-tty.Note
The same renderer mangles pre-existing messages that start with a flag (e.g.
api-keys create --days-to-expire 5000prints--Days-To-Expire must be between 1 and 3650). That is untouched here — it predates this branch and affects several commands, so it is better fixed on its own.Follow-up commit testing
Also smoke tested against the live API; every resource created was deleted.
proxies update— create, rename, get (verified), deleteapi-keys rotate— create a throwaway key,rotate --expire-in-days 0(new key issued with a distinct secret),get --include-deleted, both keys deleted. The confirmation guard also verified to fail fast in a non-interactive shell instead of rotating.browsers process exec --env— confirmed the variable actually reached the process (echo "FOO=$FOO"→FOO=bar), which was impossible before the flag was registeredbrowsers process spawn—--allocate-tty --cols 100 --rows 40 --env T=1accepted;--colswithout--allocate-ttyrejectedauth connections—update --telemetry allthengetnow showsenabled (default categories)where it previously showeddisabled;--telemetry console,networklists the categories;--telemetry offomits the rowgo build ./...,go vet ./..., andgo test ./...pass. Unit tests accompany each addition, including theapi-keys rotatecase where--expire-in-days 0must reach the API as an explicit0rather than being dropped as a zero value.Triggered by: kernel/kernel-go-sdk@12b3ec6
Reviewer: @rgarcia
Note
Medium Risk
Touches API key rotation, org concurrency defaults, and managed auth submit/telemetry—important operational paths—but changes are mostly additive CLI wiring with validation and tests.
Overview
Bumps kernel-go-sdk to
v0.83.1-0.20260724213320-12b3ec62f63eand exposes previously missing SDK capabilities through new commands, flags, and README coverage.New commands:
api-keys rotate,proxies update,auth connections timeline,profiles update,projects update, andorg limits get/set.New / extended flags: API key
get(--include-deleted) and rotate options; proxycheck(--url); browserupdate(--disable-default-proxy); processexec/spawn(--env, plus PTY--allocate-tty/--cols/--rowson spawn); profile download--format; auth connection--telemetryon create/update/login and canonicalsubmitvia--field-value/--choice-id.Behavior fixes: Restores merge-dropped wiring (
parseStringMapFlag,DisableDefaultProxyon browser update, registered process flags); auth connection telemetry display no longer treats{"enabled": true}without categories as disabled; submit omits empty legacyfieldsso the API sees a single mode; duplicateprojectsroot registration removed.Reviewed by Cursor Bugbot for commit db12c8a. Bugbot is set up for automated code reviews on this repo. Configure here.