Package com.adyen.service.management
Class UsersMerchantLevelApi
- java.lang.Object
-
- com.adyen.Service
-
- com.adyen.service.management.UsersMerchantLevelApi
-
public class UsersMerchantLevelApi extends Service
-
-
Field Summary
Fields Modifier and Type Field Description static StringAPI_VERSIONprotected StringbaseURL
-
Constructor Summary
Constructors Constructor Description UsersMerchantLevelApi(Client client)Users - merchant level constructor inpackage.UsersMerchantLevelApi(Client client, String baseURL)Users - merchant level constructor inpackage.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CreateUserResponsecreateNewUser(String merchantId, CreateMerchantUserRequest createMerchantUserRequest)Create a new userCreateUserResponsecreateNewUser(String merchantId, CreateMerchantUserRequest createMerchantUserRequest, RequestOptions requestOptions)Create a new userUsergetUserDetails(String merchantId, String userId)Get user detailsUsergetUserDetails(String merchantId, String userId, RequestOptions requestOptions)Get user detailsListMerchantUsersResponselistUsers(String merchantId)Get a list of usersListMerchantUsersResponselistUsers(String merchantId, Integer pageNumber, Integer pageSize, String username, RequestOptions requestOptions)Get a list of usersUserupdateUser(String merchantId, String userId, UpdateMerchantUserRequest updateMerchantUserRequest)Update a userUserupdateUser(String merchantId, String userId, UpdateMerchantUserRequest updateMerchantUserRequest, RequestOptions requestOptions)Update a user-
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
-
UsersMerchantLevelApi
public UsersMerchantLevelApi(Client client)
Users - merchant level constructor inpackage.- Parameters:
client-Client(required)
-
UsersMerchantLevelApi
public UsersMerchantLevelApi(Client client, String baseURL)
Users - merchant 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 CreateUserResponse createNewUser(String merchantId, CreateMerchantUserRequest createMerchantUserRequest) throws ApiException, IOException
Create a new user- Parameters:
merchantId-StringUnique identifier of the merchant. (required)createMerchantUserRequest-CreateMerchantUserRequest(required)- Returns:
CreateUserResponse- Throws:
ApiException- if fails to make API callIOException
-
createNewUser
public CreateUserResponse createNewUser(String merchantId, CreateMerchantUserRequest createMerchantUserRequest, RequestOptions requestOptions) throws ApiException, IOException
Create a new user- Parameters:
merchantId-StringUnique identifier of the merchant. (required)createMerchantUserRequest-CreateMerchantUserRequest(required)requestOptions-RequestOptionsObject to store additional data such as idempotency-keys (optional)- Returns:
CreateUserResponse- Throws:
ApiException- if fails to make API callIOException
-
getUserDetails
public User getUserDetails(String merchantId, String userId) throws ApiException, IOException
Get user details- Parameters:
merchantId-StringUnique identifier of the merchant. (required)userId-StringUnique identifier of the user. (required)- Returns:
User- Throws:
ApiException- if fails to make API callIOException
-
getUserDetails
public User getUserDetails(String merchantId, String userId, RequestOptions requestOptions) throws ApiException, IOException
Get user details- Parameters:
merchantId-StringUnique identifier of the merchant. (required)userId-StringUnique identifier of the user. (required)requestOptions-RequestOptionsObject to store additional data such as idempotency-keys (optional)- Returns:
User- Throws:
ApiException- if fails to make API callIOException
-
listUsers
public ListMerchantUsersResponse listUsers(String merchantId) throws ApiException, IOException
Get a list of users- Parameters:
merchantId-StringUnique identifier of the merchant. (required)- Returns:
ListMerchantUsersResponse- Throws:
ApiException- if fails to make API callIOException
-
listUsers
public ListMerchantUsersResponse listUsers(String merchantId, Integer pageNumber, Integer pageSize, String username, RequestOptions requestOptions) throws ApiException, IOException
Get a list of users- Parameters:
merchantId-StringUnique identifier of the merchant. (required)pageNumber-IntegerQuery: The number of the page to fetch. (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:
ListMerchantUsersResponse- Throws:
ApiException- if fails to make API callIOException
-
updateUser
public User updateUser(String merchantId, String userId, UpdateMerchantUserRequest updateMerchantUserRequest) throws ApiException, IOException
Update a user- Parameters:
merchantId-StringUnique identifier of the merchant. (required)userId-StringUnique identifier of the user. (required)updateMerchantUserRequest-UpdateMerchantUserRequest(required)- Returns:
User- Throws:
ApiException- if fails to make API callIOException
-
updateUser
public User updateUser(String merchantId, String userId, UpdateMerchantUserRequest updateMerchantUserRequest, RequestOptions requestOptions) throws ApiException, IOException
Update a user- Parameters:
merchantId-StringUnique identifier of the merchant. (required)userId-StringUnique identifier of the user. (required)updateMerchantUserRequest-UpdateMerchantUserRequest(required)requestOptions-RequestOptionsObject to store additional data such as idempotency-keys (optional)- Returns:
User- Throws:
ApiException- if fails to make API callIOException
-
-