class BitBucket::User
Constants
- DEFAULT_USER_OPTIONS
Public Class Methods
BitBucket::API::new
# File lib/bitbucket_rest_api/user.rb, line 13 def initialize(options = {}) super(options) end
Public Instance Methods
GET the list of repositories on the dashboard Gets the repositories list from the account's dashboard.
# File lib/bitbucket_rest_api/user.rb, line 83 def dashboard get_request('/1.0/user/repositories/dashboard') end
GET a list of repositories an account follows Gets the details of the repositories that the individual or team account follows. This call returns the full data about the repositories including if the repository is a fork of another repository. An account always “follows” its own repositories.
# File lib/bitbucket_rest_api/user.rb, line 60 def follows get_request('/1.0/user/follows') end
GET a list of repositories the account is following Gets a list of the repositories the account follows. This is the same list that appears on the Following tab on your account dashboard.
# File lib/bitbucket_rest_api/user.rb, line 77 def overview get_request('/1.0/user/repositories/overview') end
GET a list of user privileges
# File lib/bitbucket_rest_api/user.rb, line 51 def privileges get_request('/1.0/user/privileges') end
Gets the basic information associated with an account and a list of all of the repositories owned by the user. See confluence.atlassian.com/display/BITBUCKET/user+Endpoint#userEndpoint-GETauserprofile
Examples¶ ↑
bitbucket = BitBucket.new bitbucket.user_api.profile
# File lib/bitbucket_rest_api/user.rb, line 25 def profile get_request('/1.0/user') end
GET a list of repositories visible to an account Gets the details of the repositories that the user owns or has at least read access to. Use this if you're looking for a full list of all of the repositories associated with a user.
# File lib/bitbucket_rest_api/user.rb, line 68 def repositories get_request('/1.0/user/repositories') end
Parameters¶ ↑
-
:first_name
Optional string -
:last_name
Optional string -
:avatar
Optional string -
:resource_uri
Optional string
Examples¶ ↑
bitbucket = BitBucket.new bitbucket.user_api.update :first_name => 'first-name', :last_name => 'last-name'
# File lib/bitbucket_rest_api/user.rb, line 43 def update(params = {}) normalize! params filter! DEFAULT_USER_OPTIONS, params put_request('/1.0/user', DEFAULT_USER_OPTIONS.merge(params)) end