summaryrefslogtreecommitdiff
path: root/lib/bitbucket/client.rb
blob: c05fc35f36e4e98bbfe533c62e3e1946cd44a0d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
module Bitbucket
  class Client
    def initialize(options = {})
      @connection = options.fetch(:connection, Connection.new(options))
    end

    def user
      parsed_response = connection.get('/user')
      Representation::User.new(parsed_response)
    end

    private

    attr_reader :connection
  end
end