chore: promote test to main (sandbox staged-files cutover)#1749
Conversation
* feat(chat): migrate sandbox upload token handshake to api
Flips `handleUploadUrl` in lib/sandboxes/uploadSandboxFiles.ts from
the local /api/sandbox/upload route to the new
${getClientApiBaseUrl()}/api/sandboxes/staged-files on api, then
deletes the now-unused local route.
Closes Group 6 of the chat→api migration. Pairs with api PR for
the staged-files handler and docs PR for the OpenAPI entry.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(chat): point sandbox upload at /api/sandboxes/stage-files
Pairs with the api-side rename of /api/sandboxes/staged-files to
/api/sandboxes/stage-files.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(chat): point sandbox upload at /api/sandboxes/staged-file
Pairs with the api-side rename to the noun-shaped resource path.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(chat): pass sandbox staging auth via Authorization header
Vercel Blob client's upload() supports a `headers` option that
forwards arbitrary headers onto the handshake POST — replacing the
clientPayload.token dance with a normal Bearer header. Pairs with
the api-side switch to validateAuthContext().
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughThe pull request removes the legacy ChangesUpload Endpoint Migration
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Promotes
testtomain. Includes:POST /api/sandbox/uploadto apiManual verification of #1744 ran on the preview deployment — both Vercel Blob handshake (
/api/sandboxes/staged-file) and commit (/api/sandboxes/files) hit api with theAuthorization: Bearerheader; CORS preflight ok; old/api/sandbox/uploadroute on chat returns 404 as expected.Summary by cubic
Promotes test to main and completes the sandbox upload cutover to the API. Removes the local
POST /api/sandbox/uploadroute and updates uploads to call the API’s/api/sandboxes/staged-filewith anAuthorization: Bearerheader.Written for commit 7f0c518. Summary will update on new commits. Review in cubic
Summary by CodeRabbit