Skip to content
Docs

Start a blob upload

POSThttps://api.vercel.com/v2/{teamSlug}/{projectSlug}/{repositoryName}/blobs/uploads/
POST /v2/:teamSlug/:projectSlug/:repositoryName/blobs/uploads/[?mount=&from=] Initiate a blob upload. Returns a UUID in the Location header that the client uses for subsequent PATCH (chunk) and PUT (complete) requests.
https://api.vercel.com/v2/{teamSlug}/{projectSlug}/{repositoryName}/blobs/uploads/
const response = await fetch('https://api.vercel.com/v2/teamSlug/projectSlug/repositoryName/blobs/uploads/?mount=string&from=string', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_ACCESS_TOKEN',
'Content-Type': 'application/json',
},
});
const data = await response.json();
console.log(data);
Response
"value"
teamSlugstringRequired
Single Docker repository team slug component.
projectSlugstringRequired
Single Docker repository project slug component.
repositoryNamestringRequired
Single Docker repository name component.
mountstringOptional
Digest of the blob to mount from another repository.
fromstringOptional
Source repository to mount the blob from.
202Success
400One of the provided values in the request query is invalid.
401The request is not authorized.
402The account is missing a payment so payment method must be updated
403You do not have permission to access this resource.
404Error
410Error