class BillingMailer < ActionMailer::Base
  default from: "no-reply@3scale.net"

  def billing_finished(results)
    @results = results
    verb = @results.successful? ? 'succeeded' : 'failed'

    mail(to: 'system-dev@3scale.net',
         subject: "Billing and charging #{verb} (#{@results.period})")
  end
end
