The server layer for Vite apps.
Databases, storage, queues, workflows, and more. Use one API in your app and deploy it to your choice of cloud.
Logs
Structured logs with Evlog
KV
State and cache
Blob
Files and uploads
Database
Relational data
Queue
Background jobs
Workflow
Durable orchestration
Schedule
Recurring work
Auth
Users and sessions
Connections
Connected account APIs
Workspace
Persistent file trees
Sandbox
Isolated execution
Browser
Browser operations
Shell
Command execution
Source
Read-only content
Content
Parse and search
Email
Transactional email
Channels
Named message delivery
Env
Typed configuration
Rate Limit
Request budgets
Realtime
Collaborative documents
Agent
Portable automation
UI
Agent interfaces
Write once.
Deploy anywhere.
Same code on every host. The host picks the provider.
server/api/settings.get.tsStore data docsDocs
import { defineEventHandler } from "h3"
import { kv } from "vite-hub/kv"
export default defineEventHandler(async () => {
const [error, settings] = await kv.get("settings")
if (error) throw error
return settings
})
Provider per host
- CloudflareWorkers KV
- VercelUpstash Redis
- DenoDeno KV
- Nodefs-lite or Upstash
Define an Agent in one file.
An Agent is one more file in your server. It deploys with your app and uses the same storage as your routes.
import { defineAgent } from "vite-hub/agent"
import { browser, kv } from "vite-hub/agent/capabilities"
import { github } from "vite-hub/agent/channels"
export default defineAgent({
description: "Reviews pull requests.",
channels: {
github: github({ pullRequest: { reconcile: { events: ["opened"] } } }),
},
driver: "codex",
workspace: { mode: "write" },
capabilities: [browser(), kv({ mode: "write" })],
})
import { defineEventHandler } from "h3"
import { kv } from "vite-hub/kv"
export default defineEventHandler(async () => {
const [error, keys] = await kv.keys()
if (error) throw error
return keys
})
Ship the server part with your Vite app.
- No account to start
- Apache-2.0
- Migrate from NuxtHub
- Runs onCloudflare, Vercel, Netlify, Deno, Node