Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
namara / lib / authenticators / cookie_authenticator.rb
Size: Mime:
require_relative '../authenticator.rb'

  class CookieAuthenticator < Authenticator
    def initialize(account_url, cookies)
      @cookies = cookies
      super account_url
    end

    def headers
      { Cookie: @cookies.to_header,
        "X-NAMARA-CLIENT": 'ruby',
        "X-NAMARA-CLIENT-VERSION": Namara::VERSION }
    end

    def token
      fetch_token
    end
  end