Build platforms where agents and users deploy apps
import { Vercel } from '@vercel/sdk';
const vercel = new Vercel({
bearerToken: process.env.VERCEL_TOKEN,
});
async function createAndGetProject() {
try {
const project = await vercel.projects.createProject({
requestBody: {
name: 'my-new-project',
framework: 'nextjs',
},
});
console.log(`Project created: ${project.id}`);
} catch (error) {
console.error(
error instanceof Error ? `Error: ${error.message}` : String(error),
);
}
}
createAndGetProject();Most platforms on Vercel follow one of two patterns. Pick the one that matches how isolated each customer needs to be:
| Approach | Codebase and deployment | Complexity | Best for |
|---|---|---|---|
| Multi-tenant | One codebase, one deployment serves every tenant | Lower | Content and branding differ, but functionality is the same (documentation sites, website builders, SaaS dashboards) |
| Multi-project | One project and deployment per tenant | Higher | Each tenant needs custom code or isolated infrastructure (AI coding platforms, user-generated apps) |
For a multi-tenant build, clone the Platforms Starter Kit. For a multi-project build, follow the multi-project quickstart to create and deploy tenant projects with the Vercel SDK.
Teams run many kinds of platforms on Vercel:
- AI app builders and coding platforms, where agents generate code and each app gets an isolated project and deployment. Start with the Platform Template or OSS coding agent.
- Content platforms, such as Hashnode and Dub.
- Documentation platforms, such as Mintlify, Fern, and Plain.
- Website and store builders, such as Super, Typedream, and Universe.
- B2B SaaS platforms, such as Zapier, Instatus, and Cal.
A typical setup gives you a root domain for your platform (acme.com), subdomains for tenants (tenant1.acme.com), and fully custom domains for customers who want them (tenantcustomdomain.com).
- Custom domains and
*.yourdomain.comsubdomains, subject to plan limits. - Automatic SSL for verified domains. Vercel issues and renews certificates after domain verification.
- Programmatic domain management through the REST API or the Vercel SDK.
- Global low-latency routing over the Vercel CDN and Anycast network.
- Preview deployments so you can test tenant changes before they ship.
- Support for 35+ frontend and backend frameworks.
Multi-tenant platforms
Serve many customers from one codebase with custom domains and subdomains.
Multi-project platforms
Give each customer an isolated project and deployment, created with the SDK.
Examples
Start from multi-project AI app builders or multi-tenant templates.
Platform elements
Drop in prebuilt actions and UI blocks for domains and deployments.
Starter template
Deploy a multi-tenant Next.js app with subdomain routing and tenant storage.
Was this helpful?