Class: XeroRuby::FinanceApi
- Inherits:
-
Object
- Object
- XeroRuby::FinanceApi
- Defined in:
- lib/xero-ruby/api/finance_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#get_bank_statement_accounting(xero_tenant_id, bank_account_id, from_date, to_date, opts = {}) ⇒ BankStatementAccountingResponse
Get Bank Statement Accounting For lenders that prefer using bank statement data as the source of truth.
-
#get_bank_statement_accounting_with_http_info(xero_tenant_id, bank_account_id, from_date, to_date, options = {}) ⇒ Array<(BankStatementAccountingResponse, Integer, Hash)>
Get Bank Statement Accounting For lenders that prefer using bank statement data as the source of truth.
-
#get_cash_validation(xero_tenant_id, opts = {}) ⇒ Array<CashValidationResponse>
Get cash validation Summarizes the total cash position for each account for an org.
-
#get_cash_validation_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(Array<CashValidationResponse>, Integer, Hash)>
Get cash validation Summarizes the total cash position for each account for an org.
-
#get_financial_statement_balance_sheet(xero_tenant_id, opts = {}) ⇒ BalanceSheetResponse
Get Balance Sheet report The balance sheet report is a standard financial report which describes the financial position of an organisation at a point in time.
-
#get_financial_statement_balance_sheet_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(BalanceSheetResponse, Integer, Hash)>
Get Balance Sheet report The balance sheet report is a standard financial report which describes the financial position of an organisation at a point in time.
-
#get_financial_statement_cashflow(xero_tenant_id, opts = {}) ⇒ CashflowResponse
Get Cash flow report The statement of cash flows - direct method, provides the year to date changes in operating, financing and investing cash flow activities for an organisation.
-
#get_financial_statement_cashflow_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(CashflowResponse, Integer, Hash)>
Get Cash flow report The statement of cash flows - direct method, provides the year to date changes in operating, financing and investing cash flow activities for an organisation.
-
#get_financial_statement_contacts_expense(xero_tenant_id, opts = {}) ⇒ IncomeByContactResponse
Get expense by contacts report The expense by contact report provides a year to date profit and loss for customers and suppliers for a given organisation, including detailed contact information.
-
#get_financial_statement_contacts_expense_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(IncomeByContactResponse, Integer, Hash)>
Get expense by contacts report The expense by contact report provides a year to date profit and loss for customers and suppliers for a given organisation, including detailed contact information.
-
#get_financial_statement_contacts_revenue(xero_tenant_id, opts = {}) ⇒ IncomeByContactResponse
Get revenue by contacts report The revenue by contact report provides a year to date profit and loss for customers and suppliers for a given organisation, including detailed contact information.
-
#get_financial_statement_contacts_revenue_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(IncomeByContactResponse, Integer, Hash)>
Get revenue by contacts report The revenue by contact report provides a year to date profit and loss for customers and suppliers for a given organisation, including detailed contact information.
-
#get_financial_statement_profit_and_loss(xero_tenant_id, opts = {}) ⇒ ProfitAndLossResponse
Get Profit & Loss report The profit and loss statement is a standard financial report providing detailed year to date income and expense detail for an organisation.
-
#get_financial_statement_profit_and_loss_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(ProfitAndLossResponse, Integer, Hash)>
Get Profit & Loss report The profit and loss statement is a standard financial report providing detailed year to date income and expense detail for an organisation.
-
#get_financial_statement_trial_balance(xero_tenant_id, opts = {}) ⇒ TrialBalanceResponse
Get Trial Balance report The trial balance provides a detailed list of all accounts of an organisation at a point in time, with revenue and expense items being year to date.
-
#get_financial_statement_trial_balance_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(TrialBalanceResponse, Integer, Hash)>
Get Trial Balance report The trial balance provides a detailed list of all accounts of an organisation at a point in time, with revenue and expense items being year to date.
-
#initialize(api_client = ApiClient.new) ⇒ FinanceApi
constructor
A new instance of FinanceApi.
Constructor Details
#initialize(api_client = ApiClient.new) ⇒ FinanceApi
Returns a new instance of FinanceApi.
16 17 18 |
# File 'lib/xero-ruby/api/finance_api.rb', line 16 def initialize(api_client = ApiClient.new) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
14 15 16 |
# File 'lib/xero-ruby/api/finance_api.rb', line 14 def api_client @api_client end |
Instance Method Details
#get_bank_statement_accounting(xero_tenant_id, bank_account_id, from_date, to_date, opts = {}) ⇒ BankStatementAccountingResponse
Get Bank Statement Accounting For lenders that prefer using bank statement data as the source of truth. We provide a data point that will allow access to customer bank statements, plus for reconciled bank transactions the matching accounting, invoice and billing data as well. As customers reconcile bank statements to invoices and bills, this transaction detail will provide valuable insight for lender’s assessment measures.
28 29 30 31 |
# File 'lib/xero-ruby/api/finance_api.rb', line 28 def get_bank_statement_accounting(xero_tenant_id, bank_account_id, from_date, to_date, opts = {}) data, _status_code, _headers = get_bank_statement_accounting_with_http_info(xero_tenant_id, bank_account_id, from_date, to_date, opts) data end |
#get_bank_statement_accounting_with_http_info(xero_tenant_id, bank_account_id, from_date, to_date, options = {}) ⇒ Array<(BankStatementAccountingResponse, Integer, Hash)>
Get Bank Statement Accounting For lenders that prefer using bank statement data as the source of truth. We provide a data point that will allow access to customer bank statements, plus for reconciled bank transactions the matching accounting, invoice and billing data as well. As customers reconcile bank statements to invoices and bills, this transaction detail will provide valuable insight for lender's assessment measures.
42 43 44 45 46 47 48 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 102 103 104 105 106 107 108 109 110 111 112 |
# File 'lib/xero-ruby/api/finance_api.rb', line 42 def get_bank_statement_accounting_with_http_info(xero_tenant_id, bank_account_id, from_date, to_date, = {}) opts = .dup if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: FinanceApi.get_bank_statement_accounting ...' end # verify the required parameter 'xero_tenant_id' is set if @api_client.config.client_side_validation && xero_tenant_id.nil? fail ArgumentError, "Missing the required parameter 'xero_tenant_id' when calling FinanceApi.get_bank_statement_accounting" end # verify the required parameter 'bank_account_id' is set if @api_client.config.client_side_validation && bank_account_id.nil? fail ArgumentError, "Missing the required parameter 'bank_account_id' when calling FinanceApi.get_bank_statement_accounting" end # verify the required parameter 'from_date' is set if @api_client.config.client_side_validation && from_date.nil? fail ArgumentError, "Missing the required parameter 'from_date' when calling FinanceApi.get_bank_statement_accounting" end # verify the required parameter 'to_date' is set if @api_client.config.client_side_validation && to_date.nil? fail ArgumentError, "Missing the required parameter 'to_date' when calling FinanceApi.get_bank_statement_accounting" end # resource path local_var_path = '/BankStatementsPlus/statements' # camelize keys of incoming `where` opts opts[:'where'] = @api_client.parameterize_where(opts[:'where']) if !opts[:'where'].nil? # query parameters query_params = opts[:query_params] || {} query_params[:'BankAccountID'] = bank_account_id query_params[:'FromDate'] = from_date query_params[:'ToDate'] = to_date query_params[:'SummaryOnly'] = opts[:'summary_only'] if !opts[:'summary_only'].nil? # XeroAPI's `IDs` convention openapi-generator does not snake_case properly.. manual over-riding `i_ds` malformations: query_params[:'IDs'] = @api_client.build_collection_param(opts[:'ids'], :csv) if !opts[:'ids'].nil? query_params[:'ContactIDs'] = @api_client.build_collection_param(opts[:'contact_ids'], :csv) if !opts[:'contact_ids'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) header_params[:'xero-tenant-id'] = xero_tenant_id # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'BankStatementAccountingResponse' # auth_names auth_names = opts[:auth_names] || ['OAuth2'] = opts.merge( :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, "FinanceApi", ) if @api_client.config.debugging @api_client.config.logger.debug "API called: FinanceApi#get_bank_statement_accounting\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_cash_validation(xero_tenant_id, opts = {}) ⇒ Array<CashValidationResponse>
Get cash validation Summarizes the total cash position for each account for an org
122 123 124 125 |
# File 'lib/xero-ruby/api/finance_api.rb', line 122 def get_cash_validation(xero_tenant_id, opts = {}) data, _status_code, _headers = get_cash_validation_with_http_info(xero_tenant_id, opts) data end |
#get_cash_validation_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(Array<CashValidationResponse>, Integer, Hash)>
Get cash validation Summarizes the total cash position for each account for an org
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 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 |
# File 'lib/xero-ruby/api/finance_api.rb', line 135 def get_cash_validation_with_http_info(xero_tenant_id, = {}) opts = .dup if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: FinanceApi.get_cash_validation ...' end # verify the required parameter 'xero_tenant_id' is set if @api_client.config.client_side_validation && xero_tenant_id.nil? fail ArgumentError, "Missing the required parameter 'xero_tenant_id' when calling FinanceApi.get_cash_validation" end # resource path local_var_path = '/CashValidation' # camelize keys of incoming `where` opts opts[:'where'] = @api_client.parameterize_where(opts[:'where']) if !opts[:'where'].nil? # query parameters query_params = opts[:query_params] || {} query_params[:'balanceDate'] = opts[:'balance_date'] if !opts[:'balance_date'].nil? query_params[:'asAtSystemDate'] = opts[:'as_at_system_date'] if !opts[:'as_at_system_date'].nil? query_params[:'beginDate'] = opts[:'begin_date'] if !opts[:'begin_date'].nil? # XeroAPI's `IDs` convention openapi-generator does not snake_case properly.. manual over-riding `i_ds` malformations: query_params[:'IDs'] = @api_client.build_collection_param(opts[:'ids'], :csv) if !opts[:'ids'].nil? query_params[:'ContactIDs'] = @api_client.build_collection_param(opts[:'contact_ids'], :csv) if !opts[:'contact_ids'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) header_params[:'xero-tenant-id'] = xero_tenant_id # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'Array<CashValidationResponse>' # auth_names auth_names = opts[:auth_names] || ['OAuth2'] = opts.merge( :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, "FinanceApi", ) if @api_client.config.debugging @api_client.config.logger.debug "API called: FinanceApi#get_cash_validation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_financial_statement_balance_sheet(xero_tenant_id, opts = {}) ⇒ BalanceSheetResponse
Get Balance Sheet report The balance sheet report is a standard financial report which describes the financial position of an organisation at a point in time.
200 201 202 203 |
# File 'lib/xero-ruby/api/finance_api.rb', line 200 def get_financial_statement_balance_sheet(xero_tenant_id, opts = {}) data, _status_code, _headers = get_financial_statement_balance_sheet_with_http_info(xero_tenant_id, opts) data end |
#get_financial_statement_balance_sheet_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(BalanceSheetResponse, Integer, Hash)>
Get Balance Sheet report The balance sheet report is a standard financial report which describes the financial position of an organisation at a point in time.
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 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 |
# File 'lib/xero-ruby/api/finance_api.rb', line 211 def get_financial_statement_balance_sheet_with_http_info(xero_tenant_id, = {}) opts = .dup if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: FinanceApi.get_financial_statement_balance_sheet ...' end # verify the required parameter 'xero_tenant_id' is set if @api_client.config.client_side_validation && xero_tenant_id.nil? fail ArgumentError, "Missing the required parameter 'xero_tenant_id' when calling FinanceApi.get_financial_statement_balance_sheet" end # resource path local_var_path = '/FinancialStatements/BalanceSheet' # camelize keys of incoming `where` opts opts[:'where'] = @api_client.parameterize_where(opts[:'where']) if !opts[:'where'].nil? # query parameters query_params = opts[:query_params] || {} query_params[:'balanceDate'] = opts[:'balance_date'] if !opts[:'balance_date'].nil? # XeroAPI's `IDs` convention openapi-generator does not snake_case properly.. manual over-riding `i_ds` malformations: query_params[:'IDs'] = @api_client.build_collection_param(opts[:'ids'], :csv) if !opts[:'ids'].nil? query_params[:'ContactIDs'] = @api_client.build_collection_param(opts[:'contact_ids'], :csv) if !opts[:'contact_ids'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) header_params[:'xero-tenant-id'] = xero_tenant_id # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'BalanceSheetResponse' # auth_names auth_names = opts[:auth_names] || ['OAuth2'] = opts.merge( :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, "FinanceApi", ) if @api_client.config.debugging @api_client.config.logger.debug "API called: FinanceApi#get_financial_statement_balance_sheet\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_financial_statement_cashflow(xero_tenant_id, opts = {}) ⇒ CashflowResponse
Get Cash flow report The statement of cash flows - direct method, provides the year to date changes in operating, financing and investing cash flow activities for an organisation. Cashflow statement is not available in US region at this stage.
275 276 277 278 |
# File 'lib/xero-ruby/api/finance_api.rb', line 275 def get_financial_statement_cashflow(xero_tenant_id, opts = {}) data, _status_code, _headers = get_financial_statement_cashflow_with_http_info(xero_tenant_id, opts) data end |
#get_financial_statement_cashflow_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(CashflowResponse, Integer, Hash)>
Get Cash flow report The statement of cash flows - direct method, provides the year to date changes in operating, financing and investing cash flow activities for an organisation. Cashflow statement is not available in US region at this stage.
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 |
# File 'lib/xero-ruby/api/finance_api.rb', line 287 def get_financial_statement_cashflow_with_http_info(xero_tenant_id, = {}) opts = .dup if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: FinanceApi.get_financial_statement_cashflow ...' end # verify the required parameter 'xero_tenant_id' is set if @api_client.config.client_side_validation && xero_tenant_id.nil? fail ArgumentError, "Missing the required parameter 'xero_tenant_id' when calling FinanceApi.get_financial_statement_cashflow" end # resource path local_var_path = '/FinancialStatements/Cashflow' # camelize keys of incoming `where` opts opts[:'where'] = @api_client.parameterize_where(opts[:'where']) if !opts[:'where'].nil? # query parameters query_params = opts[:query_params] || {} query_params[:'startDate'] = opts[:'start_date'] if !opts[:'start_date'].nil? query_params[:'endDate'] = opts[:'end_date'] if !opts[:'end_date'].nil? # XeroAPI's `IDs` convention openapi-generator does not snake_case properly.. manual over-riding `i_ds` malformations: query_params[:'IDs'] = @api_client.build_collection_param(opts[:'ids'], :csv) if !opts[:'ids'].nil? query_params[:'ContactIDs'] = @api_client.build_collection_param(opts[:'contact_ids'], :csv) if !opts[:'contact_ids'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) header_params[:'xero-tenant-id'] = xero_tenant_id # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'CashflowResponse' # auth_names auth_names = opts[:auth_names] || ['OAuth2'] = opts.merge( :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, "FinanceApi", ) if @api_client.config.debugging @api_client.config.logger.debug "API called: FinanceApi#get_financial_statement_cashflow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_financial_statement_contacts_expense(xero_tenant_id, opts = {}) ⇒ IncomeByContactResponse
Get expense by contacts report The expense by contact report provides a year to date profit and loss for customers and suppliers for a given organisation, including detailed contact information.
354 355 356 357 |
# File 'lib/xero-ruby/api/finance_api.rb', line 354 def get_financial_statement_contacts_expense(xero_tenant_id, opts = {}) data, _status_code, _headers = get_financial_statement_contacts_expense_with_http_info(xero_tenant_id, opts) data end |
#get_financial_statement_contacts_expense_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(IncomeByContactResponse, Integer, Hash)>
Get expense by contacts report The expense by contact report provides a year to date profit and loss for customers and suppliers for a given organisation, including detailed contact information.
368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 |
# File 'lib/xero-ruby/api/finance_api.rb', line 368 def get_financial_statement_contacts_expense_with_http_info(xero_tenant_id, = {}) opts = .dup if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: FinanceApi.get_financial_statement_contacts_expense ...' end # verify the required parameter 'xero_tenant_id' is set if @api_client.config.client_side_validation && xero_tenant_id.nil? fail ArgumentError, "Missing the required parameter 'xero_tenant_id' when calling FinanceApi.get_financial_statement_contacts_expense" end # resource path local_var_path = '/FinancialStatements/contacts/expense' # camelize keys of incoming `where` opts opts[:'where'] = @api_client.parameterize_where(opts[:'where']) if !opts[:'where'].nil? # query parameters query_params = opts[:query_params] || {} query_params[:'contactIds'] = @api_client.build_collection_param(opts[:'contact_ids'], :multi) if !opts[:'contact_ids'].nil? query_params[:'includeManualJournals'] = opts[:'include_manual_journals'] if !opts[:'include_manual_journals'].nil? query_params[:'startDate'] = opts[:'start_date'] if !opts[:'start_date'].nil? query_params[:'endDate'] = opts[:'end_date'] if !opts[:'end_date'].nil? # XeroAPI's `IDs` convention openapi-generator does not snake_case properly.. manual over-riding `i_ds` malformations: query_params[:'IDs'] = @api_client.build_collection_param(opts[:'ids'], :csv) if !opts[:'ids'].nil? query_params[:'ContactIDs'] = @api_client.build_collection_param(opts[:'contact_ids'], :csv) if !opts[:'contact_ids'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) header_params[:'xero-tenant-id'] = xero_tenant_id # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'IncomeByContactResponse' # auth_names auth_names = opts[:auth_names] || ['OAuth2'] = opts.merge( :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, "FinanceApi", ) if @api_client.config.debugging @api_client.config.logger.debug "API called: FinanceApi#get_financial_statement_contacts_expense\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_financial_statement_contacts_revenue(xero_tenant_id, opts = {}) ⇒ IncomeByContactResponse
Get revenue by contacts report The revenue by contact report provides a year to date profit and loss for customers and suppliers for a given organisation, including detailed contact information.
437 438 439 440 |
# File 'lib/xero-ruby/api/finance_api.rb', line 437 def get_financial_statement_contacts_revenue(xero_tenant_id, opts = {}) data, _status_code, _headers = get_financial_statement_contacts_revenue_with_http_info(xero_tenant_id, opts) data end |
#get_financial_statement_contacts_revenue_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(IncomeByContactResponse, Integer, Hash)>
Get revenue by contacts report The revenue by contact report provides a year to date profit and loss for customers and suppliers for a given organisation, including detailed contact information.
451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 |
# File 'lib/xero-ruby/api/finance_api.rb', line 451 def get_financial_statement_contacts_revenue_with_http_info(xero_tenant_id, = {}) opts = .dup if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: FinanceApi.get_financial_statement_contacts_revenue ...' end # verify the required parameter 'xero_tenant_id' is set if @api_client.config.client_side_validation && xero_tenant_id.nil? fail ArgumentError, "Missing the required parameter 'xero_tenant_id' when calling FinanceApi.get_financial_statement_contacts_revenue" end # resource path local_var_path = '/FinancialStatements/contacts/revenue' # camelize keys of incoming `where` opts opts[:'where'] = @api_client.parameterize_where(opts[:'where']) if !opts[:'where'].nil? # query parameters query_params = opts[:query_params] || {} query_params[:'contactIds'] = @api_client.build_collection_param(opts[:'contact_ids'], :multi) if !opts[:'contact_ids'].nil? query_params[:'includeManualJournals'] = opts[:'include_manual_journals'] if !opts[:'include_manual_journals'].nil? query_params[:'startDate'] = opts[:'start_date'] if !opts[:'start_date'].nil? query_params[:'endDate'] = opts[:'end_date'] if !opts[:'end_date'].nil? # XeroAPI's `IDs` convention openapi-generator does not snake_case properly.. manual over-riding `i_ds` malformations: query_params[:'IDs'] = @api_client.build_collection_param(opts[:'ids'], :csv) if !opts[:'ids'].nil? query_params[:'ContactIDs'] = @api_client.build_collection_param(opts[:'contact_ids'], :csv) if !opts[:'contact_ids'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) header_params[:'xero-tenant-id'] = xero_tenant_id # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'IncomeByContactResponse' # auth_names auth_names = opts[:auth_names] || ['OAuth2'] = opts.merge( :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, "FinanceApi", ) if @api_client.config.debugging @api_client.config.logger.debug "API called: FinanceApi#get_financial_statement_contacts_revenue\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_financial_statement_profit_and_loss(xero_tenant_id, opts = {}) ⇒ ProfitAndLossResponse
Get Profit & Loss report The profit and loss statement is a standard financial report providing detailed year to date income and expense detail for an organisation.
518 519 520 521 |
# File 'lib/xero-ruby/api/finance_api.rb', line 518 def get_financial_statement_profit_and_loss(xero_tenant_id, opts = {}) data, _status_code, _headers = get_financial_statement_profit_and_loss_with_http_info(xero_tenant_id, opts) data end |
#get_financial_statement_profit_and_loss_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(ProfitAndLossResponse, Integer, Hash)>
Get Profit & Loss report The profit and loss statement is a standard financial report providing detailed year to date income and expense detail for an organisation.
530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 |
# File 'lib/xero-ruby/api/finance_api.rb', line 530 def get_financial_statement_profit_and_loss_with_http_info(xero_tenant_id, = {}) opts = .dup if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: FinanceApi.get_financial_statement_profit_and_loss ...' end # verify the required parameter 'xero_tenant_id' is set if @api_client.config.client_side_validation && xero_tenant_id.nil? fail ArgumentError, "Missing the required parameter 'xero_tenant_id' when calling FinanceApi.get_financial_statement_profit_and_loss" end # resource path local_var_path = '/FinancialStatements/ProfitAndLoss' # camelize keys of incoming `where` opts opts[:'where'] = @api_client.parameterize_where(opts[:'where']) if !opts[:'where'].nil? # query parameters query_params = opts[:query_params] || {} query_params[:'startDate'] = opts[:'start_date'] if !opts[:'start_date'].nil? query_params[:'endDate'] = opts[:'end_date'] if !opts[:'end_date'].nil? # XeroAPI's `IDs` convention openapi-generator does not snake_case properly.. manual over-riding `i_ds` malformations: query_params[:'IDs'] = @api_client.build_collection_param(opts[:'ids'], :csv) if !opts[:'ids'].nil? query_params[:'ContactIDs'] = @api_client.build_collection_param(opts[:'contact_ids'], :csv) if !opts[:'contact_ids'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) header_params[:'xero-tenant-id'] = xero_tenant_id # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'ProfitAndLossResponse' # auth_names auth_names = opts[:auth_names] || ['OAuth2'] = opts.merge( :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, "FinanceApi", ) if @api_client.config.debugging @api_client.config.logger.debug "API called: FinanceApi#get_financial_statement_profit_and_loss\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_financial_statement_trial_balance(xero_tenant_id, opts = {}) ⇒ TrialBalanceResponse
Get Trial Balance report The trial balance provides a detailed list of all accounts of an organisation at a point in time, with revenue and expense items being year to date.
594 595 596 597 |
# File 'lib/xero-ruby/api/finance_api.rb', line 594 def get_financial_statement_trial_balance(xero_tenant_id, opts = {}) data, _status_code, _headers = get_financial_statement_trial_balance_with_http_info(xero_tenant_id, opts) data end |
#get_financial_statement_trial_balance_with_http_info(xero_tenant_id, options = {}) ⇒ Array<(TrialBalanceResponse, Integer, Hash)>
Get Trial Balance report The trial balance provides a detailed list of all accounts of an organisation at a point in time, with revenue and expense items being year to date.
605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 |
# File 'lib/xero-ruby/api/finance_api.rb', line 605 def get_financial_statement_trial_balance_with_http_info(xero_tenant_id, = {}) opts = .dup if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: FinanceApi.get_financial_statement_trial_balance ...' end # verify the required parameter 'xero_tenant_id' is set if @api_client.config.client_side_validation && xero_tenant_id.nil? fail ArgumentError, "Missing the required parameter 'xero_tenant_id' when calling FinanceApi.get_financial_statement_trial_balance" end # resource path local_var_path = '/FinancialStatements/TrialBalance' # camelize keys of incoming `where` opts opts[:'where'] = @api_client.parameterize_where(opts[:'where']) if !opts[:'where'].nil? # query parameters query_params = opts[:query_params] || {} query_params[:'endDate'] = opts[:'end_date'] if !opts[:'end_date'].nil? # XeroAPI's `IDs` convention openapi-generator does not snake_case properly.. manual over-riding `i_ds` malformations: query_params[:'IDs'] = @api_client.build_collection_param(opts[:'ids'], :csv) if !opts[:'ids'].nil? query_params[:'ContactIDs'] = @api_client.build_collection_param(opts[:'contact_ids'], :csv) if !opts[:'contact_ids'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) header_params[:'xero-tenant-id'] = xero_tenant_id # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'TrialBalanceResponse' # auth_names auth_names = opts[:auth_names] || ['OAuth2'] = opts.merge( :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, "FinanceApi", ) if @api_client.config.debugging @api_client.config.logger.debug "API called: FinanceApi#get_financial_statement_trial_balance\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |