Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
xero-ruby (11.2.0)
xero-ruby (11.3.0)
faraday (>= 2.0, < 3.0)
json (~> 2.1, >= 2.1.0)
json-jwt (~> 1.16, >= 1.16.3)
Expand Down
4 changes: 2 additions & 2 deletions docs/accounting/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -6220,7 +6220,7 @@
"OrganisationRole" : {
"type" : "string",
"description" : "User role that defines permissions in Xero and via API (READONLY, INVOICEONLY, STANDARD, FINANCIALADVISER, etc)",
"enum" : [ "READONLY", "INVOICEONLY", "STANDARD", "FINANCIALADVISER", "MANAGEDCLIENT", "CASHBOOKCLIENT", "UNKNOWN" ]
"enum" : [ "READONLY", "INVOICEONLY", "STANDARD", "FINANCIALADVISER", "MANAGEDCLIENT", "CASHBOOKCLIENT", "UNKNOWN", "REMOVED" ]
}
},
"description" : "",
Expand Down Expand Up @@ -6339,7 +6339,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Accounting"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Accounting"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="Accounting"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="Accounting"><a href="#api-Accounting">Methods</a></li>
<li data-group="Accounting" data-name="createAccount" class="">
<a href="#api-Accounting-createAccount">createAccount</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/app_store/Product.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Name | Type | Description | Notes
**id** | **String** | The unique identifier for the product | [optional]
**name** | **String** | The name of the product | [optional]
**seat_unit** | **String** | The unit of the per seat product. e.g. \&quot;user\&quot;, \&quot;organisation\&quot;, \&quot;SMS\&quot;, etc | [optional]
**type** | **String** | The pricing model of the product: * FIXED: Customers are charged a fixed amount for each billing period * PER_SEAT: Customers are charged based on the number of units they purchase * METERED: Customers are charged per use of this product | [optional]
**type** | **String** | The pricing model of the product: * FIXED: Customers are charged a fixed amount for each billing period * PER_SEAT: Customers are charged based on the number of units they purchase * METERED: Customers are charged per use of this product * SIMPLE: Customers are charged on a fixed amount for each billing period with an optional add-on feature | [optional]
**usage_unit** | **String** | The unit of the usage product. e.g. \&quot;user\&quot;, \&quot;minutes\&quot;, \&quot;SMS\&quot;, etc | [optional]

