lib/kentaa/api/client.rb in kentaa-api-0.1.1 vs lib/kentaa/api/client.rb in kentaa-api-0.2.0
- old
+ new
@@ -1,43 +1,43 @@
# frozen_string_literal: true
module Kentaa
module Api
class Client
- def initialize(api_key, options = {})
- @request = Kentaa::Api::Request.new(api_key, options)
+ def initialize(config)
+ @config = config
end
def actions
- Kentaa::Api::Requests::Actions.new(@request)
+ Kentaa::Api::Clients::Actions.new(@config)
end
def donations
- Kentaa::Api::Requests::Donations.new(@request)
+ Kentaa::Api::Clients::Donations.new(@config)
end
def newsletter_subscriptions
- Kentaa::Api::Requests::NewsletterSubscriptions.new(@request)
+ Kentaa::Api::Clients::NewsletterSubscriptions.new(@config)
end
def projects
- Kentaa::Api::Requests::Projects.new(@request)
+ Kentaa::Api::Clients::Projects.new(@config)
end
def segments
- Kentaa::Api::Requests::Segments.new(@request)
+ Kentaa::Api::Clients::Segments.new(@config)
end
def sites
- Kentaa::Api::Requests::Sites.new(@request)
+ Kentaa::Api::Clients::Sites.new(@config)
end
def teams
- Kentaa::Api::Requests::Teams.new(@request)
+ Kentaa::Api::Clients::Teams.new(@config)
end
def users
- Kentaa::Api::Requests::Users.new(@request)
+ Kentaa::Api::Clients::Users.new(@config)
end
end
end
end