From f0a0ad673082f6000560d5df1288e56e18c1d670 Mon Sep 17 00:00:00 2001 From: Rett Behrens Date: Mon, 9 May 2022 14:58:31 -0600 Subject: [PATCH] generates xero-ruby 3.9.0 from OAS 2.22.4 --- docs/accounting/AccountingApi.md | 65 ++++++++++ docs/accounting/index.html | 121 +++++++++++++++++- docs/app_store/index.html | 2 +- docs/assets/index.html | 2 +- docs/files/index.html | 2 +- docs/finance/StatementResponse.md | 6 +- docs/finance/index.html | 16 ++- docs/payroll_au/index.html | 2 +- docs/payroll_nz/index.html | 2 +- docs/payroll_uk/index.html | 2 +- docs/projects/index.html | 2 +- lib/xero-ruby/api/accounting_api.rb | 75 +++++++++++ .../models/accounting/organisation.rb | 5 +- lib/xero-ruby/models/accounting/tax_rate.rb | 11 +- lib/xero-ruby/models/accounting/tax_type.rb | 7 + .../models/finance/statement_response.rb | 24 +++- lib/xero-ruby/version.rb | 4 +- 17 files changed, 326 insertions(+), 22 deletions(-) diff --git a/docs/accounting/AccountingApi.md b/docs/accounting/AccountingApi.md index 0b14036b..89906c91 100644 --- a/docs/accounting/AccountingApi.md +++ b/docs/accounting/AccountingApi.md @@ -127,6 +127,7 @@ Method | HTTP request | Description [**get_item_history**](AccountingApi.md#get_item_history) | **GET** /Items/{ItemID}/History | Retrieves history for a specific item [**get_items**](AccountingApi.md#get_items) | **GET** /Items | Retrieves items [**get_journal**](AccountingApi.md#get_journal) | **GET** /Journals/{JournalID} | Retrieves a specific journal using a unique journal Id. +[**get_journal_by_number**](AccountingApi.md#get_journal_by_number) | **GET** /Journals/{JournalNumber} | Retrieves a specific journal using a unique journal number. [**get_journals**](AccountingApi.md#get_journals) | **GET** /Journals | Retrieves journals [**get_linked_transaction**](AccountingApi.md#get_linked_transaction) | **GET** /LinkedTransactions/{LinkedTransactionID} | Retrieves a specific linked transaction (billable expenses) using a unique linked transaction Id [**get_linked_transactions**](AccountingApi.md#get_linked_transactions) | **GET** /LinkedTransactions | Retrieves linked transactions (billable expenses) @@ -8531,6 +8532,70 @@ Name | Type | Description | Notes - **Accept**: application/json +## get_journal_by_number + +> Journals get_journal_by_number(xero_tenant_id, journal_number) + +Retrieves a specific journal using a unique journal number. + +### Example + +```ruby +# load the gem +require 'xero-ruby' + +creds = { + client_id: ENV['CLIENT_ID'], + client_secret: ENV['CLIENT_SECRET'], + redirect_uri: ENV['REDIRECT_URI'], + scopes: ENV['SCOPES'] +} +xero_client = XeroRuby::ApiClient.new(credentials: creds) + +token_set = fetch_valid_token_set(user) # example + +xero_client.refresh_token_set(token_set) + +# You need to namespace your api method call to one of the following api sets +# [:accounting_api, :assets_api, :projects_api, :files_api, :payroll_au_api, :payroll_nz_api, :payroll_uk_api, :app_store_api] + +api_instance = xero_client. + + + +xero_tenant_id = 'YOUR_XERO_TENANT_ID' # String | Xero identifier for Tenant +journal_number = 1000 # Integer | Number of a Journal +begin + #Retrieves a specific journal using a unique journal number. + result = api_instance.get_journal_by_number(xero_tenant_id, journal_number) + p result +rescue XeroRuby::Accounting::ApiError => e + puts "Exception when calling AccountingApi->get_journal_by_number: #{e}" +end +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **xero_tenant_id** | **String**| Xero identifier for Tenant | + **journal_number** | **Integer**| Number of a Journal | + +### Return type + +[**Journals**](Journals.md) + +### Authorization + +[OAuth2](../README.md#OAuth2) + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + + ## get_journals > Journals get_journals(xero_tenant_id, opts) diff --git a/docs/accounting/index.html b/docs/accounting/index.html index 642544f5..a5886af6 100644 --- a/docs/accounting/index.html +++ b/docs/accounting/index.html @@ -4017,7 +4017,7 @@ "Class" : { "type" : "string", "description" : "Organisation Classes describe which plan the Xero organisation is on (e.g. DEMO, TRIAL, PREMIUM)", - "enum" : [ "DEMO", "TRIAL", "STARTER", "STANDARD", "PREMIUM", "PREMIUM_20", "PREMIUM_50", "PREMIUM_100", "LEDGER", "GST_CASHBOOK", "NON_GST_CASHBOOK" ] + "enum" : [ "DEMO", "TRIAL", "STARTER", "STANDARD", "PREMIUM", "PREMIUM_20", "PREMIUM_50", "PREMIUM_100", "LEDGER", "GST_CASHBOOK", "NON_GST_CASHBOOK", "ULTIMATE" ] }, "Edition" : { "type" : "string", @@ -5560,7 +5560,7 @@ "ReportTaxType" : { "type" : "string", "description" : "See ReportTaxTypes", - "enum" : [ "AVALARA", "BASEXCLUDED", "CAPITALSALESOUTPUT", "CAPITALEXPENSESINPUT", "ECOUTPUT", "ECOUTPUTSERVICES", "ECINPUT", "ECACQUISITIONS", "EXEMPTEXPENSES", "EXEMPTINPUT", "EXEMPTOUTPUT", "GSTONIMPORTS", "INPUT", "INPUTTAXED", "MOSSSALES", "NONE", "NONEOUTPUT", "OUTPUT", "PURCHASESINPUT", "SALESOUTPUT", "EXEMPTCAPITAL", "EXEMPTEXPORT", "CAPITALEXINPUT", "GSTONCAPIMPORTS", "GSTONCAPITALIMPORTS", "REVERSECHARGES", "PAYMENTS", "INVOICE", "CASH", "ACCRUAL", "FLATRATECASH", "FLATRATEACCRUAL", "ACCRUALS", "TXCA", "SRCAS", "DSOUTPUT", "BLINPUT2", "EPINPUT", "IMINPUT2", "MEINPUT", "IGDSINPUT2", "ESN33OUTPUT", "OPINPUT", "OSOUTPUT", "TXN33INPUT", "TXESSINPUT", "TXREINPUT", "TXPETINPUT", "NRINPUT", "ES33OUTPUT", "ZERORATEDINPUT", "ZERORATEDOUTPUT", "DRCHARGESUPPLY", "DRCHARGE", "CAPINPUT", "CAPIMPORTS", "IMINPUT", "INPUT2", "CIUINPUT", "SRINPUT", "OUTPUT2", "SROUTPUT", "CAPOUTPUT", "SROUTPUT2", "CIUOUTPUT", "ZROUTPUT", "ZREXPORT", "ACC28PLUS", "ACCUPTO28", "OTHEROUTPUT", "SHOUTPUT", "ZRINPUT", "BADDEBT", "OTHERINPUT" ] + "enum" : [ "AVALARA", "BASEXCLUDED", "CAPITALSALESOUTPUT", "CAPITALEXPENSESINPUT", "ECOUTPUT", "ECOUTPUTSERVICES", "ECINPUT", "ECACQUISITIONS", "EXEMPTEXPENSES", "EXEMPTINPUT", "EXEMPTOUTPUT", "GSTONIMPORTS", "INPUT", "INPUTTAXED", "MOSSSALES", "NONE", "NONEOUTPUT", "OUTPUT", "PURCHASESINPUT", "SALESOUTPUT", "EXEMPTCAPITAL", "EXEMPTEXPORT", "CAPITALEXINPUT", "GSTONCAPIMPORTS", "GSTONCAPITALIMPORTS", "REVERSECHARGES", "PAYMENTS", "INVOICE", "CASH", "ACCRUAL", "FLATRATECASH", "FLATRATEACCRUAL", "ACCRUALS", "TXCA", "SRCAS", "DSOUTPUT", "BLINPUT2", "EPINPUT", "IMINPUT2", "MEINPUT", "IGDSINPUT2", "ESN33OUTPUT", "OPINPUT", "OSOUTPUT", "TXN33INPUT", "TXESSINPUT", "TXREINPUT", "TXPETINPUT", "NRINPUT", "ES33OUTPUT", "ZERORATEDINPUT", "ZERORATEDOUTPUT", "DRCHARGESUPPLY", "DRCHARGE", "CAPINPUT", "CAPIMPORTS", "IMINPUT", "INPUT2", "CIUINPUT", "SRINPUT", "OUTPUT2", "SROUTPUT", "CAPOUTPUT", "SROUTPUT2", "CIUOUTPUT", "ZROUTPUT", "ZREXPORT", "ACC28PLUS", "ACCUPTO28", "OTHEROUTPUT", "SHOUTPUT", "ZRINPUT", "BADDEBT", "OTHERINPUT", "BADDEBTRELIEF", "IGDSINPUT3", "SROVR", "TOURISTREFUND", "TXRCN33INPUT", "TXRCREINPUT", "TXRCESSINPUT" ] }, "CanApplyToAssets" : { "type" : "boolean", @@ -5625,7 +5625,7 @@ "title" : "", "type" : "string", "description" : "See Tax Types – can only be used on update calls", - "enum" : [ "OUTPUT", "INPUT", "CAPEXINPUT", "EXEMPTEXPORT", "EXEMPTEXPENSES", "EXEMPTCAPITAL", "EXEMPTOUTPUT", "INPUTTAXED", "BASEXCLUDED", "GSTONCAPIMPORTS", "GSTONIMPORTS", "NONE", "INPUT2", "ZERORATED", "OUTPUT2", "CAPEXINPUT2", "CAPEXOUTPUT", "CAPEXOUTPUT2", "CAPEXSRINPUT", "CAPEXSROUTPUT", "ECACQUISITIONS", "ECZRINPUT", "ECZROUTPUT", "ECZROUTPUTSERVICES", "EXEMPTINPUT", "REVERSECHARGES", "RRINPUT", "RROUTPUT", "SRINPUT", "SROUTPUT", "ZERORATEDINPUT", "ZERORATEDOUTPUT", "BLINPUT", "DSOUTPUT", "EPINPUT", "ES33OUTPUT", "ESN33OUTPUT", "IGDSINPUT2", "IMINPUT2", "MEINPUT", "NRINPUT", "OPINPUT", "OSOUTPUT", "TXESSINPUT", "TXN33INPUT", "TXPETINPUT", "TXREINPUT", "INPUT3", "INPUT4", "OUTPUT3", "OUTPUT4", "SROUTPUT2", "TXCA", "SRCAS", "BLINPUT2", "DRCHARGESUPPLY20", "DRCHARGE20", "DRCHARGESUPPLY5", "DRCHARGE5" ] + "enum" : [ "OUTPUT", "INPUT", "CAPEXINPUT", "EXEMPTEXPORT", "EXEMPTEXPENSES", "EXEMPTCAPITAL", "EXEMPTOUTPUT", "INPUTTAXED", "BASEXCLUDED", "GSTONCAPIMPORTS", "GSTONIMPORTS", "NONE", "INPUT2", "ZERORATED", "OUTPUT2", "CAPEXINPUT2", "CAPEXOUTPUT", "CAPEXOUTPUT2", "CAPEXSRINPUT", "CAPEXSROUTPUT", "ECACQUISITIONS", "ECZRINPUT", "ECZROUTPUT", "ECZROUTPUTSERVICES", "EXEMPTINPUT", "REVERSECHARGES", "RRINPUT", "RROUTPUT", "SRINPUT", "SROUTPUT", "ZERORATEDINPUT", "ZERORATEDOUTPUT", "BLINPUT", "DSOUTPUT", "EPINPUT", "ES33OUTPUT", "ESN33OUTPUT", "IGDSINPUT2", "IMINPUT2", "MEINPUT", "NRINPUT", "OPINPUT", "OSOUTPUT", "TXESSINPUT", "TXN33INPUT", "TXPETINPUT", "TXREINPUT", "INPUT3", "INPUT4", "OUTPUT3", "OUTPUT4", "SROUTPUT2", "TXCA", "SRCAS", "BLINPUT2", "DRCHARGESUPPLY20", "DRCHARGE20", "DRCHARGESUPPLY5", "DRCHARGE5", "BADDEBTRELIEF", "IGDSINPUT3", "SROVR", "TOURISTREFUND", "TXRCN33INPUT", "TXRCREINPUT", "TXRCESSINPUT" ] }; defs["TenNinetyNineContact"] = { "title" : "", @@ -6008,7 +6008,7 @@