class Tinybucket::Model::Profile

Profile

@see developer.atlassian.com/bitbucket/api/2/reference/resource/users/%7Busername%7D

users Endpoint

@!attribute [rw] username

@return [String]

@!attribute [rw] kind

@return [NillClass]

@!attribute [rw] website

@return [String]

@!attribute [rw] display_name

@return [String]

@!attribute [rw] links

@return [Hash]

@!attribute [rw] created_on

@return [String]

@!attribute [rw] location

@return [String]

@!attribute [rw] type

@return [String]

@!attribute [rw] uuid

@return [String]

Public Instance Methods

followers(options = {}) click to toggle source

Get this user's followers

@param options [Hash] @return [Tinybucket::Resource::User::Followers]

# File lib/tinybucket/model/profile.rb, line 37
def followers(options = {})
  Tinybucket::Resource::User::Followers.new(username, options)
end
following(options = {}) click to toggle source

Get users which this user is following

@param options [Hash] @return [Tinybucket::Resource::User::Following]

# File lib/tinybucket/model/profile.rb, line 45
def following(options = {})
  Tinybucket::Resource::User::Following.new(username, options)
end
repos(options = {}) click to toggle source

Get this user's repositories

@param options [Hash] @return [Tinybucket::Resource::User::Repos]

# File lib/tinybucket/model/profile.rb, line 53
def repos(options = {})
  Tinybucket::Resource::User::Repos.new(username, options)
end

Private Instance Methods

load_model() click to toggle source
# File lib/tinybucket/model/profile.rb, line 65
def load_model
  user_api.profile
end
user_api() click to toggle source
# File lib/tinybucket/model/profile.rb, line 59
def user_api
  create_api('User').tap do |api|
    api.username = username
  end
end