HawkEx.Billing.Plan (hawk_ex v0.1.0)

Copy Markdown View Source

Ecto schema for a billable plan.

A plan is the product tier an account subscribes to, such as free, pro, or enterprise. Plans define the feature set and limits available to subscribers through HawkEx.Billing.PlanFeature.

HawkEx does not store pricing, invoices, or payment provider identifiers on plans. Keep provider-specific pricing data in your billing integration and map it to HawkEx plan names when subscriptions are created or changed.

Summary

Functions

Builds a changeset for creating or updating a plan.

Functions

changeset(plan, attrs)

Builds a changeset for creating or updating a plan.

Plan names are slugs used by APIs such as HawkEx.Billing.subscribe/2. They must contain only lowercase letters, numbers, and underscores.