-
Notifications
You must be signed in to change notification settings - Fork 1
UsersApi
All URIs are relative to https://demo.iriusrisk.com/api/v1
Method | HTTP request | Description |
---|---|---|
businessunitsBusinessUnitNameUsersDelete | DELETE /businessunits/{businessUnitName}/users | Unassign a list of users from a business unit |
businessunitsBusinessUnitNameUsersGet | GET /businessunits/{businessUnitName}/users | List users from a business unit |
businessunitsBusinessUnitNameUsersPut | PUT /businessunits/{businessUnitName}/users | Assigns users to a business unit |
businessunitsBusinessUnitNameUsersUserDelete | DELETE /businessunits/{businessUnitName}/users/{user} | Removes a user from a business unit |
groupsGroupUsersDelete | DELETE /groups/{group}/users | Unassign a list of users from a group |
groupsGroupUsersGet | GET /groups/{group}/users | List users from a group |
groupsGroupUsersPut | PUT /groups/{group}/users | Assigns users to a group |
groupsGroupUsersUserDelete | DELETE /groups/{group}/users/{user} | Removes a user from a group |
productsRefUsersDelete | DELETE /products/{ref}/users | Unassigns a list of users from a product. |
productsRefUsersGet | GET /products/{ref}/users | List all users assigned to a product |
productsRefUsersPut | PUT /products/{ref}/users | Assigns users to a product. |
productsRefUsersUserDelete | DELETE /products/{ref}/users/{user} | Unassigns a user from a product |
usersGet | GET /users | List of all Users. |
usersPost | POST /users | Creates a new user |
usersUsernameDelete | DELETE /users/{username} | Deletes a user |
usersUsernameGet | GET /users/{username} | Get all the information of a user |
usersUsernameTokenPost | POST /users/{username}/token | Generates a user API token |
businessunitsBusinessUnitNameUsersDelete(apiToken, businessUnitName, unassingUsersGroupRequestBody)
Unassign a list of users from a business unit
Unassign a list of users from a business unit. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. With this permission you will be able to unassign users from a business unit, if you belong to this business unit.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String businessUnitName = "businessUnitName_example"; // String | name of the business unit
UnassingUsersGroupRequestBody1 unassingUsersGroupRequestBody = new UnassingUsersGroupRequestBody1(); // UnassingUsersGroupRequestBody1 | JSON object that contains information to unassign users from business unit
try {
apiInstance.businessunitsBusinessUnitNameUsersDelete(apiToken, businessUnitName, unassingUsersGroupRequestBody);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#businessunitsBusinessUnitNameUsersDelete");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
businessUnitName | String | name of the business unit | |
unassingUsersGroupRequestBody | UnassingUsersGroupRequestBody1 | JSON object that contains information to unassign users from business unit |
null (empty response body)
No authorization required
- Content-Type: application/json
- Accept: application/json
List<User> businessunitsBusinessUnitNameUsersGet(apiToken, businessUnitName)
List users from a business unit
List users who belongs to a business unit. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. With this permission you will be able to list users of a business unit, if you belong to this business unit.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String businessUnitName = "businessUnitName_example"; // String | name of the business unit
try {
List<User> result = apiInstance.businessunitsBusinessUnitNameUsersGet(apiToken, businessUnitName);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#businessunitsBusinessUnitNameUsersGet");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
businessUnitName | String | name of the business unit |
No authorization required
- Content-Type: application/json
- Accept: application/json
InlineResponse201 businessunitsBusinessUnitNameUsersPut(apiToken, businessUnitName, assignUserGroupRequestBody)
Assigns users to a business unit
Assigns users to a business unit. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. With this permission you will be able to assign users to a business unit, if you belong to this business unit.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String businessUnitName = "businessUnitName_example"; // String | name of the business unit
AssignUserGroupRequestBody1 assignUserGroupRequestBody = new AssignUserGroupRequestBody1(); // AssignUserGroupRequestBody1 | JSON object that contains information to assign users to business unit
try {
InlineResponse201 result = apiInstance.businessunitsBusinessUnitNameUsersPut(apiToken, businessUnitName, assignUserGroupRequestBody);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#businessunitsBusinessUnitNameUsersPut");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
businessUnitName | String | name of the business unit | |
assignUserGroupRequestBody | AssignUserGroupRequestBody1 | JSON object that contains information to assign users to business unit |
No authorization required
- Content-Type: application/json
- Accept: application/json
businessunitsBusinessUnitNameUsersUserDelete(apiToken, businessUnitName, user)
Removes a user from a business unit
Unassign a user from a business unit. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. With this permission you will be able to unassign user from a business unit, if you belong to this business unit.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String businessUnitName = "businessUnitName_example"; // String | name of the business unit
String user = "user_example"; // String | user to be removed from business unit
try {
apiInstance.businessunitsBusinessUnitNameUsersUserDelete(apiToken, businessUnitName, user);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#businessunitsBusinessUnitNameUsersUserDelete");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
businessUnitName | String | name of the business unit | |
user | String | user to be removed from business unit |
null (empty response body)
No authorization required
- Content-Type: Not defined
- Accept: application/json
groupsGroupUsersDelete(apiToken, group, unassingUsersGroupRequestBody)
Unassign a list of users from a group
Unassign a list of users from a group. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. With this permission you will be able to unassign users from a group, if you belong to this group.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String group = "group_example"; // String | name of the group
UnassingUsersGroupRequestBody unassingUsersGroupRequestBody = new UnassingUsersGroupRequestBody(); // UnassingUsersGroupRequestBody | JSON object that contains information to unassign users from group
try {
apiInstance.groupsGroupUsersDelete(apiToken, group, unassingUsersGroupRequestBody);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#groupsGroupUsersDelete");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
group | String | name of the group | |
unassingUsersGroupRequestBody | UnassingUsersGroupRequestBody | JSON object that contains information to unassign users from group |
null (empty response body)
No authorization required
- Content-Type: application/json
- Accept: application/json
List<User> groupsGroupUsersGet(apiToken, group)
List users from a group
List users who belongs to a group. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. With this permission you will be able to list users of a group, if you belong to this group.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String group = "group_example"; // String | name of the group
try {
List<User> result = apiInstance.groupsGroupUsersGet(apiToken, group);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#groupsGroupUsersGet");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
group | String | name of the group |
No authorization required
- Content-Type: application/json
- Accept: application/json
InlineResponse201 groupsGroupUsersPut(apiToken, group, assignUserGroupRequestBody)
Assigns users to a group
Assigns users to a group. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. With this permission you will be able to assign users to a group, if you belong to this group.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String group = "group_example"; // String | name of the group
AssignUserGroupRequestBody assignUserGroupRequestBody = new AssignUserGroupRequestBody(); // AssignUserGroupRequestBody | JSON object that contains information to assign users to group
try {
InlineResponse201 result = apiInstance.groupsGroupUsersPut(apiToken, group, assignUserGroupRequestBody);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#groupsGroupUsersPut");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
group | String | name of the group | |
assignUserGroupRequestBody | AssignUserGroupRequestBody | JSON object that contains information to assign users to group |
No authorization required
- Content-Type: application/json
- Accept: application/json
groupsGroupUsersUserDelete(apiToken, group, user)
Removes a user from a group
Unassign a user from a group. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. With this permission you will be able to unassign user from a group, if you belong to this group.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String group = "group_example"; // String | name of the group
String user = "user_example"; // String | user to be removed from group
try {
apiInstance.groupsGroupUsersUserDelete(apiToken, group, user);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#groupsGroupUsersUserDelete");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
group | String | name of the group | |
user | String | user to be removed from group |
null (empty response body)
No authorization required
- Content-Type: Not defined
- Accept: application/json
productsRefUsersDelete(apiToken, ref, unassignUsersProductRequestBody)
Unassigns a list of users from a product.
Unassign a list of users from a product. Conditions to be able to perform the action: - To have the permission PRODUCT_UPDATE granted.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String ref = "ref_example"; // String | Reference for product
UnassignUsersProductRequestBody unassignUsersProductRequestBody = new UnassignUsersProductRequestBody(); // UnassignUsersProductRequestBody | JSON object that contains information to unassign users from product
try {
apiInstance.productsRefUsersDelete(apiToken, ref, unassignUsersProductRequestBody);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#productsRefUsersDelete");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
ref | String | Reference for product | |
unassignUsersProductRequestBody | UnassignUsersProductRequestBody | JSON object that contains information to unassign users from product |
null (empty response body)
No authorization required
- Content-Type: application/json
- Accept: application/json
List<String> productsRefUsersGet(apiToken, ref)
List all users assigned to a product
List all users assigned to a product. Conditions to be able to perform the action: - No permissions are required to perform this action.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String ref = "ref_example"; // String | Reference to product
try {
List<String> result = apiInstance.productsRefUsersGet(apiToken, ref);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#productsRefUsersGet");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
ref | String | Reference to product |
List<String>
No authorization required
- Content-Type: Not defined
- Accept: application/json
ProductShortUsers productsRefUsersPut(apiToken, ref, assignUsersProductRequestBody)
Assigns users to a product.
Assigns users to a product. Conditions to be able to perform the action: - To have the permission PRODUCT_UPDATE granted.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String ref = "ref_example"; // String | Reference for product
AssignUsersProductRequestBody assignUsersProductRequestBody = new AssignUsersProductRequestBody(); // AssignUsersProductRequestBody | JSON data that contains the information to assign users to product
try {
ProductShortUsers result = apiInstance.productsRefUsersPut(apiToken, ref, assignUsersProductRequestBody);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#productsRefUsersPut");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
ref | String | Reference for product | |
assignUsersProductRequestBody | AssignUsersProductRequestBody | JSON data that contains the information to assign users to product |
No authorization required
- Content-Type: application/json
- Accept: application/json
productsRefUsersUserDelete(apiToken, ref, user)
Unassigns a user from a product
Unassigns a user from a product. Conditions to be able to perform the action: - To have the permission PRODUCT_UPDATE granted.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String ref = "ref_example"; // String | Reference for product
String user = "user_example"; // String | Username of the user who will be unassigned from the product
try {
apiInstance.productsRefUsersUserDelete(apiToken, ref, user);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#productsRefUsersUserDelete");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
ref | String | Reference for product | |
user | String | Username of the user who will be unassigned from the product |
null (empty response body)
No authorization required
- Content-Type: application/json
- Accept: application/json
List<User> usersGet(apiToken)
List of all Users.
Returns a list of all the users of the system. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
try {
List<User> result = apiInstance.usersGet(apiToken);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#usersGet");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token |
No authorization required
- Content-Type: application/json
- Accept: application/json
usersPost(apiToken, createUserRequestBody)
Creates a new user
Creates a new user. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
CreateUserRequestBody createUserRequestBody = new CreateUserRequestBody(); // CreateUserRequestBody | JSON data that contains information to creates new user
try {
apiInstance.usersPost(apiToken, createUserRequestBody);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#usersPost");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
createUserRequestBody | CreateUserRequestBody | JSON data that contains information to creates new user |
null (empty response body)
No authorization required
- Content-Type: application/json
- Accept: application/json
usersUsernameDelete(apiToken, username)
Deletes a user
Deletes a user. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. Having this permission you can delete users who belongs to some of your user groups.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String username = "username_example"; // String | User's username
try {
apiInstance.usersUsernameDelete(apiToken, username);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#usersUsernameDelete");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
username | String | User's username |
null (empty response body)
No authorization required
- Content-Type: Not defined
- Accept: application/json
UserDetailed usersUsernameGet(apiToken, username)
Get all the information of a user
Get all the relevant information of a user
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String username = "username_example"; // String | User's username
try {
UserDetailed result = apiInstance.usersUsernameGet(apiToken, username);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#usersUsernameGet");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
username | String | User's username |
No authorization required
- Content-Type: application/json
- Accept: application/json
String usersUsernameTokenPost(apiToken, username)
Generates a user API token
Generates a new user API token. If the user already has a generated API token, generates a new one. Conditions to be able to perform the action: - To have the permission ALL_USERS_UPDATE granted, or - To have the permission MANAGE_USERS_BU granted. Having this permission you can generate a user API token to users who belongs to some of your user groups.
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.UsersApi;
UsersApi apiInstance = new UsersApi();
String apiToken = "apiToken_example"; // String | Authentication token
String username = "username_example"; // String | User's username
try {
String result = apiInstance.usersUsernameTokenPost(apiToken, username);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UsersApi#usersUsernameTokenPost");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
apiToken | String | Authentication token | |
username | String | User's username |
String
No authorization required
- Content-Type: Not defined
- Accept: application/json