# User

This contains APIs related to User as defined in Harness

## Add user to user groups

 - [PUT /ng/api/user/add-user-to-groups/{userId}](https://apidocs.harness.io/user/addusertousergroups.md): Adds the user to the specified user group IDs passed in the body and removes all other user groups for user except harness managed user groups

## Add user(s) to scope

 - [POST /ng/api/user/users](https://apidocs.harness.io/user/addusers.md)

## Change user password

 - [PUT /ng/api/user/password](https://apidocs.harness.io/user/changeuserpassword.md): Updates the User password

## Check if user is last admin

 - [GET /ng/api/user/last-admin](https://apidocs.harness.io/user/checkiflastadmin.md): Check whether the user is last admin at scope or not

## Disable two factor authentication

 - [PUT /ng/api/user/disable-two-factor-auth](https://apidocs.harness.io/user/disablettwofactorauth.md): Disables two-factor-auth for an user in an account

## end impersonation session for user

 - [POST /ng/api/user/endImpersonation/{userId}](https://apidocs.harness.io/user/endimpersonation.md)

## Get detailed user information

 - [GET /ng/api/user/aggregate/{userId}](https://apidocs.harness.io/user/getaggregateduser.md): Returns the user metadata along with rolesAssignments by userId and scope

## Get list of users

 - [POST /ng/api/user/aggregate](https://apidocs.harness.io/user/getaggregatedusers.md): List of all the user's metadata along with rolesAssignments who have access to given scope

## Gets Two Factor Auth Settings

 - [GET /ng/api/user/two-factor-auth/{authMechanism}](https://apidocs.harness.io/user/gettwofactorauthsettings.md): Gets two factor authentication settings information of the current logged in user

## Get Current User Info

 - [GET /ng/api/user/currentUser](https://apidocs.harness.io/user/getcurrentuserinfo.md): Gets current logged in User information

## Get users list

 - [POST /ng/api/user/batch](https://apidocs.harness.io/user/getusers.md): Get list of user's for a given scope

## impersonate User

 - [POST /ng/api/user/impersonate/{userId}](https://apidocs.harness.io/user/impersonateuser.md)

## Update User

 - [PUT /ng/api/user/{userId}](https://apidocs.harness.io/user/updateuserinfo_1.md): Updates the User information

## Remove user from scope

 - [DELETE /ng/api/user/{userId}](https://apidocs.harness.io/user/removeuser.md): Remove user as the collaborator from the scope

## Reset two factor authorization

 - [GET /ng/api/user/reset-two-factor-auth/{userId}](https://apidocs.harness.io/user/reset2fa.md): Reset Two-Factor authorization.

## Unlock user

 - [PUT /ng/api/user/unlock-user/{userId}](https://apidocs.harness.io/user/unlockuser.md): unlock user in a given scope

## Enable two factor authentication

 - [PUT /ng/api/user/enable-two-factor-auth](https://apidocs.harness.io/user/enabletwofactorauth.md): Enables two-factor-auth for an user in an account

## Update User

 - [PUT /ng/api/user](https://apidocs.harness.io/user/updateuserinfo.md): Updates the User information

