Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 28 additions & 2 deletions docs/v4/accounting/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4756,6 +4756,11 @@
"description" : "Returns Invoice number field. Reference field isn't available.",
"readOnly" : true
},
"InvoiceNumber" : {
"type" : "string",
"description" : "Returns Invoice number for prepayment receive document only.",
"readOnly" : true
},
"UpdatedDateUTC" : {
"type" : "string",
"description" : "UTC timestamp of last update to the prepayment",
Expand Down Expand Up @@ -6346,7 +6351,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Accounting"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Accounting"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="Accounting"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="Accounting"><a href="#api-Accounting">Methods</a></li>
<li data-group="Accounting" data-name="createAccount" class="">
<a href="#api-Accounting-createAccount">createAccount</a>
Expand Down Expand Up @@ -33683,9 +33688,10 @@ <h3>Usage and SDK Samples</h3>
Integer page = 1;
Integer unitdp = 4;
Integer pageSize = 100;
array[String] invoiceNumbers = &quot;INV-001&quot;, &quot;INV-002&quot;;

try {
Prepayments result = apiInstance.getPrepayments(accessToken, xeroTenantId, ifModifiedSince, where, order, page, unitdp, pageSize);
Prepayments result = apiInstance.getPrepayments(accessToken, xeroTenantId, ifModifiedSince, where, order, page, unitdp, pageSize, invoiceNumbers);
System.out.println(result);
} catch (XeroException e) {
System.err.println("Exception when calling AccountingApi#getPrepayments");
Expand Down Expand Up @@ -33867,6 +33873,26 @@ <h2>Parameters</h2>
</div>
</div>
</td>
</tr>

<tr><td style="width:150px;">InvoiceNumbers</td>
<td>


<div id="d2e199_getPrepayments_invoiceNumbers">
<div class="json-schema-view">
<div class="primitive">
<span class="type">
array[String]
</span>

<div class="inner description marked">
Filter by a comma-separated list of InvoiceNumbers
</div>
</div>
</div>
</div>
</td>
</tr>

</table>
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/appstore/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1238,7 +1238,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="AppStore"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="AppStore"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="AppStore"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="AppStore"><a href="#api-AppStore">Methods</a></li>
<li data-group="AppStore" data-name="getSubscription" class="">
<a href="#api-AppStore-getSubscription">getSubscription</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/assets/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1416,7 +1416,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Asset"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Asset"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="Asset"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="Asset"><a href="#api-Asset">Methods</a></li>
<li data-group="Asset" data-name="createAsset" class="">
<a href="#api-Asset-createAsset">createAsset</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/files/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1145,7 +1145,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Files"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Files"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="Files"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="Files"><a href="#api-Files">Methods</a></li>
<li data-group="Files" data-name="createFileAssociation" class="">
<a href="#api-Files-createFileAssociation">createFileAssociation</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/finance/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2372,7 +2372,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="Finance"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="Finance"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="Finance"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="Finance"><a href="#api-Finance">Methods</a></li>
<li data-group="Finance" data-name="getBankStatementAccounting" class="">
<a href="#api-Finance-getBankStatementAccounting">getBankStatementAccounting</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/payroll-au-v2/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1156,7 +1156,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="PayrollAuV2"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="PayrollAuV2"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="PayrollAuV2"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="PayrollAuV2"><a href="#api-PayrollAuV2">Methods</a></li>
<li data-group="PayrollAuV2" data-name="approveTimesheet" class="">
<a href="#api-PayrollAuV2-approveTimesheet">approveTimesheet</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/payroll-au/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3446,7 +3446,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="PayrollAu"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="PayrollAu"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="PayrollAu"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="PayrollAu"><a href="#api-PayrollAu">Methods</a></li>
<li data-group="PayrollAu" data-name="approveLeaveApplication" class="">
<a href="#api-PayrollAu-approveLeaveApplication">approveLeaveApplication</a>
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/payroll-nz/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4064,7 +4064,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="PayrollNz"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="PayrollNz"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="PayrollNz"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="PayrollNz"><a href="#api-PayrollNz">Methods</a></li>
<li data-group="PayrollNz" data-name="approveTimesheet" class="">
<a href="#api-PayrollNz-approveTimesheet">approveTimesheet</a>
Expand Down
6 changes: 3 additions & 3 deletions docs/v4/payroll-uk/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1458,7 +1458,7 @@
"earningsType" : {
"type" : "string",
"description" : "Indicates how an employee will be paid when taking this type of earning",
"enum" : [ "Allowance", "BackPay", "Bonus", "Commission", "LumpSum", "OtherEarnings", "OvertimeEarnings", "RegularEarnings", "StatutoryAdoptionPay", "StatutoryAdoptionPayNonPensionable", "StatutoryBereavementPay", "StatutoryMaternityPay", "StatutoryMaternityPayNonPensionable", "StatutoryPaternityPay", "StatutoryPaternityPayNonPensionable", "StatutoryParentalBereavementPayNonPensionable", "StatutorySharedParentalPay", "StatutorySharedParentalPayNonPensionable", "StatutorySickPay", "StatutorySickPayNonPensionable", "TipsNonDirect", "TipsDirect", "TerminationPay", "StatutoryNeonatalCarePay", "StatutoryNeonatalCarePayNonPensionable" ]
"enum" : [ "Allowance", "BackPay", "Bonus", "Commission", "LumpSum", "OtherEarnings", "OvertimeEarnings", "RegularEarnings", "StatutoryAdoptionPay", "StatutoryAdoptionPayNonPensionable", "StatutoryBereavementPay", "StatutoryMaternityPay", "StatutoryMaternityPayNonPensionable", "StatutoryPaternityPay", "StatutoryPaternityPayNonPensionable", "StatutoryParentalBereavementPayNonPensionable", "StatutorySharedParentalPay", "StatutorySharedParentalPayNonPensionable", "StatutorySickPay", "StatutorySickPayNonPensionable", "TipsNonDirect", "TipsDirect", "TerminationPay", "StatutoryNeonatalCarePay", "StatutoryNeonatalCarePayNonPensionable", "StatutoryBereavementPayNorthernIreland" ]
},
"rateType" : {
"type" : "string",
Expand Down Expand Up @@ -2086,7 +2086,7 @@
"type" : {
"type" : "string",
"description" : "The category of statutory leave",
"enum" : [ "Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement", "NeonatalCare" ]
"enum" : [ "Sick", "Adoption", "Maternity", "Paternity", "Sharedparental", "Bereavement", "NeonatalCare", "BereavementNire" ]
},
"startDate" : {
"type" : "string",
Expand Down Expand Up @@ -3697,7 +3697,7 @@
<nav id="scrollingNav">
<ul class="sidenav nav nav-list">
<li class="nav-header" data-group="PayrollUk"><strong>SDK: </strong><span id='sdk-name'></span></li>
<li class="nav-header" data-group="PayrollUk"><strong>VSN: </strong>13.0.0</li>
<li class="nav-header" data-group="PayrollUk"><strong>VSN: </strong>12.4.1</li>
<li class="nav-header" data-group="PayrollUk"><a href="#api-PayrollUk">Methods</a></li>
<li data-group="PayrollUk" data-name="approveTimesheet" class="">
<a href="#api-PayrollUk-approveTimesheet">approveTimesheet</a>
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>xero-java</artifactId>
<packaging>jar</packaging>
<name>xero-java</name>
<version>13.0.0</version>
<version>12.4.1</version>
<url>https://github.com/XeroAPI/Xero-Java</url>
<description>This is the official Java SDK for Xero API</description>
<licenses>
Expand Down
106 changes: 101 additions & 5 deletions src/main/java/com/xero/api/client/AccountingApi.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Xero Accounting API
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 11.1.0
* The version of the OpenAPI document: 12.0.0
* Contact: api@xero.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down Expand Up @@ -102,7 +102,7 @@ public class AccountingApi {
private ApiClient apiClient;
private static AccountingApi instance = null;
private String userAgent = "Default";
private String version = "13.0.0";
private String version = "12.4.1";
static final Logger logger = LoggerFactory.getLogger(AccountingApi.class);

/** AccountingApi */
Expand Down Expand Up @@ -234,6 +234,70 @@ public HttpResponse getOverpaymentsForHttpResponse(
accessToken, xeroTenantId, ifModifiedSince, where, order, page, unitdp, pageSize, null);
}

/**
* Retrieves prepayments
*
* <p><b>200</b> - Success - return response of type Prepayments array for all Prepayment
*
* @param xeroTenantId Xero identifier for Tenant
* @param ifModifiedSince Only records created or modified since this timestamp will be returned
* @param where Filter by an any element
* @param order Order by an any element
* @param page e.g. page&#x3D;1 – Up to 100 prepayments will be returned in a single API call with
* line items shown for each overpayment
* @param unitdp e.g. unitdp&#x3D;4 – (Unit Decimal Places) You can opt in to use four decimal
* places for unit amounts
* @param pageSize Number of records to retrieve per page
* @param accessToken Authorization token for user set in header of each request
* @return Prepayments
* @throws IOException if an error occurs while attempting to invoke the API *
*/
public Prepayments getPrepayments(
String accessToken,
String xeroTenantId,
OffsetDateTime ifModifiedSince,
String where,
String order,
Integer page,
Integer unitdp,
Integer pageSize)
throws IOException {
return getPrepayments(
accessToken, xeroTenantId, ifModifiedSince, where, order, page, unitdp, pageSize, null);
}

/**
* Retrieves prepayments
*
* <p><b>200</b> - Success - return response of type Prepayments array for all Prepayment
*
* @param xeroTenantId Xero identifier for Tenant
* @param ifModifiedSince Only records created or modified since this timestamp will be returned
* @param where Filter by an any element
* @param order Order by an any element
* @param page e.g. page&#x3D;1 – Up to 100 prepayments will be returned in a single API call with
* line items shown for each overpayment
* @param unitdp e.g. unitdp&#x3D;4 – (Unit Decimal Places) You can opt in to use four decimal
* places for unit amounts
* @param pageSize Number of records to retrieve per page
* @param accessToken Authorization token for user set in header of each request
* @return HttpResponse
* @throws IOException if an error occurs while attempting to invoke the API
*/
public HttpResponse getPrepaymentsForHttpResponse(
String accessToken,
String xeroTenantId,
OffsetDateTime ifModifiedSince,
String where,
String order,
Integer page,
Integer unitdp,
Integer pageSize)
throws IOException {
return getPrepaymentsForHttpResponse(
accessToken, xeroTenantId, ifModifiedSince, where, order, page, unitdp, pageSize, null);
}

/* End backward compatibility functions */

/**
Expand Down Expand Up @@ -20766,6 +20830,7 @@ public HttpResponse getPrepaymentHistoryForHttpResponse(
* @param unitdp e.g. unitdp&#x3D;4 – (Unit Decimal Places) You can opt in to use four decimal
* places for unit amounts
* @param pageSize Number of records to retrieve per page
* @param invoiceNumbers Filter by a comma-separated list of InvoiceNumbers
* @param accessToken Authorization token for user set in header of each request
* @return Prepayments
* @throws IOException if an error occurs while attempting to invoke the API *
Expand All @@ -20778,13 +20843,22 @@ public Prepayments getPrepayments(
String order,
Integer page,
Integer unitdp,
Integer pageSize)
Integer pageSize,
List<String> invoiceNumbers)
throws IOException {
try {
TypeReference<Prepayments> typeRef = new TypeReference<Prepayments>() {};
HttpResponse response =
getPrepaymentsForHttpResponse(
accessToken, xeroTenantId, ifModifiedSince, where, order, page, unitdp, pageSize);
accessToken,
xeroTenantId,
ifModifiedSince,
where,
order,
page,
unitdp,
pageSize,
invoiceNumbers);
return apiClient.getObjectMapper().readValue(response.getContent(), typeRef);
} catch (HttpResponseException e) {
if (logger.isDebugEnabled()) {
Expand Down Expand Up @@ -20816,6 +20890,7 @@ public Prepayments getPrepayments(
* @param unitdp e.g. unitdp&#x3D;4 – (Unit Decimal Places) You can opt in to use four decimal
* places for unit amounts
* @param pageSize Number of records to retrieve per page
* @param invoiceNumbers Filter by a comma-separated list of InvoiceNumbers
* @param accessToken Authorization token for user set in header of each request
* @return HttpResponse
* @throws IOException if an error occurs while attempting to invoke the API
Expand All @@ -20828,7 +20903,8 @@ public HttpResponse getPrepaymentsForHttpResponse(
String order,
Integer page,
Integer unitdp,
Integer pageSize)
Integer pageSize,
List<String> invoiceNumbers)
throws IOException {
// verify the required parameter 'xeroTenantId' is set
if (xeroTenantId == null) {
Expand Down Expand Up @@ -20947,6 +21023,26 @@ public HttpResponse getPrepaymentsForHttpResponse(
uriBuilder = uriBuilder.queryParam(key, value);
}
}
if (invoiceNumbers != null) {
String key = "InvoiceNumbers";
Object value = invoiceNumbers;
if (value instanceof Collection) {
List valueList = new ArrayList<>((Collection) value);
if (!valueList.isEmpty() && valueList.get(0) instanceof UUID) {
List<String> list = new ArrayList<String>();
for (int i = 0; i < valueList.size(); i++) {
list.add(valueList.get(i).toString());
}
uriBuilder = uriBuilder.queryParam(key, String.join(",", list));
} else {
uriBuilder = uriBuilder.queryParam(key, String.join(",", valueList));
}
} else if (value instanceof Object[]) {
uriBuilder = uriBuilder.queryParam(key, (Object[]) value);
} else {
uriBuilder = uriBuilder.queryParam(key, value);
}
}
String url = uriBuilder.build().toString();
GenericUrl genericUrl = new GenericUrl(url);
if (logger.isDebugEnabled()) {
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/xero/api/client/AppStoreApi.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Xero AppStore API
* These endpoints are for Xero Partners to interact with the App Store Billing platform
*
* The version of the OpenAPI document: 11.1.0
* The version of the OpenAPI document: 12.0.0
* Contact: api@xero.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down Expand Up @@ -46,7 +46,7 @@ public class AppStoreApi {
private ApiClient apiClient;
private static AppStoreApi instance = null;
private String userAgent = "Default";
private String version = "13.0.0";
private String version = "12.4.1";
static final Logger logger = LoggerFactory.getLogger(AppStoreApi.class);

/** AppStoreApi */
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/xero/api/client/AssetApi.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Xero Assets API
* The Assets API exposes fixed asset related functions of the Xero Accounting application and can be used for a variety of purposes such as creating assets, retrieving asset valuations etc.
*
* The version of the OpenAPI document: 11.1.0
* The version of the OpenAPI document: 12.0.0
* Contact: api@xero.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down Expand Up @@ -49,7 +49,7 @@ public class AssetApi {
private ApiClient apiClient;
private static AssetApi instance = null;
private String userAgent = "Default";
private String version = "13.0.0";
private String version = "12.4.1";
static final Logger logger = LoggerFactory.getLogger(AssetApi.class);

/** AssetApi */
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/xero/api/client/BankFeedsApi.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Xero Bank Feeds API
* The Bank Feeds API is a closed API that is only available to financial institutions that have an established financial services partnership with Xero. If you're an existing financial services partner that wants access, contact your local Partner Manager. If you're a financial institution who wants to provide bank feeds to your business customers, contact us to become a financial services partner.
*
* The version of the OpenAPI document: 11.1.0
* The version of the OpenAPI document: 12.0.0
* Contact: api@xero.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down Expand Up @@ -48,7 +48,7 @@ public class BankFeedsApi {
private ApiClient apiClient;
private static BankFeedsApi instance = null;
private String userAgent = "Default";
private String version = "13.0.0";
private String version = "12.4.1";
static final Logger logger = LoggerFactory.getLogger(BankFeedsApi.class);

/** BankFeedsApi */
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/xero/api/client/FilesApi.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Xero Files API
* These endpoints are specific to Xero Files API
*
* The version of the OpenAPI document: 11.1.0
* The version of the OpenAPI document: 12.0.0
* Contact: api@xero.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down Expand Up @@ -54,7 +54,7 @@ public class FilesApi {
private ApiClient apiClient;
private static FilesApi instance = null;
private String userAgent = "Default";
private String version = "13.0.0";
private String version = "12.4.1";
static final Logger logger = LoggerFactory.getLogger(FilesApi.class);

/** FilesApi */
Expand Down
Loading
Loading