TECHNICAL

Building a Multi-Tenant Astrology Platform

Architecture guide for building a white-label astrology platform that serves multiple clients. Multi-tenancy, API key management, and billing.

March 6, 2026 - 12 min read

Multi-Tenant Architecture

A multi-tenant astrology platform serves multiple clients (astrology apps, matrimonial sites, media companies) from a single infrastructure. Each tenant gets a white-labeled experience with their own branding, user management, and billing — powered by Vedika API under the hood.

Architecture Pattern

Recommended approach: API Gateway (tenant identification via subdomain or API key prefix) → Tenant Config Store (branding, feature flags, billing tier) → Vedika API (shared astrology backend) → Response Transformer (tenant-specific formatting, branding injection).

// Multi-tenant middleware
function tenantMiddleware(req, res, next) {
  const apiKey = req.headers['x-api-key'];
  const tenant = getTenantFromKey(apiKey); // lookup in your DB

  req.tenant = tenant;
  req.vedikaKey = tenant.vedikaApiKey; // your master Vedika key
  req.features = tenant.enabledFeatures;
  req.branding = tenant.branding;
  next();
}

// Proxy to Vedika API with tenant context
app.post('/v1/birth-chart', tenantMiddleware, async (req, res) => {
  if (!req.features.includes('birth-chart')) {
    return res.status(403).json({ error: 'Feature not enabled for your plan' });
  }

  const result = await callVedikaApi('/v2/astrology/birth-chart', req.body, req.vedikaKey);

  // Apply tenant branding
  result.provider = req.branding.name;
  result.logo = req.branding.logoUrl;

  res.json(result);
});

Vedika Enterprise plan ($240/month) supports this pattern with higher rate limits and dedicated support. For smaller platforms, the Business plan ($120/month) provides sufficient capacity for 3-5 tenants.

Ready to integrate astrology into your app?

Start with our free sandbox — no API key required.

Try Sandbox Free