Feat: Add models + sandbox file/exec/library routes (33/33 with prod)#2
Merged
Conversation
Bundle the 7 routes prod gained after PR #1 so 2.1.0 ships in full sync: - Models resource: list (GET /v2/models) - Sandbox: exec (bash/python), list_files, download_file (raw bytes), delete_file, library_diff, create_library_patch - _client.request gains raw= for binary downloads - Vendored manifest bumped to 33; respx + live-staging coverage added Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
CI's ruff collapsed download_file's call to one line; pin ruff exactly so local and CI formatting never diverge (even patch releases change formatting). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
Bundles the routes prod added after #1 so 2.1.0 ships in full sync with prod (33/33 routes) rather than 26.
Grounded against the live backend handlers on
release(prod):models.go,sandbox.go.New methods
list()→GET /v2/models(models a key may pass as the chatmodelfield).exec(id, *, command, kind=None, env=None)→POST …/:id/exec(bash/python →{stdout,stderr,exit_code,error}; distinct fromexecute, which runs a Python script and returns dataframes).list_files(id, *, path=None)→GET …/:id/filesdownload_file(id, file_path)→GET …/:id/files/*— returns raw bytes (addedraw=to the client).delete_file(id, file_path)→DELETE …/:id/files/*library_diff(id)→GET …/:id/library/diffcreate_library_patch(id, *, title, description, draft, patch_number)→POST …/:id/library/patchesDrift guard
release);# v2:coversadded for every new method;test_route_coverageasserts 33/33.Verification
ruff+pyright(strict) clean;pytest44 passed, incl. live-staging coverage formodels.list,exec,list_files,library_diff.Note
Prod is moving fast (7 routes added in days) — reinforces the generated-SDK (Speakeasy) direction discussed separately. This PR is a point-in-time snapshot to ship 2.1.0 complete.
🤖 Generated with Claude Code