AddUsers
- HTTP Verb : POST
- URL : Origin/UserService/Manager/User/AddUsers
- Request Body :
{ "UserInfos": [ { "UserName": "Bob", "FullName"?: "Bob Smith", "Password": "password123456", "Email": "Bob@email.com", "ExtendedProperties"?: { "Mentor": "Tom", "Address": "Beijing" } }, { "UserName": "Andy", "FullName"?: "Andy Brown", "Password": "password123456", "Email": "Andy@email.com", "ExtendedProperties"?: { "Mentor": "Tom", "Address": "Shanghai" } } ] }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Optional Default Value UserInfos List User information collection UserName string User name FullName string User full name true null Password string Password string ExtendedProperties object Custom extended property true null
AddWindowsUsers
- HTTP Verb : POST
- URL : Origin/UserService/Manager/User/AddWindowsUsers
- Request Body :
{ "UserInfos": [ { "UserName": "Alex", "ExtendedProperties"?: { "Mentor": "Vivian", "Address": "Chongqing" } }, { "UserName": "Ellen", "ExtendedProperties"?: { "Mentor": "Vivian", "Address": "Tianjin" } } ] }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Optional Default Value UserInfos List Windows domain user information collection UserName string User name ExtendedProperties object Custom extended property true null
DeleteUsers
- HTTP Verb : POST
- URL : Origin/UserService/Manager/User/DeleteUsers
- Request Body :
{ "Users": ["Bob", "Andy"] }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Users List User name collection
DeleteWindowsUsers
- HTTP Verb : POST
- URL : Origin/UserService/Manager/User/DeleteWindowsUsers
- Request Body :
{ "Users": ["Alex", "Ellen"] }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Users List Windows domain user name collection
UpdateUserInfo
- HTTP Verb : POST
- URL : Origin/UserService/Manager/User/UpdateUserInfo
- Request Body :
{ "UserName": "Bob", "FullName"?: "Bob Smith", "Email"?: "Bob2@email.com", "IsEnabled"?: false, "ExtendedProperties"?: { "Mentor": "Tom", "Address": "Shanghai" } }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Optional Default Value UserName string User name FullName string User full name true Original value string true Original value IsEnabled string Whether to enable user true Original value ExtendedProperties object Custom extended property true Original value
UpdateWindowsUserInfo
- HTTP Verb : POST
- URL : Origin/UserService/Manager/User/UpdateWindowsUserInfo
- Request Body :
{ "UserName": "Alex", "Email"?: "Alex2@email.com", "ExtendedProperties"?: { "Mentor": "Vivian", "Address": "Beijing" } }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Optional Default Value UserName string User name string true Original value ExtendedProperties object Custom extended property true Original value
- Note: If the value of Email is null or empty, the Email will set as the email of user in windows domain.
ResetUserPassword
- HTTP Verb : POST
- URL : Origin/UserService/Manager/User/ResetUserPassword
- Request Body :
{ "UserName": "Bob", "NewPassword": "123456password" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment UserName string User name NewPassword string New password
GetUserInfo
- HTTP Verb : GET
- URL : Origin/UserService/Manager/User/GetUserInfo?userName=Bob
- Return :
{ "Result": true, "Message": null, "UserInfo":{ "UserName": "Bob", "FullName": "Bob Smith", "Email": "Bob@email.com", "ExtendedProperties": { "Mentor": "Tom", "Address": "Beijing" }, "IsEnabled": true, "Roles": ["Intern", "Developer"], "OrganizationPaths": ["GrapeCity/Development1", "GrapeCity/Intern"] } }
Param Type Comment userName string User name
GetWindowsUserInfo
- HTTP Verb : GET
- URL : Origin/UserService/Manager/User/GetWindowsUserInfo?userName=Alex
- Return :
{ "Result": true, "Message": null, "UserInfo": { "UserName": "Alex", "FullName": "Alex", "Email": "Alex@email.com", "ExtendedProperties": { "Mentor": "Vivian", "Address": "Chongqing", }, "IsEnabled": true, "Roles": ["Intern", "Developer"], "OrganizationPaths": ["GrapeCity/Development1", "GrapeCity/Intern"] } }
Param Type Comment userName string User name
GetUserInfos
- HTTP Verb : GET
- URL : Origin/UserService/Manager/User/GetUserInfos?roleName=Developer
- Return :
{ "Result": true, "Message": null, "Users": [ { "Name": "Bob", "FullName": "Bob Smith", "Email": "Bob@email.com", "ExtendedProperties": { "Mentor": "Tom", "Address": "Beijing" }, "IsEnabled": true, "Roles": ["Intern", "Developer"], "Organizations": ["GrapeCity/Development1", "GrapeCity/Intern"] }, { "Name": "Andy", "FullName": "Andy Brown", "Email": "Andy@email.com", "ExtendedProperties": { "Mentor": "Tom", "Address": "Shanghai" }, "IsEnabled": true, "Roles": ["Developer"], "Organizations": ["GrapeCity/Development2", "GrapeCity/Club/Basketball"] } ] }
Param Type Comment Optional Default Value roleName string Role name true null
GetWindowsUserInfos
- HTTP Verb : GET
- URL : Origin/UserService/Manager/User/GetWindowsUserInfos?roleName=Developer
- Return :
{ "Result": true, "Message": null, "Users": [ { "Name": "Alex", "FullName": "Alex", "Email": "Alex@email.com", "ExtendedProperties": { "Mentor": "Vivian", "Address": "Chongqing" }, "IsEnabled": true, "Roles": ["Intern", "Developer"], "Organizations": ["GrapeCity/Development1", "GrapeCity/Intern"] }, { "Name": "Ellen", "FullName": "Ellen Johnson", "Email": "Ellen@email.com", "ExtendedProperties": { "Mentor": "Vivian", "Address": "Tianjin" }, "IsEnabled": true, "Roles": ["Developer"], "Organizations": ["GrapeCity/Development2", "GrapeCity/Club/Basketball"] } ] }
Param Type Comment Optional Default Value roleName string Role name true null
AddRole
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Role/AddRole
- Request Body :
{ "RoleName": "Intern" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment RoleName string Role name
DeleteRole
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Role/DeleteRole
- Request Body :
{ "RoleName": "Intern" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment RoleName string Role name
UpdateRoleName
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Role/UpdateRoleName
- Request Body :
{ "OldRoleName": "Intern", "NewRoleName": "Newbie" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment OldRoleName string Old role name NewRoleName string New role name
GetRoles
- HTTP Verb : GET
- URL : Origin/UserService/Manager/Role/GetRoles
- Return :
{ "Result": true, "Message": null, "Roles": ["Intern", "Developer", "Tester", "PM"] }
AddUsersToRole
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Role/AddUsersToRole
- Request Body :
{ "Users": ["Bob", "Andy"], "RoleName": "Developer" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Users List User name collection RoleName string Role name
AddWindowsUsersToRole
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Role/AddWindowsUsersToRole
- Request Body :
{ "Users":["Alex", "Ellen"], "RoleName": "Developer" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Users List Windows domain user name collection RoleName string Role name
RemoveUsersFromRole
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Role/RemoveUsersFromRole
- Request Body :
{ "Users": ["Bob", "Andy"], "RoleName": "Intern" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Users List user name collection RoleName string Role name
RemoveWindowsUsersFromRole
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Role/RemoveWindowsUsersFromRole
- Request Body :
{ "Users": ["Alex", "Ellen"], "RoleName": "Intern" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Users List Windows domain user name collection RoleName string Role name
AddOrganizationLevel
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/AddOrganizationLevel
- Request Body :
{ "OrganizationLevelName": "Company" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment OrganizationLevelName string Organization level name
DeleteOrganizationLevel
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/DeleteOrganizationLevel
- Request Body :
{ "OrganizationLevelName": "SubDepartment" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment OrganizationLevelName string Organization level name
UpdateOrganizationLevel
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/UpdateOrganizationLevel
- Request Body :
{ "OldOrganizationLevelName": "Company", "NewOrganizationLevelName": "Corporation" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment OldOrganizationLevelName string Old organization level name NewOrganizationLevelName string New organization level name
GetOrganizationLevels
- HTTP Verb : GET
- URL : Origin/UserService/Manager/Organization/GetOrganizationLevels
- Return :
{ "Result": true, "Message": null, "OrganizationLevels": ["Company", "Department", "SubDepartment"] }
AddOrganization
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/AddOrganization
- Request Body :
{ "OrganizationName": "Group1", "ParentOrganizationPath": "GrapeCity/Development1", "OrganizationLevel"?: "SubDepartment" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Optional Default Value OrganizationName string Organization level ParentOrganizationPath string Parent organization path OrganizationLevel string Organization level true null
- Note: When ParentOrganizationPath is null or empty, it represents the root node.
DeleteOrganization
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/DeleteOrganization
- Request Body :
{ "OrganizationPath": "GrapeCity/Development1/Group1" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment OrganizationPath string Organization path
UpdateOrganizationInfo
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/UpdateOrganizationInfo
- Request Body :
{ "OldOrganizationName": "Group1", "ParentOrganizationPath": "GrapeCity/Development1", "NewOrganizationName"?: "Group2", "NewOrganizationLevel"?: "Department" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Optional Default Value OldOrganizationName string Old organization name ParentOrganizationPath string Parent organization path NewOrganizationName string New organization name true Original value NewOrganizationLevel string New organization level true Original value
- Note: When ParentOrganizationPath is null or empty, it represents the root node.
GetOrganizationInfos
- HTTP Verb : GET
- URL : Origin/UserService/Manager/Organization/GetOrganizationInfos?organizationPath=GrapeCity/Development1&isRecursive=true
- Return :
{ "Result": true, "Message": null, "OrganizationInfos": [ { "ParentOrganizationPath": "", "OrganizationPath": "GrapeCity", "OrganizationName": "GrapeCity", "OrganizationLevelName": "Company", "SubOrganizations": [ { "ParentOrganizationPath": "GrapeCity", "OrganizationPath": "GrapeCity/Development1", "OrganizationName": "Development1", "OrganizationLevelName": "Department", "SubOrganizations": [...], "Members": [...] } ], "Members": [ { "UserName": "David", "IsWindowsUser": false, "IsLeader": false, "OrganizationRole": "Intern" }, { "UserName": "Alex", "IsWindowsUser": true, "IsLeader": true, "OrganizationRole": "Developer" } ] }, { "ParentOrganizationPath": "", "OrganizationPath": "GrapeSeed", "OrganizationName": "GrapeSeed", "OrganizationLevelName": "Company", "SubOrganizations": [ { "ParentOrganizationPath": "GrapeSeed", "OrganizationPath": "GrapeSeed/Development1", "OrganizationName": "Development1", "OrganizationLevelName": "Department", "SubOrganizations": [...], "Members": [...] } ], "Members": [ { "UserName": "David", "IsWindowsUser": false, "IsLeader": false, "OrganizationRole": "Intern" }, { "UserName": "Alex", "IsWindowsUser": true, "IsLeader": false, "OrganizationRole": "Teacher" } ] } ] }
Param Type Comment Optional Default Value organizationPath string Organization Path true null isRecursive bool Is recursive suborganization info true true
- Note: When organizationPath is null or empty, it represents the whole organizational tree.
AddUsersToOrganization
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/AddUsersToOrganization
- Request Body :
{ "Users": [ { "UserName": "Bob", "IsLeader"?: false, "OrganizationRole"?: "Intern" }, { "UserName": "Andy", "IsLeader"?: false, "OrganizationRole"?: "Developer" } ], "OrganizationPath": "GrapeCity/Development1/Group1" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Optional Default Value Users List User information collection UserName string User name IsLeader bool Is leader of organization true false OrganizationRole string User role in organization true null OrganizationPath string Organization path
AddWindowsUsersToOrganization
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/AddWindowsUsersToOrganization
- Request Body :
{ "Users": [ { "UserName": "Alex", "IsLeader"?: false, "OrganizationRole"?: "Intern" }, { "UserName": "Ellen", "IsLeader"?: false, "OrganizationRole"?: "Developer" } ], "OrganizationPath": "GrapeCity/Development1/Group1" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Optional Default Value Users List Windows domain user information collection UserName string User name IsLeader bool Is leader of organization true false OrganizationRole string User role in organization true null OrganizationPath string Organization path
RemoveUsersFromOrganization
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/RemoveUsersFromOrganization
- Request Body :
{ "Users": ["Bob", "Andy"], "OrganizationPath": "GrapeCity/Development1/Group1" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Users List User name collection OrganizationPath string Organization path
RemoveWindowsUsersFromOrganization
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/RemoveWindowsUsersFromOrganization
- Request Body :
{ "Users": ["Alex", "Ellen"], "OrganizationPath": "GrapeCity/Development1/Group1" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment Users List Windows domain user name collection OrganizationPath string Organization path
MoveEntireOrganization
- HTTP Verb : POST
- URL : Origin/UserService/Manager/Organization/MoveEntireOrganization
- Request Body :
{ "OrganizationPath": "GrapeCity/Development1/Group1", "NewParentOrganizationPath": "GrapeCity/Development2" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment OrganizationPath string Organization path NewParentOrganizationPath string New parent organization path
- Note: When NewParentOrganizationPath is null or empty, it represents the root node.
AddExtendedProperty
- HTTP Verb : POST
- URL : Origin/UserService/Manager/ExtendedProperty/AddExtendedProperty
- Request Body :
{ "PropertyName": "Address", "PropertyType": "Text" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment PropertyName string Property name PropertyType string Property type
- Note: PropertyType can only be "Text" or "User".
DeleteExtendedProperty
- HTTP Verb : POST
- URL : Origin/UserService/Manager/ExtendedProperty/DeleteExtendedProperty
- Request Body :
{ "PropertyName": "Address" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment PropertyName string Property name
UpdateExtendedPropertyName
- HTTP Verb : POST
- URL : Origin/UserService/Manager/ExtendedProperty/UpdateExtendedPropertyName
- Request Body :
{ "OldPropertyName": "Address", "NewPropertyName": "Hometown" }- Return :
{ "Result": false, "Message": "Error message." }
Param Type Comment OldPropertyName string Old poperty name NewPropertyName string New property name
GetExtendedProperties
- HTTP Verb : GET
- URL : Origin/UserService/Manager/ExtendedProperty/GetExtendedProperties
- Return :
{ "Result": true, "Message": null, "ExtendedProperties": [ { "PropertyName": "Mentor", "PropertyType": "User" }, { "PropertyName": "Address", "PropertyType": "Text" } ] }