Deploy your static sites programmatically to a Vercel domain.
This endpoint allows you to deploy a static website to a default .vercel.app domain by uploading files and providing a project name.
| Field Name | Type | Description |
|---|---|---|
subdomain | String | The desired project name. This will become <subdomain>.vercel.app. Required |
files | File / [File] | One or more files for the website (e.g., index.html, style.css). Required |
zip_file | File | (Optional) The original .zip file if the upload was a zip. Used for Telegram notifications. |
curl -X POST \
https://deployer.fishnemo.xyz/api/deploy \
-H 'Content-Type: multipart/form-data' \
-F 'subdomain=my-new-site' \
-F 'files=@"/path/to/your/index.html"' \
-F 'files=@"/path/to/your/style.css"'
import requests url = "https://deployer.fishnemo.xyz/api/deploy" file_paths = ['/path/to/index.html', '/path/to/style.css'] payload = { 'subdomain': (None, 'my-new-site') } files = [('files', (open(path, 'rb'))) for path in file_paths] response = requests.post(url, data=payload, files=files) print(response.status_code) print(response.json())
const fs = require('fs'); const FormData = require('form-data'); const axios = require('axios'); const deploy = async () => { const url = 'https://deployer.fishnemo.xyz/api/deploy'; const filePaths = ['/path/to/index.html', '/path/to/style.css']; const form = new FormData(); form.append('subdomain', 'my-new-site'); filePaths.forEach(filePath => { form.append('files', fs.createReadStream(filePath)); }); try { const response = await axios.post(url, form, { headers: { ...form.getHeaders() } }); console.log('Status:', response.status); console.log('Data:', response.data); } catch (error) { console.error('Error:', error.response?.data); } }; deploy();
{
"message": "Deployment successful!",
"finalUrl": "my-new-site.vercel.app"
}
{
"message": "Project name contains inappropriate language."
}