Class AccountsApi

java.lang.Object
cm.xd.genapi.ynab.api.AccountsApi

public class AccountsApi extends Object
  • Constructor Details

    • AccountsApi

      public AccountsApi()
    • AccountsApi

      public AccountsApi(ApiClient apiClient)
  • Method Details

    • getApiClient

      public ApiClient getApiClient()
    • setApiClient

      public void setApiClient(ApiClient apiClient)
    • getHostIndex

      public int getHostIndex()
    • setHostIndex

      public void setHostIndex(int hostIndex)
    • getCustomBaseUrl

      public String getCustomBaseUrl()
    • setCustomBaseUrl

      public void setCustomBaseUrl(String customBaseUrl)
    • createAccountCall

      public okhttp3.Call createAccountCall(@Nonnull String planId, @Nonnull PostAccountWrapper data, ApiCallback _callback) throws ApiException
      Build call for createAccount
      Parameters:
      planId - The id of the plan (\"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan) (required)
      data - The account to create. (required)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      Http Response Details
      Response Details
      Status Code Description Response Headers
      201 The account was successfully created -
      400 The request could not be understood due to malformed syntax or validation error(s). -
    • createAccount

      public AccountResponse createAccount(@Nonnull String planId, @Nonnull PostAccountWrapper data) throws ApiException
      Create an account Creates a new account
      Parameters:
      planId - The id of the plan (\"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan) (required)
      data - The account to create. (required)
      Returns:
      AccountResponse
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      Http Response Details
      Response Details
      Status Code Description Response Headers
      201 The account was successfully created -
      400 The request could not be understood due to malformed syntax or validation error(s). -
    • createAccountWithHttpInfo

      public ApiResponse<AccountResponse> createAccountWithHttpInfo(@Nonnull String planId, @Nonnull PostAccountWrapper data) throws ApiException
      Create an account Creates a new account
      Parameters:
      planId - The id of the plan (\"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan) (required)
      data - The account to create. (required)
      Returns:
      ApiResponse<AccountResponse>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      Http Response Details
      Response Details
      Status Code Description Response Headers
      201 The account was successfully created -
      400 The request could not be understood due to malformed syntax or validation error(s). -
    • createAccountAsync

      public okhttp3.Call createAccountAsync(@Nonnull String planId, @Nonnull PostAccountWrapper data, ApiCallback<AccountResponse> _callback) throws ApiException
      Create an account (asynchronously) Creates a new account
      Parameters:
      planId - The id of the plan (\"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan) (required)
      data - The account to create. (required)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      Http Response Details
      Response Details
      Status Code Description Response Headers
      201 The account was successfully created -
      400 The request could not be understood due to malformed syntax or validation error(s). -
    • getAccountByIdCall

      public okhttp3.Call getAccountByIdCall(@Nonnull String planId, @Nonnull UUID accountId, ApiCallback _callback) throws ApiException
      Build call for getAccountById
      Parameters:
      planId - The id of the plan. \"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan). (required)
      accountId - The id of the account (required)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      Http Response Details
      Response Details
      Status Code Description Response Headers
      200 The requested account -
      404 The requested account was not found -
    • getAccountById

      public AccountResponse getAccountById(@Nonnull String planId, @Nonnull UUID accountId) throws ApiException
      Get an account Returns a single account
      Parameters:
      planId - The id of the plan. \"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan). (required)
      accountId - The id of the account (required)
      Returns:
      AccountResponse
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      Http Response Details
      Response Details
      Status Code Description Response Headers
      200 The requested account -
      404 The requested account was not found -
    • getAccountByIdWithHttpInfo

      public ApiResponse<AccountResponse> getAccountByIdWithHttpInfo(@Nonnull String planId, @Nonnull UUID accountId) throws ApiException
      Get an account Returns a single account
      Parameters:
      planId - The id of the plan. \"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan). (required)
      accountId - The id of the account (required)
      Returns:
      ApiResponse<AccountResponse>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      Http Response Details
      Response Details
      Status Code Description Response Headers
      200 The requested account -
      404 The requested account was not found -
    • getAccountByIdAsync

      public okhttp3.Call getAccountByIdAsync(@Nonnull String planId, @Nonnull UUID accountId, ApiCallback<AccountResponse> _callback) throws ApiException
      Get an account (asynchronously) Returns a single account
      Parameters:
      planId - The id of the plan. \"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan). (required)
      accountId - The id of the account (required)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      Http Response Details
      Response Details
      Status Code Description Response Headers
      200 The requested account -
      404 The requested account was not found -
    • getAccountsCall

      public okhttp3.Call getAccountsCall(@Nonnull String planId, @Nullable Long lastKnowledgeOfServer, ApiCallback _callback) throws ApiException
      Build call for getAccounts
      Parameters:
      planId - The id of the plan. \"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan). (required)
      lastKnowledgeOfServer - The starting server knowledge. If provided, only entities that have changed since `last_knowledge_of_server` will be included. (optional)
      _callback - Callback for upload/download progress
      Returns:
      Call to execute
      Throws:
      ApiException - If fail to serialize the request body object
      Http Response Details
      Response Details
      Status Code Description Response Headers
      200 The list of requested accounts -
      404 No accounts were found -
    • getAccounts

      public AccountsResponse getAccounts(@Nonnull String planId, @Nullable Long lastKnowledgeOfServer) throws ApiException
      Get all accounts Returns all accounts
      Parameters:
      planId - The id of the plan. \"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan). (required)
      lastKnowledgeOfServer - The starting server knowledge. If provided, only entities that have changed since `last_knowledge_of_server` will be included. (optional)
      Returns:
      AccountsResponse
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      Http Response Details
      Response Details
      Status Code Description Response Headers
      200 The list of requested accounts -
      404 No accounts were found -
    • getAccountsWithHttpInfo

      public ApiResponse<AccountsResponse> getAccountsWithHttpInfo(@Nonnull String planId, @Nullable Long lastKnowledgeOfServer) throws ApiException
      Get all accounts Returns all accounts
      Parameters:
      planId - The id of the plan. \"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan). (required)
      lastKnowledgeOfServer - The starting server knowledge. If provided, only entities that have changed since `last_knowledge_of_server` will be included. (optional)
      Returns:
      ApiResponse<AccountsResponse>
      Throws:
      ApiException - If fail to call the API, e.g. server error or cannot deserialize the response body
      Http Response Details
      Response Details
      Status Code Description Response Headers
      200 The list of requested accounts -
      404 No accounts were found -
    • getAccountsAsync

      public okhttp3.Call getAccountsAsync(@Nonnull String planId, @Nullable Long lastKnowledgeOfServer, ApiCallback<AccountsResponse> _callback) throws ApiException
      Get all accounts (asynchronously) Returns all accounts
      Parameters:
      planId - The id of the plan. \"last-used\" can be used to specify the last used plan and \"default\" can be used if default plan selection is enabled (see: https://api.ynab.com/#oauth-default-plan). (required)
      lastKnowledgeOfServer - The starting server knowledge. If provided, only entities that have changed since `last_knowledge_of_server` will be included. (optional)
      _callback - The callback to be executed when the API call finishes
      Returns:
      The request call
      Throws:
      ApiException - If fail to process the API call, e.g. serializing the request body object
      Http Response Details
      Response Details
      Status Code Description Response Headers
      200 The list of requested accounts -
      404 No accounts were found -