lib/moip2.rb in moip2-0.1.4 vs lib/moip2.rb in moip2-1.0.0
- old
+ new
@@ -5,19 +5,23 @@
require "moip2/version"
require "moip2/auth/basic"
require "moip2/auth/oauth"
+require "moip2/resource/account"
require "moip2/resource/order"
require "moip2/resource/payment"
require "moip2/resource/multi_order"
require "moip2/resource/multi_payment"
require "moip2/resource/customer"
require "moip2/resource/invoice"
require "moip2/resource/keys"
require "moip2/resource/refund"
require "moip2/resource/webhooks"
+require "moip2/resource/connect"
+require "moip2/resource/credit_card"
+require "moip2/resource/notification"
require "moip2/response"
require "moip2/client"
require "moip2/order_api"
require "moip2/multi_order_api"
@@ -27,19 +31,22 @@
require "moip2/invoice_api"
require "moip2/refund_api"
require "moip2/api"
require "moip2/keys_api"
require "moip2/webhooks_api"
+require "moip2/accounts_api"
+require "moip2/connect_api"
+require "moip2/notifications_api"
require "moip2/exceptions/invalid_enviroment_error"
-module Moip2
+require "moip2/util/filters_encoder"
+module Moip2
class << self
+ VALID_ENVS = %i(sandbox production).freeze
- VALID_ENVS = %i(sandbox production)
-
def env=(env)
raise InvalidEnviromentError unless VALID_ENVS.include?(env.to_sym)
@env = env
end
@@ -66,12 +73,10 @@
def new
raise "Auth is not set" unless auth
Api.new Client.new(env, auth)
end
-
end
class NotFoundError < StandardError
end
-
end