Class: ChargeBee::Event
Defined Under Namespace
Instance Attribute Summary collapse
- 
  
    
      #api_version  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute api_version.
 - 
  
    
      #event_type  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute event_type.
 - 
  
    
      #id  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute id.
 - 
  
    
      #occurred_at  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute occurred_at.
 - 
  
    
      #origin_user  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute origin_user.
 - 
  
    
      #source  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute source.
 - 
  
    
      #user  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute user.
 - 
  
    
      #webhook_failure_reason  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute webhook_failure_reason.
 - 
  
    
      #webhook_status  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute webhook_status.
 - 
  
    
      #webhooks  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute webhooks.
 
Class Method Summary collapse
- .deserialize(json) ⇒ Object
 - 
  
    
      .list(params = {}, env = nil, headers = {})  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    
OPERATIONS ———–.
 - .retrieve(id, env = nil, headers = {}) ⇒ Object
 
Instance Method Summary collapse
Methods inherited from Model
construct, #init_dependant, #init_dependant_list, #initialize, #inspect, #load, #method_missing, #replace_white_space_with_underscore, #to_s, uri_path
Constructor Details
This class inherits a constructor from ChargeBee::Model
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class ChargeBee::Model
Instance Attribute Details
#api_version ⇒ Object
Returns the value of attribute api_version.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def api_version @api_version end  | 
  
#event_type ⇒ Object
Returns the value of attribute event_type.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def event_type @event_type end  | 
  
#id ⇒ Object
Returns the value of attribute id.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def id @id end  | 
  
#occurred_at ⇒ Object
Returns the value of attribute occurred_at.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def occurred_at @occurred_at end  | 
  
#origin_user ⇒ Object
Returns the value of attribute origin_user.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def origin_user @origin_user end  | 
  
#source ⇒ Object
Returns the value of attribute source.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def source @source end  | 
  
#user ⇒ Object
Returns the value of attribute user.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def user @user end  | 
  
#webhook_failure_reason ⇒ Object
Returns the value of attribute webhook_failure_reason.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def webhook_failure_reason @webhook_failure_reason end  | 
  
#webhook_status ⇒ Object
Returns the value of attribute webhook_status.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def webhook_status @webhook_status end  | 
  
#webhooks ⇒ Object
Returns the value of attribute webhooks.
      8 9 10  | 
    
      # File 'lib/chargebee/models/event.rb', line 8 def webhooks @webhooks end  | 
  
Class Method Details
.deserialize(json) ⇒ Object
      18 19 20 21 22 23 24 25 26 27 28 29 30 31 32  | 
    
      # File 'lib/chargebee/models/event.rb', line 18 def self.deserialize(json) begin webhook_data = JSON.parse(json) rescue JSON::ParserError => e raise Error.new("Invalid webhook object to deserialize. #{e}",e) end api_version = webhook_data["api_version"] if api_version != nil && api_version.casecmp(Environment::API_VERSION) != 0 raise Error.new("API version [#{api_version.upcase}] in response does not match with client library API version [#{Environment::API_VERSION.upcase}]") end webhook_data = Util.symbolize_keys(webhook_data) Event.construct(webhook_data) end  | 
  
.list(params = {}, env = nil, headers = {}) ⇒ Object
OPERATIONS
      37 38 39  | 
    
      # File 'lib/chargebee/models/event.rb', line 37 def self.list(params={}, env=nil, headers={}) Request.send_list_request('get', uri_path("events"), params, env, headers) end  |