Skip to content
Merged
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
2 changes: 1 addition & 1 deletion .codegen.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{ "engineHash": "bfb97cc", "specHash": "ccdb456", "version": "5.3.0" }
{ "engineHash": "bfb97cc", "specHash": "77eac4b", "version": "5.3.0" }
2 changes: 2 additions & 0 deletions docs/sdkgen/signrequests.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ client.getSignRequests().cancelSignRequest(createdSignRequest.getId())

- signRequestId `String`
- The ID of the signature request. Example: "33243242"
- requestBody `SignRequestCancelRequest`
- Request body of cancelSignRequest method
- headers `CancelSignRequestHeaders`
- Headers of cancelSignRequest method

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ public class GetFolderByIdQueryParams {
/**
* The offset of the item at which to begin the response.
*
* <p>Queries with offset parameter value exceeding 10000 will be rejected with a 400 response.
* <p>Offset-based pagination is not guaranteed to work reliably for high offset values and may
* fail for large datasets. In those cases, reduce the number of items in the folder (for example,
* by restructuring the folder into smaller subfolders) before retrying the request.
*/
public Long offset;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ public class GetFolderItemsQueryParams {
/**
* The offset of the item at which to begin the response.
*
* <p>Queries with offset parameter value exceeding 10000 will be rejected with a 400 response.
* <p>Offset-based pagination is not guaranteed to work reliably for high offset values and may
* fail for large datasets. In those cases, use marker-based pagination by setting `usemarker` to
* `true`.
*/
public Long offset;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import com.box.sdkgen.networking.fetchresponse.FetchResponse;
import com.box.sdkgen.networking.network.NetworkSession;
import com.box.sdkgen.schemas.signrequest.SignRequest;
import com.box.sdkgen.schemas.signrequestcancelrequest.SignRequestCancelRequest;
import com.box.sdkgen.schemas.signrequestcreaterequest.SignRequestCreateRequest;
import com.box.sdkgen.schemas.signrequests.SignRequests;
import com.box.sdkgen.serialization.json.JsonManager;
Expand All @@ -38,7 +39,17 @@ protected SignRequestsManager(Builder builder) {
* @param signRequestId The ID of the signature request. Example: "33243242"
*/
public SignRequest cancelSignRequest(String signRequestId) {
return cancelSignRequest(signRequestId, new CancelSignRequestHeaders());
return cancelSignRequest(signRequestId, null, new CancelSignRequestHeaders());
}

/**
* Cancels a sign request.
*
* @param signRequestId The ID of the signature request. Example: "33243242"
* @param requestBody Request body of cancelSignRequest method
*/
public SignRequest cancelSignRequest(String signRequestId, SignRequestCancelRequest requestBody) {
return cancelSignRequest(signRequestId, requestBody, new CancelSignRequestHeaders());
}

/**
Expand All @@ -48,6 +59,20 @@ public SignRequest cancelSignRequest(String signRequestId) {
* @param headers Headers of cancelSignRequest method
*/
public SignRequest cancelSignRequest(String signRequestId, CancelSignRequestHeaders headers) {
return cancelSignRequest(signRequestId, null, headers);
}

/**
* Cancels a sign request.
*
* @param signRequestId The ID of the signature request. Example: "33243242"
* @param requestBody Request body of cancelSignRequest method
* @param headers Headers of cancelSignRequest method
*/
public SignRequest cancelSignRequest(
String signRequestId,
SignRequestCancelRequest requestBody,
CancelSignRequestHeaders headers) {
Map<String, String> headersMap = prepareParams(mergeMaps(mapOf(), headers.getExtraHeaders()));
FetchResponse response =
this.networkSession
Expand All @@ -62,6 +87,8 @@ public SignRequest cancelSignRequest(String signRequestId, CancelSignRequestHead
"/cancel"),
"POST")
.headers(headersMap)
.data((!(requestBody == null) ? JsonManager.serialize(requestBody) : null))
.contentType("application/json")
.responseFormat(ResponseFormat.JSON)
.auth(this.auth)
.networkSession(this.networkSession)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ public class AiExtractStructuredResponse extends SerializableObject {
protected String completionReason;

/**
* The confidence score numeric values for each extracted field as a JSON dictionary. This can be
* empty if no field could be extracted.
* The confidence score levels and numeric values for each extracted field as a JSON dictionary.
* This can be empty if no field could be extracted.
*/
@JsonProperty("confidence_score")
protected Map<String, Object> confidenceScore;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
package com.box.sdkgen.schemas.signrequestcancelrequest;

import com.box.sdkgen.internal.NullableFieldTracker;
import com.box.sdkgen.internal.SerializableObject;
import com.fasterxml.jackson.annotation.JsonFilter;
import java.util.Objects;

/** Request body for cancelling a sign request. */
@JsonFilter("nullablePropertyFilter")
public class SignRequestCancelRequest extends SerializableObject {

/** An optional reason for cancelling the sign request. */
protected String reason;

public SignRequestCancelRequest() {
super();
}

protected SignRequestCancelRequest(Builder builder) {
super();
this.reason = builder.reason;
markNullableFieldsAsSet(builder.getExplicitlySetNullableFields());
}

public String getReason() {
return reason;
}

@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
SignRequestCancelRequest casted = (SignRequestCancelRequest) o;
return Objects.equals(reason, casted.reason);
}

@Override
public int hashCode() {
return Objects.hash(reason);
}

@Override
public String toString() {
return "SignRequestCancelRequest{" + "reason='" + reason + '\'' + "}";
}

public static class Builder extends NullableFieldTracker {

protected String reason;

public Builder reason(String reason) {
this.reason = reason;
return this;
}

public SignRequestCancelRequest build() {
return new SignRequestCancelRequest(this);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,12 @@ public class SignRequestCreateSigner extends SerializableObject {
@Nullable
protected Boolean suppressNotifications;

/**
* The language of the user, formatted in modified version of the [ISO
* 639-1](https://developer.box.com/guides/api-calls/language-codes) format.
*/
@Nullable protected String language;

public SignRequestCreateSigner() {
super();
}
Expand All @@ -126,6 +132,7 @@ protected SignRequestCreateSigner(Builder builder) {
this.password = builder.password;
this.signerGroupId = builder.signerGroupId;
this.suppressNotifications = builder.suppressNotifications;
this.language = builder.language;
markNullableFieldsAsSet(builder.getExplicitlySetNullableFields());
}

Expand Down Expand Up @@ -177,6 +184,10 @@ public Boolean getSuppressNotifications() {
return suppressNotifications;
}

public String getLanguage() {
return language;
}

@Override
public boolean equals(Object o) {
if (this == o) {
Expand All @@ -197,7 +208,8 @@ public boolean equals(Object o) {
&& Objects.equals(verificationPhoneNumber, casted.verificationPhoneNumber)
&& Objects.equals(password, casted.password)
&& Objects.equals(signerGroupId, casted.signerGroupId)
&& Objects.equals(suppressNotifications, casted.suppressNotifications);
&& Objects.equals(suppressNotifications, casted.suppressNotifications)
&& Objects.equals(language, casted.language);
}

@Override
Expand All @@ -214,7 +226,8 @@ public int hashCode() {
verificationPhoneNumber,
password,
signerGroupId,
suppressNotifications);
suppressNotifications,
language);
}

@Override
Expand Down Expand Up @@ -267,6 +280,10 @@ public String toString() {
+ "suppressNotifications='"
+ suppressNotifications
+ '\''
+ ", "
+ "language='"
+ language
+ '\''
+ "}";
}

Expand Down Expand Up @@ -296,6 +313,8 @@ public static class Builder extends NullableFieldTracker {

protected Boolean suppressNotifications;

protected String language;

public Builder email(String email) {
this.email = email;
this.markNullableFieldAsSet("email");
Expand Down Expand Up @@ -370,6 +389,12 @@ public Builder suppressNotifications(Boolean suppressNotifications) {
return this;
}

public Builder language(String language) {
this.language = language;
this.markNullableFieldAsSet("language");
return this;
}

public SignRequestCreateSigner build() {
return new SignRequestCreateSigner(this);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ public boolean equals(Object o) {
&& Objects.equals(password, casted.password)
&& Objects.equals(signerGroupId, casted.signerGroupId)
&& Objects.equals(suppressNotifications, casted.suppressNotifications)
&& Objects.equals(language, casted.language)
&& Objects.equals(hasViewedDocument, casted.hasViewedDocument)
&& Objects.equals(signerDecision, casted.signerDecision)
&& Objects.equals(inputs, casted.inputs)
Expand All @@ -126,6 +127,7 @@ public int hashCode() {
password,
signerGroupId,
suppressNotifications,
language,
hasViewedDocument,
signerDecision,
inputs,
Expand Down Expand Up @@ -185,6 +187,10 @@ public String toString() {
+ suppressNotifications
+ '\''
+ ", "
+ "language='"
+ language
+ '\''
+ ", "
+ "hasViewedDocument='"
+ hasViewedDocument
+ '\''
Expand Down Expand Up @@ -346,6 +352,13 @@ public Builder suppressNotifications(Boolean suppressNotifications) {
return this;
}

@Override
public Builder language(String language) {
this.language = language;
this.markNullableFieldAsSet("language");
return this;
}

public SignRequestSigner build() {
return new SignRequestSigner(this);
}
Expand Down