Package io.moov.sdk

Class Accounts

    • 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 createAccount)
                                     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:
        createAccount -
        Returns:
        The response from the API call
        Throws:
        java.lang.Exception - if the API call fails
      • create

        public CreateAccountResponse create​(java.util.Optional<java.lang.String> xMoovVersion,
                                            CreateAccount createAccount)
                                     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.

        Specified by:
        create in interface SDKMethodInterfaces.MethodCallCreateAccount
        Parameters:
        xMoovVersion - Specify an API version. API versioning follows the format `vYYYY.QQ.BB`, where - `YYYY` is the year - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10) - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter. - For example, `v2024.01.00` is the initial release of the first quarter of 2024. The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
        createAccount -
        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.

        Specified by:
        list in interface SDKMethodInterfaces.MethodCallListAccounts
        Parameters:
        request - The request object containing all of 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
      • get

        public GetAccountResponse get​(java.util.Optional<java.lang.String> xMoovVersion,
                                      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.

        Specified by:
        get in interface SDKMethodInterfaces.MethodCallGetAccount
        Parameters:
        xMoovVersion - Specify an API version. API versioning follows the format `vYYYY.QQ.BB`, where - `YYYY` is the year - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10) - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter. - For example, `v2024.01.00` is the initial release of the first quarter of 2024. The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
        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
      • update

        public UpdateAccountResponse update​(java.util.Optional<java.lang.String> xMoovVersion,
                                            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.

        Specified by:
        update in interface SDKMethodInterfaces.MethodCallUpdateAccount
        Parameters:
        xMoovVersion - Specify an API version. API versioning follows the format `vYYYY.QQ.BB`, where - `YYYY` is the year - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10) - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter. - For example, `v2024.01.00` is the initial release of the first quarter of 2024. The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
        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
      • disconnect

        public DisconnectAccountResponse disconnect​(java.util.Optional<java.lang.String> xMoovVersion,
                                                    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.

        Specified by:
        disconnect in interface SDKMethodInterfaces.MethodCallDisconnectAccount
        Parameters:
        xMoovVersion - Specify an API version. API versioning follows the format `vYYYY.QQ.BB`, where - `YYYY` is the year - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10) - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter. - For example, `v2024.01.00` is the initial release of the first quarter of 2024. The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
        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
      • getCountries

        public GetAccountCountriesResponse getCountries​(java.util.Optional<java.lang.String> xMoovVersion,
                                                        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.

        Specified by:
        getCountries in interface SDKMethodInterfaces.MethodCallGetAccountCountries
        Parameters:
        xMoovVersion - Specify an API version. API versioning follows the format `vYYYY.QQ.BB`, where - `YYYY` is the year - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10) - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter. - For example, `v2024.01.00` is the initial release of the first quarter of 2024. The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
        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
      • assignCountries

        public AssignAccountCountriesResponse assignCountries​(java.util.Optional<java.lang.String> xMoovVersion,
                                                              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.

        Specified by:
        assignCountries in interface SDKMethodInterfaces.MethodCallAssignAccountCountries
        Parameters:
        xMoovVersion - Specify an API version. API versioning follows the format `vYYYY.QQ.BB`, where - `YYYY` is the year - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10) - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter. - For example, `v2024.01.00` is the initial release of the first quarter of 2024. The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
        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
      • getMerchantProcessingAgreement

        public GetMerchantProcessingAgreementResponse getMerchantProcessingAgreement​(java.util.Optional<java.lang.String> xMoovVersion,
                                                                                     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.

        Specified by:
        getMerchantProcessingAgreement in interface SDKMethodInterfaces.MethodCallGetMerchantProcessingAgreement
        Parameters:
        xMoovVersion - Specify an API version. API versioning follows the format `vYYYY.QQ.BB`, where - `YYYY` is the year - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10) - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter. - For example, `v2024.01.00` is the initial release of the first quarter of 2024. The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
        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> xMoovVersion,
                                                                     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/).

        Specified by:
        getTermsOfServiceToken in interface SDKMethodInterfaces.MethodCallGetTermsOfServiceToken
        Parameters:
        xMoovVersion - Specify an API version. API versioning follows the format `vYYYY.QQ.BB`, where - `YYYY` is the year - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10) - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter. - For example, `v2024.01.00` is the initial release of the first quarter of 2024. The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
        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