Class Accounts
- java.lang.Object
-
- io.moov.sdk.Accounts
-
public class Accounts extends java.lang.Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AssignAccountCountriesRequestBuilderassignCountries()Assign the countries of operation for an account.AssignAccountCountriesResponseassignCountries(java.lang.String accountID, AccountCountries accountCountries)Assign the countries of operation for an account.CreateAccountRequestBuildercreate()You can create **business** or **individual** accounts for your users (i.e., customers, merchants) by passing the required information to Moov.CreateAccountResponsecreate(CreateAccount request)You can create **business** or **individual** accounts for your users (i.e., customers, merchants) by passing the required information to Moov.DisconnectAccountRequestBuilderdisconnect()This will sever the connection between you and the account specified and it will no longer be listed as active in the list of accounts.DisconnectAccountResponsedisconnect(java.lang.String accountID)This will sever the connection between you and the account specified and it will no longer be listed as active in the list of accounts.GetAccountRequestBuilderget()Retrieves details for the account with the specified ID.GetAccountResponseget(java.lang.String accountID)Retrieves details for the account with the specified ID.GetAccountCountriesRequestBuildergetCountries()Retrieve the specified countries of operation for an account.GetAccountCountriesResponsegetCountries(java.lang.String accountID)Retrieve the specified countries of operation for an account.GetMerchantProcessingAgreementRequestBuildergetMerchantProcessingAgreement()Retrieve a merchant account's processing agreement.GetMerchantProcessingAgreementResponsegetMerchantProcessingAgreement(java.lang.String accountID)Retrieve a merchant account's processing agreement.GetTermsOfServiceTokenRequestBuildergetTermsOfServiceToken()Generates a non-expiring token that can then be used to accept Moov's terms of service.GetTermsOfServiceTokenResponsegetTermsOfServiceToken(java.util.Optional<java.lang.String> origin, java.util.Optional<java.lang.String> referer)Generates a non-expiring token that can then be used to accept Moov's terms of service.GetTermsOfServiceTokenResponsegetTermsOfServiceTokenDirect()Generates a non-expiring token that can then be used to accept Moov's terms of service.ListAccountsRequestBuilderlist()List or search accounts to which the caller is connected.ListAccountsResponselist(ListAccountsRequest request)List or search accounts to which the caller is connected.UpdateAccountRequestBuilderupdate()When **can** profile data be updated: + For unverified accounts, all profile data can be edited.UpdateAccountResponseupdate(java.lang.String accountID, PatchAccount patchAccount)When **can** profile data be updated: + For unverified accounts, all profile data can be edited.
-
-
-
Method Detail
-
create
public CreateAccountRequestBuilder create()
You can create **business** or **individual** accounts for your users (i.e., customers, merchants) by passing the required information to Moov. Requirements differ per account type and requested [capabilities](https://docs.moov.io/guides/accounts/capabilities/requirements/).If you're requesting the `wallet`, `send-funds`, `collect-funds`, or `card-issuing` capabilities, you'll need to: + Send Moov the user [platform terms of service agreement](https://docs.moov.io/guides/accounts/requirements/platform-agreement/) acceptance. This can be done upon account creation, or by [patching](https://docs.moov.io/api/moov-accounts/accounts/patch/) the account using the `termsOfService` field. If you're creating a business account with the business type `llc`, `partnership`, or `privateCorporation`, you'll need to: + Provide [business representatives](https://docs.moov.io/api/moov-accounts/representatives/) after creating the account. + [Patch](https://docs.moov.io/api/moov-accounts/accounts/patch/) the account to indicate that business representative ownership information is complete.
Visit our documentation to read more about [creating accounts](https://docs.moov.io/guides/accounts/create-accounts/) and [verification requirements](https://docs.moov.io/guides/accounts/requirements/identity-verification/). Note that the `mode` field (for production or sandbox) is only required when creating a _facilitator_ account. All non-facilitator account requests will ignore the mode field and be set to the calling facilitator's mode.
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts.write` scope.
- Returns:
- The call builder
-
create
public CreateAccountResponse create(CreateAccount request) throws java.lang.Exception
You can create **business** or **individual** accounts for your users (i.e., customers, merchants) by passing the required information to Moov. Requirements differ per account type and requested [capabilities](https://docs.moov.io/guides/accounts/capabilities/requirements/).If you're requesting the `wallet`, `send-funds`, `collect-funds`, or `card-issuing` capabilities, you'll need to: + Send Moov the user [platform terms of service agreement](https://docs.moov.io/guides/accounts/requirements/platform-agreement/) acceptance. This can be done upon account creation, or by [patching](https://docs.moov.io/api/moov-accounts/accounts/patch/) the account using the `termsOfService` field. If you're creating a business account with the business type `llc`, `partnership`, or `privateCorporation`, you'll need to: + Provide [business representatives](https://docs.moov.io/api/moov-accounts/representatives/) after creating the account. + [Patch](https://docs.moov.io/api/moov-accounts/accounts/patch/) the account to indicate that business representative ownership information is complete.
Visit our documentation to read more about [creating accounts](https://docs.moov.io/guides/accounts/create-accounts/) and [verification requirements](https://docs.moov.io/guides/accounts/requirements/identity-verification/). Note that the `mode` field (for production or sandbox) is only required when creating a _facilitator_ account. All non-facilitator account requests will ignore the mode field and be set to the calling facilitator's mode.
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts.write` scope.
- Parameters:
request- The request object containing all the parameters for the API call.- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
list
public ListAccountsRequestBuilder list()
List or search accounts to which the caller is connected.All supported query parameters are optional. If none are provided the response will include all connected accounts. Pagination is supported via the `skip` and `count` query parameters. Searching by name and email will overlap and return results based on relevance.
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts.read` scope.
- Returns:
- The call builder
-
list
public ListAccountsResponse list(ListAccountsRequest request) throws java.lang.Exception
List or search accounts to which the caller is connected.All supported query parameters are optional. If none are provided the response will include all connected accounts. Pagination is supported via the `skip` and `count` query parameters. Searching by name and email will overlap and return results based on relevance.
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts.read` scope.
- Parameters:
request- The request object containing all the parameters for the API call.- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
get
public GetAccountRequestBuilder get()
Retrieves details for the account with the specified ID.To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.read` scope.
- Returns:
- The call builder
-
get
public GetAccountResponse get(java.lang.String accountID) throws java.lang.Exception
Retrieves details for the account with the specified ID.To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.read` scope.
- Parameters:
accountID-- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
update
public UpdateAccountRequestBuilder update()
When **can** profile data be updated: + For unverified accounts, all profile data can be edited. + During the verification process, missing or incomplete profile data can be edited. + Verified accounts can only add missing profile data.When **can't** profile data be updated: + Verified accounts cannot change any existing profile data.
If you need to update information in a locked state, please contact Moov support.
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.write` scope.
- Returns:
- The call builder
-
update
public UpdateAccountResponse update(java.lang.String accountID, PatchAccount patchAccount) throws java.lang.Exception
When **can** profile data be updated: + For unverified accounts, all profile data can be edited. + During the verification process, missing or incomplete profile data can be edited. + Verified accounts can only add missing profile data.When **can't** profile data be updated: + Verified accounts cannot change any existing profile data.
If you need to update information in a locked state, please contact Moov support.
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.write` scope.
- Parameters:
accountID-patchAccount- Describes the fields available when patching a Moov account.- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
disconnect
public DisconnectAccountRequestBuilder disconnect()
This will sever the connection between you and the account specified and it will no longer be listed as active in the list of accounts. This also means you'll only have read-only access to the account going forward for reporting purposes.To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.disconnect` scope.
- Returns:
- The call builder
-
disconnect
public DisconnectAccountResponse disconnect(java.lang.String accountID) throws java.lang.Exception
This will sever the connection between you and the account specified and it will no longer be listed as active in the list of accounts. This also means you'll only have read-only access to the account going forward for reporting purposes.To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.disconnect` scope.
- Parameters:
accountID-- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
getCountries
public GetAccountCountriesRequestBuilder getCountries()
Retrieve the specified countries of operation for an account.To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.read` scope.
- Returns:
- The call builder
-
getCountries
public GetAccountCountriesResponse getCountries(java.lang.String accountID) throws java.lang.Exception
Retrieve the specified countries of operation for an account.To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.read` scope.
- Parameters:
accountID-- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
assignCountries
public AssignAccountCountriesRequestBuilder assignCountries()
Assign the countries of operation for an account.This endpoint will always overwrite the previously assigned values.
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.write` scope.
- Returns:
- The call builder
-
assignCountries
public AssignAccountCountriesResponse assignCountries(java.lang.String accountID, AccountCountries accountCountries) throws java.lang.Exception
Assign the countries of operation for an account.This endpoint will always overwrite the previously assigned values.
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.write` scope.
- Parameters:
accountID-accountCountries- The countries in which an account operates.- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
getMerchantProcessingAgreement
public GetMerchantProcessingAgreementRequestBuilder getMerchantProcessingAgreement()
Retrieve a merchant account's processing agreement.To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.read` scope.
- Returns:
- The call builder
-
getMerchantProcessingAgreement
public GetMerchantProcessingAgreementResponse getMerchantProcessingAgreement(java.lang.String accountID) throws java.lang.Exception
Retrieve a merchant account's processing agreement.To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) you'll need to specify the `/accounts/{accountID}/profile.read` scope.
- Parameters:
accountID-- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
getTermsOfServiceToken
public GetTermsOfServiceTokenRequestBuilder getTermsOfServiceToken()
Generates a non-expiring token that can then be used to accept Moov's terms of service.This token can only be generated via API. Any Moov account requesting the collect funds, send funds, wallet, or card issuing capabilities must accept Moov's terms of service, then have the generated terms of service token patched to the account. Read more in our [documentation](https://docs.moov.io/guides/accounts/requirements/platform-agreement/).
- Returns:
- The call builder
-
getTermsOfServiceTokenDirect
public GetTermsOfServiceTokenResponse getTermsOfServiceTokenDirect() throws java.lang.Exception
Generates a non-expiring token that can then be used to accept Moov's terms of service.This token can only be generated via API. Any Moov account requesting the collect funds, send funds, wallet, or card issuing capabilities must accept Moov's terms of service, then have the generated terms of service token patched to the account. Read more in our [documentation](https://docs.moov.io/guides/accounts/requirements/platform-agreement/).
- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
getTermsOfServiceToken
public GetTermsOfServiceTokenResponse getTermsOfServiceToken(java.util.Optional<java.lang.String> origin, java.util.Optional<java.lang.String> referer) throws java.lang.Exception
Generates a non-expiring token that can then be used to accept Moov's terms of service.This token can only be generated via API. Any Moov account requesting the collect funds, send funds, wallet, or card issuing capabilities must accept Moov's terms of service, then have the generated terms of service token patched to the account. Read more in our [documentation](https://docs.moov.io/guides/accounts/requirements/platform-agreement/).
- Parameters:
origin- Indicates the domain from which the request originated. Required if referer header is not present.referer- Specifies the URL of the resource from which the request originated. Required if origin header is not present.- Returns:
- The response from the API call
- Throws:
java.lang.Exception- if the API call fails
-
-