Mursil Documentation

Product

Mursil is a fully open-source, standalone product for managing application email. There is no paid edition in this repository. It is a product layer above the CleanArch Pro Communication module. The framework module remains the low-level encrypted queue and delivery foundation. Mursil owns the product surface around that foundation.

A secure, template-first communication control plane for SaaS and enterprise applications.

The job

Product teams stop hard-coding email. They manage communication as a governed surface:

  • Reusable templates, addressed by a stable key.
  • Tenant branding applied at render time, so templates stay reusable.
  • Immutable published versions. A draft is not what production send uses.
  • Preview and test-send before publish.
  • Provider routing across SMTP, SendGrid, and other transports.
  • Delivery history, retries, and dead-letter handling.
  • Audit of operator actions.
  • Integration events written through a transactional outbox. Payloads are redacted.
  • A versioned HTTP API and a NuGet integration package.
  • A standalone operator portal.

Any product can be a consumer. Mursil is not coupled to one host product.

Who the portal is for

At launch, portal users are communication administrators and operators. The role claim has six values: SystemAdmin, TenantOwner, TenantAdmin, TemplateEditor, Operator, and Viewer. SuperAdmin is an alias of SystemAdmin.

Normal end users of a consumer product should not be sent into Mursil. If a host product needs the person to resend an invitation or change an email address, that flow stays in the host product.

Standalone first

Mursil has its own UI, API, database boundary, deployment unit, and release cycle. Host products do not embed the communication UI. They link operators to the portal and rely on OIDC single sign-on. Launch context, such as a tenant slug, is convenience. Authorization happens after sign-in.

Template first

The normal send path is a template key plus a structured model. Raw HTML is not the production contract. An empty template key on the integration package falls back to the seeded key mursil.email.raw-fallback, with model fields subject and body. That path exists so older callers still work. New integrations should name a published template.

Boundaries

In this repositoryOutside this repository
Server, Admin, Migrator, domain, application, infrastructureThe Kayan consumer
Local Docker stack and Aspire AppHostStaging and production host topology
Mailpit as the local SMTP sinkA required SendGrid account
Mursil.Integration and Mursil.Contracts packagesThe Zapier-style Integration companion
OIDC authorization against a configured authorityA Mursil user store

CleanArch Pro is consumed as versioned NuGet packages. This repository does not vendor the framework.