Class: InvoiceCount::Connection

Inherits:
SimpleDelegator
  • Object
show all
Includes:
Singleton
Defined in:
lib/invoice_count/connection.rb

Instance Method Summary collapse

Constructor Details

#initializeConnection

Returns a new instance of Connection.



8
9
10
11
12
13
14
15
16
# File 'lib/invoice_count/connection.rb', line 8

def initialize
  connection = Faraday.new(url: 'http://34.209.24.195/')

  connection.headers['Content-Type'] = 'application/json'
  connection.headers['Accept']       = 'application/json'
  connection.headers['User-Agent']   = "InvoiceCount/#{InvoiceCount::VERSION}"

  super(connection)
end