Skip to Content
ReferenceDatabase Enums

Database Enums

PostgreSQL enum types used throughout the RustBill schema.

product_type

Product classification.

ValueDescription
licensedTraditional licensed software with license keys
saasSoftware-as-a-Service with recurring subscriptions
apiAPI product with usage-based billing

customer_tier

Customer classification tier.

ValueDescription
starterEntry-level tier
professionalMid-tier with expanded features
enterpriseFull-featured enterprise tier

subscription_status

Current state of a subscription.

ValueDescription
activeCurrently billing normally
pausedTemporarily suspended — no invoices generated
canceledPermanently ended
past_duePayment failed — in dunning recovery
trialingWithin free trial period

invoice_status

Invoice lifecycle state.

ValueDescription
draftCreated but not yet sent
issuedSent to customer, awaiting payment
paidPayment received
overduePast due date without payment
voidCanceled / invalidated

payment_method

Supported payment methods.

ValueDescription
manualManual / offline payment
stripeStripe payment processing
xenditXendit payment processing
lemonsqueezyLemonSqueezy payment processing
bank_transferDirect bank transfer
checkPaper check

billing_cycle

Subscription billing frequency.

ValueDescription
monthlyBilled every month
quarterlyBilled every 3 months
yearlyBilled every 12 months

pricing_model

How a plan’s price is calculated.

ValueDescription
flatFixed price per billing cycle
per_unitPrice multiplied by quantity
tieredPrice varies by usage tier
usage_basedPrice based on metered usage events

dunning_step

Payment recovery escalation stages.

ValueDescription
reminderFirst gentle payment reminder
warningEscalated warning about service impact
final_noticeLast chance notice before suspension
suspensionService suspended due to non-payment

user_role

Admin user roles.

ValueDescription
adminFull administrative access
customerCustomer-scoped access
Last updated on