Skip to content

Commit

Permalink
feat: add read-only params to sign templates (box/box-openapi#400)
Browse files Browse the repository at this point in the history
  • Loading branch information
box-sdk-build committed Feb 28, 2024
1 parent c32e802 commit 70dbd4b
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 72 deletions.
1 change: 1 addition & 0 deletions .codegen.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{ "engineHash": "48b83ea", "specHash": "d32ad54", "version": "0.1.0" }
16 changes: 2 additions & 14 deletions docs/fileVersionLegalHolds.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,7 @@ This operation is performed by calling function `getFileVersionLegalHoldById`.
See the endpoint docs at
[API Reference](https://developer.box.com/reference/get-file-version-legal-holds-id/).

<!-- sample get_file_version_legal_holds_id -->

```ts
await client.fileVersionLegalHolds.getFileVersionLegalHoldById(
fileVersionLegalHoldId
);
```
_Currently we don't have an example for calling `getFileVersionLegalHoldById` in integration tests_

### Arguments

Expand Down Expand Up @@ -64,13 +58,7 @@ This operation is performed by calling function `getFileVersionLegalHolds`.
See the endpoint docs at
[API Reference](https://developer.box.com/reference/get-file-version-legal-holds/).

<!-- sample get_file_version_legal_holds -->

```ts
await client.fileVersionLegalHolds.getFileVersionLegalHolds({
policyId: policyId,
} satisfies GetFileVersionLegalHoldsQueryParams);
```
_Currently we don't have an example for calling `getFileVersionLegalHolds` in integration tests_

### Arguments

Expand Down
32 changes: 11 additions & 21 deletions src/schemas.generated.ts
Original file line number Diff line number Diff line change
Expand Up @@ -311,9 +311,6 @@ export interface AccessToken {
readonly refreshToken?: string;
readonly issuedTokenType?: AccessTokenIssuedTokenTypeField;
}
export type GenericSource = {
readonly [key: string]: string;
};
export type IntegrationMappingBaseIntegrationTypeField = 'slack';
export interface IntegrationMappingBase {
readonly id?: string;
Expand Down Expand Up @@ -1697,11 +1694,10 @@ export type Folder = FolderMini & {
readonly itemStatus?: FolderItemStatusField;
readonly itemCollection?: Items;
};
export type EventSourceOrFileOrFolderOrGenericSourceOrUser =
export type EventSourceOrFileOrFolderOrUser =
| EventSource
| File
| Folder
| GenericSource
| User;
export type EventEventTypeField =
| 'ACCESS_GRANTED'
Expand Down Expand Up @@ -1846,7 +1842,7 @@ export interface Event {
readonly createdBy?: UserMini;
readonly eventType?: EventEventTypeField;
readonly sessionId?: string;
readonly source?: EventSourceOrFileOrFolderOrGenericSourceOrUser;
readonly source?: EventSourceOrFileOrFolderOrUser;
readonly additionalDetails?: EventAdditionalDetailsField;
}
export interface Events {
Expand Down Expand Up @@ -4906,12 +4902,6 @@ export function deserializeAccessToken(val: any): AccessToken {
issuedTokenType: issuedTokenType,
} satisfies AccessToken;
}
export function serializeGenericSource(val: GenericSource): SerializedData {
return val;
}
export function deserializeGenericSource(val: any): GenericSource {
return val;
}
export function serializeIntegrationMappingBaseIntegrationTypeField(
val: IntegrationMappingBaseIntegrationTypeField
): SerializedData {
Expand Down Expand Up @@ -14098,18 +14088,18 @@ export function deserializeFolder(val: any): Folder {
type: type,
} satisfies Folder;
}
export function serializeEventSourceOrFileOrFolderOrGenericSourceOrUser(
val: EventSourceOrFileOrFolderOrGenericSourceOrUser
export function serializeEventSourceOrFileOrFolderOrUser(
val: EventSourceOrFileOrFolderOrUser
): SerializedData {
throw new BoxSdkError({
message: "Can't serialize EventSourceOrFileOrFolderOrGenericSourceOrUser",
message: "Can't serialize EventSourceOrFileOrFolderOrUser",
});
}
export function deserializeEventSourceOrFileOrFolderOrGenericSourceOrUser(
export function deserializeEventSourceOrFileOrFolderOrUser(
val: any
): EventSourceOrFileOrFolderOrGenericSourceOrUser {
): EventSourceOrFileOrFolderOrUser {
throw new BoxSdkError({
message: "Can't deserialize EventSourceOrFileOrFolderOrGenericSourceOrUser",
message: "Can't deserialize EventSourceOrFileOrFolderOrUser",
});
}
export function serializeEventEventTypeField(
Expand Down Expand Up @@ -14552,7 +14542,7 @@ export function serializeEvent(val: Event): SerializedData {
['source']:
val.source == void 0
? void 0
: serializeEventSourceOrFileOrFolderOrGenericSourceOrUser(val.source),
: serializeEventSourceOrFileOrFolderOrUser(val.source),
['additional_details']:
val.additionalDetails == void 0
? void 0
Expand All @@ -14575,10 +14565,10 @@ export function deserializeEvent(val: any): Event {
: deserializeEventEventTypeField(val.event_type);
const sessionId: undefined | string =
val.session_id == void 0 ? void 0 : val.session_id;
const source: undefined | EventSourceOrFileOrFolderOrGenericSourceOrUser =
const source: undefined | EventSourceOrFileOrFolderOrUser =
val.source == void 0
? void 0
: deserializeEventSourceOrFileOrFolderOrGenericSourceOrUser(val.source);
: deserializeEventSourceOrFileOrFolderOrUser(val.source);
const additionalDetails: undefined | EventAdditionalDetailsField =
val.additional_details == void 0
? void 0
Expand Down
37 changes: 0 additions & 37 deletions src/test/fileVersionLegalHolds.generated.test.ts

This file was deleted.

0 comments on commit 70dbd4b

Please sign in to comment.