Class: MisarMail::PlanResource

Inherits:
Resource
  • Object
show all
Defined in:
lib/misar_mail/client.rb

Overview

Live subscription standing for the key's owner.

Read this before an expensive call rather than discovering the ceiling through a PlanLimitError: usage reports every metered feature and upgrade is non-nil as soon as one of them is spent.

Instance Method Summary collapse

Methods inherited from Resource

#initialize

Constructor Details

This class inherits a constructor from MisarMail::Resource

Instance Method Details

#getObject

GET /plan — plan, sending allowances, per-feature usage, upgrade offer.



375
376
377
# File 'lib/misar_mail/client.rb', line 375

def get
  @client.request(:get, "/plan")
end

#monetizationObject

GET /monetization/stats — revenue and monetization counters.



380
381
382
# File 'lib/misar_mail/client.rb', line 380

def monetization
  @client.request(:get, "/monetization/stats")
end