Package gitlab3 :: Class GitLab :: Class CurrentUser
[hide private]
[frames] | no frames]

Class CurrentUser

The currently authenticated user. See http://github.com/gitlabhq/gitlabhq/blob/master/doc/api/users.md#current-user

Nested Classes [hide private]
  SSHKey
An ssh key belonging to the currently authenticated user.
Instance Methods [hide private]
 
ssh_keys(limit=None, page=None, per_page=None)
Return a list of CurrentUser ssh_keys.
 
find_ssh_key(find_all=False, cached=None, **kwargs)
Find the first matching SSHKey whose properties match all of the key, value pairs given in the arguments.
 
ssh_key(id)
Return the SSHKey specified by the given id.
 
add_ssh_key(title, key)
Add a new ssh_key to this CurrentUser
 
delete_ssh_key(ssh_key)
Equivalent to ssh_key.delete()
Method Details [hide private]

ssh_keys(limit=None, page=None, per_page=None)

 

Return a list of CurrentUser ssh_keys.

limit can be given to specify the maximum list size.

page and per_page can be used for pagination.

limit should not be specified with either page or per_page. If it is, limit takes precedence.

find_ssh_key(find_all=False, cached=None, **kwargs)

 

Find the first matching SSHKey whose properties match all of the key, value pairs given in the arguments.

If find_all is true, a list of all matching ssh_keys will be returned. If a cached list is not given, the list to search will be queried from the server each time this is called.

Searching is done via an unoptimized, inefficient o(n) search.

All arguments must be named.

ssh_key(id)

 

Return the SSHKey specified by the given id. get_ssh_key() may be used as an alias for this function.

add_ssh_key(title, key)

 

Add a new ssh_key to this CurrentUser

On success, the newly created object is returned.