velt-proxy-server-best-practices

Configure reverse proxies routing Velt SDK traffic through nginx or Cloudflare Workers.

1|Updated Jan 23, 2026
One-click install
npx skills add https://github.com/velt-js/agent-skills --skill velt-proxy-server-best-practices-velt-js
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: velt-proxy-server-best-practices
Source: https://github.com/velt-js/agent-skills/tree/main/skills/velt-proxy-server-best-practices
Command: npx skills add https://github.com/velt-js/agent-skills --skill velt-proxy-server-best-practices-velt-js

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Enterprise network policies often prohibit direct browser connections to third-party services, which blocks the Velt collaboration SDK from reaching its CDN, API, database, storage, and auth endpoints. This Skill provides the exact SDK configuration and server-side proxy patterns needed to route all Velt traffic through your own domain. ## Core Features & Use Cases - SDK proxyConfig Setup: Configure all six proxy hosts (cdnHost, apiHost, v1DbHost, v2DbHost, storageHost, authHost) on VeltProvider for React/Next.js or initVelt() for Angular, Vue, and vanilla JS. - Server Proxy Recipes: Ready-to-adapt nginx server blocks and a Cloudflare Workers pattern covering WebSocket upgrades, Firebase RTDB shard host-locking, path-based auth routing, and dynamic upstream resolution. - Security & Debugging: Content Security Policy whitelisting, Subresource Integrity (SRI) for the proxied SDK bundle, the forceLongPolling fallback, and a verification checklist for common failures like CORS errors and dropped WebSocket connections. - Use Case: Your security team requires all third-party traffic to pass through proxy.acmecorp.com. Use this Skill to generate the full VeltProvider proxyConfig plus nginx configs for every Velt service host, including WebSocket support for the ephemeral database. ## Quick Start Ask the agent to set up a complete Velt reverse proxy with proxyConfig for your React app and matching nginx server blocks for the CDN, API, databases, storage, and auth hosts.

Frequently Asked Questions about velt-proxy-server-best-practices

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up a reverse proxy for the Velt SDK?▼

Set proxyConfig inside the config prop on VeltProvider (React) or the options argument of initVelt(), specifying base URLs for the hosts you proxy such as cdnHost, apiHost, v1DbHost, v2DbHost, storageHost, and authHost. Then configure nginx or Cloudflare Workers to transparently forward each host to its upstream target.

nginx vs Cloudflare Workers for proxying Velt traffic?▼

nginx covers all six Velt service hosts including CDN and API, while the Cloudflare Workers recipe covers only Auth, v2Db, v1Db, and Storage. Workers handles WebSocket upgrades automatically at the edge; nginx requires explicit Upgrade and Connection headers.

Does the Velt proxy support WebSocket connections?▼

Yes, but your proxy must support WebSocket upgrades. For nginx, set proxy_http_version 1.1 with Upgrade and Connection headers plus long read timeouts. If your proxy cannot handle WebSockets, set forceLongPolling: true in proxyConfig to use HTTP long-polling instead.

Why is my Velt proxyConfig not taking effect?▼

Common causes include placing proxyConfig at the VeltProvider top level instead of inside config, typos in field names like v1DBHost instead of v1DbHost, or migrating from apiProxyDomain without moving it to proxyConfig.apiHost. Auth proxy changes may also require clearing localStorage.

What CSP domains do I whitelist for Velt with a proxy?▼

Whitelist your proxy domains in script-src, connect-src, img-src, and media-src, including wss:// entries for WebSocket database connections. If only some services are proxied, also include the default Velt domains (*.velt.dev, *.firebaseio.com, *.googleapis.com) for un-proxied traffic.