Class: ElasticWeb::Client
- Inherits:
-
Object
- Object
- ElasticWeb::Client
- Includes:
- Accounts, Aliases, Billing, Connection, DNS, Databases, Domains, NGINXConfigurations, Servers, User, HTTParty
- Defined in:
- lib/elasticweb/client.rb,
lib/elasticweb/client/dns.rb,
lib/elasticweb/client/user.rb,
lib/elasticweb/client/errors.rb,
lib/elasticweb/client/aliases.rb,
lib/elasticweb/client/billing.rb,
lib/elasticweb/client/domains.rb,
lib/elasticweb/client/servers.rb,
lib/elasticweb/client/accounts.rb,
lib/elasticweb/client/databases.rb,
lib/elasticweb/client/connection.rb,
lib/elasticweb/client/accounts/cron.rb,
lib/elasticweb/client/databases/users.rb,
lib/elasticweb/client/nginx_configurations.rb
Defined Under Namespace
Modules: Accounts, Aliases, Billing, Connection, DNS, Databases, Domains, NGINXConfigurations, Servers, User Classes: Errors
Instance Method Summary collapse
-
#initialize(access_token = nil) ⇒ Client
constructor
A new instance of Client.
Methods included from Billing
Methods included from Databases
#create_database, #databases, #delete_database
Methods included from Databases::Users
#create_database_user, #database_user_info, #databases_users, #delete_database_user, #update_database_user
Methods included from DNS
#create_dns, #delete_dns, #dns, #domain_dns
Methods included from NGINXConfigurations
Methods included from Domains
#create_domain, #delete_domain, #domains, #update_domain
Methods included from Aliases
#aliases, #create_alias, #delete_alias, #update_alias
Methods included from Servers
Methods included from Accounts
#accounts, #create_account, #delete_account, #update_account
Methods included from Accounts::Cron
Methods included from User
Methods included from Connection
Constructor Details
#initialize(access_token = nil) ⇒ Client
Returns a new instance of Client.
30 31 32 33 |
# File 'lib/elasticweb/client.rb', line 30 def initialize(access_token = nil) access_token ||= ENV['ELASTICWEB_ACCESS_TOKEN'] self.class..merge!(headers: { 'X-API-KEY' => access_token }) end |