text: //@ sourceMappingURL=webhook_notification.map
  // Generated by CoffeeScript 1.6.1
  var AccountUpdaterDailyReport, AttributeSetter, Disbursement, Dispute, MerchantAccount, PartnerMerchant, Subscription, Transaction, ValidationErrorsCollection, WebhookNotification,
    __hasProp = {}.hasOwnProperty,
    __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
  
  AttributeSetter = require('./attribute_setter').AttributeSetter;
  
  MerchantAccount = require('./merchant_account').MerchantAccount;
  
  Transaction = require('./transaction').Transaction;
  
  Disbursement = require('./disbursement').Disbursement;
  
  Dispute = require('./dispute').Dispute;
  
  PartnerMerchant = require('./partner_merchant').PartnerMerchant;
  
  Subscription = require('./subscription').Subscription;
  
  AccountUpdaterDailyReport = require('./account_updater_daily_report').AccountUpdaterDailyReport;
  
  ValidationErrorsCollection = require('./validation_errors_collection').ValidationErrorsCollection;
  
  WebhookNotification = (function(_super) {
  
    __extends(WebhookNotification, _super);
  
    WebhookNotification.Kind = {
      AccountUpdaterDailyReport: "account_updater_daily_report",
      Check: "check",
      Disbursement: "disbursement",
      DisbursementException: "disbursement_exception",
      DisputeOpened: "dispute_opened",
      DisputeLost: "dispute_lost",
      DisputeWon: "dispute_won",
      PartnerMerchantConnected: "partner_merchant_connected",
      PartnerMerchantDisconnected: "partner_merchant_disconnected",
      PartnerMerchantDeclined: "partner_merchant_declined",
      SubscriptionCanceled: "subscription_canceled",
      SubscriptionChargedSuccessfully: "subscription_charged_successfully",
      SubscriptionChargedUnsuccessfully: "subscription_charged_unsuccessfully",
      SubscriptionExpired: "subscription_expired",
      SubscriptionTrialEnded: "subscription_trial_ended",
      SubscriptionWentActive: "subscription_went_active",
      SubscriptionWentPastDue: "subscription_went_past_due",
      SubMerchantAccountApproved: "sub_merchant_account_approved",
      SubMerchantAccountDeclined: "sub_merchant_account_declined",
      TransactionDisbursed: "transaction_disbursed"
    };
  
    function WebhookNotification(attributes) {
      var wrapper_node;
      WebhookNotification.__super__.constructor.call(this, attributes);
      if (attributes.subject.apiErrorResponse != null) {
        wrapper_node = attributes.subject.apiErrorResponse;
      } else {
        wrapper_node = attributes.subject;
      }
      if (wrapper_node.subscription != null) {
        this.subscription = new Subscription(wrapper_node.subscription);
      }
      if (wrapper_node.merchantAccount != null) {
        this.merchantAccount = new MerchantAccount(wrapper_node.merchantAccount);
      }
      if (wrapper_node.disbursement != null) {
        this.disbursement = new Disbursement(wrapper_node.disbursement);
      }
      if (wrapper_node.transaction != null) {
        this.transaction = new Transaction(wrapper_node.transaction);
      }
      if (wrapper_node.partnerMerchant != null) {
        this.partnerMerchant = new PartnerMerchant(wrapper_node.partnerMerchant);
      }
      if (wrapper_node.dispute != null) {
        this.dispute = new Dispute(wrapper_node.dispute);
      }
      if (wrapper_node.accountUpdaterDailyReport != null) {
        this.accountUpdaterDailyReport = new AccountUpdaterDailyReport(wrapper_node.accountUpdaterDailyReport);
      }
      if (wrapper_node.errors != null) {
        this.errors = new ValidationErrorsCollection(wrapper_node.errors);
        this.message = wrapper_node.message;
      }
    }
  
    return WebhookNotification;
  
  })(AttributeSetter);
  
  exports.WebhookNotification = WebhookNotification;
  