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 (10.1.0)
xero-ruby (11.0.0)
faraday (>= 2.0, < 3.0)
json (~> 2.1, >= 2.1.0)
json-jwt (~> 1.16, >= 1.16.3)
Expand Down
2 changes: 1 addition & 1 deletion docs/accounting/index.html
Original file line number Diff line number Diff line change
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>10.1.0</li>
<li class="nav-header" data-group="Accounting"><strong>VSN: </strong>11.0.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/index.html
Original file line number Diff line number Diff line change
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>10.1.0</li>
<li class="nav-header" data-group="AppStore"><strong>VSN: </strong>11.0.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>10.1.0</li>
<li class="nav-header" data-group="Asset"><strong>VSN: </strong>11.0.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
2 changes: 1 addition & 1 deletion 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>10.1.0</li>
<li class="nav-header" data-group="Files"><strong>VSN: </strong>11.0.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
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>10.1.0</li>
<li class="nav-header" data-group="Finance"><strong>VSN: </strong>11.0.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>10.1.0</li>
<li class="nav-header" data-group="PayrollAu"><strong>VSN: </strong>11.0.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>10.1.0</li>
<li class="nav-header" data-group="PayrollNz"><strong>VSN: </strong>11.0.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
4 changes: 4 additions & 0 deletions docs/payroll_uk/Employee.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ Name | Type | Description | Notes
**payroll_calendar_id** | **String** | Xero unique identifier for the payroll calendar of the employee | [optional]
**updated_date_utc** | **DateTime** | UTC timestamp of last update to the employee | [optional]
**created_date_utc** | **DateTime** | UTC timestamp when the employee was created in Xero | [optional]
**ni_category** | [**NICategoryLetter**](NICategoryLetter.md) | | [optional]
**ni_categories** | [**Array&lt;NICategory&gt;**](NICategory.md) | The employee&#39;s NI categories | [optional]
**national_insurance_number** | **String** | National insurance number of the employee | [optional]
**is_off_payroll_worker** | **Boolean** | Whether the employee is an off payroll worker | [optional]

Expand All @@ -40,6 +42,8 @@ instance = XeroRuby::PayrollUk::Employee.new(employee_id: d90457c4-f1be-4f2e-b4e
payroll_calendar_id: null,
updated_date_utc: null,
created_date_utc: null,
ni_category: null,
ni_categories: null,
national_insurance_number: AB123456C,
is_off_payroll_worker: null)
```
Expand Down
6 changes: 4 additions & 2 deletions docs/payroll_uk/Employment.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ Name | Type | Description | Notes
**payroll_calendar_id** | **String** | Xero unique identifier for the payroll calendar of the employee | [optional]
**start_date** | **Date** | Start date of the employment (YYYY-MM-DD) | [optional]
**employee_number** | **String** | The employment number of the employee | [optional]
**ni_category** | **String** | The NI Category of the employee | [optional]
**ni_category** | [**NICategoryLetter**](NICategoryLetter.md) | | [optional]
**ni_categories** | [**Array&lt;NICategory&gt;**](NICategory.md) | The employee&#39;s NI categories | [optional]

## Code Sample

Expand All @@ -17,7 +18,8 @@ require 'XeroRuby::PayrollUk'
instance = XeroRuby::PayrollUk::Employment.new(payroll_calendar_id: null,
start_date: null,
employee_number: 7,
ni_category: A)
ni_category: null,
ni_categories: null)
```


25 changes: 25 additions & 0 deletions docs/payroll_uk/NICategory.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# XeroRuby::PayrollUk::NICategory

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**start_date** | **Date** | The start date of the NI category (YYYY-MM-DD) | [optional]
**ni_category** | [**NICategoryLetter**](NICategoryLetter.md) | |
**ni_category_id** | **Float** | Xero unique identifier for the NI category | [optional]
**date_first_employed_as_civilian** | **Date** | The date in which the employee was first employed as a civilian (YYYY-MM-DD) | [optional]
**workplace_postcode** | **String** | The workplace postcode |

## Code Sample

```ruby
require 'XeroRuby::PayrollUk'

instance = XeroRuby::PayrollUk::NICategory.new(start_date: Mon Dec 02 00:00:00 GMT 2024,
ni_category: null,
ni_category_id: 15,
date_first_employed_as_civilian: Mon Dec 02 00:00:00 GMT 2024,
workplace_postcode: SW1A 1AA)
```


16 changes: 16 additions & 0 deletions docs/payroll_uk/NICategoryLetter.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# XeroRuby::PayrollUk::NICategoryLetter

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------

## Code Sample

```ruby
require 'XeroRuby::PayrollUk'

instance = XeroRuby::PayrollUk::NICategoryLetter.new()
```


17 changes: 17 additions & 0 deletions docs/payroll_uk/NICategoryOneOf.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# XeroRuby::PayrollUk::NICategoryOneOf

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**ni_category** | **String** | | [optional]

## Code Sample

```ruby
require 'XeroRuby::PayrollUk'

instance = XeroRuby::PayrollUk::NICategoryOneOf.new(ni_category: null)
```


17 changes: 17 additions & 0 deletions docs/payroll_uk/NICategoryOneOf1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# XeroRuby::PayrollUk::NICategoryOneOf1

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**ni_category** | **String** | | [optional]

## Code Sample

```ruby
require 'XeroRuby::PayrollUk'

instance = XeroRuby::PayrollUk::NICategoryOneOf1.new(ni_category: null)
```


2 changes: 1 addition & 1 deletion docs/payroll_uk/PayrollUkApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -950,7 +950,7 @@ api_instance = xero_client.<api_set>

xero_tenant_id = 'xero_tenant_id_example' # String | Xero identifier for Tenant
employee_id = '4ff1e5cc-9835-40d5-bb18-09fdb118db9c' # String | Employee id for single object
employment = { "PayrollCalendarID": "216d80e6-af55-47b1-b718-9457c3f5d2fe", "StartDate": "2020-04-01", "EmployeeNumber": "123ABC", "NICategory": "A" } # Employment |
employment = { "PayrollCalendarID": "216d80e6-af55-47b1-b718-9457c3f5d2fe", "StartDate": "2020-04-01", "NICategories": [ { "NICategory": "A", "StartDate": "2020-05-01" } ], "EmployeeNumber": "123ABC" } # Employment |
opts = {
idempotency_key: 'KEY_VALUE' # String | This allows you to safely retry requests without the risk of duplicate processing. 128 character max.
}
Expand Down
99 changes: 92 additions & 7 deletions docs/payroll_uk/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1595,6 +1595,16 @@
"format" : "date-time",
"x-is-datetime" : true
},
"niCategory" : {
"$ref" : "#/components/schemas/NICategoryLetter"
},
"niCategories" : {
"type" : "array",
"description" : "The employee's NI categories",
"items" : {
"$ref" : "#/components/schemas/NICategory"
}
},
"nationalInsuranceNumber" : {
"type" : "string",
"description" : "National insurance number of the employee",
Expand Down Expand Up @@ -2262,7 +2272,7 @@
};
defs["Employment"] = {
"title" : "",
"required" : [ "EmployeeNumber", "NICategory", "PayrollCalendarID", "StartDate" ],
"required" : [ "EmployeeNumber", "NICategories", "PayrollCalendarID", "StartDate" ],
"type" : "object",
"properties" : {
"payrollCalendarID" : {
Expand All @@ -2282,10 +2292,14 @@
"example" : "7"
},
"niCategory" : {
"type" : "string",
"description" : "The NI Category of the employee",
"example" : "A",
"enum" : [ "A", "B", "C", "F", "H", "I", "J", "L", "M", "S", "V", "X", "Z" ]
"$ref" : "#/components/schemas/NICategoryLetter"
},
"niCategories" : {
"type" : "array",
"description" : "The employee's NI categories",
"items" : {
"$ref" : "#/components/schemas/NICategory"
}
}
},
"description" : ""
Expand Down Expand Up @@ -2502,6 +2516,75 @@
}
},
"description" : ""
};
defs["NICategory"] = {
"title" : "",
"required" : [ "niCategory", "workplacePostcode" ],
"type" : "object",
"properties" : {
"startDate" : {
"type" : "string",
"description" : "The start date of the NI category (YYYY-MM-DD)",
"format" : "date",
"example" : "2024-12-02",
"x-is-date" : true
},
"niCategory" : {
"$ref" : "#/components/schemas/NICategoryLetter"
},
"niCategoryID" : {
"type" : "number",
"description" : "Xero unique identifier for the NI category",
"example" : 15
},
"dateFirstEmployedAsCivilian" : {
"type" : "string",
"description" : "The date in which the employee was first employed as a civilian (YYYY-MM-DD)",
"format" : "date",
"example" : "2024-12-02",
"x-is-date" : true
},
"workplacePostcode" : {
"type" : "string",
"description" : "The workplace postcode",
"example" : "SW1A 1AA"
}
},
"description" : "",
"oneOf" : [ {
"$ref" : "#/components/schemas/NICategory_oneOf"
}, {
"$ref" : "#/components/schemas/NICategory_oneOf_1"
} ]
};
defs["NICategoryLetter"] = {
"title" : "",
"type" : "string",
"description" : "The employee's NI Category letter.",
"example" : "I",
"enum" : [ "A", "B", "C", "D", "E", "F", "H", "I", "J", "K", "L", "M", "N", "S", "V", "X", "Z" ]
};
defs["NICategory_oneOf"] = {
"title" : "",
"required" : [ "workplacePostcode" ],
"properties" : {
"niCategory" : {
"type" : "string",
"enum" : [ "F", "I", "L", "S", "N", "E", "D", "K" ]
}
},
"description" : ""
};
defs["NICategory_oneOf_1"] = {
"title" : "",
"required" : [ "dateFirstEmployedAsCivilian" ],
"properties" : {
"niCategory" : {
"type" : "string",
"enum" : [ "V" ]
}
},
"description" : ""
};
defs["Pagination"] = {
"title" : "",
Expand Down Expand Up @@ -3517,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>10.1.0</li>
<li class="nav-header" data-group="PayrollUk"><strong>VSN: </strong>11.0.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 Expand Up @@ -5714,6 +5797,8 @@ <h3>Usage and SDK Samples</h3>
start_date: start_date
}

ni_categories = {

begin
response = xero_client.accounting_api.create_employment(xero_tenant_id, employee_id, employment, idempotency_key)
return response
Expand Down Expand Up @@ -5845,7 +5930,7 @@ <h2>Parameters</h2>
"schema" : {
"$ref" : "#/components/schemas/Employment"
},
"example" : "{ \"PayrollCalendarID\": \"216d80e6-af55-47b1-b718-9457c3f5d2fe\", \"StartDate\": \"2020-04-01\", \"EmployeeNumber\": \"123ABC\", \"NICategory\": \"A\" }"
"example" : "{ \"PayrollCalendarID\": \"216d80e6-af55-47b1-b718-9457c3f5d2fe\", \"StartDate\": \"2020-04-01\", \"NICategories\": [ { \"NICategory\": \"A\", \"StartDate\": \"2020-05-01\" } ], \"EmployeeNumber\": \"123ABC\" }"
}
},
"required" : true
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>10.1.0</li>
<li class="nav-header" data-group="Project"><strong>VSN: </strong>11.0.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
4 changes: 4 additions & 0 deletions lib/xero-ruby.rb
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,10 @@
require 'xero-ruby/models/payroll_uk/leave_type'
require 'xero-ruby/models/payroll_uk/leave_type_object'
require 'xero-ruby/models/payroll_uk/leave_types'
require 'xero-ruby/models/payroll_uk/ni_category'
require 'xero-ruby/models/payroll_uk/ni_category_letter'
require 'xero-ruby/models/payroll_uk/ni_category_one_of'
require 'xero-ruby/models/payroll_uk/ni_category_one_of1'
require 'xero-ruby/models/payroll_uk/pagination'
require 'xero-ruby/models/payroll_uk/pay_run'
require 'xero-ruby/models/payroll_uk/pay_run_calendar'
Expand Down
Loading