Sha256: ad4a463a02ecda7d70226baaeae4601a6c97deeca887007316e9732eff0f4d06

Contents?: true

Size: 394 Bytes

Versions: 3

Compression:

Stored size: 394 Bytes

Contents

class Ey::Core::Client
  class Real
    def get_api_token(username, password)
      request(
        :path   => "tokens",
        :method => :post,
        :body   => {email: username, password: password},
      )
    end
  end

  class Mock
    def get_api_token(username, password)
      response(
        :body => {"api_token" => self.api_token}
      )
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ey-core-3.6.6 lib/ey-core/requests/get_api_token.rb
ey-core-3.4.5 lib/ey-core/requests/get_api_token.rb
ey-core-3.6.5 lib/ey-core/requests/get_api_token.rb