Delete a drive
DEL
https://api.vercel.com/v2/sandboxes/drives/{name}Deletes a drive by project and name. Attached drives cannot be deleted. Stop or replace the session currently using the drive before retrying deletion.
https://api.vercel.com/v2/sandboxes/drives/{name}
const response = await fetch('https://api.vercel.com/v2/sandboxes/drives/name?projectId=string&teamId=string&slug=string', { method: 'DELETE', headers: { 'Authorization': 'Bearer YOUR_ACCESS_TOKEN', 'Content-Type': 'application/json', },});
const data = await response.json();console.log(data);Response
{ "drive": { "createdAt": "1750344501629", "currentSandboxName": "my-sandbox", "currentSessionId": "sbx_123", "id": "drive_abc123", "maxSizeBytes": "1099511627776", "name": "workspace", "projectId": "prj_abc123", "region": "iad1", "updatedAt": "1750344501629", "v0": "false" }}AuthorizationbearerToken
Default authentication mechanism