diff --git a/.codegen.json b/.codegen.json index 11213633..cb58a4bf 100644 --- a/.codegen.json +++ b/.codegen.json @@ -1 +1 @@ -{ "engineHash": "7146a71", "specHash": "7eec0db", "version": "10.13.0" } +{ "engineHash": "7146a71", "specHash": "86fcc6c", "version": "10.13.0" } diff --git a/package-lock.json b/package-lock.json index c5421642..eb092189 100644 --- a/package-lock.json +++ b/package-lock.json @@ -749,9 +749,9 @@ } }, "node_modules/@jest/reporters/node_modules/brace-expansion": { - "version": "1.1.16", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.16.tgz", - "integrity": "sha512-IDw48K2/2kRkg9LdJxurvq3lV3aBgq0REY89duEqFRthjlPdXHKMj7EnQOXVckxzgisinf3nHfrcE2FufFLXMw==", + "version": "1.1.18", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.18.tgz", + "integrity": "sha512-Edep/X9fGqVNmzKBVsDYIOtD+z1tuezV70LBjdCst9Tqu76lsnvRiZ6oTic1n+/BIwX6QDGAO94PN4N2SADvtw==", "dev": true, "license": "MIT", "dependencies": { @@ -2188,9 +2188,9 @@ "license": "MIT" }, "node_modules/baseline-browser-mapping": { - "version": "2.11.6", - "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.11.6.tgz", - "integrity": "sha512-69D/imtToCsIcAl8WBS2YaRwA4jO/j0HhU+hELqMEu9f54MoUtI6+XH5mrKU8rEFNEk/Ui1I2MK4/JkWacclGw==", + "version": "2.11.8", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.11.8.tgz", + "integrity": "sha512-zAgkquC2WYF0PIc6XbNYkA2uuxxFavzgmX61R+dHDUa558V8Ejf8ozTZFR6QzM24RWu4kBcRkhJ5kpz77j9fnQ==", "dev": true, "license": "Apache-2.0", "bin": { @@ -2223,9 +2223,9 @@ } }, "node_modules/brace-expansion": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.3.tgz", - "integrity": "sha512-DRdx5neNsG/QXbniLFWi2YmC/68oeOOmKz6zOjVk6ZS1ZLXgLIKqVEc6hWsmkjBbgii0SwaBTcJ5XKj5gzY/4A==", + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.4.tgz", + "integrity": "sha512-hGfVzPxthbf3+2yjg/RBs60cB0FhqBS/zvdV/4wn4/BmN0bNMMHPc4V/BbFieqf1TKAGGAHnY4eSjajCl0f2Xg==", "dev": true, "license": "MIT", "dependencies": { @@ -2728,9 +2728,9 @@ } }, "node_modules/electron-to-chromium": { - "version": "1.5.397", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.397.tgz", - "integrity": "sha512-khGTy9U9x02KEtsKM8vx5A62BsRmcOsIgDpWr1ImE32Ax8GxHGPHZf+Eu9H8zOOyHJnB0jTbseyTHbq2XCT8yw==", + "version": "1.5.399", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.399.tgz", + "integrity": "sha512-lEcqhErbHjXRvd41rnWLpzbyU/IXfIYo7QwaFWmxGeLiLyY2TBCdHnWY88vB+p3ubnihRypDm66panXl7TylLA==", "dev": true, "license": "ISC" }, @@ -2755,9 +2755,9 @@ "license": "MIT" }, "node_modules/enhanced-resolve": { - "version": "5.24.3", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.24.3.tgz", - "integrity": "sha512-PwKooW9JUzh5chmYfHM3IQl5OkK2u2Nm011MgeZrss3JmFraUx/fqrf78kk8GUMYoibx/14MdwTl/1WKkG7TpQ==", + "version": "5.24.5", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.24.5.tgz", + "integrity": "sha512-L1l8TNvomm6UVW5B253AGxQagSQr+vGwhMlrrfRS2qmhx46AMpMVJKQYLvWYbysTMY8VoicOvzHzoHMbyzB+4A==", "dev": true, "license": "MIT", "peer": true, @@ -3045,9 +3045,9 @@ "license": "MIT" }, "node_modules/fast-uri": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.4.tgz", - "integrity": "sha512-8JnbkQ4juDyvYs4mgFGQqg4yCYtFDtUtmp2QIQq11ZZe5CFQ5wcqm1rqDgAh/QdMySuBnPzMUiJUNZG5N/AiQw==", + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.5.tgz", + "integrity": "sha512-gHwA1O9LDIcKunMKhObS/HimwtehO1nPUECKAu5TpKgaO19fcWEl4bliWe1jWxVFvIXztJjjQ4L8XQ1EU9f7Jw==", "dev": true, "funding": [ { @@ -3537,9 +3537,9 @@ "license": "ISC" }, "node_modules/ip-address": { - "version": "10.3.1", - "resolved": "https://registry.npmjs.org/ip-address/-/ip-address-10.3.1.tgz", - "integrity": "sha512-1e9d3kb97NHJTIJDZW9rKqW2h6+dFa50Dy0fpPSMQp2ADje5gvKsXmdiK6dwY5t76TaTt5+P5N1Y/LoToIxP6g==", + "version": "10.4.0", + "resolved": "https://registry.npmjs.org/ip-address/-/ip-address-10.4.0.tgz", + "integrity": "sha512-oSK96Grm3aP6OrS263xVxbNDGVL7rzBtYdpGqlDG8iQdoenDoTs/nkki+DflYbAEE8Xl6o5YxhxlrKvI3nqKXQ==", "license": "MIT", "engines": { "node": ">= 12" @@ -3910,9 +3910,9 @@ } }, "node_modules/jest-config/node_modules/brace-expansion": { - "version": "1.1.16", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.16.tgz", - "integrity": "sha512-IDw48K2/2kRkg9LdJxurvq3lV3aBgq0REY89duEqFRthjlPdXHKMj7EnQOXVckxzgisinf3nHfrcE2FufFLXMw==", + "version": "1.1.18", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.18.tgz", + "integrity": "sha512-Edep/X9fGqVNmzKBVsDYIOtD+z1tuezV70LBjdCst9Tqu76lsnvRiZ6oTic1n+/BIwX6QDGAO94PN4N2SADvtw==", "dev": true, "license": "MIT", "dependencies": { @@ -4252,9 +4252,9 @@ } }, "node_modules/jest-runtime/node_modules/brace-expansion": { - "version": "1.1.16", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.16.tgz", - "integrity": "sha512-IDw48K2/2kRkg9LdJxurvq3lV3aBgq0REY89duEqFRthjlPdXHKMj7EnQOXVckxzgisinf3nHfrcE2FufFLXMw==", + "version": "1.1.18", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.18.tgz", + "integrity": "sha512-Edep/X9fGqVNmzKBVsDYIOtD+z1tuezV70LBjdCst9Tqu76lsnvRiZ6oTic1n+/BIwX6QDGAO94PN4N2SADvtw==", "dev": true, "license": "MIT", "dependencies": { @@ -5832,9 +5832,9 @@ } }, "node_modules/test-exclude/node_modules/brace-expansion": { - "version": "1.1.16", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.16.tgz", - "integrity": "sha512-IDw48K2/2kRkg9LdJxurvq3lV3aBgq0REY89duEqFRthjlPdXHKMj7EnQOXVckxzgisinf3nHfrcE2FufFLXMw==", + "version": "1.1.18", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.18.tgz", + "integrity": "sha512-Edep/X9fGqVNmzKBVsDYIOtD+z1tuezV70LBjdCst9Tqu76lsnvRiZ6oTic1n+/BIwX6QDGAO94PN4N2SADvtw==", "dev": true, "license": "MIT", "dependencies": { @@ -6193,9 +6193,9 @@ "license": "BSD-2-Clause" }, "node_modules/webpack": { - "version": "5.109.1", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.109.1.tgz", - "integrity": "sha512-Q4XQscWSLNQSaMFsIWUZ+IVpvwLqD+MvjIuSQC1hG8m1ZMK78VAsNMhTjD3icJelypp6aM5Hq8BZNEX3sc1PJw==", + "version": "5.109.2", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.109.2.tgz", + "integrity": "sha512-U9/cvLzxObKNEZ9+TtdqrHM5/9z3lgl2c+c4BzbqGxFQvQvBAq87yql5A8pQ+rrMbS496MZJeF5enVBndIy2hw==", "dev": true, "license": "MIT", "peer": true, @@ -6208,7 +6208,7 @@ "acorn": "^8.16.0", "browserslist": "^4.28.1", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.24.2", + "enhanced-resolve": "^5.24.4", "es-module-lexer": "^2.1.0", "eslint-scope": "5.1.1", "events": "^3.2.0", diff --git a/src/managers/users.ts b/src/managers/users.ts index c6a9518f..9a0bf71c 100644 --- a/src/managers/users.ts +++ b/src/managers/users.ts @@ -516,6 +516,11 @@ export interface UpdateUserByIdRequestBody { /** * Whether the user is required to reset their password. */ readonly isPasswordResetRequired?: boolean; + /** + * Whether collaborators can access content owned by the user when + * the user is inactive. This setting preserves existing + * collaborator access and does not grant new permissions. */ + readonly isCollaboratedContentAvailableWhenOwnerInactive?: boolean; /** * The user's account status. */ readonly status?: UpdateUserByIdRequestBodyStatusField; @@ -1375,6 +1380,8 @@ export function serializeUpdateUserByIdRequestBody( ['is_exempt_from_device_limits']: val.isExemptFromDeviceLimits, ['is_exempt_from_login_verification']: val.isExemptFromLoginVerification, ['is_password_reset_required']: val.isPasswordResetRequired, + ['is_collaborated_content_available_when_owner_inactive']: + val.isCollaboratedContentAvailableWhenOwnerInactive, ['status']: val.status == void 0 ? val.status @@ -1555,6 +1562,19 @@ export function deserializeUpdateUserByIdRequestBody( val.is_password_reset_required == void 0 ? void 0 : val.is_password_reset_required; + if ( + !(val.is_collaborated_content_available_when_owner_inactive == void 0) && + !sdIsBoolean(val.is_collaborated_content_available_when_owner_inactive) + ) { + throw new BoxSdkError({ + message: + 'Expecting boolean for "is_collaborated_content_available_when_owner_inactive" of type "UpdateUserByIdRequestBody"', + }); + } + const isCollaboratedContentAvailableWhenOwnerInactive: undefined | boolean = + val.is_collaborated_content_available_when_owner_inactive == void 0 + ? void 0 + : val.is_collaborated_content_available_when_owner_inactive; const status: undefined | UpdateUserByIdRequestBodyStatusField = val.status == void 0 ? void 0 @@ -1603,6 +1623,8 @@ export function deserializeUpdateUserByIdRequestBody( isExemptFromDeviceLimits: isExemptFromDeviceLimits, isExemptFromLoginVerification: isExemptFromLoginVerification, isPasswordResetRequired: isPasswordResetRequired, + isCollaboratedContentAvailableWhenOwnerInactive: + isCollaboratedContentAvailableWhenOwnerInactive, status: status, spaceAmount: spaceAmount, notificationEmail: notificationEmail, diff --git a/src/schemas/userFull.ts b/src/schemas/userFull.ts index d0ec729b..813327bf 100644 --- a/src/schemas/userFull.ts +++ b/src/schemas/userFull.ts @@ -52,6 +52,7 @@ export class UserFull extends User { readonly isExternalCollabRestricted?: boolean; readonly isExemptFromDeviceLimits?: boolean; readonly isExemptFromLoginVerification?: boolean; + readonly isCollaboratedContentAvailableWhenOwnerInactive?: boolean; readonly enterprise?: UserFullEnterpriseField; readonly myTags?: readonly string[]; readonly hostname?: string; @@ -80,6 +81,10 @@ export class UserFull extends User { if (fields.isExemptFromLoginVerification !== undefined) { this.isExemptFromLoginVerification = fields.isExemptFromLoginVerification; } + if (fields.isCollaboratedContentAvailableWhenOwnerInactive !== undefined) { + this.isCollaboratedContentAvailableWhenOwnerInactive = + fields.isCollaboratedContentAvailableWhenOwnerInactive; + } if (fields.enterprise !== undefined) { this.enterprise = fields.enterprise; } @@ -195,6 +200,8 @@ export function serializeUserFull(val: UserFull): SerializedData { ['is_external_collab_restricted']: val.isExternalCollabRestricted, ['is_exempt_from_device_limits']: val.isExemptFromDeviceLimits, ['is_exempt_from_login_verification']: val.isExemptFromLoginVerification, + ['is_collaborated_content_available_when_owner_inactive']: + val.isCollaboratedContentAvailableWhenOwnerInactive, ['enterprise']: val.enterprise == void 0 ? val.enterprise @@ -287,6 +294,19 @@ export function deserializeUserFull(val: SerializedData): UserFull { val.is_exempt_from_login_verification == void 0 ? void 0 : val.is_exempt_from_login_verification; + if ( + !(val.is_collaborated_content_available_when_owner_inactive == void 0) && + !sdIsBoolean(val.is_collaborated_content_available_when_owner_inactive) + ) { + throw new BoxSdkError({ + message: + 'Expecting boolean for "is_collaborated_content_available_when_owner_inactive" of type "UserFull"', + }); + } + const isCollaboratedContentAvailableWhenOwnerInactive: undefined | boolean = + val.is_collaborated_content_available_when_owner_inactive == void 0 + ? void 0 + : val.is_collaborated_content_available_when_owner_inactive; const enterprise: undefined | UserFullEnterpriseField = val.enterprise == void 0 ? void 0 @@ -458,6 +478,8 @@ export function deserializeUserFull(val: SerializedData): UserFull { isExternalCollabRestricted: isExternalCollabRestricted, isExemptFromDeviceLimits: isExemptFromDeviceLimits, isExemptFromLoginVerification: isExemptFromLoginVerification, + isCollaboratedContentAvailableWhenOwnerInactive: + isCollaboratedContentAvailableWhenOwnerInactive, enterprise: enterprise, myTags: myTags, hostname: hostname,