A provider is a module service that is selected for a standardized role.
It is not a separate system type:
kindremainsmodule.- module setup, migrations, routes, workflows, and storage are unchanged.
- the role binding is the contract point (
providersindamat.config.ts).
Common provider roles:
auth— principal lookup, session/token validation, API-key operations.payment— create/list/capture/refund and checkout-facing adapters.subscription— plan creation changes, state transitions, and webhook intake.
In this model, provider role callers use typed methods from getProvider(role), and
your app code decides when to invoke provider methods.
import { getProvider } from "@damatjs/framework";
const auth = getProvider("auth");
const user = await auth.getPrincipal(userId);
For implementation and integration details, continue to the implementation page: