Skip to content

Commit e37c1be

Browse files
committed
Releasing 11.0.1 (OAS: 13.0.0)
1 parent 50239d6 commit e37c1be

20 files changed

Lines changed: 120 additions & 1320 deletions

File tree

docs/v1/accounting/index.html

Lines changed: 6 additions & 691 deletions
Large diffs are not rendered by default.

docs/v1/files/index.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -881,6 +881,16 @@
881881
"description" : "The size of the associated file in bytes. Note- The Size element is only returned when using /Associations/{ObjectId} endpoint.",
882882
"example" : 12357
883883
},
884+
"CreatedDateUtc" : {
885+
"type" : "string",
886+
"description" : "The date the file was created (UTC). Note- The CreatedDateUtc element is only returned when using /Associations/{ObjectId} endpoint.",
887+
"format" : "date-time"
888+
},
889+
"AssociationDateUtc" : {
890+
"type" : "string",
891+
"description" : "The date the file was associated with the object (UTC). Note- The AssociationDateUtc element is only returned when using /Associations/{ObjectId} endpoint.",
892+
"format" : "date-time"
893+
},
884894
"FileId" : {
885895
"type" : "string",
886896
"description" : "The unique identifier of the file",

xero_python/accounting/api/accounting_api.py

Lines changed: 1 addition & 340 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
"""
2222

2323
"""
24-
OpenAPI spec version: 12.0.2
24+
OpenAPI spec version: 13.0.0
2525
"""
2626

2727

@@ -2063,96 +2063,6 @@ def create_currency(
20632063
except exceptions.HTTPStatusException as error:
20642064
raise translate_status_exception(error, self, "create_currency")
20652065

2066-
def create_employees(
2067-
self,
2068-
xero_tenant_id,
2069-
employees,
2070-
summarize_errors=empty,
2071-
idempotency_key=empty,
2072-
_return_http_data_only=True,
2073-
_preload_content=True,
2074-
_request_timeout=None,
2075-
):
2076-
"""Creates new employees used in Xero payrun # noqa: E501
2077-
OAuth2 scope: accounting.settings
2078-
This endpoint is deprecated and will be removed April 28, 2026 # noqa: E501
2079-
:param str xero_tenant_id: Xero identifier for Tenant (required)
2080-
:param Employees employees: Employees with array of Employee object in body of request (required)
2081-
:param bool summarize_errors: If false return 200 OK and mix of successfully created objects and any with validation errors
2082-
:param str idempotency_key: This allows you to safely retry requests without the risk of duplicate processing. 128 character max.
2083-
:param bool _return_http_data_only: return received data only
2084-
:param bool _preload_content: load received data in models
2085-
:param bool _request_timeout: maximum wait time for response
2086-
:return: Employees
2087-
"""
2088-
2089-
# verify the required parameter 'xero_tenant_id' is set
2090-
if xero_tenant_id is None:
2091-
raise ValueError(
2092-
"Missing the required parameter `xero_tenant_id` "
2093-
"when calling `create_employees`"
2094-
)
2095-
# verify the required parameter 'employees' is set
2096-
if employees is None:
2097-
raise ValueError(
2098-
"Missing the required parameter `employees` "
2099-
"when calling `create_employees`"
2100-
)
2101-
2102-
collection_formats = {}
2103-
path_params = {}
2104-
2105-
query_params = []
2106-
2107-
if summarize_errors is not empty:
2108-
query_params.append(("summarizeErrors", summarize_errors))
2109-
2110-
header_params = {
2111-
"xero-tenant-id": xero_tenant_id,
2112-
}
2113-
2114-
if idempotency_key is not empty:
2115-
header_params["Idempotency-Key"] = idempotency_key
2116-
2117-
local_var_files = {}
2118-
form_params = []
2119-
2120-
body_params = employees
2121-
# HTTP header `Accept`
2122-
header_params["Accept"] = self.api_client.select_header_accept(
2123-
["application/json"]
2124-
)
2125-
2126-
# HTTP header `Content-Type`
2127-
header_params["Content-Type"] = self.api_client.select_header_content_type(
2128-
["application/json"]
2129-
)
2130-
2131-
# Authentication setting
2132-
auth_settings = ["OAuth2"]
2133-
url = self.get_resource_url("/Employees")
2134-
2135-
try:
2136-
return self.api_client.call_api(
2137-
url,
2138-
"PUT",
2139-
path_params,
2140-
query_params,
2141-
header_params,
2142-
body=body_params,
2143-
post_params=form_params,
2144-
files=local_var_files,
2145-
response_type="Employees",
2146-
response_model_finder=self.get_model_finder(),
2147-
auth_settings=auth_settings,
2148-
_return_http_data_only=_return_http_data_only,
2149-
_preload_content=_preload_content,
2150-
_request_timeout=_request_timeout,
2151-
collection_formats=collection_formats,
2152-
)
2153-
except exceptions.HTTPStatusException as error:
2154-
raise translate_status_exception(error, self, "create_employees")
2155-
21562066
def create_expense_claim_history(
21572067
self,
21582068
xero_tenant_id,
@@ -10143,165 +10053,6 @@ def get_currencies(
1014310053
except exceptions.HTTPStatusException as error:
1014410054
raise translate_status_exception(error, self, "get_currencies")
1014510055

10146-
def get_employee(
10147-
self,
10148-
xero_tenant_id,
10149-
employee_id,
10150-
_return_http_data_only=True,
10151-
_preload_content=True,
10152-
_request_timeout=None,
10153-
):
10154-
"""Retrieves a specific employee used in Xero payrun using a unique employee Id # noqa: E501
10155-
OAuth2 scope: accounting.settings, accounting.settings.read
10156-
This endpoint is deprecated and will be removed April 28, 2026 # noqa: E501
10157-
:param str xero_tenant_id: Xero identifier for Tenant (required)
10158-
:param str employee_id: Unique identifier for a Employee (required)
10159-
:param bool _return_http_data_only: return received data only
10160-
:param bool _preload_content: load received data in models
10161-
:param bool _request_timeout: maximum wait time for response
10162-
:return: Employees
10163-
"""
10164-
10165-
# verify the required parameter 'xero_tenant_id' is set
10166-
if xero_tenant_id is None:
10167-
raise ValueError(
10168-
"Missing the required parameter `xero_tenant_id` "
10169-
"when calling `get_employee`"
10170-
)
10171-
# verify the required parameter 'employee_id' is set
10172-
if employee_id is None:
10173-
raise ValueError(
10174-
"Missing the required parameter `employee_id` "
10175-
"when calling `get_employee`"
10176-
)
10177-
10178-
collection_formats = {}
10179-
path_params = {
10180-
"EmployeeID": employee_id,
10181-
}
10182-
10183-
query_params = []
10184-
10185-
header_params = {
10186-
"xero-tenant-id": xero_tenant_id,
10187-
}
10188-
10189-
local_var_files = {}
10190-
form_params = []
10191-
10192-
body_params = None
10193-
# HTTP header `Accept`
10194-
header_params["Accept"] = self.api_client.select_header_accept(
10195-
["application/json"]
10196-
)
10197-
10198-
# Authentication setting
10199-
auth_settings = ["OAuth2"]
10200-
url = self.get_resource_url("/Employees/{EmployeeID}")
10201-
10202-
try:
10203-
return self.api_client.call_api(
10204-
url,
10205-
"GET",
10206-
path_params,
10207-
query_params,
10208-
header_params,
10209-
body=body_params,
10210-
post_params=form_params,
10211-
files=local_var_files,
10212-
response_type="Employees",
10213-
response_model_finder=self.get_model_finder(),
10214-
auth_settings=auth_settings,
10215-
_return_http_data_only=_return_http_data_only,
10216-
_preload_content=_preload_content,
10217-
_request_timeout=_request_timeout,
10218-
collection_formats=collection_formats,
10219-
)
10220-
except exceptions.HTTPStatusException as error:
10221-
raise translate_status_exception(error, self, "get_employee")
10222-
10223-
def get_employees(
10224-
self,
10225-
xero_tenant_id,
10226-
if_modified_since=empty,
10227-
where=empty,
10228-
order=empty,
10229-
_return_http_data_only=True,
10230-
_preload_content=True,
10231-
_request_timeout=None,
10232-
):
10233-
"""Retrieves employees used in Xero payrun # noqa: E501
10234-
OAuth2 scope: accounting.settings, accounting.settings.read
10235-
This endpoint is deprecated and will be removed April 28, 2026 # noqa: E501
10236-
:param str xero_tenant_id: Xero identifier for Tenant (required)
10237-
:param datetime if_modified_since: Only records created or modified since this timestamp will be returned
10238-
:param str where: Filter by an any element
10239-
:param str order: Order by an any element
10240-
:param bool _return_http_data_only: return received data only
10241-
:param bool _preload_content: load received data in models
10242-
:param bool _request_timeout: maximum wait time for response
10243-
:return: Employees
10244-
"""
10245-
10246-
# verify the required parameter 'xero_tenant_id' is set
10247-
if xero_tenant_id is None:
10248-
raise ValueError(
10249-
"Missing the required parameter `xero_tenant_id` "
10250-
"when calling `get_employees`"
10251-
)
10252-
10253-
collection_formats = {}
10254-
path_params = {}
10255-
10256-
query_params = []
10257-
10258-
if where is not empty:
10259-
query_params.append(("where", where))
10260-
10261-
if order is not empty:
10262-
query_params.append(("order", order))
10263-
10264-
header_params = {
10265-
"xero-tenant-id": xero_tenant_id,
10266-
}
10267-
10268-
if if_modified_since is not empty:
10269-
header_params["If-Modified-Since"] = if_modified_since
10270-
10271-
local_var_files = {}
10272-
form_params = []
10273-
10274-
body_params = None
10275-
# HTTP header `Accept`
10276-
header_params["Accept"] = self.api_client.select_header_accept(
10277-
["application/json"]
10278-
)
10279-
10280-
# Authentication setting
10281-
auth_settings = ["OAuth2"]
10282-
url = self.get_resource_url("/Employees")
10283-
10284-
try:
10285-
return self.api_client.call_api(
10286-
url,
10287-
"GET",
10288-
path_params,
10289-
query_params,
10290-
header_params,
10291-
body=body_params,
10292-
post_params=form_params,
10293-
files=local_var_files,
10294-
response_type="Employees",
10295-
response_model_finder=self.get_model_finder(),
10296-
auth_settings=auth_settings,
10297-
_return_http_data_only=_return_http_data_only,
10298-
_preload_content=_preload_content,
10299-
_request_timeout=_request_timeout,
10300-
collection_formats=collection_formats,
10301-
)
10302-
except exceptions.HTTPStatusException as error:
10303-
raise translate_status_exception(error, self, "get_employees")
10304-
1030510056
def get_expense_claim(
1030610057
self,
1030710058
xero_tenant_id,
@@ -19271,96 +19022,6 @@ def update_or_create_credit_notes(
1927119022
error, self, "update_or_create_credit_notes"
1927219023
)
1927319024

19274-
def update_or_create_employees(
19275-
self,
19276-
xero_tenant_id,
19277-
employees,
19278-
summarize_errors=empty,
19279-
idempotency_key=empty,
19280-
_return_http_data_only=True,
19281-
_preload_content=True,
19282-
_request_timeout=None,
19283-
):
19284-
"""Creates a single new employees used in Xero payrun # noqa: E501
19285-
OAuth2 scope: accounting.settings
19286-
This endpoint is deprecated and will be removed April 28, 2026 # noqa: E501
19287-
:param str xero_tenant_id: Xero identifier for Tenant (required)
19288-
:param Employees employees: Employees with array of Employee object in body of request (required)
19289-
:param bool summarize_errors: If false return 200 OK and mix of successfully created objects and any with validation errors
19290-
:param str idempotency_key: This allows you to safely retry requests without the risk of duplicate processing. 128 character max.
19291-
:param bool _return_http_data_only: return received data only
19292-
:param bool _preload_content: load received data in models
19293-
:param bool _request_timeout: maximum wait time for response
19294-
:return: Employees
19295-
"""
19296-
19297-
# verify the required parameter 'xero_tenant_id' is set
19298-
if xero_tenant_id is None:
19299-
raise ValueError(
19300-
"Missing the required parameter `xero_tenant_id` "
19301-
"when calling `update_or_create_employees`"
19302-
)
19303-
# verify the required parameter 'employees' is set
19304-
if employees is None:
19305-
raise ValueError(
19306-
"Missing the required parameter `employees` "
19307-
"when calling `update_or_create_employees`"
19308-
)
19309-
19310-
collection_formats = {}
19311-
path_params = {}
19312-
19313-
query_params = []
19314-
19315-
if summarize_errors is not empty:
19316-
query_params.append(("summarizeErrors", summarize_errors))
19317-
19318-
header_params = {
19319-
"xero-tenant-id": xero_tenant_id,
19320-
}
19321-
19322-
if idempotency_key is not empty:
19323-
header_params["Idempotency-Key"] = idempotency_key
19324-
19325-
local_var_files = {}
19326-
form_params = []
19327-
19328-
body_params = employees
19329-
# HTTP header `Accept`
19330-
header_params["Accept"] = self.api_client.select_header_accept(
19331-
["application/json"]
19332-
)
19333-
19334-
# HTTP header `Content-Type`
19335-
header_params["Content-Type"] = self.api_client.select_header_content_type(
19336-
["application/json"]
19337-
)
19338-
19339-
# Authentication setting
19340-
auth_settings = ["OAuth2"]
19341-
url = self.get_resource_url("/Employees")
19342-
19343-
try:
19344-
return self.api_client.call_api(
19345-
url,
19346-
"POST",
19347-
path_params,
19348-
query_params,
19349-
header_params,
19350-
body=body_params,
19351-
post_params=form_params,
19352-
files=local_var_files,
19353-
response_type="Employees",
19354-
response_model_finder=self.get_model_finder(),
19355-
auth_settings=auth_settings,
19356-
_return_http_data_only=_return_http_data_only,
19357-
_preload_content=_preload_content,
19358-
_request_timeout=_request_timeout,
19359-
collection_formats=collection_formats,
19360-
)
19361-
except exceptions.HTTPStatusException as error:
19362-
raise translate_status_exception(error, self, "update_or_create_employees")
19363-
1936419025
def update_or_create_invoices(
1936519026
self,
1936619027
xero_tenant_id,

0 commit comments

Comments
 (0)