diff options
Diffstat (limited to 'lib/api/users.rb')
-rw-r--r-- | lib/api/users.rb | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/api/users.rb b/lib/api/users.rb index 7d88880d412..776329622e2 100644 --- a/lib/api/users.rb +++ b/lib/api/users.rb @@ -51,6 +51,10 @@ module API optional :avatar, type: File, desc: 'Avatar image for user' optional :private_profile, type: Boolean, desc: 'Flag indicating the user has a private profile' all_or_none_of :extern_uid, :provider + + if Gitlab.ee? + optional :shared_runners_minutes_limit, type: Integer, desc: 'Pipeline minutes quota for this user' + end end params :sort_params do @@ -80,6 +84,10 @@ module API use :sort_params use :pagination use :with_custom_attributes + + if Gitlab.ee? + optional :skip_ldap, type: Boolean, default: false, desc: 'Skip LDAP users' + end end # rubocop: disable CodeReuse/ActiveRecord get do @@ -124,7 +132,7 @@ module API user = User.find_by(id: params[:id]) not_found!('User') unless user && can?(current_user, :read_user, user) - opts = { with: current_user&.admin? ? Entities::UserWithAdmin : Entities::User, current_user: current_user } + opts = { with: current_user&.admin? ? Entities::UserDetailsWithAdmin : Entities::User, current_user: current_user } user, opts = with_custom_attributes(user, opts) present user, opts |