Skip to content

Commit

Permalink
Merge pull request #96 from XeroAPI/regen_260
Browse files Browse the repository at this point in the history
2.4.0
  • Loading branch information
SerKnight authored Dec 5, 2020
2 parents f1e8e22 + 1176825 commit c09d240
Show file tree
Hide file tree
Showing 465 changed files with 2,834 additions and 687 deletions.
69 changes: 67 additions & 2 deletions docs/accounting/AccountingApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,7 @@ Method | HTTP request | Description
[**get_tracking_category**](AccountingApi.md#get_tracking_category) | **GET** /TrackingCategories/{TrackingCategoryID} | Allows you to retrieve tracking categories and options for specified category
[**get_user**](AccountingApi.md#get_user) | **GET** /Users/{UserID} | Allows you to retrieve a specified user
[**get_users**](AccountingApi.md#get_users) | **GET** /Users | Allows you to retrieve users
[**post_setup**](AccountingApi.md#post_setup) | **POST** /Setup | Allows you to set the chart of accounts, the conversion date and conversion balances
[**update_account**](AccountingApi.md#update_account) | **POST** /Accounts/{AccountID} | Allows you to update a chart of accounts
[**update_account_attachment_by_file_name**](AccountingApi.md#update_account_attachment_by_file_name) | **POST** /Accounts/{AccountID}/Attachments/{FileName} | Allows you to update Attachment on Account by Filename
[**update_bank_transaction**](AccountingApi.md#update_bank_transaction) | **POST** /BankTransactions/{BankTransactionID} | Allows you to update a single spend or receive money transaction
Expand Down Expand Up @@ -12007,7 +12008,7 @@ api_instance = xero_client.<api_set>

xero_tenant_id = 'YOUR_XERO_TENANT_ID' # String | Xero identifier for Tenant
opts = {
date: '2019-11-01', # String | The date of the Balance Sheet report
date: Date.parse('2019-11-01'), # Date | The date of the Balance Sheet report

periods: 3, # Integer | The number of periods for the Balance Sheet report

Expand Down Expand Up @@ -12037,7 +12038,7 @@ end
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**xero_tenant_id** | **String**| Xero identifier for Tenant |
**date** | **String**| The date of the Balance Sheet report | [optional]
**date** | **Date**| The date of the Balance Sheet report | [optional]
**periods** | **Integer**| The number of periods for the Balance Sheet report | [optional]
**timeframe** | **String**| The period size to compare to (MONTH, QUARTER, YEAR) | [optional]
**tracking_option_id1** | **String**| The tracking option 1 for the Balance Sheet report | [optional]
Expand Down Expand Up @@ -12847,6 +12848,70 @@ Name | Type | Description | Notes
- **Accept**: application/json


## post_setup

> ImportSummaryObject post_setup(xero_tenant_id, setup)
Allows you to set the chart of accounts, the conversion date and conversion balances

### 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]

api_instance = xero_client.<api_set>



xero_tenant_id = 'YOUR_XERO_TENANT_ID' # String | Xero identifier for Tenant
setup = { "ConversionDate": {}, "ConversionBalances": [], "Accounts": [ { "Code": "200", "Name": "Sales", "Type": "SALES", "ReportingCode": "REV.TRA.GOO" }, { "Code": "400", "Name": "Advertising", "Type": "OVERHEADS", "ReportingCode": "EXP" }, { "Code": "610", "Name": "Accounts Receivable", "Type": "CURRENT", "SystemAccount": "DEBTORS", "ReportingCode": "ASS.CUR.REC.TRA" }, { "Code": "800", "Name": "Accounts Payable", "Type": "CURRLIAB", "SystemAccount": "CREDITORS", "ReportingCode": "LIA.CUR.PAY" } ] } # Setup | Object including an accounts array, a conversion balances array and a conversion date object in body of request
begin
#Allows you to set the chart of accounts, the conversion date and conversion balances
result = api_instance.post_setup(xero_tenant_id, setup)
p result
rescue XeroRuby::Accounting::ApiError => e
puts "Exception when calling AccountingApi->post_setup: #{e}"
end
```

### Parameters


Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**xero_tenant_id** | **String**| Xero identifier for Tenant |
**setup** | [**Setup**](Setup.md)| Object including an accounts array, a conversion balances array and a conversion date object in body of request |

### Return type

[**ImportSummaryObject**](ImportSummaryObject.md)

### Authorization

[OAuth2](../README.md#OAuth2)

### HTTP request headers

- **Content-Type**: application/json
- **Accept**: application/json


## update_account

> Accounts update_account(xero_tenant_id, account_id, accounts)
Expand Down
21 changes: 21 additions & 0 deletions docs/accounting/BalanceDetails.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# XeroRuby::Accounting::BalanceDetails

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**balance** | **Float** | The opening balances of the account. Debits are positive, credits are negative values | [optional]
**currency_code** | **String** | The currency of the balance (Not required for base currency) | [optional]
**currency_rate** | **BigDecimal** | (Optional) Exchange rate to base currency when money is spent or received. If not specified, XE rate for the day is applied | [optional]

## Code Sample

```ruby
require 'XeroRuby::Accounting'

instance = XeroRuby::Accounting::BalanceDetails.new(balance: null,
currency_code: null,
currency_rate: null)
```


21 changes: 21 additions & 0 deletions docs/accounting/ConversionBalances.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# XeroRuby::Accounting::ConversionBalances

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**account_code** | **String** | The account code for a account | [optional]
**balance** | **Float** | The opening balances of the account. Debits are positive, credits are negative values | [optional]
**balance_details** | [**Array&lt;BalanceDetails&gt;**](BalanceDetails.md) | | [optional]

## Code Sample

```ruby
require 'XeroRuby::Accounting'

instance = XeroRuby::Accounting::ConversionBalances.new(account_code: null,
balance: null,
balance_details: null)
```


19 changes: 19 additions & 0 deletions docs/accounting/ConversionDate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# XeroRuby::Accounting::ConversionDate

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**month** | **Integer** | The month the organisation starts using Xero. Value is an integer between 1 and 12 | [optional]
**year** | **Integer** | The year the organisation starts using Xero. Value is an integer greater than 2006 | [optional]

## Code Sample

```ruby
require 'XeroRuby::Accounting'

instance = XeroRuby::Accounting::ConversionDate.new(month: 1,
year: 2020)
```


2 changes: 2 additions & 0 deletions docs/accounting/CreditNote.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Name | Type | Description | Notes
**type** | **String** | See Credit Note Types | [optional]
**contact** | [**Contact**](Contact.md) | | [optional]
**date** | **Date** | The date the credit note is issued YYYY-MM-DD. If the Date element is not specified then it will default to the current date based on the timezone setting of the organisation | [optional]
**due_date** | **Date** | Date invoice is due – YYYY-MM-DD | [optional]
**status** | **String** | See Credit Note Status Codes | [optional]
**line_amount_types** | [**LineAmountTypes**](LineAmountTypes.md) | | [optional]
**line_items** | [**Array&lt;LineItem&gt;**](LineItem.md) | See Invoice Line Items | [optional]
Expand Down Expand Up @@ -39,6 +40,7 @@ require 'XeroRuby::Accounting'
instance = XeroRuby::Accounting::CreditNote.new(type: null,
contact: null,
date: null,
due_date: null,
status: null,
line_amount_types: null,
line_items: null,
Expand Down
19 changes: 19 additions & 0 deletions docs/accounting/ImportSummary.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# XeroRuby::Accounting::ImportSummary

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**accounts** | [**ImportSummaryAccounts**](ImportSummaryAccounts.md) | | [optional]
**organisation** | [**ImportSummaryOrganisation**](ImportSummaryOrganisation.md) | | [optional]

## Code Sample

```ruby
require 'XeroRuby::Accounting'

instance = XeroRuby::Accounting::ImportSummary.new(accounts: null,
organisation: null)
```


33 changes: 33 additions & 0 deletions docs/accounting/ImportSummaryAccounts.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# XeroRuby::Accounting::ImportSummaryAccounts

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**total** | **Float** | The total number of accounts in the org | [optional]
**new** | **Float** | The number of new accounts created | [optional]
**updated** | **Float** | The number of accounts updated | [optional]
**deleted** | **Float** | The number of accounts deleted | [optional]
**locked** | **Float** | The number of locked accounts | [optional]
**system** | **Float** | The number of system accounts | [optional]
**errored** | **Float** | The number of accounts that had an error | [optional]
**present** | **Boolean** | | [optional]
**new_or_updated** | **Float** | The number of new or updated accounts | [optional]

## Code Sample

```ruby
require 'XeroRuby::Accounting'

instance = XeroRuby::Accounting::ImportSummaryAccounts.new(total: null,
new: null,
updated: null,
deleted: null,
locked: null,
system: null,
errored: null,
present: null,
new_or_updated: null)
```


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

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**import_summary** | [**ImportSummary**](ImportSummary.md) | | [optional]

## Code Sample

```ruby
require 'XeroRuby::Accounting'

instance = XeroRuby::Accounting::ImportSummaryObject.new(import_summary: null)
```


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

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**present** | **Boolean** | | [optional]

## Code Sample

```ruby
require 'XeroRuby::Accounting'

instance = XeroRuby::Accounting::ImportSummaryOrganisation.new(present: null)
```


21 changes: 21 additions & 0 deletions docs/accounting/Setup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# XeroRuby::Accounting::Setup

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**conversion_date** | [**ConversionDate**](ConversionDate.md) | | [optional]
**conversion_balances** | [**Array&lt;ConversionBalances&gt;**](ConversionBalances.md) | Balance supplied for each account that has a value as at the conversion date. | [optional]
**accounts** | [**Array&lt;Account&gt;**](Account.md) | | [optional]

## Code Sample

```ruby
require 'XeroRuby::Accounting'

instance = XeroRuby::Accounting::Setup.new(conversion_date: null,
conversion_balances: null,
accounts: null)
```


2 changes: 2 additions & 0 deletions docs/assets/Asset.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Name | Type | Description | Notes
**asset_number** | **String** | Must be unique. | [optional]
**purchase_date** | **Date** | The date the asset was purchased YYYY-MM-DD | [optional]
**purchase_price** | **BigDecimal** | The purchase price of the asset | [optional]
**disposal_date** | **Date** | The date the asset was disposed | [optional]
**disposal_price** | **BigDecimal** | The price the asset was disposed at | [optional]
**asset_status** | [**AssetStatus**](AssetStatus.md) | | [optional]
**warranty_expiry_date** | **String** | The date the asset’s warranty expires (if needed) YYYY-MM-DD | [optional]
Expand All @@ -31,6 +32,7 @@ instance = XeroRuby::Assets::Asset.new(asset_id: 3b5b3a38-5649-495f-87a1-14a4e59
asset_number: FA-0013,
purchase_date: null,
purchase_price: 1000.0000,
disposal_date: null,
disposal_price: 1.0000,
asset_status: null,
warranty_expiry_date: ca4c6b39-4f4f-43e8-98da-5e1f350a6694,
Expand Down
18 changes: 9 additions & 9 deletions docs/files/FileObject.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **String** | TODO | [optional]
**mime_type** | **String** | TODO | [optional]
**size** | **Integer** | TODO | [optional]
**created_date_utc** | **DateTime** | TODO | [optional]
**updated_date_utc** | **DateTime** | TODO | [optional]
**name** | **String** | File Name | [optional]
**mime_type** | **String** | MimeType of the file (image/png, image/jpeg, application/pdf, etc..) | [optional]
**size** | **Integer** | Numeric value in bytes | [optional]
**created_date_utc** | **String** | Created date in UTC | [optional]
**updated_date_utc** | **String** | Updated date in UTC | [optional]
**user** | [**User**](User.md) | | [optional]
**id** | **String** | TODO | [optional]
**folder_id** | **String** | TODO | [optional]
**id** | **String** | File object&#39;s UUID | [optional]
**folder_id** | **String** | Folder relation object&#39;s UUID | [optional]

## Code Sample

Expand All @@ -21,8 +21,8 @@ require 'XeroRuby::Files'
instance = XeroRuby::Files::FileObject.new(name: File2.jpg,
mime_type: image/jpeg,
size: 3615,
created_date_utc: null,
updated_date_utc: null,
created_date_utc: 2020-12-03T19:04:58.6970000,
updated_date_utc: 2020-12-03T19:04:58.6970000,
user: null,
id: d290f1ee-6c54-4b01-90e6-d701748f0851,
folder_id: 0f8ccf21-7267-4268-9167-a1e2c40c84c8)
Expand Down
20 changes: 8 additions & 12 deletions docs/files/User.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,26 +4,22 @@

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**user_id** | **String** | Xero identifier | [optional]
**email_address** | **String** | Email address of user | [optional]
**first_name** | **String** | First name of user |
**last_name** | **String** | Last name of user |
**updated_date_utc** | **DateTime** | Last name of user | [optional]
**is_subscriber** | **Boolean** | Boolean to indicate if user is the subscriber | [optional]
**organisation_role** | **String** | Boolean to indicate if user is the subscriber | [optional]
**id** | **String** | Xero identifier |
**name** | **String** | Key is Name, but returns Email address of user who created the file | [optional]
**first_name** | **String** | First name of user | [optional]
**last_name** | **String** | Last name of user | [optional]
**full_name** | **String** | Last name of user | [optional]

## Code Sample

```ruby
require 'XeroRuby::Files'

instance = XeroRuby::Files::User.new(user_id: 4ff1e5cc-9835-40d5-bb18-09fdb118db9c,
email_address: john.smith@mail.com,
instance = XeroRuby::Files::User.new(id: 4ff1e5cc-9835-40d5-bb18-09fdb118db9c,
name: john.smith@mail.com,
first_name: John,
last_name: Smith,
updated_date_utc: null,
is_subscriber: true,
organisation_role: STANDARD)
full_name: Smith)
```


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

## Properties

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

## Code Sample

```ruby
require 'XeroRuby::PayrollNz'

instance = XeroRuby::PayrollNz::CalendarType.new()
```


2 changes: 1 addition & 1 deletion docs/payroll_nz/PayRun.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Name | Type | Description | Notes
**total_pay** | **BigDecimal** | Total pay of the pay run | [optional]
**pay_run_status** | **String** | Pay run status | [optional]
**pay_run_type** | **String** | Pay run type | [optional]
**calendar_type** | **String** | Calendar type of the pay run | [optional]
**calendar_type** | [**CalendarType**](CalendarType.md) | | [optional]
**posted_date_time** | **Date** | Posted date time of the pay run | [optional]
**pay_slips** | [**Array&lt;PaySlip&gt;**](PaySlip.md) | | [optional]

Expand Down
Loading

0 comments on commit c09d240

Please sign in to comment.