gitlab-haskell-1.0.0.5: A Haskell library for the GitLab web API
Copyright(c) Rob Stewart Heriot-Watt University 2019
LicenseBSD3
Maintainerrobstewart57@gmail.com
Stabilitystable
Safe HaskellSafe-Inferred
LanguageHaskell2010

GitLab.API.Users

Description

 
Synopsis

List users

users :: GitLab [User] Source #

all registered users.

Single user

user Source #

Arguments

:: Int

ID of users

-> GitLab (Either (Response ByteString) (Maybe User)) 

Get a single user.

searchUser Source #

Arguments

:: Text

username to search for

-> GitLab (Maybe User) 

searches for a user given a username.

User creation

createUser Source #

Arguments

:: Text

email address

-> Text

user's name

-> Text

user's username

-> UserAttrs

optional attributes

-> GitLab (Either (Response ByteString) (Maybe User)) 

Creates a new user. Note only administrators can create new users. Either password, reset_password, or force_random_password must be specified. If reset_password and force_random_password are both false, then password is required. force_random_password and reset_password take priority over password. In addition, reset_password and force_random_password can be used together.

User modification

userAttributes Source #

Arguments

:: User

the user

-> Bool

is the user a GitLab server administrator

-> UserAttrs

the extracted user attributes

Extracts the user attributes for a user. Useful for modifying attrbibutes with modifyUser.

modifyUser Source #

Arguments

:: Int

user ID

-> UserAttrs

optional attributes

-> GitLab (Either (Response ByteString) (Maybe User)) 

Modifies an existing user. Only administrators can change attributes of a user.

Delete authentication identity from user

deleteAuthIdentity Source #

Arguments

:: User

user

-> Text

external providor name

-> GitLab (Either (Response ByteString) (Maybe ())) 

Deletes a user’s authentication identity using the provider name associated with that identity. Available only for administrators.

User deletion

deleteUser Source #

Arguments

:: User

user

-> GitLab (Either (Response ByteString) (Maybe ())) 

Deletes a user. Available only for administrators.

List current user

currentUser :: GitLab User Source #

Get current user.

User status

currentUserStatus :: GitLab UserStatus Source #

Get current user status.

Get the status of a user

userStatus Source #

Arguments

:: User

user

-> GitLab UserStatus 

Get the status of a user.

Get user preferences

userPreferences :: GitLab UserPrefs Source #

Get the status of the current user.

Follow and unfollow users

followUser Source #

Arguments

:: User

user

-> GitLab (Either (Response ByteString) (Maybe User)) 

Follow a user.

unfollowUser Source #

Arguments

:: User

user

-> GitLab (Either (Response ByteString) (Maybe User)) 

Unfollow a user.

User counts

currentUserCounts :: GitLab UserCount Source #

Get the counts of the currently signed in user.

List SSH keys

currentUserSshKeys :: GitLab Key Source #

Get a list of currently authenticated user’s SSH keys.

List SSH keys for user

userSshKeys Source #

Arguments

:: User

user

-> GitLab Key 

Get a list of a specified user’s SSH keys.

Add SSH key

addSshKeyCurrentUser Source #

Arguments

:: Text

key

-> Text

title

-> GitLab (Either (Response ByteString) (Maybe Key)) 

Creates a new key owned by the currently authenticated user.

Add SSH key for user

addSshKeyUser Source #

Arguments

:: User

User

-> Text

key

-> Text

title

-> GitLab (Either (Response ByteString) (Maybe Key)) 

Create new key owned by specified user. Available only for administrator.

Delete SSH key for current user

deleteSshKeyCurrentUser Source #

Arguments

:: Int

key ID

-> GitLab (Either (Response ByteString) (Maybe ())) 

Deletes key owned by currently authenticated user.

Delete SSH key for given user

deleteSshKeyUser Source #

Arguments

:: User

user

-> Int

key ID

-> GitLab (Either (Response ByteString) (Maybe ())) 

Deletes key owned by a specified user. Available only for administrator.

List emails

emails :: GitLab [Email] Source #

Get a list of currently authenticated user’s emails.

List emails for user

emailsCurrentUser Source #

Arguments

:: User

user

-> GitLab [Email] 

Get a list of currently authenticated user’s emails.

Block or unblock user

blockUser Source #

Arguments

:: User

user

-> GitLab (Maybe User) 

Blocks the specified user. Available only for administrator.

unblockUser Source #

Arguments

:: User

user

-> GitLab (Maybe User) 

Unblocks the specified user. Available only for administrator.

Activate or deactivate user

activateUser Source #

Arguments

:: User

user

-> GitLab (Maybe User) 

Activates the specified user. Available only for administrator.

deactivateUser Source #

Arguments

:: User

user

-> GitLab (Maybe User) 

Deactivates the specified user. Available only for administrator.

Ban or unban user

banUser Source #

Arguments

:: User

user

-> GitLab (Maybe User) 

Bans the specified user. Available only for administrator.

unbanUser Source #

Arguments

:: User

user

-> GitLab (Maybe User) 

Unbans the specified user. Available only for administrator.

Approve or reject user

approveUser Source #

Arguments

:: User

user

-> GitLab (Maybe User) 

Approves the specified user. Available only for administrator.

rejectUser Source #

Arguments

:: User

user

-> GitLab (Maybe User) 

Rejects specified user that is pending approval. Available only for administrator.

Users attributes

defaultUserFilters :: UserAttrs Source #

No group filters applied, thereby returning all groups.

data UserAttrs Source #

Attributes related to a group

Constructors

UserAttrs 

Fields