diff --git a/docs/accounting/AccountingApi.md b/docs/accounting/AccountingApi.md index e5f17099..255e8e89 100644 --- a/docs/accounting/AccountingApi.md +++ b/docs/accounting/AccountingApi.md @@ -25,7 +25,6 @@ Method | HTTP request | Description [**create_credit_note_history**](AccountingApi.md#create_credit_note_history) | **PUT** /CreditNotes/{CreditNoteID}/History | Retrieves history records of a specific credit note [**create_credit_notes**](AccountingApi.md#create_credit_notes) | **PUT** /CreditNotes | Creates a new credit note [**create_currency**](AccountingApi.md#create_currency) | **PUT** /Currencies | Create a new currency for a Xero organisation -[**create_employees**](AccountingApi.md#create_employees) | **PUT** /Employees | Creates new employees used in Xero payrun [**create_expense_claim_history**](AccountingApi.md#create_expense_claim_history) | **PUT** /ExpenseClaims/{ExpenseClaimID}/History | Creates a history record for a specific expense claim [**create_expense_claims**](AccountingApi.md#create_expense_claims) | **PUT** /ExpenseClaims | Creates expense claims [**create_invoice_attachment_by_file_name**](AccountingApi.md#create_invoice_attachment_by_file_name) | **PUT** /Invoices/{InvoiceID}/Attachments/{FileName} | Creates an attachment for a specific invoice or purchase bill by filename @@ -117,8 +116,6 @@ Method | HTTP request | Description [**get_credit_note_history**](AccountingApi.md#get_credit_note_history) | **GET** /CreditNotes/{CreditNoteID}/History | Retrieves history records of a specific credit note [**get_credit_notes**](AccountingApi.md#get_credit_notes) | **GET** /CreditNotes | Retrieves any credit notes [**get_currencies**](AccountingApi.md#get_currencies) | **GET** /Currencies | Retrieves currencies for your Xero organisation -[**get_employee**](AccountingApi.md#get_employee) | **GET** /Employees/{EmployeeID} | Retrieves a specific employee used in Xero payrun using a unique employee Id -[**get_employees**](AccountingApi.md#get_employees) | **GET** /Employees | Retrieves employees used in Xero payrun [**get_expense_claim**](AccountingApi.md#get_expense_claim) | **GET** /ExpenseClaims/{ExpenseClaimID} | Retrieves a specific expense claim using a unique expense claim Id [**get_expense_claim_history**](AccountingApi.md#get_expense_claim_history) | **GET** /ExpenseClaims/{ExpenseClaimID}/History | Retrieves history records of a specific expense claim [**get_expense_claims**](AccountingApi.md#get_expense_claims) | **GET** /ExpenseClaims | Retrieves expense claims @@ -223,7 +220,6 @@ Method | HTTP request | Description [**update_or_create_bank_transactions**](AccountingApi.md#update_or_create_bank_transactions) | **POST** /BankTransactions | Updates or creates one or more spent or received money transaction [**update_or_create_contacts**](AccountingApi.md#update_or_create_contacts) | **POST** /Contacts | Updates or creates one or more contacts in a Xero organisation [**update_or_create_credit_notes**](AccountingApi.md#update_or_create_credit_notes) | **POST** /CreditNotes | Updates or creates one or more credit notes -[**update_or_create_employees**](AccountingApi.md#update_or_create_employees) | **POST** /Employees | Creates a single new employees used in Xero payrun [**update_or_create_invoices**](AccountingApi.md#update_or_create_invoices) | **POST** /Invoices | Updates or creates one or more sales invoices or purchase bills [**update_or_create_items**](AccountingApi.md#update_or_create_items) | **POST** /Items | Updates or creates one or more items [**update_or_create_manual_journals**](AccountingApi.md#update_or_create_manual_journals) | **POST** /ManualJournals | Updates or creates a single manual journal @@ -1751,80 +1747,6 @@ Name | Type | Description | Notes - **Accept**: application/json -## create_employees - -> Employees create_employees(xero_tenant_id, employees, opts) - -Creates new employees used in Xero payrun - -This endpoint is deprecated and will be removed April 28, 2026 - -### 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 -employees = {"Employees":[{"FirstName":"Nick","LastName":"Fury","ExternalLink":{"Url":"http://twitter.com/#!/search/Nick+Fury"}}]} # Employees | Employees with array of Employee object in body of request -opts = { - summarize_errors: false, # Boolean | If false return 200 OK and mix of successfully created objects and any with validation errors - - idempotency_key: 'KEY_VALUE' # String | This allows you to safely retry requests without the risk of duplicate processing. 128 character max. -} - -begin - #Creates new employees used in Xero payrun - result = api_instance.create_employees(xero_tenant_id, employees, opts) - p result -rescue XeroRuby::Accounting::ApiError => e - puts "Exception when calling AccountingApi->create_employees: #{e}" -end -``` - -### Parameters - - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **xero_tenant_id** | **String**| Xero identifier for Tenant | - **employees** | [**Employees**](Employees.md)| Employees with array of Employee object in body of request | - **summarize_errors** | **Boolean**| If false return 200 OK and mix of successfully created objects and any with validation errors | [optional] [default to false] - **idempotency_key** | **String**| This allows you to safely retry requests without the risk of duplicate processing. 128 character max. | [optional] - -### Return type - -[**Employees**](Employees.md) - -### Authorization - -[OAuth2](../README.md#OAuth2) - -### HTTP request headers - -- **Content-Type**: application/json -- **Accept**: application/json - - ## create_expense_claim_history > HistoryRecords create_expense_claim_history(xero_tenant_id, expense_claim_id, history_records, opts) @@ -8108,147 +8030,6 @@ Name | Type | Description | Notes - **Accept**: application/json -## get_employee - -> Employees get_employee(xero_tenant_id, employee_id) - -Retrieves a specific employee used in Xero payrun using a unique employee Id - -This endpoint is deprecated and will be removed April 28, 2026 - -### 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 -employee_id = '00000000-0000-0000-0000-000000000000' # String | Unique identifier for a Employee -begin - #Retrieves a specific employee used in Xero payrun using a unique employee Id - result = api_instance.get_employee(xero_tenant_id, employee_id) - p result -rescue XeroRuby::Accounting::ApiError => e - puts "Exception when calling AccountingApi->get_employee: #{e}" -end -``` - -### Parameters - - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **xero_tenant_id** | **String**| Xero identifier for Tenant | - **employee_id** | [**String**](.md)| Unique identifier for a Employee | - -### Return type - -[**Employees**](Employees.md) - -### Authorization - -[OAuth2](../README.md#OAuth2) - -### HTTP request headers - -- **Content-Type**: Not defined -- **Accept**: application/json - - -## get_employees - -> Employees get_employees(xero_tenant_id, opts) - -Retrieves employees used in Xero payrun - -This endpoint is deprecated and will be removed April 28, 2026 - -### 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 -opts = { - if_modified_since: DateTime.parse('2020-02-06T12:17:43.202-08:00'), # DateTime | Only records created or modified since this timestamp will be returned - - where: 'Status==\"ACTIVE\"', # String | Filter by an any element - - order: 'LastName ASC' # String | Order by an any element -} - -begin - #Retrieves employees used in Xero payrun - result = api_instance.get_employees(xero_tenant_id, opts) - p result -rescue XeroRuby::Accounting::ApiError => e - puts "Exception when calling AccountingApi->get_employees: #{e}" -end -``` - -### Parameters - - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **xero_tenant_id** | **String**| Xero identifier for Tenant | - **if_modified_since** | **DateTime**| Only records created or modified since this timestamp will be returned | [optional] - **where** | **String**| Filter by an any element | [optional] - **order** | **String**| Order by an any element | [optional] - -### Return type - -[**Employees**](Employees.md) - -### Authorization - -[OAuth2](../README.md#OAuth2) - -### HTTP request headers - -- **Content-Type**: Not defined -- **Accept**: application/json - - ## get_expense_claim > ExpenseClaims get_expense_claim(xero_tenant_id, expense_claim_id) @@ -15491,80 +15272,6 @@ Name | Type | Description | Notes - **Accept**: application/json -## update_or_create_employees - -> Employees update_or_create_employees(xero_tenant_id, employees, opts) - -Creates a single new employees used in Xero payrun - -This endpoint is deprecated and will be removed April 28, 2026 - -### 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 -employees = {"Employees":[{"FirstName":"Nick","LastName":"Fury","ExternalLink":{"Url":"http://twitter.com/#!/search/Nick+Fury"}}]} # Employees | Employees with array of Employee object in body of request -opts = { - summarize_errors: false, # Boolean | If false return 200 OK and mix of successfully created objects and any with validation errors - - idempotency_key: 'KEY_VALUE' # String | This allows you to safely retry requests without the risk of duplicate processing. 128 character max. -} - -begin - #Creates a single new employees used in Xero payrun - result = api_instance.update_or_create_employees(xero_tenant_id, employees, opts) - p result -rescue XeroRuby::Accounting::ApiError => e - puts "Exception when calling AccountingApi->update_or_create_employees: #{e}" -end -``` - -### Parameters - - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **xero_tenant_id** | **String**| Xero identifier for Tenant | - **employees** | [**Employees**](Employees.md)| Employees with array of Employee object in body of request | - **summarize_errors** | **Boolean**| If false return 200 OK and mix of successfully created objects and any with validation errors | [optional] [default to false] - **idempotency_key** | **String**| This allows you to safely retry requests without the risk of duplicate processing. 128 character max. | [optional] - -### Return type - -[**Employees**](Employees.md) - -### Authorization - -[OAuth2](../README.md#OAuth2) - -### HTTP request headers - -- **Content-Type**: application/json -- **Accept**: application/json - - ## update_or_create_invoices > Invoices update_or_create_invoices(xero_tenant_id, invoices, opts) diff --git a/docs/accounting/Prepayment.md b/docs/accounting/Prepayment.md index 31dae082..24a70142 100644 --- a/docs/accounting/Prepayment.md +++ b/docs/accounting/Prepayment.md @@ -18,6 +18,7 @@ Name | Type | Description | Notes **updated_date_utc** | **DateTime** | UTC timestamp of last update to the prepayment | [optional] **currency_code** | [**CurrencyCode**](CurrencyCode.md) | | [optional] **prepayment_id** | **String** | Xero generated unique identifier | [optional] +**branding_theme_id** | **String** | The unique identifier of the branding template applied to a receive prepayment | [optional] **currency_rate** | **BigDecimal** | The currency rate for a multicurrency prepayment. If no rate is specified, the XE.com day rate is used | [optional] **remaining_credit** | **BigDecimal** | The remaining credit balance on the prepayment | [optional] **allocations** | [**Array<Allocation>**](Allocation.md) | See Allocations | [optional] @@ -45,6 +46,7 @@ instance = XeroRuby::Accounting::Prepayment.new(type: null, updated_date_utc: /Date(1573755038314)/, currency_code: null, prepayment_id: null, + branding_theme_id: null, currency_rate: null, remaining_credit: null, allocations: null, diff --git a/docs/accounting/index.html b/docs/accounting/index.html index 527b94db..d8bdba9f 100644 --- a/docs/accounting/index.html +++ b/docs/accounting/index.html @@ -4778,6 +4778,12 @@ "description" : "Xero generated unique identifier", "format" : "uuid" }, + "BrandingThemeID" : { + "type" : "string", + "description" : "The unique identifier of the branding template applied to a receive prepayment", + "format" : "uuid", + "readOnly" : true + }, "CurrencyRate" : { "type" : "number", "description" : "The currency rate for a multicurrency prepayment. If no rate is specified, the XE.com day rate is used", @@ -6420,9 +6426,6 @@
  • createCurrency
  • -
  • - createEmployees -
  • createExpenseClaimHistory
  • @@ -6696,12 +6699,6 @@
  • getCurrencies
  • -
  • - getEmployee -
  • -
  • - getEmployees -
  • getExpenseClaim
  • @@ -7014,9 +7011,6 @@
  • updateOrCreateCreditNotes
  • -
  • - updateOrCreateEmployees -
  • updateOrCreateInvoices
  • @@ -11158,188 +11152,6 @@

    Parameters


    -
    -
    -
    -

    createEmployees

    -

    Creates new employees used in Xero payrun

    -
    -
    -
    -

    -

    This endpoint is deprecated and will be removed April 28, 2026

    -

    -
    -
    /Employees
    -

    -

    Usage and SDK Samples

    -

    - -
    - -
    -
    xero_client.set_token_set(user.token_set)
    -
    -xero_tenant_id = 'YOUR_XERO_TENANT_ID'
    -summarize_errors = true
    -idempotency_key = 'KEY_VALUE'
    -
    -employee = { 
    -  first_name: "Nick",
    -  last_name: "Fury"
    -}  
    -
    -employees = {  
    -  employees: [employee]
    -} 
    -
    -begin
    -  response = xero_client.accounting_api.create_employees(xero_tenant_id, employees, summarize_errors, idempotency_key)
    -  return response
    -rescue XeroRuby::ApiError => e
    -  puts "Exception when calling create_employees: #{e}"
    -end
    -
    -
    -
    -

    Scopes

    - - - - - - - -
    accounting.settingsGrant read-write access to organisation and account settings
    -

    Parameters

    -
    Header parameters
    - - - - - - - - - - - - - -
    NameDescription
    xero-tenant-id* - - -
    -
    -
    - - String - - -
    -Xero identifier for Tenant -
    -
    -
    - Required -
    -
    -
    -
    Idempotency-Key - - -
    -
    -
    - - String - - -
    -This allows you to safely retry requests without the risk of duplicate processing. 128 character max. -
    -
    -
    -
    -
    -
    Body parameters
    - - - - - - - -
    NameDescription
    employees * -
    -
    - - Employees - -
    - Employees with array of Employee object in body of request -
    -
    -
    - Required -
    -
    - -
    -
    Query parameters
    - - - - - - - - - -
    NameDescription
    summarizeErrors - - -
    -
    -
    - - Boolean - - -
    -If false return 200 OK and mix of successfully created objects and any with validation errors -
    -
    -
    -
    -
    -
    -
    -
    @@ -25913,281 +25725,6 @@

    Parameters

    - - - - - -
    -
    -
    -
    -

    getEmployee

    -

    Retrieves a specific employee used in Xero payrun using a unique employee Id

    -
    -
    -
    -

    -

    This endpoint is deprecated and will be removed April 28, 2026

    -

    -
    -
    /Employees/{EmployeeID}
    -

    -

    Usage and SDK Samples

    -

    - -
    - -
    -
    xero_client.set_token_set(user.token_set)
    -
    -xero_tenant_id = 'YOUR_XERO_TENANT_ID'
    -employee_id = '00000000-0000-0000-0000-000000000000'
    -
    -begin
    -  response = xero_client.accounting_api.get_employee(xero_tenant_id, employee_id)
    -  return response
    -rescue XeroRuby::ApiError => e
    -  puts "Exception when calling get_employee: #{e}"
    -end
    -
    -
    -
    -

    Scopes

    - - - - - - - - - - - - -
    accounting.settingsGrant read-write access to organisation and account settings
    accounting.settings.readGrant read-only access to organisation and account settings
    -

    Parameters

    -
    Path parameters
    - - - - - - - - - -
    NameDescription
    EmployeeID* - - -
    -
    -
    - - UUID - - - (uuid) - - -
    -Unique identifier for a Employee -
    -
    -
    - Required -
    -
    -
    -
    -
    Header parameters
    - - - - - - - - - -
    NameDescription
    xero-tenant-id* - - -
    -
    -
    - - String - - -
    -Xero identifier for Tenant -
    -
    -
    - Required -
    -
    -
    -
    -
    -
    -
    -
    -
    -
    -

    getEmployees

    -

    Retrieves employees used in Xero payrun

    -
    -
    -
    -

    -

    This endpoint is deprecated and will be removed April 28, 2026

    -

    -
    -
    /Employees
    -

    -

    Usage and SDK Samples

    -

    - -
    - -
    -
    xero_client.set_token_set(user.token_set)
    -
    -xero_tenant_id = 'YOUR_XERO_TENANT_ID'
    -if_modified_since = "2020-02-06T12:17:43.202-08:00"
    -where = 'Status==#{XeroRuby::Accounting::Employee::ACTIVE}'
    -order = 'LastName ASC'
    -
    -begin
    -  response = xero_client.accounting_api.get_employees(xero_tenant_id, if_modified_since, where, order)
    -  return response
    -rescue XeroRuby::ApiError => e
    -  puts "Exception when calling get_employees: #{e}"
    -end
    -
    -
    -
    -

    Scopes

    - - - - - - - - - - - - -
    accounting.settingsGrant read-write access to organisation and account settings
    accounting.settings.readGrant read-only access to organisation and account settings
    -

    Parameters

    -
    Header parameters
    - - - - - - - - - - - - - -
    NameDescription
    xero-tenant-id* - - -
    -
    -
    - - String - - -
    -Xero identifier for Tenant -
    -
    -
    - Required -
    -
    -
    -
    If-Modified-Since - - -
    -
    -
    - - Date - - - (date-time) - - -
    -Only records created or modified since this timestamp will be returned -
    -
    -
    -
    -
    -
    Query parameters
    - - - - - - - - - - -
    NameDescription
    where - - -
    -
    -
    - - String - - -
    -Filter by an any element -
    -
    -
    -
    -
    order - - -
    -
    -
    - - String - - -
    -Order by an any element -
    -
    -
    -
    -
    @@ -42681,188 +42218,6 @@

    Parameters

    - - - - - -
    -
    -
    -
    -

    updateOrCreateEmployees

    -

    Creates a single new employees used in Xero payrun

    -
    -
    -
    -

    -

    This endpoint is deprecated and will be removed April 28, 2026

    -

    -
    -
    /Employees
    -

    -

    Usage and SDK Samples

    -

    - -
    - -
    -
    xero_client.set_token_set(user.token_set)
    -
    -xero_tenant_id = 'YOUR_XERO_TENANT_ID'
    -summarize_errors = true
    -idempotency_key = 'KEY_VALUE'
    -
    -employee = { 
    -  first_name: "Nick",
    -  last_name: "Fury"
    -}  
    -
    -employees = {  
    -  employees: [employee]
    -} 
    -
    -begin
    -  response = xero_client.accounting_api.update_or_create_employees(xero_tenant_id, employees, summarize_errors, idempotency_key)
    -  return response
    -rescue XeroRuby::ApiError => e
    -  puts "Exception when calling update_or_create_employees: #{e}"
    -end
    -
    -
    -
    -

    Scopes

    - - - - - - - -
    accounting.settingsGrant read-write access to organisation and account settings
    -

    Parameters

    -
    Header parameters
    - - - - - - - - - - - - - -
    NameDescription
    xero-tenant-id* - - -
    -
    -
    - - String - - -
    -Xero identifier for Tenant -
    -
    -
    - Required -
    -
    -
    -
    Idempotency-Key - - -
    -
    -
    - - String - - -
    -This allows you to safely retry requests without the risk of duplicate processing. 128 character max. -
    -
    -
    -
    -
    -
    Body parameters
    - - - - - - - -
    NameDescription
    employees * -
    -
    - - Employees - -
    - Employees with array of Employee object in body of request -
    -
    -
    - Required -
    -
    - -
    -
    Query parameters
    - - - - - - -
    NameDescription
    summarizeErrors - - -
    -
    -
    - - Boolean - - -
    -If false return 200 OK and mix of successfully created objects and any with validation errors -
    -
    -
    -
    -
    diff --git a/docs/files/Association.md b/docs/files/Association.md index db6ea56c..49745e3f 100644 --- a/docs/files/Association.md +++ b/docs/files/Association.md @@ -7,6 +7,8 @@ Name | Type | Description | Notes **send_with_object** | **Boolean** | Boolean flag to determines whether the file is sent with the document it is attached to on client facing communications. Note- The SendWithObject element is only returned when using /Associations/{ObjectId} endpoint. | [optional] **name** | **String** | The name of the associated file. Note- The Name element is only returned when using /Associations/{ObjectId} endpoint. | [optional] **size** | **Integer** | The size of the associated file in bytes. Note- The Size element is only returned when using /Associations/{ObjectId} endpoint. | [optional] +**created_date_utc** | **DateTime** | The date the file was created (UTC). Note- The CreatedDateUtc element is only returned when using /Associations/{ObjectId} endpoint. | [optional] +**association_date_utc** | **DateTime** | The date the file was associated with the object (UTC). Note- The AssociationDateUtc element is only returned when using /Associations/{ObjectId} endpoint. | [optional] **file_id** | **String** | The unique identifier of the file | [optional] **object_id** | **String** | The identifier of the object that the file is being associated with (e.g. InvoiceID, BankTransactionID, ContactID) | [optional] **object_group** | [**ObjectGroup**](ObjectGroup.md) | | [optional] @@ -20,6 +22,8 @@ require 'XeroRuby::Files' instance = XeroRuby::Files::Association.new(send_with_object: true, name: Test.pdf, size: 12357, + created_date_utc: null, + association_date_utc: null, file_id: null, object_id: null, object_group: null, diff --git a/docs/files/FilesApi.md b/docs/files/FilesApi.md index c5de16b6..636e90f7 100644 --- a/docs/files/FilesApi.md +++ b/docs/files/FilesApi.md @@ -406,7 +406,7 @@ opts = { page: 2, # Integer | number of records to skip for pagination - sort: 'Associations/{ObjectId}?sort=CreatedDateUtc', # String | values to sort by + sort: 'CreatedDateUtc', # String | values to sort by direction: 'Associations/{ObjectId}?sort=CreatedDateUtc&direction=DESC' # String | direction to sort by } @@ -429,7 +429,7 @@ Name | Type | Description | Notes **object_id** | [**String**](.md)| Object id for single object | **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] + **sort** | **String**| values to sort by | [optional] [default to 'CreatedDateUtc'] **direction** | **String**| direction to sort by | [optional] ### Return type diff --git a/docs/files/index.html b/docs/files/index.html index 0a070705..9e378752 100644 --- a/docs/files/index.html +++ b/docs/files/index.html @@ -881,6 +881,16 @@ "description" : "The size of the associated file in bytes. Note- The Size element is only returned when using /Associations/{ObjectId} endpoint.", "example" : 12357 }, + "CreatedDateUtc" : { + "type" : "string", + "description" : "The date the file was created (UTC). Note- The CreatedDateUtc element is only returned when using /Associations/{ObjectId} endpoint.", + "format" : "date-time" + }, + "AssociationDateUtc" : { + "type" : "string", + "description" : "The date the file was associated with the object (UTC). Note- The AssociationDateUtc element is only returned when using /Associations/{ObjectId} endpoint.", + "format" : "date-time" + }, "FileId" : { "type" : "string", "description" : "The unique identifier of the file", diff --git a/lib/xero-ruby/api/accounting_api.rb b/lib/xero-ruby/api/accounting_api.rb index 60b8b3b9..9c13855a 100644 --- a/lib/xero-ruby/api/accounting_api.rb +++ b/lib/xero-ruby/api/accounting_api.rb @@ -1824,91 +1824,6 @@ def create_currency_with_http_info(xero_tenant_id, currency, options = {}) return data, status_code, headers end - # Creates new employees used in Xero payrun - # This endpoint is deprecated and will be removed April 28, 2026 - # @param xero_tenant_id [String] Xero identifier for Tenant - # @param employees [Employees] Employees with array of Employee object in body of request - # @param [Hash] opts the optional parameters - # @option opts [Boolean] :summarize_errors If false return 200 OK and mix of successfully created objects and any with validation errors (default to false) - # @option opts [String] :idempotency_key This allows you to safely retry requests without the risk of duplicate processing. 128 character max. - # @return [Employees] - def create_employees(xero_tenant_id, employees, opts = {}) - data, _status_code, _headers = create_employees_with_http_info(xero_tenant_id, employees, opts) - data - end - - # Creates new employees used in Xero payrun - # This endpoint is deprecated and will be removed April 28, 2026 - # @param xero_tenant_id [String] Xero identifier for Tenant - # @param employees [Employees] Employees with array of Employee object in body of request - # @param [Hash] opts the optional parameters - # @option opts [Boolean] :summarize_errors If false return 200 OK and mix of successfully created objects and any with validation errors - # @option opts [String] :idempotency_key This allows you to safely retry requests without the risk of duplicate processing. 128 character max. - # @return [Array<(Employees, Integer, Hash)>] Employees data, response status code and response headers - def create_employees_with_http_info(xero_tenant_id, employees, options = {}) - opts = options.dup - if @api_client.config.debugging - @api_client.config.logger.debug 'Calling API: AccountingApi.create_employees ...' - 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 AccountingApi.create_employees" - end - # verify the required parameter 'employees' is set - if @api_client.config.client_side_validation && employees.nil? - fail ArgumentError, "Missing the required parameter 'employees' when calling AccountingApi.create_employees" - end - # resource path - local_var_path = '/Employees' - - # 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[:'summarizeErrors'] = opts[:'summarize_errors'] if !opts[:'summarize_errors'].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']) - # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) - header_params[:'xero-tenant-id'] = xero_tenant_id - header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil? - - # form parameters - form_params = opts[:form_params] || {} - - # http body (model) - post_body = opts[:body] || @api_client.object_to_http_body(employees) - - # return_type - return_type = opts[:return_type] || 'Employees' - - # auth_names - auth_names = opts[:auth_names] || ['OAuth2'] - - new_options = 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(:PUT, local_var_path, "AccountingApi", new_options) - if @api_client.config.debugging - @api_client.config.logger.debug "API called: AccountingApi#create_employees\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" - end - return data, status_code, headers - end - # Creates a history record for a specific expense claim # @param xero_tenant_id [String] Xero identifier for Tenant # @param expense_claim_id [String] Unique identifier for a ExpenseClaim @@ -9358,163 +9273,6 @@ def get_currencies_with_http_info(xero_tenant_id, options = {}) return data, status_code, headers end - # Retrieves a specific employee used in Xero payrun using a unique employee Id - # This endpoint is deprecated and will be removed April 28, 2026 - # @param xero_tenant_id [String] Xero identifier for Tenant - # @param employee_id [String] Unique identifier for a Employee - # @param [Hash] opts the optional parameters - # @return [Employees] - def get_employee(xero_tenant_id, employee_id, opts = {}) - data, _status_code, _headers = get_employee_with_http_info(xero_tenant_id, employee_id, opts) - data - end - - # Retrieves a specific employee used in Xero payrun using a unique employee Id - # This endpoint is deprecated and will be removed April 28, 2026 - # @param xero_tenant_id [String] Xero identifier for Tenant - # @param employee_id [String] Unique identifier for a Employee - # @param [Hash] opts the optional parameters - # @return [Array<(Employees, Integer, Hash)>] Employees data, response status code and response headers - def get_employee_with_http_info(xero_tenant_id, employee_id, options = {}) - opts = options.dup - if @api_client.config.debugging - @api_client.config.logger.debug 'Calling API: AccountingApi.get_employee ...' - 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 AccountingApi.get_employee" - end - # verify the required parameter 'employee_id' is set - if @api_client.config.client_side_validation && employee_id.nil? - fail ArgumentError, "Missing the required parameter 'employee_id' when calling AccountingApi.get_employee" - end - # resource path - local_var_path = '/Employees/{EmployeeID}'.sub('{' + 'EmployeeID' + '}', employee_id.to_s) - - # 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] || {} - - # 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] || 'Employees' - - # auth_names - auth_names = opts[:auth_names] || ['OAuth2'] - - new_options = 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, "AccountingApi", new_options) - if @api_client.config.debugging - @api_client.config.logger.debug "API called: AccountingApi#get_employee\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" - end - return data, status_code, headers - end - - # Retrieves employees used in Xero payrun - # This endpoint is deprecated and will be removed April 28, 2026 - # @param xero_tenant_id [String] Xero identifier for Tenant - # @param [Hash] opts the optional parameters - # @option opts [DateTime] :if_modified_since Only records created or modified since this timestamp will be returned - # @option opts [String] :where Filter by an any element - # @option opts [String] :order Order by an any element - # @return [Employees] - def get_employees(xero_tenant_id, opts = {}) - data, _status_code, _headers = get_employees_with_http_info(xero_tenant_id, opts) - data - end - - # Retrieves employees used in Xero payrun - # This endpoint is deprecated and will be removed April 28, 2026 - # @param xero_tenant_id [String] Xero identifier for Tenant - # @param [Hash] opts the optional parameters - # @option opts [DateTime] :if_modified_since Only records created or modified since this timestamp will be returned - # @option opts [String] :where Filter by an any element - # @option opts [String] :order Order by an any element - # @return [Array<(Employees, Integer, Hash)>] Employees data, response status code and response headers - def get_employees_with_http_info(xero_tenant_id, options = {}) - opts = options.dup - if @api_client.config.debugging - @api_client.config.logger.debug 'Calling API: AccountingApi.get_employees ...' - 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 AccountingApi.get_employees" - end - # resource path - local_var_path = '/Employees' - - # 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[:'where'] = opts[:'where'] if !opts[:'where'].nil? - query_params[:'order'] = opts[:'order'] if !opts[:'order'].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 - header_params[:'If-Modified-Since'] = opts[:'if_modified_since'] if !opts[:'if_modified_since'].nil? - - # form parameters - form_params = opts[:form_params] || {} - - # http body (model) - post_body = opts[:body] - - # return_type - return_type = opts[:return_type] || 'Employees' - - # auth_names - auth_names = opts[:auth_names] || ['OAuth2'] - - new_options = 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, "AccountingApi", new_options) - if @api_client.config.debugging - @api_client.config.logger.debug "API called: AccountingApi#get_employees\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" - end - return data, status_code, headers - end - # Retrieves a specific expense claim using a unique expense claim Id # @param xero_tenant_id [String] Xero identifier for Tenant # @param expense_claim_id [String] Unique identifier for a ExpenseClaim @@ -17949,91 +17707,6 @@ def update_or_create_credit_notes_with_http_info(xero_tenant_id, credit_notes, o return data, status_code, headers end - # Creates a single new employees used in Xero payrun - # This endpoint is deprecated and will be removed April 28, 2026 - # @param xero_tenant_id [String] Xero identifier for Tenant - # @param employees [Employees] Employees with array of Employee object in body of request - # @param [Hash] opts the optional parameters - # @option opts [Boolean] :summarize_errors If false return 200 OK and mix of successfully created objects and any with validation errors (default to false) - # @option opts [String] :idempotency_key This allows you to safely retry requests without the risk of duplicate processing. 128 character max. - # @return [Employees] - def update_or_create_employees(xero_tenant_id, employees, opts = {}) - data, _status_code, _headers = update_or_create_employees_with_http_info(xero_tenant_id, employees, opts) - data - end - - # Creates a single new employees used in Xero payrun - # This endpoint is deprecated and will be removed April 28, 2026 - # @param xero_tenant_id [String] Xero identifier for Tenant - # @param employees [Employees] Employees with array of Employee object in body of request - # @param [Hash] opts the optional parameters - # @option opts [Boolean] :summarize_errors If false return 200 OK and mix of successfully created objects and any with validation errors - # @option opts [String] :idempotency_key This allows you to safely retry requests without the risk of duplicate processing. 128 character max. - # @return [Array<(Employees, Integer, Hash)>] Employees data, response status code and response headers - def update_or_create_employees_with_http_info(xero_tenant_id, employees, options = {}) - opts = options.dup - if @api_client.config.debugging - @api_client.config.logger.debug 'Calling API: AccountingApi.update_or_create_employees ...' - 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 AccountingApi.update_or_create_employees" - end - # verify the required parameter 'employees' is set - if @api_client.config.client_side_validation && employees.nil? - fail ArgumentError, "Missing the required parameter 'employees' when calling AccountingApi.update_or_create_employees" - end - # resource path - local_var_path = '/Employees' - - # 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[:'summarizeErrors'] = opts[:'summarize_errors'] if !opts[:'summarize_errors'].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']) - # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) - header_params[:'xero-tenant-id'] = xero_tenant_id - header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil? - - # form parameters - form_params = opts[:form_params] || {} - - # http body (model) - post_body = opts[:body] || @api_client.object_to_http_body(employees) - - # return_type - return_type = opts[:return_type] || 'Employees' - - # auth_names - auth_names = opts[:auth_names] || ['OAuth2'] - - new_options = 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(:POST, local_var_path, "AccountingApi", new_options) - if @api_client.config.debugging - @api_client.config.logger.debug "API called: AccountingApi#update_or_create_employees\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" - end - return data, status_code, headers - end - # Updates or creates one or more sales invoices or purchase bills # @param xero_tenant_id [String] Xero identifier for Tenant # @param invoices [Invoices] diff --git a/lib/xero-ruby/api/files_api.rb b/lib/xero-ruby/api/files_api.rb index 721215da..8030b6a1 100644 --- a/lib/xero-ruby/api/files_api.rb +++ b/lib/xero-ruby/api/files_api.rb @@ -424,7 +424,7 @@ def delete_folder_with_http_info(xero_tenant_id, folder_id, options = {}) # @param [Hash] opts the optional parameters # @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] :sort values to sort by (default to 'CreatedDateUtc') # @option opts [String] :direction direction to sort by # @return [Array] def get_associations_by_object(xero_tenant_id, object_id, opts = {}) @@ -463,7 +463,7 @@ def get_associations_by_object_with_http_info(xero_tenant_id, object_id, options fail ArgumentError, 'invalid value for "opts[:"page"]" when calling FilesApi.get_associations_by_object, must be greater than or equal to 1.' end - allowable_values = ["Name", "CreatedDateUTC"] + allowable_values = ["Name", "Size", "CreatedDateUtc", "AssociationDateUtc"] 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 diff --git a/lib/xero-ruby/models/accounting/prepayment.rb b/lib/xero-ruby/models/accounting/prepayment.rb index 8a8f24cc..ceec5880 100644 --- a/lib/xero-ruby/models/accounting/prepayment.rb +++ b/lib/xero-ruby/models/accounting/prepayment.rb @@ -65,6 +65,9 @@ class Prepayment # Xero generated unique identifier attr_accessor :prepayment_id + # The unique identifier of the branding template applied to a receive prepayment + attr_accessor :branding_theme_id + # The currency rate for a multicurrency prepayment. If no rate is specified, the XE.com day rate is used attr_accessor :currency_rate @@ -125,6 +128,7 @@ def self.attribute_map :'updated_date_utc' => :'UpdatedDateUTC', :'currency_code' => :'CurrencyCode', :'prepayment_id' => :'PrepaymentID', + :'branding_theme_id' => :'BrandingThemeID', :'currency_rate' => :'CurrencyRate', :'remaining_credit' => :'RemainingCredit', :'allocations' => :'Allocations', @@ -152,6 +156,7 @@ def self.openapi_types :'updated_date_utc' => :'DateTime', :'currency_code' => :'CurrencyCode', :'prepayment_id' => :'String', + :'branding_theme_id' => :'String', :'currency_rate' => :'BigDecimal', :'remaining_credit' => :'BigDecimal', :'allocations' => :'Array', @@ -235,6 +240,10 @@ def initialize(attributes = {}) self.prepayment_id = attributes[:'prepayment_id'] end + if attributes.key?(:'branding_theme_id') + self.branding_theme_id = attributes[:'branding_theme_id'] + end + if attributes.key?(:'currency_rate') self.currency_rate = attributes[:'currency_rate'] end @@ -328,6 +337,7 @@ def ==(o) updated_date_utc == o.updated_date_utc && currency_code == o.currency_code && prepayment_id == o.prepayment_id && + branding_theme_id == o.branding_theme_id && currency_rate == o.currency_rate && remaining_credit == o.remaining_credit && allocations == o.allocations && @@ -346,7 +356,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [type, contact, date, status, line_amount_types, line_items, sub_total, total_tax, total, reference, invoice_number, updated_date_utc, currency_code, prepayment_id, currency_rate, remaining_credit, allocations, payments, applied_amount, has_attachments, attachments].hash + [type, contact, date, status, line_amount_types, line_items, sub_total, total_tax, total, reference, invoice_number, updated_date_utc, currency_code, prepayment_id, branding_theme_id, currency_rate, remaining_credit, allocations, payments, applied_amount, has_attachments, attachments].hash end # Builds the object from hash diff --git a/lib/xero-ruby/models/files/association.rb b/lib/xero-ruby/models/files/association.rb index 81980130..5e56771b 100644 --- a/lib/xero-ruby/models/files/association.rb +++ b/lib/xero-ruby/models/files/association.rb @@ -25,6 +25,12 @@ class Association # The size of the associated file in bytes. Note- The Size element is only returned when using /Associations/{ObjectId} endpoint. attr_accessor :size + # The date the file was created (UTC). Note- The CreatedDateUtc element is only returned when using /Associations/{ObjectId} endpoint. + attr_accessor :created_date_utc + + # The date the file was associated with the object (UTC). Note- The AssociationDateUtc element is only returned when using /Associations/{ObjectId} endpoint. + attr_accessor :association_date_utc + # The unique identifier of the file attr_accessor :file_id @@ -43,6 +49,8 @@ def self.attribute_map :'send_with_object' => :'SendWithObject', :'name' => :'Name', :'size' => :'Size', + :'created_date_utc' => :'CreatedDateUtc', + :'association_date_utc' => :'AssociationDateUtc', :'file_id' => :'FileId', :'object_id' => :'ObjectId', :'object_group' => :'ObjectGroup', @@ -56,6 +64,8 @@ def self.openapi_types :'send_with_object' => :'Boolean', :'name' => :'String', :'size' => :'Integer', + :'created_date_utc' => :'DateTime', + :'association_date_utc' => :'DateTime', :'file_id' => :'String', :'object_id' => :'String', :'object_group' => :'ObjectGroup', @@ -90,6 +100,14 @@ def initialize(attributes = {}) self.size = attributes[:'size'] end + if attributes.key?(:'created_date_utc') + self.created_date_utc = attributes[:'created_date_utc'] + end + + if attributes.key?(:'association_date_utc') + self.association_date_utc = attributes[:'association_date_utc'] + end + if attributes.key?(:'file_id') self.file_id = attributes[:'file_id'] end @@ -128,6 +146,8 @@ def ==(o) send_with_object == o.send_with_object && name == o.name && size == o.size && + created_date_utc == o.created_date_utc && + association_date_utc == o.association_date_utc && file_id == o.file_id && object_id == o.object_id && object_group == o.object_group && @@ -143,7 +163,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [send_with_object, name, size, file_id, object_id, object_group, object_type].hash + [send_with_object, name, size, created_date_utc, association_date_utc, file_id, object_id, object_group, object_type].hash end # Builds the object from hash diff --git a/lib/xero-ruby/version.rb b/lib/xero-ruby/version.rb index 4bf23ea4..6fb284ea 100644 --- a/lib/xero-ruby/version.rb +++ b/lib/xero-ruby/version.rb @@ -7,7 +7,7 @@ Generated by: https://openapi-generator.tech OpenAPI Generator version: 4.3.1 -The version of the XeroOpenAPI document: 12.0.2 +The version of the XeroOpenAPI document: 13.0.0 =end module XeroRuby