MATIH Platform is in active MVP development. Documentation reflects current implementation status.
7. Tenant Lifecycle
Branding & Domain Endpoints

Branding and Domain Endpoints

The branding endpoints manage tenant visual customization including logos, color schemes, theme presets, custom CSS, login page styling, and email branding. Served by TenantBrandingController at /api/v1/tenants/:tenantId/branding.


Endpoints

MethodEndpointDescription
GET.../brandingGet branding configuration
GET.../branding/renderGet rendered branding for mode
POST.../branding/initializeInitialize with defaults
PUT.../brandingUpdate branding
PUT.../branding/logoUpdate logo
PUT.../branding/colorsUpdate color scheme
GET.../branding/presetsGet available theme presets
POST.../branding/presets/:presetNameApply theme preset
PUT.../branding/custom-cssUpdate custom CSS
PUT.../branding/login-pageUpdate login page
PUT.../branding/emailUpdate email branding
POST.../branding/resetReset to defaults

GET .../branding/render

Returns rendered branding for a specific display mode. Useful for clients that need resolved values.

ParameterTypeDefaultDescription
darkModebooleanfalseWhether to return dark mode colors

Theme Presets

Available theme presets can be listed with GET .../branding/presets and applied with POST .../branding/presets/:presetName.

Applying a preset replaces the color scheme and typography settings while preserving logos and custom CSS.


Custom CSS

PUT .../branding/custom-css
{
  "css": ".sidebar { background: #1a1a2e; }",
  "enabled": true
}

Custom CSS is injected after the base theme styles, allowing tenants to override specific elements. The enabled flag controls whether the CSS is active.


Reset to Defaults

POST .../branding/reset

Restores all branding settings to platform defaults. This operation cannot be undone.