diff --git a/docs/v1/accounting/index.html b/docs/v1/accounting/index.html index fa9b5e62..dd5cb3c4 100644 --- a/docs/v1/accounting/index.html +++ b/docs/v1/accounting/index.html @@ -6344,7 +6344,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods createAccount diff --git a/docs/v1/appstore/index.html b/docs/v1/appstore/index.html index ac1d8090..3581c7eb 100644 --- a/docs/v1/appstore/index.html +++ b/docs/v1/appstore/index.html @@ -1241,7 +1241,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods getSubscription diff --git a/docs/v1/assets/index.html b/docs/v1/assets/index.html index bba16afc..cdbe4fca 100644 --- a/docs/v1/assets/index.html +++ b/docs/v1/assets/index.html @@ -1419,7 +1419,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods createAsset diff --git a/docs/v1/files/index.html b/docs/v1/files/index.html index b8ffbebb..86e1ccb4 100644 --- a/docs/v1/files/index.html +++ b/docs/v1/files/index.html @@ -1170,7 +1170,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods createFileAssociation diff --git a/docs/v1/finance/index.html b/docs/v1/finance/index.html index 826519b6..85621be5 100644 --- a/docs/v1/finance/index.html +++ b/docs/v1/finance/index.html @@ -2716,7 +2716,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods getAccountingActivityAccountUsage diff --git a/docs/v1/payroll-au/index.html b/docs/v1/payroll-au/index.html index 22b80211..427f4bc1 100644 --- a/docs/v1/payroll-au/index.html +++ b/docs/v1/payroll-au/index.html @@ -3412,7 +3412,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods approveLeaveApplication diff --git a/docs/v1/payroll-nz/index.html b/docs/v1/payroll-nz/index.html index 03811498..01c42e9c 100644 --- a/docs/v1/payroll-nz/index.html +++ b/docs/v1/payroll-nz/index.html @@ -4087,7 +4087,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods approveTimesheet diff --git a/docs/v1/payroll-uk/index.html b/docs/v1/payroll-uk/index.html index fef6c4c8..a01e4de5 100644 --- a/docs/v1/payroll-uk/index.html +++ b/docs/v1/payroll-uk/index.html @@ -1091,6 +1091,53 @@ } }, "description" : "" +}; + defs["ContractType"] = { + "title" : "", + "type" : "string", + "description" : "The contract type of the employee.", + "example" : "FullTime", + "enum" : [ "FullTime", "PartTime", "ZeroHour", "Unspecified" ] +}; + defs["Contracts"] = { + "title" : "", + "required" : [ "contractType", "employmentStatus", "startDate" ], + "type" : "object", + "properties" : { + "startDate" : { + "type" : "string", + "description" : "The contract start date of the employee. This will be locked once an employee has been paid and cannot be changed (YYYY-MM-DD)", + "format" : "date", + "example" : "2024-12-02", + "x-is-date" : true + }, + "employmentStatus" : { + "$ref" : "#/components/schemas/EmploymentStatus" + }, + "contractType" : { + "$ref" : "#/components/schemas/ContractType" + }, + "publicKey" : { + "type" : "string", + "description" : "The public key of the contract. Public key is required if the intention is to edit an existing contract. If no key is supplied a new contract will be created", + "format" : "uuid" + }, + "isFixedTerm" : { + "type" : "boolean", + "description" : "describes whether the contract is fixed term (required if trying to create Fixed term contract)" + }, + "fixedTermEndDate" : { + "type" : "string", + "description" : "The fixed term end date of the employee. Not required if isFixedTerm is false or not provided (required if trying to create Fixed term contract)", + "format" : "date", + "example" : "2025-11-01", + "x-is-date" : true + }, + "developmentalRoleDetails" : { + "$ref" : "#/components/schemas/DevelopmentalRoleDetails" + } + }, + "description" : "" }; defs["CourtOrderLine"] = { "title" : "", @@ -1249,6 +1296,38 @@ } }, "description" : "" +}; + defs["DevelopmentalRoleDetails"] = { + "title" : "", + "required" : [ "developmentalRole", "endDate", "startDate" ], + "type" : "object", + "properties" : { + "startDate" : { + "type" : "string", + "description" : "The start date of the developmental role", + "format" : "date", + "example" : "2024-12-02", + "x-is-date" : true + }, + "endDate" : { + "type" : "string", + "description" : "The end date of the developmental role", + "format" : "date", + "example" : "2024-12-02", + "x-is-date" : true + }, + "developmentalRole" : { + "type" : "string", + "description" : "The developmental role type - \"Apprentice\" is the only supported role currently", + "example" : "Apprentice" + }, + "publicKey" : { + "type" : "string", + "description" : "The public key of the developmental role. Public key is required if the intention is to edit an existing developmental role. If no key is supplied a new developmental role will be created", + "format" : "uuid" + } + }, + "description" : "" }; defs["EarningsLine"] = { "title" : "", @@ -1613,6 +1692,13 @@ "isOffPayrollWorker" : { "type" : "boolean", "description" : "Whether the employee is an off payroll worker" + }, + "contracts" : { + "type" : "array", + "description" : "The employee's contracts", + "items" : { + "$ref" : "#/components/schemas/Contracts" + } } }, "description" : "" @@ -2300,6 +2386,13 @@ "items" : { "$ref" : "#/components/schemas/NICategory" } + }, + "contracts" : { + "type" : "array", + "description" : "The employee's contracts", + "items" : { + "$ref" : "#/components/schemas/Contracts" + } } }, "description" : "" @@ -2319,6 +2412,13 @@ } }, "description" : "" +}; + defs["EmploymentStatus"] = { + "title" : "", + "type" : "string", + "description" : "The employment status of the employee.", + "example" : "Employee", + "enum" : [ "Employee", "Worker", "Unspecified" ] }; defs["InvalidField"] = { "title" : "", @@ -3600,7 +3700,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods approveTimesheet diff --git a/docs/v1/projects/index.html b/docs/v1/projects/index.html index e83e2303..1f318d41 100644 --- a/docs/v1/projects/index.html +++ b/docs/v1/projects/index.html @@ -1462,7 +1462,7 @@ SDK: - VSN: 9.2.0 + VSN: 9.3.0 Methods createProject diff --git a/setup.py b/setup.py index d56d3290..8e16e76c 100644 --- a/setup.py +++ b/setup.py @@ -48,5 +48,5 @@ def read_file(filename): keywords="xero python sdk API oAuth", name="xero_python", packages=find_packages(include=["xero_python", "xero_python.*"]), - version="9.2.0", + version="9.3.0", ) diff --git a/xero_python/__init__.py b/xero_python/__init__.py index c32f2750..2934e6ca 100644 --- a/xero_python/__init__.py +++ b/xero_python/__init__.py @@ -2,4 +2,4 @@ __author__ = """Xero Developer API""" __email__ = "api@xero.com" -__version__ = "9.2.0" +__version__ = "9.3.0" diff --git a/xero_python/accounting/api/accounting_api.py b/xero_python/accounting/api/accounting_api.py index 4faf2430..2f908e32 100644 --- a/xero_python/accounting/api/accounting_api.py +++ b/xero_python/accounting/api/accounting_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/appstore/api/app_store_api.py b/xero_python/appstore/api/app_store_api.py index 1fa97296..07440aaf 100644 --- a/xero_python/appstore/api/app_store_api.py +++ b/xero_python/appstore/api/app_store_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/assets/api/asset_api.py b/xero_python/assets/api/asset_api.py index 307de3fb..5f161168 100644 --- a/xero_python/assets/api/asset_api.py +++ b/xero_python/assets/api/asset_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/docs/README.md b/xero_python/docs/README.md index 8a7d9493..0dc2ac55 100644 --- a/xero_python/docs/README.md +++ b/xero_python/docs/README.md @@ -3,8 +3,8 @@ These endpoints are related to managing authentication tokens and identity for X The `xero_python` package is automatically generated by the [XeroAPI SDK 2.0 Codegen](https://github.com/xero-github/xeroapi-sdk-codegen) project: -- API version: 9.2.0 -- Package version: 9.2.0 +- API version: 9.3.0 +- Package version: 9.3.0 - Build package: org.openapitools.codegen.languages.PythonClientCodegen For more information, please visit [https://developer.xero.com](https://developer.xero.com) diff --git a/xero_python/file/api/files_api.py b/xero_python/file/api/files_api.py index 0c3ec833..35c76e36 100644 --- a/xero_python/file/api/files_api.py +++ b/xero_python/file/api/files_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/finance/api/finance_api.py b/xero_python/finance/api/finance_api.py index 07295d90..c064d9d9 100644 --- a/xero_python/finance/api/finance_api.py +++ b/xero_python/finance/api/finance_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/identity/api/identity_api.py b/xero_python/identity/api/identity_api.py index 29163e7f..245f518f 100644 --- a/xero_python/identity/api/identity_api.py +++ b/xero_python/identity/api/identity_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/payrollau/api/payroll_au_api.py b/xero_python/payrollau/api/payroll_au_api.py index f02b5164..e37062d3 100644 --- a/xero_python/payrollau/api/payroll_au_api.py +++ b/xero_python/payrollau/api/payroll_au_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/payrollnz/api/payroll_nz_api.py b/xero_python/payrollnz/api/payroll_nz_api.py index f9268e9b..0f3aa8ef 100644 --- a/xero_python/payrollnz/api/payroll_nz_api.py +++ b/xero_python/payrollnz/api/payroll_nz_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/payrolluk/__init__.py b/xero_python/payrolluk/__init__.py index 6665ea65..6b51b5d2 100644 --- a/xero_python/payrolluk/__init__.py +++ b/xero_python/payrolluk/__init__.py @@ -25,11 +25,16 @@ from xero_python.payrolluk.models.benefit_line import BenefitLine from xero_python.payrolluk.models.benefit_object import BenefitObject from xero_python.payrolluk.models.benefits import Benefits +from xero_python.payrolluk.models.contract_type import ContractType +from xero_python.payrolluk.models.contracts import Contracts from xero_python.payrolluk.models.court_order_line import CourtOrderLine from xero_python.payrolluk.models.deduction import Deduction from xero_python.payrolluk.models.deduction_line import DeductionLine from xero_python.payrolluk.models.deduction_object import DeductionObject from xero_python.payrolluk.models.deductions import Deductions +from xero_python.payrolluk.models.developmental_role_details import ( + DevelopmentalRoleDetails, +) from xero_python.payrolluk.models.earnings_line import EarningsLine from xero_python.payrolluk.models.earnings_order import EarningsOrder from xero_python.payrolluk.models.earnings_order_object import EarningsOrderObject @@ -88,6 +93,7 @@ from xero_python.payrolluk.models.employees import Employees from xero_python.payrolluk.models.employment import Employment from xero_python.payrolluk.models.employment_object import EmploymentObject +from xero_python.payrolluk.models.employment_status import EmploymentStatus from xero_python.payrolluk.models.invalid_field import InvalidField from xero_python.payrolluk.models.leave_accrual_line import LeaveAccrualLine from xero_python.payrolluk.models.leave_earnings_line import LeaveEarningsLine diff --git a/xero_python/payrolluk/api/payroll_uk_api.py b/xero_python/payrolluk/api/payroll_uk_api.py index 356df08d..cc8d1812 100644 --- a/xero_python/payrolluk/api/payroll_uk_api.py +++ b/xero_python/payrolluk/api/payroll_uk_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """ diff --git a/xero_python/payrolluk/docs/ContractType.md b/xero_python/payrolluk/docs/ContractType.md new file mode 100644 index 00000000..b968f7d7 --- /dev/null +++ b/xero_python/payrolluk/docs/ContractType.md @@ -0,0 +1,9 @@ +# ContractType + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/xero_python/payrolluk/docs/Contracts.md b/xero_python/payrolluk/docs/Contracts.md new file mode 100644 index 00000000..ff0956b6 --- /dev/null +++ b/xero_python/payrolluk/docs/Contracts.md @@ -0,0 +1,16 @@ +# Contracts + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**start_date** | **date** | The contract start date of the employee. This will be locked once an employee has been paid and cannot be changed (YYYY-MM-DD) | +**employment_status** | [**EmploymentStatus**](EmploymentStatus.md) | | +**contract_type** | [**ContractType**](ContractType.md) | | +**public_key** | **str** | The public key of the contract. Public key is required if the intention is to edit an existing contract. If no key is supplied a new contract will be created | [optional] +**is_fixed_term** | **bool** | describes whether the contract is fixed term (required if trying to create Fixed term contract) | [optional] +**fixed_term_end_date** | **date** | The fixed term end date of the employee. Not required if isFixedTerm is false or not provided (required if trying to create Fixed term contract) | [optional] +**developmental_role_details** | [**DevelopmentalRoleDetails**](DevelopmentalRoleDetails.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/xero_python/payrolluk/docs/DevelopmentalRoleDetails.md b/xero_python/payrolluk/docs/DevelopmentalRoleDetails.md new file mode 100644 index 00000000..952e7a3d --- /dev/null +++ b/xero_python/payrolluk/docs/DevelopmentalRoleDetails.md @@ -0,0 +1,13 @@ +# DevelopmentalRoleDetails + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**start_date** | **date** | The start date of the developmental role | +**end_date** | **date** | The end date of the developmental role | +**developmental_role** | **str** | The developmental role type - \"Apprentice\" is the only supported role currently | +**public_key** | **str** | The public key of the developmental role. Public key is required if the intention is to edit an existing developmental role. If no key is supplied a new developmental role will be created | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/xero_python/payrolluk/docs/Employee.md b/xero_python/payrolluk/docs/Employee.md index ad711576..7795d2e5 100644 --- a/xero_python/payrolluk/docs/Employee.md +++ b/xero_python/payrolluk/docs/Employee.md @@ -21,6 +21,7 @@ Name | Type | Description | Notes **ni_categories** | [**list[NICategory]**](NICategory.md) | The employee's NI categories | [optional] **national_insurance_number** | **str** | National insurance number of the employee | [optional] **is_off_payroll_worker** | **bool** | Whether the employee is an off payroll worker | [optional] +**contracts** | [**list[Contracts]**](Contracts.md) | The employee's contracts | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/xero_python/payrolluk/docs/Employment.md b/xero_python/payrolluk/docs/Employment.md index 47768363..f44edf31 100644 --- a/xero_python/payrolluk/docs/Employment.md +++ b/xero_python/payrolluk/docs/Employment.md @@ -8,6 +8,7 @@ Name | Type | Description | Notes **employee_number** | **str** | The employment number of the employee | **ni_category** | [**NICategoryLetter**](NICategoryLetter.md) | | [optional] **ni_categories** | [**list[NICategory]**](NICategory.md) | The employee's NI categories | +**contracts** | [**list[Contracts]**](Contracts.md) | The employee's contracts | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/xero_python/payrolluk/docs/EmploymentStatus.md b/xero_python/payrolluk/docs/EmploymentStatus.md new file mode 100644 index 00000000..05ccec0d --- /dev/null +++ b/xero_python/payrolluk/docs/EmploymentStatus.md @@ -0,0 +1,9 @@ +# EmploymentStatus + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/xero_python/payrolluk/models/__init__.py b/xero_python/payrolluk/models/__init__.py index 5ecbd5e9..15156247 100644 --- a/xero_python/payrolluk/models/__init__.py +++ b/xero_python/payrolluk/models/__init__.py @@ -20,11 +20,16 @@ from xero_python.payrolluk.models.benefit_line import BenefitLine from xero_python.payrolluk.models.benefit_object import BenefitObject from xero_python.payrolluk.models.benefits import Benefits +from xero_python.payrolluk.models.contract_type import ContractType +from xero_python.payrolluk.models.contracts import Contracts from xero_python.payrolluk.models.court_order_line import CourtOrderLine from xero_python.payrolluk.models.deduction import Deduction from xero_python.payrolluk.models.deduction_line import DeductionLine from xero_python.payrolluk.models.deduction_object import DeductionObject from xero_python.payrolluk.models.deductions import Deductions +from xero_python.payrolluk.models.developmental_role_details import ( + DevelopmentalRoleDetails, +) from xero_python.payrolluk.models.earnings_line import EarningsLine from xero_python.payrolluk.models.earnings_order import EarningsOrder from xero_python.payrolluk.models.earnings_order_object import EarningsOrderObject @@ -83,6 +88,7 @@ from xero_python.payrolluk.models.employees import Employees from xero_python.payrolluk.models.employment import Employment from xero_python.payrolluk.models.employment_object import EmploymentObject +from xero_python.payrolluk.models.employment_status import EmploymentStatus from xero_python.payrolluk.models.invalid_field import InvalidField from xero_python.payrolluk.models.leave_accrual_line import LeaveAccrualLine from xero_python.payrolluk.models.leave_earnings_line import LeaveEarningsLine diff --git a/xero_python/payrolluk/models/contract_type.py b/xero_python/payrolluk/models/contract_type.py new file mode 100644 index 00000000..9097d9df --- /dev/null +++ b/xero_python/payrolluk/models/contract_type.py @@ -0,0 +1,30 @@ +# coding: utf-8 + +""" +Xero Payroll UK + +This is the Xero Payroll API for orgs in the UK region. # noqa: E501 + +Contact: api@xero.com +Generated by: https://openapi-generator.tech +""" + + +import re # noqa: F401 + +from enum import Enum + + +class ContractType(Enum): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + allowed enum values + """ + + FULLTIME = "FullTime" + PARTTIME = "PartTime" + ZEROHOUR = "ZeroHour" + UNSPECIFIED = "Unspecified" diff --git a/xero_python/payrolluk/models/contracts.py b/xero_python/payrolluk/models/contracts.py new file mode 100644 index 00000000..f3bc94ce --- /dev/null +++ b/xero_python/payrolluk/models/contracts.py @@ -0,0 +1,250 @@ +# coding: utf-8 + +""" +Xero Payroll UK + +This is the Xero Payroll API for orgs in the UK region. # noqa: E501 + +Contact: api@xero.com +Generated by: https://openapi-generator.tech +""" + + +import re # noqa: F401 + +from xero_python.models import BaseModel + + +class Contracts(BaseModel): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + "start_date": "date", + "employment_status": "EmploymentStatus", + "contract_type": "ContractType", + "public_key": "str", + "is_fixed_term": "bool", + "fixed_term_end_date": "date", + "developmental_role_details": "DevelopmentalRoleDetails", + } + + attribute_map = { + "start_date": "startDate", + "employment_status": "employmentStatus", + "contract_type": "contractType", + "public_key": "publicKey", + "is_fixed_term": "isFixedTerm", + "fixed_term_end_date": "fixedTermEndDate", + "developmental_role_details": "developmentalRoleDetails", + } + + def __init__( + self, + start_date=None, + employment_status=None, + contract_type=None, + public_key=None, + is_fixed_term=None, + fixed_term_end_date=None, + developmental_role_details=None, + ): # noqa: E501 + """Contracts - a model defined in OpenAPI""" # noqa: E501 + + self._start_date = None + self._employment_status = None + self._contract_type = None + self._public_key = None + self._is_fixed_term = None + self._fixed_term_end_date = None + self._developmental_role_details = None + self.discriminator = None + + self.start_date = start_date + self.employment_status = employment_status + self.contract_type = contract_type + if public_key is not None: + self.public_key = public_key + if is_fixed_term is not None: + self.is_fixed_term = is_fixed_term + if fixed_term_end_date is not None: + self.fixed_term_end_date = fixed_term_end_date + if developmental_role_details is not None: + self.developmental_role_details = developmental_role_details + + @property + def start_date(self): + """Gets the start_date of this Contracts. # noqa: E501 + + The contract start date of the employee. This will be locked once an employee has been paid and cannot be changed (YYYY-MM-DD) # noqa: E501 + + :return: The start_date of this Contracts. # noqa: E501 + :rtype: date + """ + return self._start_date + + @start_date.setter + def start_date(self, start_date): + """Sets the start_date of this Contracts. + + The contract start date of the employee. This will be locked once an employee has been paid and cannot be changed (YYYY-MM-DD) # noqa: E501 + + :param start_date: The start_date of this Contracts. # noqa: E501 + :type: date + """ + if start_date is None: + raise ValueError( + "Invalid value for `start_date`, must not be `None`" + ) # noqa: E501 + + self._start_date = start_date + + @property + def employment_status(self): + """Gets the employment_status of this Contracts. # noqa: E501 + + + :return: The employment_status of this Contracts. # noqa: E501 + :rtype: EmploymentStatus + """ + return self._employment_status + + @employment_status.setter + def employment_status(self, employment_status): + """Sets the employment_status of this Contracts. + + + :param employment_status: The employment_status of this Contracts. # noqa: E501 + :type: EmploymentStatus + """ + if employment_status is None: + raise ValueError( + "Invalid value for `employment_status`, must not be `None`" + ) # noqa: E501 + + self._employment_status = employment_status + + @property + def contract_type(self): + """Gets the contract_type of this Contracts. # noqa: E501 + + + :return: The contract_type of this Contracts. # noqa: E501 + :rtype: ContractType + """ + return self._contract_type + + @contract_type.setter + def contract_type(self, contract_type): + """Sets the contract_type of this Contracts. + + + :param contract_type: The contract_type of this Contracts. # noqa: E501 + :type: ContractType + """ + if contract_type is None: + raise ValueError( + "Invalid value for `contract_type`, must not be `None`" + ) # noqa: E501 + + self._contract_type = contract_type + + @property + def public_key(self): + """Gets the public_key of this Contracts. # noqa: E501 + + The public key of the contract. Public key is required if the intention is to edit an existing contract. If no key is supplied a new contract will be created # noqa: E501 + + :return: The public_key of this Contracts. # noqa: E501 + :rtype: str + """ + return self._public_key + + @public_key.setter + def public_key(self, public_key): + """Sets the public_key of this Contracts. + + The public key of the contract. Public key is required if the intention is to edit an existing contract. If no key is supplied a new contract will be created # noqa: E501 + + :param public_key: The public_key of this Contracts. # noqa: E501 + :type: str + """ + + self._public_key = public_key + + @property + def is_fixed_term(self): + """Gets the is_fixed_term of this Contracts. # noqa: E501 + + describes whether the contract is fixed term (required if trying to create Fixed term contract) # noqa: E501 + + :return: The is_fixed_term of this Contracts. # noqa: E501 + :rtype: bool + """ + return self._is_fixed_term + + @is_fixed_term.setter + def is_fixed_term(self, is_fixed_term): + """Sets the is_fixed_term of this Contracts. + + describes whether the contract is fixed term (required if trying to create Fixed term contract) # noqa: E501 + + :param is_fixed_term: The is_fixed_term of this Contracts. # noqa: E501 + :type: bool + """ + + self._is_fixed_term = is_fixed_term + + @property + def fixed_term_end_date(self): + """Gets the fixed_term_end_date of this Contracts. # noqa: E501 + + The fixed term end date of the employee. Not required if isFixedTerm is false or not provided (required if trying to create Fixed term contract) # noqa: E501 + + :return: The fixed_term_end_date of this Contracts. # noqa: E501 + :rtype: date + """ + return self._fixed_term_end_date + + @fixed_term_end_date.setter + def fixed_term_end_date(self, fixed_term_end_date): + """Sets the fixed_term_end_date of this Contracts. + + The fixed term end date of the employee. Not required if isFixedTerm is false or not provided (required if trying to create Fixed term contract) # noqa: E501 + + :param fixed_term_end_date: The fixed_term_end_date of this Contracts. # noqa: E501 + :type: date + """ + + self._fixed_term_end_date = fixed_term_end_date + + @property + def developmental_role_details(self): + """Gets the developmental_role_details of this Contracts. # noqa: E501 + + + :return: The developmental_role_details of this Contracts. # noqa: E501 + :rtype: DevelopmentalRoleDetails + """ + return self._developmental_role_details + + @developmental_role_details.setter + def developmental_role_details(self, developmental_role_details): + """Sets the developmental_role_details of this Contracts. + + + :param developmental_role_details: The developmental_role_details of this Contracts. # noqa: E501 + :type: DevelopmentalRoleDetails + """ + + self._developmental_role_details = developmental_role_details diff --git a/xero_python/payrolluk/models/developmental_role_details.py b/xero_python/payrolluk/models/developmental_role_details.py new file mode 100644 index 00000000..9b43e009 --- /dev/null +++ b/xero_python/payrolluk/models/developmental_role_details.py @@ -0,0 +1,165 @@ +# coding: utf-8 + +""" +Xero Payroll UK + +This is the Xero Payroll API for orgs in the UK region. # noqa: E501 + +Contact: api@xero.com +Generated by: https://openapi-generator.tech +""" + + +import re # noqa: F401 + +from xero_python.models import BaseModel + + +class DevelopmentalRoleDetails(BaseModel): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + "start_date": "date", + "end_date": "date", + "developmental_role": "str", + "public_key": "str", + } + + attribute_map = { + "start_date": "startDate", + "end_date": "endDate", + "developmental_role": "developmentalRole", + "public_key": "publicKey", + } + + def __init__( + self, start_date=None, end_date=None, developmental_role=None, public_key=None + ): # noqa: E501 + """DevelopmentalRoleDetails - a model defined in OpenAPI""" # noqa: E501 + + self._start_date = None + self._end_date = None + self._developmental_role = None + self._public_key = None + self.discriminator = None + + self.start_date = start_date + self.end_date = end_date + self.developmental_role = developmental_role + if public_key is not None: + self.public_key = public_key + + @property + def start_date(self): + """Gets the start_date of this DevelopmentalRoleDetails. # noqa: E501 + + The start date of the developmental role # noqa: E501 + + :return: The start_date of this DevelopmentalRoleDetails. # noqa: E501 + :rtype: date + """ + return self._start_date + + @start_date.setter + def start_date(self, start_date): + """Sets the start_date of this DevelopmentalRoleDetails. + + The start date of the developmental role # noqa: E501 + + :param start_date: The start_date of this DevelopmentalRoleDetails. # noqa: E501 + :type: date + """ + if start_date is None: + raise ValueError( + "Invalid value for `start_date`, must not be `None`" + ) # noqa: E501 + + self._start_date = start_date + + @property + def end_date(self): + """Gets the end_date of this DevelopmentalRoleDetails. # noqa: E501 + + The end date of the developmental role # noqa: E501 + + :return: The end_date of this DevelopmentalRoleDetails. # noqa: E501 + :rtype: date + """ + return self._end_date + + @end_date.setter + def end_date(self, end_date): + """Sets the end_date of this DevelopmentalRoleDetails. + + The end date of the developmental role # noqa: E501 + + :param end_date: The end_date of this DevelopmentalRoleDetails. # noqa: E501 + :type: date + """ + if end_date is None: + raise ValueError( + "Invalid value for `end_date`, must not be `None`" + ) # noqa: E501 + + self._end_date = end_date + + @property + def developmental_role(self): + """Gets the developmental_role of this DevelopmentalRoleDetails. # noqa: E501 + + The developmental role type - \"Apprentice\" is the only supported role currently # noqa: E501 + + :return: The developmental_role of this DevelopmentalRoleDetails. # noqa: E501 + :rtype: str + """ + return self._developmental_role + + @developmental_role.setter + def developmental_role(self, developmental_role): + """Sets the developmental_role of this DevelopmentalRoleDetails. + + The developmental role type - \"Apprentice\" is the only supported role currently # noqa: E501 + + :param developmental_role: The developmental_role of this DevelopmentalRoleDetails. # noqa: E501 + :type: str + """ + if developmental_role is None: + raise ValueError( + "Invalid value for `developmental_role`, must not be `None`" + ) # noqa: E501 + + self._developmental_role = developmental_role + + @property + def public_key(self): + """Gets the public_key of this DevelopmentalRoleDetails. # noqa: E501 + + The public key of the developmental role. Public key is required if the intention is to edit an existing developmental role. If no key is supplied a new developmental role will be created # noqa: E501 + + :return: The public_key of this DevelopmentalRoleDetails. # noqa: E501 + :rtype: str + """ + return self._public_key + + @public_key.setter + def public_key(self, public_key): + """Sets the public_key of this DevelopmentalRoleDetails. + + The public key of the developmental role. Public key is required if the intention is to edit an existing developmental role. If no key is supplied a new developmental role will be created # noqa: E501 + + :param public_key: The public_key of this DevelopmentalRoleDetails. # noqa: E501 + :type: str + """ + + self._public_key = public_key diff --git a/xero_python/payrolluk/models/employee.py b/xero_python/payrolluk/models/employee.py index c3e011e3..9424f783 100644 --- a/xero_python/payrolluk/models/employee.py +++ b/xero_python/payrolluk/models/employee.py @@ -48,6 +48,7 @@ class Employee(BaseModel): "ni_categories": "list[NICategory]", "national_insurance_number": "str", "is_off_payroll_worker": "bool", + "contracts": "list[Contracts]", } attribute_map = { @@ -69,6 +70,7 @@ class Employee(BaseModel): "ni_categories": "niCategories", "national_insurance_number": "nationalInsuranceNumber", "is_off_payroll_worker": "isOffPayrollWorker", + "contracts": "contracts", } def __init__( @@ -91,6 +93,7 @@ def __init__( ni_categories=None, national_insurance_number=None, is_off_payroll_worker=None, + contracts=None, ): # noqa: E501 """Employee - a model defined in OpenAPI""" # noqa: E501 @@ -112,6 +115,7 @@ def __init__( self._ni_categories = None self._national_insurance_number = None self._is_off_payroll_worker = None + self._contracts = None self.discriminator = None if employee_id is not None: @@ -144,6 +148,8 @@ def __init__( self.national_insurance_number = national_insurance_number if is_off_payroll_worker is not None: self.is_off_payroll_worker = is_off_payroll_worker + if contracts is not None: + self.contracts = contracts @property def employee_id(self): @@ -587,3 +593,26 @@ def is_off_payroll_worker(self, is_off_payroll_worker): """ self._is_off_payroll_worker = is_off_payroll_worker + + @property + def contracts(self): + """Gets the contracts of this Employee. # noqa: E501 + + The employee's contracts # noqa: E501 + + :return: The contracts of this Employee. # noqa: E501 + :rtype: list[Contracts] + """ + return self._contracts + + @contracts.setter + def contracts(self, contracts): + """Sets the contracts of this Employee. + + The employee's contracts # noqa: E501 + + :param contracts: The contracts of this Employee. # noqa: E501 + :type: list[Contracts] + """ + + self._contracts = contracts diff --git a/xero_python/payrolluk/models/employment.py b/xero_python/payrolluk/models/employment.py index 65a9d314..a350aa9c 100644 --- a/xero_python/payrolluk/models/employment.py +++ b/xero_python/payrolluk/models/employment.py @@ -35,6 +35,7 @@ class Employment(BaseModel): "employee_number": "str", "ni_category": "NICategoryLetter", "ni_categories": "list[NICategory]", + "contracts": "list[Contracts]", } attribute_map = { @@ -43,6 +44,7 @@ class Employment(BaseModel): "employee_number": "employeeNumber", "ni_category": "niCategory", "ni_categories": "niCategories", + "contracts": "contracts", } def __init__( @@ -52,6 +54,7 @@ def __init__( employee_number=None, ni_category=None, ni_categories=None, + contracts=None, ): # noqa: E501 """Employment - a model defined in OpenAPI""" # noqa: E501 @@ -60,6 +63,7 @@ def __init__( self._employee_number = None self._ni_category = None self._ni_categories = None + self._contracts = None self.discriminator = None self.payroll_calendar_id = payroll_calendar_id @@ -68,6 +72,8 @@ def __init__( if ni_category is not None: self.ni_category = ni_category self.ni_categories = ni_categories + if contracts is not None: + self.contracts = contracts @property def payroll_calendar_id(self): @@ -197,3 +203,26 @@ def ni_categories(self, ni_categories): ) # noqa: E501 self._ni_categories = ni_categories + + @property + def contracts(self): + """Gets the contracts of this Employment. # noqa: E501 + + The employee's contracts # noqa: E501 + + :return: The contracts of this Employment. # noqa: E501 + :rtype: list[Contracts] + """ + return self._contracts + + @contracts.setter + def contracts(self, contracts): + """Sets the contracts of this Employment. + + The employee's contracts # noqa: E501 + + :param contracts: The contracts of this Employment. # noqa: E501 + :type: list[Contracts] + """ + + self._contracts = contracts diff --git a/xero_python/payrolluk/models/employment_status.py b/xero_python/payrolluk/models/employment_status.py new file mode 100644 index 00000000..ab4e2e49 --- /dev/null +++ b/xero_python/payrolluk/models/employment_status.py @@ -0,0 +1,29 @@ +# coding: utf-8 + +""" +Xero Payroll UK + +This is the Xero Payroll API for orgs in the UK region. # noqa: E501 + +Contact: api@xero.com +Generated by: https://openapi-generator.tech +""" + + +import re # noqa: F401 + +from enum import Enum + + +class EmploymentStatus(Enum): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + allowed enum values + """ + + EMPLOYEE = "Employee" + WORKER = "Worker" + UNSPECIFIED = "Unspecified" diff --git a/xero_python/project/api/project_api.py b/xero_python/project/api/project_api.py index 20804929..ecf04843 100644 --- a/xero_python/project/api/project_api.py +++ b/xero_python/project/api/project_api.py @@ -21,7 +21,7 @@ """ """ - OpenAPI spec version: 9.2.0 + OpenAPI spec version: 9.3.0 """