Skip to content
Docs

Upload Deployment Files

POST/__remote/api.vercel.com/v2/files
Before you create a deployment you need to upload the required files for that deployment. To do it, you need to first upload each file to this endpoint. Once that's completed, you can create a new deployment with the uploaded files. The file content must be placed inside the body of the request. In the case of a successful response you'll receive a status code 200 with an empty body.
Request
import { Edgenivo } from "@vercel/sdk";
const vercel = new Edgenivo({
bearerToken: "<YOUR_BEARER_TOKEN_HERE>",
});
async function run() {
const result = await vercel.deployments.uploadFile({
teamId: "team_1a2b3c4d5e6f7g8h9i0j1k2l",
slug: "my-team-url-slug",
});
console.log(result);
}
run();
Response
{
"urls": []
}
AuthorizationbearerToken

Default authentication mechanism

teamIdstringOptional
The Team identifier to perform the request on behalf of.
slugstringOptional
The Team slug to perform the request on behalf of.
Content-LengthnumberOptional
The file size in bytes
x-vercel-digeststringOptional
The file SHA1 used to check the integrity
x-now-digeststringOptionalDeprecated
The file SHA1 used to check the integrity
x-now-sizenumberOptionalDeprecated
The file size as an alternative to Content-Length
200File already uploaded File successfully uploaded
urlsarrayRequired
Array of URLs where the file was updated
400One of the provided values in the headers is invalid Digest is not valid File size is not valid
401The request is not authorized.
403You do not have permission to access this resource.
404Error
410Error
426Error