Package com.adyen.service.management
Class UsersCompanyLevelApi
- java.lang.Object
-
- com.adyen.Service
-
- com.adyen.service.management.UsersCompanyLevelApi
-
public class UsersCompanyLevelApi extends Service
-
-
Field Summary
Fields Modifier and Type Field Description static StringAPI_VERSIONprotected StringbaseURL
-
Constructor Summary
Constructors Constructor Description UsersCompanyLevelApi(Client client)Users - company level constructor inpackage.UsersCompanyLevelApi(Client client, String baseURL)Users - company level constructor inpackage.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CreateCompanyUserResponsecreateNewUser(String companyId, CreateCompanyUserRequest createCompanyUserRequest)Create a new userCreateCompanyUserResponsecreateNewUser(String companyId, CreateCompanyUserRequest createCompanyUserRequest, RequestOptions requestOptions)Create a new userCompanyUsergetUserDetails(String companyId, String userId)Get user detailsCompanyUsergetUserDetails(String companyId, String userId, RequestOptions requestOptions)Get user detailsListCompanyUsersResponselistUsers(String companyId)Get a list of usersListCompanyUsersResponselistUsers(String companyId, Integer pageNumber, Integer pageSize, String username, RequestOptions requestOptions)Get a list of usersCompanyUserupdateUserDetails(String companyId, String userId, UpdateCompanyUserRequest updateCompanyUserRequest)Update user detailsCompanyUserupdateUserDetails(String companyId, String userId, UpdateCompanyUserRequest updateCompanyUserRequest, RequestOptions requestOptions)Update user details-
Methods inherited from class com.adyen.Service
createBaseURL, getClient, isApiKeyRequired, setApiKeyRequired, setClient
-
-
-
-
Field Detail
-
API_VERSION
public static final String API_VERSION
- See Also:
- Constant Field Values
-
baseURL
protected String baseURL
-
-
Constructor Detail
-
UsersCompanyLevelApi
public UsersCompanyLevelApi(Client client)
Users - company level constructor inpackage.- Parameters:
client-Client(required)
-
UsersCompanyLevelApi
public UsersCompanyLevelApi(Client client, String baseURL)
Users - company level constructor inpackage. Please use this constructor only if you would like to pass along your own url for routing or testing purposes. The latest API version is defined in this class as a constant.
-
-
Method Detail
-
createNewUser
public CreateCompanyUserResponse createNewUser(String companyId, CreateCompanyUserRequest createCompanyUserRequest) throws ApiException, IOException
Create a new user- Parameters:
companyId-StringThe unique identifier of the company account. (required)createCompanyUserRequest-CreateCompanyUserRequest(required)- Returns:
CreateCompanyUserResponse- Throws:
ApiException- if fails to make API callIOException
-
createNewUser
public CreateCompanyUserResponse createNewUser(String companyId, CreateCompanyUserRequest createCompanyUserRequest, RequestOptions requestOptions) throws ApiException, IOException
Create a new user- Parameters:
companyId-StringThe unique identifier of the company account. (required)createCompanyUserRequest-CreateCompanyUserRequest(required)requestOptions-RequestOptionsObject to store additional data such as idempotency-keys (optional)- Returns:
CreateCompanyUserResponse- Throws:
ApiException- if fails to make API callIOException
-
getUserDetails
public CompanyUser getUserDetails(String companyId, String userId) throws ApiException, IOException
Get user details- Parameters:
companyId-StringThe unique identifier of the company account. (required)userId-StringThe unique identifier of the user. (required)- Returns:
CompanyUser- Throws:
ApiException- if fails to make API callIOException
-
getUserDetails
public CompanyUser getUserDetails(String companyId, String userId, RequestOptions requestOptions) throws ApiException, IOException
Get user details- Parameters:
companyId-StringThe unique identifier of the company account. (required)userId-StringThe unique identifier of the user. (required)requestOptions-RequestOptionsObject to store additional data such as idempotency-keys (optional)- Returns:
CompanyUser- Throws:
ApiException- if fails to make API callIOException
-
listUsers
public ListCompanyUsersResponse listUsers(String companyId) throws ApiException, IOException
Get a list of users- Parameters:
companyId-StringThe unique identifier of the company account. (required)- Returns:
ListCompanyUsersResponse- Throws:
ApiException- if fails to make API callIOException
-
listUsers
public ListCompanyUsersResponse listUsers(String companyId, Integer pageNumber, Integer pageSize, String username, RequestOptions requestOptions) throws ApiException, IOException
Get a list of users- Parameters:
companyId-StringThe unique identifier of the company account. (required)pageNumber-IntegerQuery: The number of the page to return. (optional)pageSize-IntegerQuery: The number of items to have on a page. Maximum value is **100**. The default is **10** items on a page. (optional)username-StringQuery: The partial or complete username to select all users that match. (optional)requestOptions-RequestOptionsObject to store additional data such as idempotency-keys (optional)- Returns:
ListCompanyUsersResponse- Throws:
ApiException- if fails to make API callIOException
-
updateUserDetails
public CompanyUser updateUserDetails(String companyId, String userId, UpdateCompanyUserRequest updateCompanyUserRequest) throws ApiException, IOException
Update user details- Parameters:
companyId-StringThe unique identifier of the company account. (required)userId-StringThe unique identifier of the user. (required)updateCompanyUserRequest-UpdateCompanyUserRequest(required)- Returns:
CompanyUser- Throws:
ApiException- if fails to make API callIOException
-
updateUserDetails
public CompanyUser updateUserDetails(String companyId, String userId, UpdateCompanyUserRequest updateCompanyUserRequest, RequestOptions requestOptions) throws ApiException, IOException
Update user details- Parameters:
companyId-StringThe unique identifier of the company account. (required)userId-StringThe unique identifier of the user. (required)updateCompanyUserRequest-UpdateCompanyUserRequest(required)requestOptions-RequestOptionsObject to store additional data such as idempotency-keys (optional)- Returns:
CompanyUser- Throws:
ApiException- if fails to make API callIOException
-
-