[]
        
(Showing Draft Content)

User

User

[GET] /api/v1/users

Get all users' information.

Parameters

Name Type Located In Description Example
PageSize int32 query The page size. 20
PageNumber int32 query The page number. 1
SearchText string query The search text. "admin"
OrderBy string query The ordered field. "UserName"
OrderType OrderType query The order type, available values are "ASC" and "DESC". "ASC"
Paging Boolean query Whether pagination or not. true
SearchType SearchType query The search type, available values are "None" and "Count". "None"

Response

Status Code: 200

Success

[POST] /api/v1/users

Add a new user.

Request Schema

UserPostViewModel

Response

Status Code: 200

Success

[GET] /api/v1/localusers

Get all local users.

Parameters

Name Type Located In Description Example
PageSize int32 query The page size. 20
PageNumber int32 query The page number. 1
SearchText string query The search text. "admin"
OrderBy string query The ordered field. "UserName"
OrderType OrderType query The order type, available values are "ASC" and "DESC". "ASC"
Paging Boolean query Whether pagination or not. true
SearchType SearchType query The search type, available values are "None" and "Count". "None"

Response

Status Code: 200

Success

[GET] /api/v1/users/{id}

Get user by id.

Parameters

Name Type Located In Description
idRequired string path

Response

Status Code: 200

Success

[PUT] /api/v1/users/{id}

Update user information.

Parameters

Name Type Located In Description
idRequired string path
ignoreRoles Boolean query

Request Schema

UserPostViewModel

Response

Status Code: 200

Success

[DELETE] /api/v1/users/{id}

Remove a exist user.

Parameters

Name Type Located In Description
idRequired string path

Response

Status Code: 200

Success

[POST] /api/v1/users/batch-delete

Delete the specified users.

Request Schema

BatchDeleteUsersModel

Response

Status Code: 200

Success

[GET] /api/v1/users/{id}/roles

Get a user's roles

Parameters

Name Type Located In Description
idRequired string path

Response

Status Code: 200

Success

[PUT] /api/v1/users/{id}/enable

Enable/Disable user.

Parameters

Name Type Located In Description
idRequired string path

Request Schema

boolean

Response

Status Code: 200

Success

[PUT] /api/v1/users/{id}/password

Change user password.

Parameters

Name Type Located In Description
idRequired string path

Request Schema

password

Response

Status Code: 200

Success

[POST] /api/v1/users/{id}/password

Check user password.

Parameters

Name Type Located In Description
idRequired string path

Request Schema

password

Response

Status Code: 200

Success

[PUT] /api/v1/users/changepassword

Change user password.

Request Schema

ChangePasswordModel

Response

Status Code: 200

Success

[POST] /api/v1/users/import

Import users.

Response

Status Code: 200

Success

[GET] /api/v1/users/export

Export all users' information.

Response

Status Code: 200

Success

[GET] /api/v1/users/template

Export user information template.

Response

Status Code: 200

Success

[GET] /api/v1/users/template/{key}

Get the user template file to check the detailed error information.

Parameters

Name Type Located In Description
keyRequired string path The key of user template file.

Response

Status Code: 200

Success

[DELETE] /api/v1/users/template/{key}

Remove the useless user template file.

Parameters

Name Type Located In Description
keyRequired string path The key of user template file.

Response

Status Code: 200

Success

[GET] /api/v1/users/locked

Get locked users.

Response

Status Code: 200

Success

[POST] /api/v1/users/{id}/unlock

Unlock user by id.

Parameters

Name Type Located In Description
idRequired string path

Response

Status Code: 200

Success

[POST] /api/v1/users/reset-password

Reset the password of user 'Admin'.

Request Schema

ResetAdminPasswordBizModel

Response

Status Code: 200

Success

[GET] /api/v1/users/available-context

Get available user context.

Response

Status Code: 200

Success

[GET] /api/v1/users/me

Get current user's claims.

Response

Status Code: 200

Success

[PUT] /api/v1/users/avatar

Add or update the user avatar.

Response

Status Code: 200

Success

[GET] /api/v1/users/profile

Get current user profile info.

Response

Status Code: 200

Success

[PUT] /api/v1/users/profile

Update current user profile info.

Request Schema

UserProfileRequestModel

Response

Status Code: 200

Success

[GET] /api/v1/users/me/sharing-roles

Get the roles that the current logged in user can share documents to.

Response

Status Code: 200

Success

[GET] /api/v1/users/{id}/permissions

Get the permissions of the specified user.

Parameters

Name Type Located In Description
idRequired string path User id.

Response

Status Code: 200

Success

[GET] /api/v1/users/{name}/permissions-by-name

Get all the permissions of the specified user.

Parameters

Name Type Located In Description
nameRequired string path User name.

Response

Status Code: 200

Success

[GET] /api/v1/users/organizations

Get all the organizations the current user belongs to.

Response

Status Code: 200

Success

[POST] /api/v1/users/organizations

Request Schema

GetUserTenantModel

Response

Status Code: 200

Success

[GET] /api/v1/users/tenants

Get all the organizations the current user belongs to.

Response

Status Code: 200

Success

[POST] /api/v1/users/tenants

Request Schema

GetUserTenantModel

Response

Status Code: 200

Success

[POST] /api/v1/users/switch-organization

Switch the organization to which the currently logged-in user belongs.

Request Schema

SwitchTenantModel

Response

Status Code: 200

Success

[POST] /api/v1/users/switch-tenant

Switch the organization to which the currently logged-in user belongs.

Request Schema

SwitchTenantModel

Response

Status Code: 200

Success

[GET] /api/v1/users/non-org-users

Get all the users that do not belong to any organization.

Response

Status Code: 200

Success

[GET] /api/v1/users/non-tenant-users

Get all the users that do not belong to any organization.

Response

Status Code: 200

Success

[POST] /api/v1/users/default-org

Set the default tenant which the user can directly log in to.

Request Schema

SwitchTenantModel

Response

Status Code: 200

Success

[DELETE] /api/v1/users/default-org

Response

Status Code: 200

Success

[POST] /api/v1/users/default-tenant

Set the default tenant which the user can directly log in to.

Request Schema

SwitchTenantModel

Response

Status Code: 200

Success

[DELETE] /api/v1/users/default-tenant

Response

Status Code: 200

Success

Models

Ƭ OrderType

Enum:

  • ASC
  • DESC

The order type.

Ƭ SearchType

Enum:

  • None
  • Count

The search type for searching records.

Ƭ UserPostViewModel

Name Type Description Example
idNullable string
usernameNullable string
firstNameNullable string
lastNameNullable string
fullNameNullable string
emailNullable string
mobileNullable string
passwordNullable string
providerNullable string
enabled Boolean
tenantIdNullable string
managerIdNullable string
rolesNullable Array<string>
customizePropertyInfoNullable Array<string>

Ƭ BatchDeleteUsersModel

Name Type Description Example
userIdsNullable Array<string>

Ƭ ChangePasswordModel

Name Type Description Example
oldPasswordNullable string
newPasswordNullable string
newPasswordConfirmNullable string

Ƭ ResetAdminPasswordBizModel

Name Type Description Example
tokenNullable string
passwordNullable string

Ƭ UserProfileRequestModel

Name Type Description Example
firstNameNullable string
lastNameNullable string
fullNameNullable string
mobileNullable string
customizePropertyInfoNullable Array<string>

Ƭ GetUserTenantModel

Name Type Description Example
userNameNullable string
passwordNullable string

Ƭ SwitchTenantModel

Name Type Description Example
tenantIdNullable string