## Code Sample
Expand Down
6 changes: 3 additions & 3 deletions docs/app_store/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -976,8 +976,8 @@
},
"type" : {
"type" : "string",
"description" : "The pricing model of the product:\n* FIXED: Customers are charged a fixed amount for each billing period\n* PER_SEAT: Customers are charged based on the number of units they purchase\n* METERED: Customers are charged per use of this product\n",
"enum" : [ "FIXED", "PER_SEAT", "METERED" ]
"description" : "The pricing model of the product:\n* FIXED: Customers are charged a fixed amount for each billing period\n* PER_SEAT: Customers are charged based on the number of units they purchase\n* METERED: Customers are charged per use of this product\n* SIMPLE: Customers are charged on a fixed amount for each billing period with an optional add-on feature\n",
"enum" : [ "FIXED", "PER_SEAT", "METERED", "SIMPLE" ]
},
"usageUnit" : {
"type" : "string",
Expand Down Expand Up @@ -1241,7 +1241,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="AppStore"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="AppStore"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="AppStore"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="AppStore"><a href="#api-AppStore">Methods</a></li>
<li data-group="AppStore" data-name="getSubscription" class="">
<a href="#api-AppStore-getSubscription">getSubscription</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/assets/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1392,7 +1392,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Asset"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Asset"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="Asset"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="Asset"><a href="#api-Asset">Methods</a></li>
<li data-group="Asset" data-name="createAsset" class="">
<a href="#api-Asset-createAsset">createAsset</a>
Expand Down
5 changes: 4 additions & 1 deletion docs/files/FilesApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -745,7 +745,9 @@ opts = {

page: 2, # Integer | number of records to skip for pagination

sort: 'CreatedDateUTC DESC' # String | values to sort by
sort: 'CreatedDateUTC', # String | values to sort by

direction: 'ASC' # String | sort direction
}

begin
Expand All @@ -766,6 +768,7 @@ Name | Type | Description | Notes
**pagesize** | **Integer**| pass an optional page size value | [optional]
**page** | **Integer**| number of records to skip for pagination | [optional]
**sort** | **String**| values to sort by | [optional]
**direction** | **String**| sort direction | [optional]

### Return type

Expand Down
27 changes: 24 additions & 3 deletions docs/files/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1170,7 +1170,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Files"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Files"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="Files"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="Files"><a href="#api-Files">Methods</a></li>
<li data-group="Files" data-name="createFileAssociation" class="">
<a href="#api-Files-createFileAssociation">createFileAssociation</a>
Expand Down Expand Up @@ -2625,10 +2625,11 @@ <h3>Usage and SDK Samples</h3>
xero_tenant_id = 'YOUR_XERO_TENANT_ID'
pagesize = 50
page = 2
sort = 'CreatedDateUTC DESC'
sort = 'CreatedDateUTC'
direction = 'ASC'

begin
response = xero_client.accounting_api.get_files(xero_tenant_id, pagesize, page, sort)
response = xero_client.accounting_api.get_files(xero_tenant_id, pagesize, page, sort, direction)
return response
rescue XeroRuby::ApiError => e
puts "Exception when calling get_files: #{e}"
Expand Down Expand Up @@ -2745,6 +2746,26 @@ <h2>Parameters</h2>
</div>
</div>
</td>
</tr>

<tr><td style="width:150px;">direction</td>
<td>


<div id="d2e199_getFiles_direction">
<div class="json-schema-view">
<div class="primitive">
<span class="type">
String
</span>

<div class="inner description marked">
sort direction
</div>
</div>
</div>
</div>
</td>
</tr>

</table>
Expand Down
2 changes: 1 addition & 1 deletion docs/finance/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2716,7 +2716,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Finance"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Finance"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="Finance"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="Finance"><a href="#api-Finance">Methods</a></li>
<li data-group="Finance" data-name="getAccountingActivityAccountUsage" class="">
<a href="#api-Finance-getAccountingActivityAccountUsage">getAccountingActivityAccountUsage</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/payroll_au/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3412,7 +3412,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="PayrollAu"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="PayrollAu"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="PayrollAu"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="PayrollAu"><a href="#api-PayrollAu">Methods</a></li>
<li data-group="PayrollAu" data-name="approveLeaveApplication" class="">
<a href="#api-PayrollAu-approveLeaveApplication">approveLeaveApplication</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/payroll_nz/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4087,7 +4087,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="PayrollNz"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="PayrollNz"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="PayrollNz"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="PayrollNz"><a href="#api-PayrollNz">Methods</a></li>
<li data-group="PayrollNz" data-name="approveTimesheet" class="">
<a href="#api-PayrollNz-approveTimesheet">approveTimesheet</a>
Expand Down
6 changes: 3 additions & 3 deletions docs/payroll_uk/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1954,7 +1954,7 @@
"leaveType" : {
"type" : "string",
"description" : "The type of statutory leave",
"enum" : [ "Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement" ]
"enum" : [ "Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement", "NeonatalCare" ]
},
"balanceRemaining" : {
"type" : "number",
Expand Down Expand Up @@ -2002,7 +2002,7 @@
"type" : {
"type" : "string",
"description" : "The category of statutory leave",
"enum" : [ "Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement" ]
"enum" : [ "Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement", "NeonatalCare" ]
},
"startDate" : {
"type" : "string",
Expand Down Expand Up @@ -3600,7 +3600,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="PayrollUk"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="PayrollUk"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="PayrollUk"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="PayrollUk"><a href="#api-PayrollUk">Methods</a></li>
<li data-group="PayrollUk" data-name="approveTimesheet" class="">
<a href="#api-PayrollUk-approveTimesheet">approveTimesheet</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/projects/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1462,7 +1462,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Project"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Project"><strong>VSN: </strong>11.2.0</li>
<li class="nav-header" data-group="Project"><strong>VSN: </strong>11.3.0</li>
<li class="nav-header" data-group="Project"><a href="#api-Project">Methods</a></li>
<li data-group="Project" data-name="createProject" class="">
<a href="#api-Project-createProject">createProject</a>
Expand Down
7 changes: 7 additions & 0 deletions lib/xero-ruby/api/files_api.rb
Original file line number Diff line number Diff line change
Expand Up @@ -835,6 +835,7 @@ def get_file_content_with_http_info(xero_tenant_id, file_id, options = {})
# @option opts [Integer] :pagesize pass an optional page size value
# @option opts [Integer] :page number of records to skip for pagination
# @option opts [String] :sort values to sort by
# @option opts [String] :direction sort direction
# @return [Files]
def get_files(xero_tenant_id, opts = {})
data, _status_code, _headers = get_files_with_http_info(xero_tenant_id, opts)
Expand All @@ -847,6 +848,7 @@ def get_files(xero_tenant_id, opts = {})
# @option opts [Integer] :pagesize pass an optional page size value
# @option opts [Integer] :page number of records to skip for pagination
# @option opts [String] :sort values to sort by
# @option opts [String] :direction sort direction
# @return [Array<(Files, Integer, Hash)>] Files data, response status code and response headers
def get_files_with_http_info(xero_tenant_id, options = {})
opts = options.dup
Expand All @@ -869,6 +871,10 @@ def get_files_with_http_info(xero_tenant_id, options = {})
if @api_client.config.client_side_validation && opts[:'sort'] && !allowable_values.include?(opts[:'sort'])
fail ArgumentError, "invalid value for \"sort\", must be one of #{allowable_values}"
end
allowable_values = ["ASC", "DESC"]
if @api_client.config.client_side_validation && opts[:'direction'] && !allowable_values.include?(opts[:'direction'])
fail ArgumentError, "invalid value for \"direction\", must be one of #{allowable_values}"
end
# resource path
local_var_path = '/Files'

Expand All @@ -880,6 +886,7 @@ def get_files_with_http_info(xero_tenant_id, options = {})
query_params[:'pagesize'] = opts[:'pagesize'] if !opts[:'pagesize'].nil?
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
query_params[:'direction'] = opts[:'direction'] if !opts[:'direction'].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?
Expand Down
5 changes: 3 additions & 2 deletions lib/xero-ruby/models/accounting/user.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ class User
MANAGEDCLIENT ||= "MANAGEDCLIENT".freeze
CASHBOOKCLIENT ||= "CASHBOOKCLIENT".freeze
UNKNOWN ||= "UNKNOWN".freeze
REMOVED ||= "REMOVED".freeze

class EnumAttributeValidator
attr_reader :datatype
Expand Down Expand Up @@ -146,15 +147,15 @@ def list_invalid_properties
# Check to see if the all the properties in the model are valid
# @return true if the model is valid
def valid?
organisation_role_validator = EnumAttributeValidator.new('String', ["READONLY", "INVOICEONLY", "STANDARD", "FINANCIALADVISER", "MANAGEDCLIENT", "CASHBOOKCLIENT", "UNKNOWN"])
organisation_role_validator = EnumAttributeValidator.new('String', ["READONLY", "INVOICEONLY", "STANDARD", "FINANCIALADVISER", "MANAGEDCLIENT", "CASHBOOKCLIENT", "UNKNOWN", "REMOVED"])
return false unless organisation_role_validator.valid?(@organisation_role)
true
end

# Custom attribute writer method checking allowed values (enum).
# @param [Object] organisation_role Object to be assigned
def organisation_role=(organisation_role)
validator = EnumAttributeValidator.new('String', ["READONLY", "INVOICEONLY", "STANDARD", "FINANCIALADVISER", "MANAGEDCLIENT", "CASHBOOKCLIENT", "UNKNOWN"])
validator = EnumAttributeValidator.new('String', ["READONLY", "INVOICEONLY", "STANDARD", "FINANCIALADVISER", "MANAGEDCLIENT", "CASHBOOKCLIENT", "UNKNOWN", "REMOVED"])
unless validator.valid?(organisation_role)
fail ArgumentError, "invalid value for \"organisation_role\", must be one of #{validator.allowable_values}."
end
Expand Down
7 changes: 4 additions & 3 deletions lib/xero-ruby/models/app_store/product.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,12 @@ class Product
# The unit of the per seat product. e.g. \"user\", \"organisation\", \"SMS\", etc
attr_accessor :seat_unit

# The pricing model of the product: * FIXED: Customers are charged a fixed amount for each billing period * PER_SEAT: Customers are charged based on the number of units they purchase * METERED: Customers are charged per use of this product
# The pricing model of the product: * FIXED: Customers are charged a fixed amount for each billing period * PER_SEAT: Customers are charged based on the number of units they purchase * METERED: Customers are charged per use of this product * SIMPLE: Customers are charged on a fixed amount for each billing period with an optional add-on feature
attr_accessor :type
FIXED ||= "FIXED".freeze
PER_SEAT ||= "PER_SEAT".freeze
METERED ||= "METERED".freeze
SIMPLE ||= "SIMPLE".freeze

# The unit of the usage product. e.g. \"user\", \"minutes\", \"SMS\", etc
attr_accessor :usage_unit
Expand Down Expand Up @@ -124,15 +125,15 @@ def list_invalid_properties
# Check to see if the all the properties in the model are valid
# @return true if the model is valid
def valid?
type_validator = EnumAttributeValidator.new('String', ["FIXED", "PER_SEAT", "METERED"])
type_validator = EnumAttributeValidator.new('String', ["FIXED", "PER_SEAT", "METERED", "SIMPLE"])
return false unless type_validator.valid?(@type)
true
end

# Custom attribute writer method checking allowed values (enum).
# @param [Object] type Object to be assigned
def type=(type)
validator = EnumAttributeValidator.new('String', ["FIXED", "PER_SEAT", "METERED"])
validator = EnumAttributeValidator.new('String', ["FIXED", "PER_SEAT", "METERED", "SIMPLE"])
unless validator.valid?(type)
fail ArgumentError, "invalid value for \"type\", must be one of #{validator.allowable_values}."
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ class EmployeeStatutoryLeaveBalance
PATERNITY ||= "Paternity".freeze
SHAREDPARENTAL ||= "Sharedparental".freeze
BEREAVEMENT ||= "Bereavement".freeze
NEONATAL_CARE ||= "NeonatalCare".freeze

# The balance remaining for the corresponding leave type as of specified date.
attr_accessor :balance_remaining
Expand Down Expand Up @@ -110,7 +111,7 @@ def list_invalid_properties
# Check to see if the all the properties in the model are valid
# @return true if the model is valid
def valid?
leave_type_validator = EnumAttributeValidator.new('String', ["Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement"])
leave_type_validator = EnumAttributeValidator.new('String', ["Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement", "NeonatalCare"])
return false unless leave_type_validator.valid?(@leave_type)
units_validator = EnumAttributeValidator.new('String', ["Hours"])
return false unless units_validator.valid?(@units)
Expand All @@ -120,7 +121,7 @@ def valid?
# Custom attribute writer method checking allowed values (enum).
# @param [Object] leave_type Object to be assigned
def leave_type=(leave_type)
validator = EnumAttributeValidator.new('String', ["Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement"])
validator = EnumAttributeValidator.new('String', ["Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement", "NeonatalCare"])
unless validator.valid?(leave_type)
fail ArgumentError, "invalid value for \"leave_type\", must be one of #{validator.allowable_values}."
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ class EmployeeStatutoryLeaveSummary
PATERNITY ||= "Paternity".freeze
SHAREDPARENTAL ||= "Sharedparental".freeze
BEREAVEMENT ||= "Bereavement".freeze
NEONATAL_CARE ||= "NeonatalCare".freeze

# The date when the leave starts
attr_accessor :start_date
Expand Down Expand Up @@ -148,7 +149,7 @@ def list_invalid_properties
# Check to see if the all the properties in the model are valid
# @return true if the model is valid
def valid?
type_validator = EnumAttributeValidator.new('String', ["Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement"])
type_validator = EnumAttributeValidator.new('String', ["Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement", "NeonatalCare"])
return false unless type_validator.valid?(@type)
status_validator = EnumAttributeValidator.new('String', ["Pending", "In-Progress", "Completed"])
return false unless status_validator.valid?(@status)
Expand All @@ -158,7 +159,7 @@ def valid?
# Custom attribute writer method checking allowed values (enum).
# @param [Object] type Object to be assigned
def type=(type)
validator = EnumAttributeValidator.new('String', ["Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement"])
validator = EnumAttributeValidator.new('String', ["Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement", "NeonatalCare"])
unless validator.valid?(type)
fail ArgumentError, "invalid value for \"type\", must be one of #{validator.allowable_values}."
end
Expand Down
Loading