A Spark DSL extension for Ash resources representing billing customers (e.g., User or Organization).
Billing state is not implicitly accepted by wildcard create/update actions. Explicitly named inputs remain an application authorization decision. Internal webhook writes retain actions, policies, validations and tenant scope.
Usage
defmodule MyApp.Accounts.User do
use Ash.Resource,
domain: MyApp.Accounts,
extensions: [AshBilling.Resource]
billing do
customer_id_attribute :stripe_customer_id
provider AshBilling.Providers.Stripe
end
end