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": "4.3.0" }
{ "engineHash": "bfb97cc", "specHash": "77eac4b", "version": "4.3.0" }
12 changes: 6 additions & 6 deletions src/sdk-gen/managers/folders.ts
Original file line number Diff line number Diff line change
Expand Up @@ -293,9 +293,10 @@ export interface GetFolderByIdQueryParams {
/**
* The offset of the item at which to begin the response.
*
* Queries with offset parameter value
* exceeding 10000 will be rejected
* with a 400 response. */
* 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. */
readonly offset?: number;
/**
* The maximum number of items to return per page. */
Expand Down Expand Up @@ -684,9 +685,8 @@ export interface GetFolderItemsQueryParams {
/**
* The offset of the item at which to begin the response.
*
* Queries with offset parameter value
* exceeding 10000 will be rejected
* with a 400 response. */
* 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`. */
readonly offset?: number;
/**
* The maximum number of items to return per page. */
Expand Down
26 changes: 24 additions & 2 deletions src/sdk-gen/managers/signRequests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,16 @@ import { serializeSignRequest } from '../schemas/signRequest';
import { deserializeSignRequest } from '../schemas/signRequest';
import { serializeClientError } from '../schemas/clientError';
import { deserializeClientError } from '../schemas/clientError';
import { serializeSignRequestCancelRequest } from '../schemas/signRequestCancelRequest';
import { deserializeSignRequestCancelRequest } from '../schemas/signRequestCancelRequest';
import { serializeSignRequests } from '../schemas/signRequests';
import { deserializeSignRequests } from '../schemas/signRequests';
import { serializeSignRequestCreateRequest } from '../schemas/signRequestCreateRequest';
import { deserializeSignRequestCreateRequest } from '../schemas/signRequestCreateRequest';
import { ResponseFormat } from '../networking/fetchOptions';
import { SignRequest } from '../schemas/signRequest';
import { ClientError } from '../schemas/clientError';
import { SignRequestCancelRequest } from '../schemas/signRequestCancelRequest';
import { SignRequests } from '../schemas/signRequests';
import { SignRequestCreateRequest } from '../schemas/signRequestCreateRequest';
import { BoxSdkError } from '../box/errors';
Expand All @@ -29,12 +32,24 @@ import { sdIsString } from '../serialization/json';
import { sdIsList } from '../serialization/json';
import { sdIsMap } from '../serialization/json';
export class CancelSignRequestOptionals {
readonly requestBody?: SignRequestCancelRequest = void 0;
readonly headers: CancelSignRequestHeaders = new CancelSignRequestHeaders({});
readonly cancellationToken?: CancellationToken = void 0;
constructor(
fields: Omit<CancelSignRequestOptionals, 'headers' | 'cancellationToken'> &
Partial<Pick<CancelSignRequestOptionals, 'headers' | 'cancellationToken'>>
fields: Omit<
CancelSignRequestOptionals,
'requestBody' | 'headers' | 'cancellationToken'
> &
Partial<
Pick<
CancelSignRequestOptionals,
'requestBody' | 'headers' | 'cancellationToken'
>
>
) {
if (fields.requestBody !== undefined) {
this.requestBody = fields.requestBody;
}
if (fields.headers !== undefined) {
this.headers = fields.headers;
}
Expand All @@ -44,6 +59,7 @@ export class CancelSignRequestOptionals {
}
}
export interface CancelSignRequestOptionalsInput {
readonly requestBody?: SignRequestCancelRequest;
readonly headers?: CancelSignRequestHeaders;
readonly cancellationToken?: CancellationToken;
}
Expand Down Expand Up @@ -274,9 +290,11 @@ export class SignRequestsManager {
): Promise<SignRequest> {
const optionals: CancelSignRequestOptionals =
new CancelSignRequestOptionals({
requestBody: optionalsInput.requestBody,
headers: optionalsInput.headers,
cancellationToken: optionalsInput.cancellationToken,
});
const requestBody: any = optionals.requestBody;
const headers: any = optionals.headers;
const cancellationToken: any = optionals.cancellationToken;
const headersMap: {
Expand All @@ -293,6 +311,10 @@ export class SignRequestsManager {
) as string,
method: 'POST',
headers: headersMap,
data: !(requestBody == void 0)
? serializeSignRequestCancelRequest(requestBody)
: void 0,
contentType: 'application/json',
responseFormat: 'json' as ResponseFormat,
auth: this.auth,
networkSession: this.networkSession,
Expand Down
2 changes: 1 addition & 1 deletion src/sdk-gen/schemas/aiExtractStructuredResponse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export interface AiExtractStructuredResponse {
* The reason the response finishes. */
readonly completionReason?: string;
/**
* 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. */
readonly confidenceScore?: {
readonly [key: string]: any;
};
Expand Down
1 change: 1 addition & 0 deletions src/sdk-gen/schemas/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ export * from './shieldInformationBarrierReportDetails';
export * from './shieldInformationBarrierSegmentMemberBase';
export * from './shieldInformationBarrierSegmentRestrictionBase';
export * from './shieldInformationBarrierSegmentRestrictionMini';
export * from './signRequestCancelRequest';
export * from './signRequestCreateSigner';
export * from './signRequestPrefillTag';
export * from './signRequestBase';
Expand Down
36 changes: 36 additions & 0 deletions src/sdk-gen/schemas/signRequestCancelRequest.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import { BoxSdkError } from '../box/errors';
import { SerializedData } from '../serialization/json';
import { sdIsEmpty } from '../serialization/json';
import { sdIsBoolean } from '../serialization/json';
import { sdIsNumber } from '../serialization/json';
import { sdIsString } from '../serialization/json';
import { sdIsList } from '../serialization/json';
import { sdIsMap } from '../serialization/json';
export interface SignRequestCancelRequest {
/**
* An optional reason for cancelling the sign request. */
readonly reason?: string;
readonly rawData?: SerializedData;
}
export function serializeSignRequestCancelRequest(
val: SignRequestCancelRequest
): SerializedData {
return { ['reason']: val.reason };
}
export function deserializeSignRequestCancelRequest(
val: SerializedData
): SignRequestCancelRequest {
if (!sdIsMap(val)) {
throw new BoxSdkError({
message: 'Expecting a map for "SignRequestCancelRequest"',
});
}
if (!(val.reason == void 0) && !sdIsString(val.reason)) {
throw new BoxSdkError({
message:
'Expecting string for "reason" of type "SignRequestCancelRequest"',
});
}
const reason: undefined | string = val.reason == void 0 ? void 0 : val.reason;
return { reason: reason } satisfies SignRequestCancelRequest;
}
14 changes: 14 additions & 0 deletions src/sdk-gen/schemas/signRequestCreateSigner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,10 @@ export interface SignRequestCreateSigner {
/**
* If true, no emails about the sign request will be sent. */
readonly suppressNotifications?: boolean | null;
/**
* The language of the user, formatted in modified version of the
* [ISO 639-1](https://developer.box.com/guides/api-calls/language-codes) format. */
readonly language?: string | null;
readonly rawData?: SerializedData;
}
export function serializeSignRequestCreateSignerRoleField(
Expand Down Expand Up @@ -119,6 +123,7 @@ export function serializeSignRequestCreateSigner(
['password']: val.password,
['signer_group_id']: val.signerGroupId,
['suppress_notifications']: val.suppressNotifications,
['language']: val.language,
};
}
export function deserializeSignRequestCreateSigner(
Expand Down Expand Up @@ -233,6 +238,14 @@ export function deserializeSignRequestCreateSigner(
}
const suppressNotifications: undefined | boolean =
val.suppress_notifications == void 0 ? void 0 : val.suppress_notifications;
if (!(val.language == void 0) && !sdIsString(val.language)) {
throw new BoxSdkError({
message:
'Expecting string for "language" of type "SignRequestCreateSigner"',
});
}
const language: undefined | string =
val.language == void 0 ? void 0 : val.language;
return {
email: email,
role: role,
Expand All @@ -246,5 +259,6 @@ export function deserializeSignRequestCreateSigner(
password: password,
signerGroupId: signerGroupId,
suppressNotifications: suppressNotifications,
language: language,
} satisfies SignRequestCreateSigner;
}
8 changes: 8 additions & 0 deletions src/sdk-gen/schemas/signRequestSigner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -336,6 +336,13 @@ export function deserializeSignRequestSigner(
}
const suppressNotifications: undefined | boolean =
val.suppress_notifications == void 0 ? void 0 : val.suppress_notifications;
if (!(val.language == void 0) && !sdIsString(val.language)) {
throw new BoxSdkError({
message: 'Expecting string for "language" of type "SignRequestSigner"',
});
}
const language: undefined | string =
val.language == void 0 ? void 0 : val.language;
return {
hasViewedDocument: hasViewedDocument,
signerDecision: signerDecision,
Expand All @@ -355,5 +362,6 @@ export function deserializeSignRequestSigner(
password: password,
signerGroupId: signerGroupId,
suppressNotifications: suppressNotifications,
language: language,
} satisfies SignRequestSigner;
}
Loading