Module: FatZebra

Defined in:
lib/fat_zebra.rb,
lib/fat_zebra/card.rb,
lib/fat_zebra/util.rb,
lib/fat_zebra/batch.rb,
lib/fat_zebra/config.rb,
lib/fat_zebra/errors.rb,
lib/fat_zebra/refund.rb,
lib/fat_zebra/request.rb,
lib/fat_zebra/version.rb,
lib/fat_zebra/customer.rb,
lib/fat_zebra/purchase.rb,
lib/fat_zebra/web_hook.rb,
lib/fat_zebra/api_helper.rb,
lib/fat_zebra/validation.rb,
lib/fat_zebra/information.rb,
lib/fat_zebra/api_resource.rb,
lib/fat_zebra/bank_account.rb,
lib/fat_zebra/direct_debit.rb,
lib/fat_zebra/payment_plan.rb,
lib/fat_zebra/direct_credit.rb,
lib/fat_zebra/object_helper.rb,
lib/fat_zebra/fat_zebra_object.rb,
lib/fat_zebra/api_operation/find.rb,
lib/fat_zebra/api_operation/save.rb,
lib/fat_zebra/api_operation/void.rb,
lib/fat_zebra/api_operation/delete.rb,
lib/fat_zebra/api_operation/search.rb,
lib/fat_zebra/request/multipart/part.rb,
lib/fat_zebra/request/multipart/param.rb,
lib/fat_zebra/request/multipart/stream.rb,
lib/fat_zebra/request/multipart/file_io.rb,
lib/fat_zebra/request/multipart/epilogue.rb

Overview

Implementation of the FatZebra

Defined Under Namespace

Modules: APIHelper, ObjectHelper, Util, Validation Classes: APIOperation, APIResource, BankAccount, Batch, Card, Config, ConfigurationError, Customer, DirectCredit, DirectDebit, FatZebraObject, Information, PaymentPlan, Purchase, Refund, Request, RequestError, RequestValidationError, UnknownRequestMethod, WebHook

Constant Summary collapse

VERSION =
'3.1.0.2'.freeze

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.configurationsFatZebra::Config (readonly)

Returns configurations.

Returns:



47
48
49
# File 'lib/fat_zebra.rb', line 47

def configurations
  @configurations
end

Class Method Details

.configure {|@configurations = FatZebra::Config.new| ... } ⇒ Object

Configures the FatZebra API

Examples:

Default configuration

FatZebra.configure do |config|
  config.username = 'my-username'
  config.token    = 'my-token'
end

Yields:



57
58
59
60
61
# File 'lib/fat_zebra.rb', line 57

def configure
  yield @configurations = FatZebra::Config.new

  FatZebra.configurations.valid!
end