MediaGrabber Pro
Reference

Configuration Files

The config files in packages/config that drive a deployment.

A deployment is shaped almost entirely by a handful of typed config files in packages/config/src. Edit these (plus environment variables) rather than hunting through application code.

Overview

FileDrives
plugin.tsIdentity — name, slug, domain, company, description
branding.tsTheme — colors, logos, CSS tokens
pricing.tsPlans and their limits
providers.tsActive auth / billing / email providers
services.tsStorage, analytics, monitoring, jobs, i18n flags
connector.tsAdmin Module connection settings

plugin.ts

export const pluginConfig = {
  name: 'My Plugin',
  slug: 'my-plugin',          // must match the Admin Module registration
  domain: 'https://my-plugin.com',
  companyName: 'The Plugins Company',
  description: 'Short description for SEO + social cards.',
}

branding.ts

Colors, logos, and CSS custom-property tokens that theme the whole UI without touching component code. The primary color also drives accents and the navigation progress bar.

pricing.ts

Defines every plan and its entitlements. Plans sync to the database and back the billing flow:

type PlanLimits = {
  activations?: number | null
  apiRequestsPerMonth?: number | null
  teamSeats?: number | null
}

providers.ts

Selects the active provider for each pluggable subsystem. Switch a provider by changing one value — adapters live behind a shared interface.

export const authProvider = 'better-auth'      // | clerk | kinde | neon-auth
export const billingProvider = 'lemonsqueezy'  // | polar | dodo | clerk-billing | kinde-billing
export const emailProviders = ['resend', 'nodemailer', 'plunk', 'maileroo', 'mailgun']

See Providers for the full switching guide.

services.ts

Central, config-driven flags for the cross-cutting platform services. Analytics and monitoring are off unless their keys are present:

ServiceGate
StorageSTORAGE_ACCESS_KEY_ID + STORAGE_BUCKET set
Analytics (GA4)NEXT_PUBLIC_GA_MEASUREMENT_ID set
Monitoring (Sentry)SENTRY_DSN / NEXT_PUBLIC_SENTRY_DSN set
Jobs (QStash)QSTASH_TOKEN set
i18nLocales listed in i18nConfig

connector.ts

Settings for the Admin Module connection:

export const connectorConfig = {
  enabled: true,
  pluginSlug: process.env.PLUGIN_SLUG ?? 'my-plugin',
  adminUrl: process.env.ADMIN_CONNECTOR_URL ?? 'http://localhost:4000',
  secret: process.env.CONNECTOR_SECRET ?? '',
}

Non-secret switches live in these files; secrets always come from environment variables. See Environment Variables.

On this page

Configuration Files | MediaGrabber Pro