Class: UpBankingClient::TransactionsApi
- Inherits:
-
Object
- Object
- UpBankingClient::TransactionsApi
- Defined in:
- lib/up_banking/api/transactions_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#accounts_account_id_transactions_get(account_id, opts = {}) ⇒ ListTransactionsResponse
List transactions by account Retrieve a list of all transactions for a specific account.
-
#accounts_account_id_transactions_get_with_http_info(account_id, opts = {}) ⇒ Array<(ListTransactionsResponse, Integer, Hash)>
List transactions by account Retrieve a list of all transactions for a specific account.
-
#initialize(api_client = ApiClient.default) ⇒ TransactionsApi
constructor
A new instance of TransactionsApi.
-
#transactions_get(opts = {}) ⇒ ListTransactionsResponse
List transactions Retrieve a list of all transactions across all accounts for the currently authenticated user.
-
#transactions_get_with_http_info(opts = {}) ⇒ Array<(ListTransactionsResponse, Integer, Hash)>
List transactions Retrieve a list of all transactions across all accounts for the currently authenticated user.
-
#transactions_id_get(id, opts = {}) ⇒ GetTransactionResponse
Retrieve transaction Retrieve a specific transaction by providing its unique identifier.
-
#transactions_id_get_with_http_info(id, opts = {}) ⇒ Array<(GetTransactionResponse, Integer, Hash)>
Retrieve transaction Retrieve a specific transaction by providing its unique identifier.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ TransactionsApi
Returns a new instance of TransactionsApi.
19 20 21 |
# File 'lib/up_banking/api/transactions_api.rb', line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/up_banking/api/transactions_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#accounts_account_id_transactions_get(account_id, opts = {}) ⇒ ListTransactionsResponse
List transactions by account Retrieve a list of all transactions for a specific account. The returned list is [paginated](#pagination) and can be scrolled by following the ‘next` and `prev` links where present. To narrow the results to a specific date range pass one or both of `filter` and `filter` in the query string. These filter parameters **should not** be used for pagination. Results are ordered newest first to oldest last.
33 34 35 36 |
# File 'lib/up_banking/api/transactions_api.rb', line 33 def accounts_account_id_transactions_get(account_id, opts = {}) data, _status_code, _headers = accounts_account_id_transactions_get_with_http_info(account_id, opts) data end |
#accounts_account_id_transactions_get_with_http_info(account_id, opts = {}) ⇒ Array<(ListTransactionsResponse, Integer, Hash)>
List transactions by account Retrieve a list of all transactions for a specific account. The returned list is [paginated](#pagination) and can be scrolled by following the `next` and `prev` links where present. To narrow the results to a specific date range pass one or both of `filter` and `filter` in the query string. These filter parameters **should not** be used for pagination. Results are ordered newest first to oldest last.
49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 |
# File 'lib/up_banking/api/transactions_api.rb', line 49 def accounts_account_id_transactions_get_with_http_info(account_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: TransactionsApi.accounts_account_id_transactions_get ...' end # verify the required parameter 'account_id' is set if @api_client.config.client_side_validation && account_id.nil? fail ArgumentError, "Missing the required parameter 'account_id' when calling TransactionsApi.accounts_account_id_transactions_get" end # resource path local_var_path = '/accounts/{accountId}/transactions'.sub('{' + 'accountId' + '}', CGI.escape(account_id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil? query_params[:'filter[status]'] = opts[:'filter_status'] if !opts[:'filter_status'].nil? query_params[:'filter[since]'] = opts[:'filter_since'] if !opts[:'filter_since'].nil? query_params[:'filter[until]'] = opts[:'filter_until'] if !opts[:'filter_until'].nil? query_params[:'filter[category]'] = opts[:'filter_category'] if !opts[:'filter_category'].nil? query_params[:'filter[tag]'] = opts[:'filter_tag'] if !opts[:'filter_tag'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ListTransactionsResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearer_auth'] = opts.merge( :operation => :"TransactionsApi.accounts_account_id_transactions_get", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: TransactionsApi#accounts_account_id_transactions_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#transactions_get(opts = {}) ⇒ ListTransactionsResponse
List transactions Retrieve a list of all transactions across all accounts for the currently authenticated user. The returned list is [paginated](#pagination) and can be scrolled by following the ‘next` and `prev` links where present. To narrow the results to a specific date range pass one or both of `filter` and `filter` in the query string. These filter parameters **should not** be used for pagination. Results are ordered newest first to oldest last.
113 114 115 116 |
# File 'lib/up_banking/api/transactions_api.rb', line 113 def transactions_get(opts = {}) data, _status_code, _headers = transactions_get_with_http_info(opts) data end |
#transactions_get_with_http_info(opts = {}) ⇒ Array<(ListTransactionsResponse, Integer, Hash)>
List transactions Retrieve a list of all transactions across all accounts for the currently authenticated user. The returned list is [paginated](#pagination) and can be scrolled by following the `next` and `prev` links where present. To narrow the results to a specific date range pass one or both of `filter` and `filter` in the query string. These filter parameters **should not** be used for pagination. Results are ordered newest first to oldest last.
128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 |
# File 'lib/up_banking/api/transactions_api.rb', line 128 def transactions_get_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: TransactionsApi.transactions_get ...' end # resource path local_var_path = '/transactions' # query parameters query_params = opts[:query_params] || {} query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil? query_params[:'filter[status]'] = opts[:'filter_status'] if !opts[:'filter_status'].nil? query_params[:'filter[since]'] = opts[:'filter_since'] if !opts[:'filter_since'].nil? query_params[:'filter[until]'] = opts[:'filter_until'] if !opts[:'filter_until'].nil? query_params[:'filter[category]'] = opts[:'filter_category'] if !opts[:'filter_category'].nil? query_params[:'filter[tag]'] = opts[:'filter_tag'] if !opts[:'filter_tag'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ListTransactionsResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearer_auth'] = opts.merge( :operation => :"TransactionsApi.transactions_get", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: TransactionsApi#transactions_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#transactions_id_get(id, opts = {}) ⇒ GetTransactionResponse
Retrieve transaction Retrieve a specific transaction by providing its unique identifier.
183 184 185 186 |
# File 'lib/up_banking/api/transactions_api.rb', line 183 def transactions_id_get(id, opts = {}) data, _status_code, _headers = transactions_id_get_with_http_info(id, opts) data end |
#transactions_id_get_with_http_info(id, opts = {}) ⇒ Array<(GetTransactionResponse, Integer, Hash)>
Retrieve transaction Retrieve a specific transaction by providing its unique identifier.
193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 |
# File 'lib/up_banking/api/transactions_api.rb', line 193 def transactions_id_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: TransactionsApi.transactions_id_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling TransactionsApi.transactions_id_get" end # resource path local_var_path = '/transactions/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'GetTransactionResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearer_auth'] = opts.merge( :operation => :"TransactionsApi.transactions_id_get", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: TransactionsApi#transactions_id_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |