@unofficialbox/box-open-sdk 0.3.1 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (143) hide show
  1. package/README.md +2 -0
  2. package/dist/cjs/auth.js +3 -3
  3. package/dist/cjs/buildinfo.js +2 -2
  4. package/dist/cjs/client.js +3 -0
  5. package/dist/cjs/jwt.js +1 -1
  6. package/dist/cjs/managers/collaboration_allowlist_entries.js +6 -6
  7. package/dist/cjs/managers/collaboration_allowlist_exempt_targets.js +6 -6
  8. package/dist/cjs/managers/index.js +1 -0
  9. package/dist/cjs/managers/memberships.js +4 -4
  10. package/dist/cjs/managers/query.js +68 -0
  11. package/dist/cjs/models/schemas.js +1 -1
  12. package/dist/cjs/runtime.js +8 -3
  13. package/dist/cjs/tokens.js +5 -3
  14. package/dist/esm/auth.js +3 -3
  15. package/dist/esm/buildinfo.js +2 -2
  16. package/dist/esm/client.js +3 -0
  17. package/dist/esm/jwt.js +1 -1
  18. package/dist/esm/managers/collaboration_allowlist_entries.js +6 -6
  19. package/dist/esm/managers/collaboration_allowlist_exempt_targets.js +6 -6
  20. package/dist/esm/managers/index.js +1 -0
  21. package/dist/esm/managers/memberships.js +4 -4
  22. package/dist/esm/managers/query.js +31 -0
  23. package/dist/esm/models/schemas.js +1 -1
  24. package/dist/esm/runtime.js +8 -3
  25. package/dist/esm/tokens.js +5 -3
  26. package/dist/types/auth.d.ts +8 -0
  27. package/dist/types/buildinfo.d.ts +1 -1
  28. package/dist/types/client.d.ts +2 -0
  29. package/dist/types/jwt.d.ts +4 -0
  30. package/dist/types/managers/archives.d.ts +2 -2
  31. package/dist/types/managers/avatars.d.ts +1 -1
  32. package/dist/types/managers/chunked_uploads.d.ts +3 -3
  33. package/dist/types/managers/classifications.d.ts +3 -3
  34. package/dist/types/managers/collaboration_allowlist_entries.d.ts +7 -7
  35. package/dist/types/managers/collaboration_allowlist_exempt_targets.d.ts +7 -7
  36. package/dist/types/managers/comments.d.ts +2 -2
  37. package/dist/types/managers/email_aliases.d.ts +1 -1
  38. package/dist/types/managers/file_classifications.d.ts +2 -2
  39. package/dist/types/managers/file_metadata.d.ts +4 -4
  40. package/dist/types/managers/file_versions.d.ts +2 -2
  41. package/dist/types/managers/file_watermarks.d.ts +1 -1
  42. package/dist/types/managers/files.d.ts +2 -2
  43. package/dist/types/managers/folder_classifications.d.ts +2 -2
  44. package/dist/types/managers/folder_locks.d.ts +1 -1
  45. package/dist/types/managers/folder_metadata.d.ts +4 -4
  46. package/dist/types/managers/folder_watermarks.d.ts +1 -1
  47. package/dist/types/managers/folders.d.ts +3 -3
  48. package/dist/types/managers/groups.d.ts +2 -2
  49. package/dist/types/managers/index.d.ts +1 -0
  50. package/dist/types/managers/integration_mappings.d.ts +2 -2
  51. package/dist/types/managers/invites.d.ts +1 -1
  52. package/dist/types/managers/legal_hold_policies.d.ts +2 -2
  53. package/dist/types/managers/legal_hold_policy_assignments.d.ts +1 -1
  54. package/dist/types/managers/memberships.d.ts +10 -10
  55. package/dist/types/managers/metadata_cascade_policies.d.ts +2 -2
  56. package/dist/types/managers/metadata_taxonomies.d.ts +6 -6
  57. package/dist/types/managers/metadata_templates.d.ts +4 -4
  58. package/dist/types/managers/query.d.ts +9 -0
  59. package/dist/types/managers/retention_policies.d.ts +2 -2
  60. package/dist/types/managers/retention_policy_assignments.d.ts +1 -1
  61. package/dist/types/managers/session_termination.d.ts +2 -2
  62. package/dist/types/managers/shared_links_files.d.ts +3 -3
  63. package/dist/types/managers/shared_links_folders.d.ts +3 -3
  64. package/dist/types/managers/shared_links_web_links.d.ts +3 -3
  65. package/dist/types/managers/shield_information_barrier_segment_members.d.ts +1 -1
  66. package/dist/types/managers/shield_information_barrier_segment_restrictions.d.ts +1 -1
  67. package/dist/types/managers/shield_information_barrier_segments.d.ts +2 -2
  68. package/dist/types/managers/shield_information_barriers.d.ts +2 -2
  69. package/dist/types/managers/skills.d.ts +3 -3
  70. package/dist/types/managers/storage_policy_assignments.d.ts +2 -2
  71. package/dist/types/managers/task_assignments.d.ts +2 -2
  72. package/dist/types/managers/tasks.d.ts +2 -2
  73. package/dist/types/managers/terms_of_service_user_statuses.d.ts +2 -2
  74. package/dist/types/managers/terms_of_services.d.ts +2 -2
  75. package/dist/types/managers/transfer.d.ts +1 -1
  76. package/dist/types/managers/trashed_files.d.ts +1 -1
  77. package/dist/types/managers/trashed_folders.d.ts +1 -1
  78. package/dist/types/managers/trashed_web_links.d.ts +1 -1
  79. package/dist/types/managers/uploads.d.ts +2 -2
  80. package/dist/types/managers/user_collaborations.d.ts +2 -2
  81. package/dist/types/managers/users.d.ts +2 -2
  82. package/dist/types/managers/web_links.d.ts +2 -2
  83. package/dist/types/managers/webhooks.d.ts +2 -2
  84. package/dist/types/managers/workflows.d.ts +1 -1
  85. package/dist/types/models/schemas.d.ts +204 -141
  86. package/dist/types/runtime.d.ts +10 -0
  87. package/dist/types/tokens.d.ts +4 -2
  88. package/docs/README.md +1 -0
  89. package/docs/managers/archives.md +2 -2
  90. package/docs/managers/avatars.md +1 -1
  91. package/docs/managers/chunked_uploads.md +3 -3
  92. package/docs/managers/classifications.md +3 -3
  93. package/docs/managers/collaboration_allowlist_entries.md +10 -10
  94. package/docs/managers/collaboration_allowlist_exempt_targets.md +10 -10
  95. package/docs/managers/comments.md +2 -2
  96. package/docs/managers/email_aliases.md +1 -1
  97. package/docs/managers/file_classifications.md +2 -2
  98. package/docs/managers/file_metadata.md +5 -5
  99. package/docs/managers/file_versions.md +2 -2
  100. package/docs/managers/file_watermarks.md +1 -1
  101. package/docs/managers/files.md +2 -2
  102. package/docs/managers/folder_classifications.md +2 -2
  103. package/docs/managers/folder_locks.md +1 -1
  104. package/docs/managers/folder_metadata.md +5 -5
  105. package/docs/managers/folder_watermarks.md +1 -1
  106. package/docs/managers/folders.md +3 -3
  107. package/docs/managers/groups.md +2 -2
  108. package/docs/managers/integration_mappings.md +2 -2
  109. package/docs/managers/invites.md +1 -1
  110. package/docs/managers/legal_hold_policies.md +2 -2
  111. package/docs/managers/legal_hold_policy_assignments.md +1 -1
  112. package/docs/managers/memberships.md +10 -10
  113. package/docs/managers/metadata_cascade_policies.md +2 -2
  114. package/docs/managers/metadata_taxonomies.md +6 -6
  115. package/docs/managers/metadata_templates.md +5 -5
  116. package/docs/managers/query.md +33 -0
  117. package/docs/managers/retention_policies.md +2 -2
  118. package/docs/managers/retention_policy_assignments.md +1 -1
  119. package/docs/managers/session_termination.md +2 -2
  120. package/docs/managers/shared_links_files.md +3 -3
  121. package/docs/managers/shared_links_folders.md +3 -3
  122. package/docs/managers/shared_links_web_links.md +3 -3
  123. package/docs/managers/shield_information_barrier_segment_members.md +1 -1
  124. package/docs/managers/shield_information_barrier_segment_restrictions.md +1 -1
  125. package/docs/managers/shield_information_barrier_segments.md +2 -2
  126. package/docs/managers/shield_information_barriers.md +2 -2
  127. package/docs/managers/skills.md +3 -3
  128. package/docs/managers/storage_policy_assignments.md +2 -2
  129. package/docs/managers/task_assignments.md +2 -2
  130. package/docs/managers/tasks.md +2 -2
  131. package/docs/managers/terms_of_service_user_statuses.md +2 -2
  132. package/docs/managers/terms_of_services.md +2 -2
  133. package/docs/managers/transfer.md +1 -1
  134. package/docs/managers/trashed_files.md +1 -1
  135. package/docs/managers/trashed_folders.md +1 -1
  136. package/docs/managers/trashed_web_links.md +1 -1
  137. package/docs/managers/uploads.md +2 -2
  138. package/docs/managers/user_collaborations.md +2 -2
  139. package/docs/managers/users.md +2 -2
  140. package/docs/managers/web_links.md +2 -2
  141. package/docs/managers/webhooks.md +2 -2
  142. package/docs/managers/workflows.md +1 -1
  143. package/package.json +1 -1
@@ -34,6 +34,14 @@ export interface ClientOptions {
34
34
  maxRetries?: number;
35
35
  /** Override individual base-URL classes (custom deployments). */
36
36
  baseUrls?: Record<string, string>;
37
+ /** Override the platform `fetch` (same signature) — e.g. to inject an
38
+ * instrumented or mocked transport. Defaults to the global `fetch`. */
39
+ fetch?: typeof fetch;
40
+ /** Headers sent with every request from this client — e.g. a tracing or
41
+ * `User-Agent` header the embedding application wants on every call. A
42
+ * header set on an individual `Request` (via `withHeader`) takes
43
+ * precedence over a same-named default. */
44
+ headers?: Record<string, string>;
37
45
  }
38
46
  /** The runtime session: it holds the auth flow, base-URL configuration, and
39
47
  * retry policy shared by every manager. */
@@ -41,6 +49,8 @@ export declare class Client {
41
49
  private readonly auth;
42
50
  private readonly baseUrls;
43
51
  private readonly maxRetries;
52
+ private readonly fetchImpl;
53
+ private readonly defaultHeaders;
44
54
  constructor(auth: Auth, options?: ClientOptions);
45
55
  /** The configured base URL for a D-106 class, without a trailing slash. */
46
56
  baseUrl(name: string): string;
@@ -45,6 +45,8 @@ export declare class CachedToken implements Auth {
45
45
  * token acquisition never escapes the runtime's error contract. The optional
46
46
  * `signal` cancels an explicit caller-initiated exchange (`exchangeCode`); the
47
47
  * cached flows do not thread one, so a shared refresh is never bound to a single
48
- * request's cancellation.
48
+ * request's cancellation. `fetchImpl` defaults to the global `fetch`; a caller
49
+ * building an `Auth` with a custom transport (matching the runtime `Client`'s
50
+ * own `fetch` override) passes it through so auth traffic is observable too.
49
51
  */
50
- export declare function postTokenForm(tokenUrl: string, form: Record<string, string>, signal?: AbortSignal): Promise<Token>;
52
+ export declare function postTokenForm(tokenUrl: string, form: Record<string, string>, signal?: AbortSignal, fetchImpl?: typeof fetch): Promise<Token>;
package/docs/README.md CHANGED
@@ -63,6 +63,7 @@ One resource manager per Box API tag, reached through the single
63
63
  | [MetadataTaxonomiesManager](managers/metadata_taxonomies.md) | 15 |
64
64
  | [MetadataTemplatesManager](managers/metadata_templates.md) | 8 |
65
65
  | [NotesManager](managers/notes.md) | 1 |
66
+ | [QueryManager](managers/query.md) | 2 |
66
67
  | [RecentItemsManager](managers/recent_items.md) | 1 |
67
68
  | [RetentionPoliciesManager](managers/retention_policies.md) | 5 |
68
69
  | [RetentionPolicyAssignmentsManager](managers/retention_policy_assignments.md) | 6 |
@@ -28,7 +28,7 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
28
28
 
29
29
  `POST /archives`
30
30
 
31
- **Request body** (`application/json`): `ArchiveCreateRequest`
31
+ **Request body** (`application/json`): `CreateArchiveRequest`
32
32
 
33
33
  **Returns:** `Archive`
34
34
 
@@ -46,7 +46,7 @@ const result = await client.archives.create({ /* … */ });
46
46
  |---|---|---|---|
47
47
  | `archive_id` | path | `string` | yes |
48
48
 
49
- **Request body** (`application/json`): `ArchiveUpdateRequest`
49
+ **Request body** (`application/json`): `UpdateArchiveRequest`
50
50
 
51
51
  **Returns:** `Archive`
52
52
 
@@ -27,7 +27,7 @@ const result = await client.avatars.getUserAvatar("USER_ID");
27
27
  |---|---|---|---|
28
28
  | `user_id` | path | `string` | yes |
29
29
 
30
- **Request body** (`multipart/form-data`): `UserAvatarCreateRequest`
30
+ **Request body** (`multipart/form-data`): `CreateUserAvatarRequest`
31
31
 
32
32
  **Returns:** `UserAvatar`
33
33
 
@@ -7,7 +7,7 @@ Reach these methods through the `chunkedUploads` field on `Client`.
7
7
 
8
8
  `POST /files/upload_sessions`
9
9
 
10
- **Request body** (`application/json`): `FileUploadSessionCreateRequest`
10
+ **Request body** (`application/json`): `CreateFileUploadSessionRequest`
11
11
 
12
12
  **Returns:** `UploadSession`
13
13
 
@@ -25,7 +25,7 @@ const result = await client.chunkedUploads.createFileUploadSession({ /* … */ }
25
25
  |---|---|---|---|
26
26
  | `file_id` | path | `string` | yes |
27
27
 
28
- **Request body** (`application/json`): `FileVersionUploadSessionCreateRequest`
28
+ **Request body** (`application/json`): `CreateFileVersionUploadSessionRequest`
29
29
 
30
30
  **Returns:** `UploadSession`
31
31
 
@@ -120,7 +120,7 @@ Paginated — `listFileUploadSessionParts(...)` is an async iterable that yields
120
120
  | `if-match` | header | `string` | no |
121
121
  | `if-none-match` | header | `string` | no |
122
122
 
123
- **Request body** (`application/json`): `FileUploadSessionCommitRequest`
123
+ **Request body** (`application/json`): `CommitFileUploadSessionRequest`
124
124
 
125
125
  **Returns:** `Files`
126
126
 
@@ -19,7 +19,7 @@ const result = await client.classifications.get();
19
19
 
20
20
  `PUT /metadata_templates/enterprise/securityClassification-6VMVochwUWo/schema`
21
21
 
22
- **Request body** (`application/json`): `Array<ClassificationUpdateRequest>`
22
+ **Request body** (`application/json`): `Array<UpdateClassificationAddRequest>`
23
23
 
24
24
  **Returns:** `ClassificationTemplate`
25
25
 
@@ -33,7 +33,7 @@ const result = await client.classifications.updateAdd([]);
33
33
 
34
34
  `PUT /metadata_templates/enterprise/securityClassification-6VMVochwUWo/schema`
35
35
 
36
- **Request body** (`application/json-patch+json`): `Array<ClassificationUpdateRequest2>`
36
+ **Request body** (`application/json-patch+json`): `Array<UpdateClassificationUpdateRequest>`
37
37
 
38
38
  **Returns:** `ClassificationTemplate`
39
39
 
@@ -47,7 +47,7 @@ const result = await client.classifications.updateUpdate([]);
47
47
 
48
48
  `POST /metadata_templates/schema`
49
49
 
50
- **Request body** (`application/json`): `MetadataTemplateSchemaCreateRequest`
50
+ **Request body** (`application/json`): `CreateMetadataTemplateSchemaClassificationsRequest`
51
51
 
52
52
  **Returns:** `ClassificationTemplate`
53
53
 
@@ -3,7 +3,7 @@
3
3
 
4
4
  Reach these methods through the `collaborationAllowlistEntries` field on `Client`.
5
5
 
6
- ## listCollaborationWhitelistEntries
6
+ ## list
7
7
 
8
8
  `GET /collaboration_whitelist_entries`
9
9
 
@@ -17,28 +17,28 @@ Reach these methods through the `collaborationAllowlistEntries` field on `Client
17
17
  **Example**
18
18
 
19
19
  ```ts
20
- for await (const item of client.collaborationAllowlistEntries.listCollaborationWhitelistEntries()) {
20
+ for await (const item of client.collaborationAllowlistEntries.list()) {
21
21
  // use item
22
22
  }
23
23
  ```
24
24
 
25
- Paginated — `listCollaborationWhitelistEntries(...)` is an async iterable that yields each entry across pages (`for await (const item of ...)`), threading the cursor for you. See the [pagination guide](../pagination.md).
25
+ Paginated — `list(...)` is an async iterable that yields each entry across pages (`for await (const item of ...)`), threading the cursor for you. See the [pagination guide](../pagination.md).
26
26
 
27
- ## createCollaborationWhitelistEntries
27
+ ## create
28
28
 
29
29
  `POST /collaboration_whitelist_entries`
30
30
 
31
- **Request body** (`application/json`): `CollaborationWhitelistEntriesCreateRequest`
31
+ **Request body** (`application/json`): `CreateCollaborationAllowlistEntryRequest`
32
32
 
33
33
  **Returns:** `CollaborationAllowlistEntry`
34
34
 
35
35
  **Example**
36
36
 
37
37
  ```ts
38
- const result = await client.collaborationAllowlistEntries.createCollaborationWhitelistEntries({ /* … */ });
38
+ const result = await client.collaborationAllowlistEntries.create({ /* … */ });
39
39
  ```
40
40
 
41
- ## getCollaborationWhitelistEntry
41
+ ## get
42
42
 
43
43
  `GET /collaboration_whitelist_entries/{collaboration_whitelist_entry_id}`
44
44
 
@@ -51,10 +51,10 @@ const result = await client.collaborationAllowlistEntries.createCollaborationWhi
51
51
  **Example**
52
52
 
53
53
  ```ts
54
- const result = await client.collaborationAllowlistEntries.getCollaborationWhitelistEntry("COLLABORATION_WHITELIST_ENTRY_ID");
54
+ const result = await client.collaborationAllowlistEntries.get("COLLABORATION_WHITELIST_ENTRY_ID");
55
55
  ```
56
56
 
57
- ## deleteCollaborationWhitelistEntry
57
+ ## delete_
58
58
 
59
59
  `DELETE /collaboration_whitelist_entries/{collaboration_whitelist_entry_id}`
60
60
 
@@ -67,6 +67,6 @@ const result = await client.collaborationAllowlistEntries.getCollaborationWhitel
67
67
  **Example**
68
68
 
69
69
  ```ts
70
- await client.collaborationAllowlistEntries.deleteCollaborationWhitelistEntry("COLLABORATION_WHITELIST_ENTRY_ID");
70
+ await client.collaborationAllowlistEntries.delete_("COLLABORATION_WHITELIST_ENTRY_ID");
71
71
  ```
72
72
 
@@ -3,7 +3,7 @@
3
3
 
4
4
  Reach these methods through the `collaborationAllowlistExemptTargets` field on `Client`.
5
5
 
6
- ## listCollaborationWhitelistExemptTargets
6
+ ## list
7
7
 
8
8
  `GET /collaboration_whitelist_exempt_targets`
9
9
 
@@ -17,28 +17,28 @@ Reach these methods through the `collaborationAllowlistExemptTargets` field on `
17
17
  **Example**
18
18
 
19
19
  ```ts
20
- for await (const item of client.collaborationAllowlistExemptTargets.listCollaborationWhitelistExemptTargets()) {
20
+ for await (const item of client.collaborationAllowlistExemptTargets.list()) {
21
21
  // use item
22
22
  }
23
23
  ```
24
24
 
25
- Paginated — `listCollaborationWhitelistExemptTargets(...)` is an async iterable that yields each entry across pages (`for await (const item of ...)`), threading the cursor for you. See the [pagination guide](../pagination.md).
25
+ Paginated — `list(...)` is an async iterable that yields each entry across pages (`for await (const item of ...)`), threading the cursor for you. See the [pagination guide](../pagination.md).
26
26
 
27
- ## createCollaborationWhitelistExemptTargets
27
+ ## create
28
28
 
29
29
  `POST /collaboration_whitelist_exempt_targets`
30
30
 
31
- **Request body** (`application/json`): `CollaborationWhitelistExemptTargetsCreateRequest`
31
+ **Request body** (`application/json`): `CreateCollaborationAllowlistExemptTargetRequest`
32
32
 
33
33
  **Returns:** `CollaborationAllowlistExemptTarget`
34
34
 
35
35
  **Example**
36
36
 
37
37
  ```ts
38
- const result = await client.collaborationAllowlistExemptTargets.createCollaborationWhitelistExemptTargets({ /* … */ });
38
+ const result = await client.collaborationAllowlistExemptTargets.create({ /* … */ });
39
39
  ```
40
40
 
41
- ## getCollaborationWhitelistExemptTarget
41
+ ## get
42
42
 
43
43
  `GET /collaboration_whitelist_exempt_targets/{collaboration_whitelist_exempt_target_id}`
44
44
 
@@ -51,10 +51,10 @@ const result = await client.collaborationAllowlistExemptTargets.createCollaborat
51
51
  **Example**
52
52
 
53
53
  ```ts
54
- const result = await client.collaborationAllowlistExemptTargets.getCollaborationWhitelistExemptTarget("COLLABORATION_WHITELIST_EXEMPT_TARGET_ID");
54
+ const result = await client.collaborationAllowlistExemptTargets.get("COLLABORATION_WHITELIST_EXEMPT_TARGET_ID");
55
55
  ```
56
56
 
57
- ## deleteCollaborationWhitelistExemptTarget
57
+ ## delete_
58
58
 
59
59
  `DELETE /collaboration_whitelist_exempt_targets/{collaboration_whitelist_exempt_target_id}`
60
60
 
@@ -67,6 +67,6 @@ const result = await client.collaborationAllowlistExemptTargets.getCollaboration
67
67
  **Example**
68
68
 
69
69
  ```ts
70
- await client.collaborationAllowlistExemptTargets.deleteCollaborationWhitelistExemptTarget("COLLABORATION_WHITELIST_EXEMPT_TARGET_ID");
70
+ await client.collaborationAllowlistExemptTargets.delete_("COLLABORATION_WHITELIST_EXEMPT_TARGET_ID");
71
71
  ```
72
72
 
@@ -52,7 +52,7 @@ const result = await client.comments.get("COMMENT_ID");
52
52
  | `comment_id` | path | `string` | yes |
53
53
  | `fields` | query | `Array<string>` | no |
54
54
 
55
- **Request body** (`application/json`): `CommentUpdateRequest`
55
+ **Request body** (`application/json`): `UpdateCommentRequest`
56
56
 
57
57
  **Returns:** `CommentFull`
58
58
 
@@ -86,7 +86,7 @@ await client.comments.delete_("COMMENT_ID");
86
86
  |---|---|---|---|
87
87
  | `fields` | query | `Array<string>` | no |
88
88
 
89
- **Request body** (`application/json`): `CommentCreateRequest`
89
+ **Request body** (`application/json`): `CreateCommentRequest`
90
90
 
91
91
  **Returns:** `CommentFull`
92
92
 
@@ -27,7 +27,7 @@ const result = await client.emailAliases.listUser("USER_ID");
27
27
  |---|---|---|---|
28
28
  | `user_id` | path | `string` | yes |
29
29
 
30
- **Request body** (`application/json`): `UserIdCreateRequest`
30
+ **Request body** (`application/json`): `CreateUserIdRequest`
31
31
 
32
32
  **Returns:** `EmailAlias`
33
33
 
@@ -27,7 +27,7 @@ const result = await client.fileClassifications.get("FILE_ID");
27
27
  |---|---|---|---|
28
28
  | `file_id` | path | `string` | yes |
29
29
 
30
- **Request body** (`application/json-patch+json`): `Array<FileClassificationUpdateRequest>`
30
+ **Request body** (`application/json-patch+json`): `Array<UpdateFileClassificationRequest>`
31
31
 
32
32
  **Returns:** `Classification`
33
33
 
@@ -45,7 +45,7 @@ const result = await client.fileClassifications.update("FILE_ID", []);
45
45
  |---|---|---|---|
46
46
  | `file_id` | path | `string` | yes |
47
47
 
48
- **Request body** (`application/json`): `FileClassificationCreateRequest`
48
+ **Request body** (`application/json`): `CreateFileClassificationRequest`
49
49
 
50
50
  **Returns:** `Classification`
51
51
 
@@ -27,7 +27,7 @@ const result = await client.fileMetadata.listFileMetadata("FILE_ID");
27
27
  | Parameter | In | Type | Required |
28
28
  |---|---|---|---|
29
29
  | `file_id` | path | `string` | yes |
30
- | `scope` | path | `GetFileIdMetadataIdIdScope` | yes |
30
+ | `scope` | path | `GetFileIdMetadataIdScope` | yes |
31
31
  | `template_key` | path | `string` | yes |
32
32
  | `view` | query | `string` | no |
33
33
 
@@ -46,10 +46,10 @@ const result = await client.fileMetadata.getFileMetadata("FILE_ID", "...", "TEMP
46
46
  | Parameter | In | Type | Required |
47
47
  |---|---|---|---|
48
48
  | `file_id` | path | `string` | yes |
49
- | `scope` | path | `GetFileIdMetadataIdIdScope` | yes |
49
+ | `scope` | path | `GetFileIdMetadataIdScope` | yes |
50
50
  | `template_key` | path | `string` | yes |
51
51
 
52
- **Request body** (`application/json-patch+json`): `Array<FileMetadataUpdateRequest>`
52
+ **Request body** (`application/json-patch+json`): `Array<UpdateFileMetadataRequest>`
53
53
 
54
54
  **Returns:** `MetadataFull`
55
55
 
@@ -66,7 +66,7 @@ const result = await client.fileMetadata.updateFileMetadata("FILE_ID", "...", "T
66
66
  | Parameter | In | Type | Required |
67
67
  |---|---|---|---|
68
68
  | `file_id` | path | `string` | yes |
69
- | `scope` | path | `GetFileIdMetadataIdIdScope` | yes |
69
+ | `scope` | path | `GetFileIdMetadataIdScope` | yes |
70
70
  | `template_key` | path | `string` | yes |
71
71
 
72
72
  **Request body** (`application/json`): `Record<string, unknown>`
@@ -86,7 +86,7 @@ const result = await client.fileMetadata.createFileMetadata("FILE_ID", "...", "T
86
86
  | Parameter | In | Type | Required |
87
87
  |---|---|---|---|
88
88
  | `file_id` | path | `string` | yes |
89
- | `scope` | path | `GetFileIdMetadataIdIdScope` | yes |
89
+ | `scope` | path | `GetFileIdMetadataIdScope` | yes |
90
90
  | `template_key` | path | `string` | yes |
91
91
 
92
92
  **Returns:** `void`
@@ -53,7 +53,7 @@ const result = await client.fileVersions.getFileVersion("FILE_ID", "FILE_VERSION
53
53
  | `file_id` | path | `string` | yes |
54
54
  | `file_version_id` | path | `string` | yes |
55
55
 
56
- **Request body** (`application/json`): `FileVersionUpdateRequest`
56
+ **Request body** (`application/json`): `UpdateFileVersionRequest`
57
57
 
58
58
  **Returns:** `FileVersionFull`
59
59
 
@@ -90,7 +90,7 @@ await client.fileVersions.deleteFileVersion("FILE_ID", "FILE_VERSION_ID");
90
90
  | `file_id` | path | `string` | yes |
91
91
  | `fields` | query | `Array<string>` | no |
92
92
 
93
- **Request body** (`application/json`): `FileVersionCurrentCreateRequest`
93
+ **Request body** (`application/json`): `CreateFileVersionCurrentRequest`
94
94
 
95
95
  **Returns:** `FileVersionFull`
96
96
 
@@ -27,7 +27,7 @@ const result = await client.fileWatermarks.getFileWatermark("FILE_ID");
27
27
  |---|---|---|---|
28
28
  | `file_id` | path | `string` | yes |
29
29
 
30
- **Request body** (`application/json`): `FileWatermarkUpdateRequest`
30
+ **Request body** (`application/json`): `UpdateFileWatermarkRequest`
31
31
 
32
32
  **Returns:** `Watermark`
33
33
 
@@ -33,7 +33,7 @@ const result = await client.files.get("FILE_ID");
33
33
  | `fields` | query | `Array<string>` | no |
34
34
  | `if-match` | header | `string` | no |
35
35
 
36
- **Request body** (`application/json`): `FileUpdateRequest`
36
+ **Request body** (`application/json`): `UpdateFileRequest`
37
37
 
38
38
  **Returns:** `FileFull`
39
39
 
@@ -69,7 +69,7 @@ await client.files.delete_("FILE_ID");
69
69
  | `file_id` | path | `string` | yes |
70
70
  | `fields` | query | `Array<string>` | no |
71
71
 
72
- **Request body** (`application/json`): `FileCopyRequest`
72
+ **Request body** (`application/json`): `CopyFileRequest`
73
73
 
74
74
  **Returns:** `FileFull`
75
75
 
@@ -27,7 +27,7 @@ const result = await client.folderClassifications.get("FOLDER_ID");
27
27
  |---|---|---|---|
28
28
  | `folder_id` | path | `string` | yes |
29
29
 
30
- **Request body** (`application/json-patch+json`): `Array<FileClassificationUpdateRequest>`
30
+ **Request body** (`application/json-patch+json`): `Array<UpdateFileClassificationRequest>`
31
31
 
32
32
  **Returns:** `Classification`
33
33
 
@@ -45,7 +45,7 @@ const result = await client.folderClassifications.update("FOLDER_ID", []);
45
45
  |---|---|---|---|
46
46
  | `folder_id` | path | `string` | yes |
47
47
 
48
- **Request body** (`application/json`): `FileClassificationCreateRequest`
48
+ **Request body** (`application/json`): `CreateFileClassificationRequest`
49
49
 
50
50
  **Returns:** `Classification`
51
51
 
@@ -23,7 +23,7 @@ const result = await client.folderLocks.list("FOLDER_ID");
23
23
 
24
24
  `POST /folder_locks`
25
25
 
26
- **Request body** (`application/json`): `FolderLockCreateRequest`
26
+ **Request body** (`application/json`): `CreateFolderLockRequest`
27
27
 
28
28
  **Returns:** `FolderLock`
29
29
 
@@ -27,7 +27,7 @@ const result = await client.folderMetadata.listFolderMetadata("FOLDER_ID");
27
27
  | Parameter | In | Type | Required |
28
28
  |---|---|---|---|
29
29
  | `folder_id` | path | `string` | yes |
30
- | `scope` | path | `GetFileIdMetadataIdIdScope` | yes |
30
+ | `scope` | path | `GetFileIdMetadataIdScope` | yes |
31
31
  | `template_key` | path | `string` | yes |
32
32
 
33
33
  **Returns:** `MetadataFull`
@@ -45,10 +45,10 @@ const result = await client.folderMetadata.getFolderMetadata("FOLDER_ID", "...",
45
45
  | Parameter | In | Type | Required |
46
46
  |---|---|---|---|
47
47
  | `folder_id` | path | `string` | yes |
48
- | `scope` | path | `GetFileIdMetadataIdIdScope` | yes |
48
+ | `scope` | path | `GetFileIdMetadataIdScope` | yes |
49
49
  | `template_key` | path | `string` | yes |
50
50
 
51
- **Request body** (`application/json-patch+json`): `Array<FileMetadataUpdateRequest>`
51
+ **Request body** (`application/json-patch+json`): `Array<UpdateFileMetadataRequest>`
52
52
 
53
53
  **Returns:** `MetadataFull`
54
54
 
@@ -65,7 +65,7 @@ const result = await client.folderMetadata.updateFolderMetadata("FOLDER_ID", "..
65
65
  | Parameter | In | Type | Required |
66
66
  |---|---|---|---|
67
67
  | `folder_id` | path | `string` | yes |
68
- | `scope` | path | `GetFileIdMetadataIdIdScope` | yes |
68
+ | `scope` | path | `GetFileIdMetadataIdScope` | yes |
69
69
  | `template_key` | path | `string` | yes |
70
70
 
71
71
  **Request body** (`application/json`): `Record<string, unknown>`
@@ -85,7 +85,7 @@ const result = await client.folderMetadata.createFolderMetadata("FOLDER_ID", "..
85
85
  | Parameter | In | Type | Required |
86
86
  |---|---|---|---|
87
87
  | `folder_id` | path | `string` | yes |
88
- | `scope` | path | `GetFileIdMetadataIdIdScope` | yes |
88
+ | `scope` | path | `GetFileIdMetadataIdScope` | yes |
89
89
  | `template_key` | path | `string` | yes |
90
90
 
91
91
  **Returns:** `void`
@@ -27,7 +27,7 @@ const result = await client.folderWatermarks.getFolderWatermark("FOLDER_ID");
27
27
  |---|---|---|---|
28
28
  | `folder_id` | path | `string` | yes |
29
29
 
30
- **Request body** (`application/json`): `FileWatermarkUpdateRequest`
30
+ **Request body** (`application/json`): `UpdateFileWatermarkRequest`
31
31
 
32
32
  **Returns:** `Watermark`
33
33
 
@@ -36,7 +36,7 @@ const result = await client.folders.get("FOLDER_ID");
36
36
  | `fields` | query | `Array<string>` | no |
37
37
  | `if-match` | header | `string` | no |
38
38
 
39
- **Request body** (`application/json`): `FolderUpdateRequest`
39
+ **Request body** (`application/json`): `UpdateFolderRequest`
40
40
 
41
41
  **Returns:** `FolderFull`
42
42
 
@@ -100,7 +100,7 @@ Paginated — `listItems(...)` is an async iterable that yields each entry acros
100
100
  |---|---|---|---|
101
101
  | `fields` | query | `Array<string>` | no |
102
102
 
103
- **Request body** (`application/json`): `FolderCreateRequest`
103
+ **Request body** (`application/json`): `CreateFolderRequest`
104
104
 
105
105
  **Returns:** `FolderFull`
106
106
 
@@ -119,7 +119,7 @@ const result = await client.folders.create({ /* … */ });
119
119
  | `folder_id` | path | `string` | yes |
120
120
  | `fields` | query | `Array<string>` | no |
121
121
 
122
- **Request body** (`application/json`): `FolderCopyRequest`
122
+ **Request body** (`application/json`): `CopyFolderRequest`
123
123
 
124
124
  **Returns:** `FolderFull`
125
125
 
@@ -34,7 +34,7 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
34
34
  |---|---|---|---|
35
35
  | `fields` | query | `Array<string>` | no |
36
36
 
37
- **Request body** (`application/json`): `GroupCreateRequest`
37
+ **Request body** (`application/json`): `CreateGroupRequest`
38
38
 
39
39
  **Returns:** `GroupFull`
40
40
 
@@ -70,7 +70,7 @@ const result = await client.groups.get("GROUP_ID");
70
70
  | `group_id` | path | `string` | yes |
71
71
  | `fields` | query | `Array<string>` | no |
72
72
 
73
- **Request body** (`application/json`): `GroupUpdateRequest`
73
+ **Request body** (`application/json`): `UpdateGroupRequest`
74
74
 
75
75
  **Returns:** `GroupFull`
76
76
 
@@ -51,7 +51,7 @@ const result = await client.integrationMappings.createSlack({ /* … */ });
51
51
  |---|---|---|---|
52
52
  | `integration_mapping_id` | path | `string` | yes |
53
53
 
54
- **Request body** (`application/json`): `SlackUpdateRequest`
54
+ **Request body** (`application/json`): `UpdateSlackRequest`
55
55
 
56
56
  **Returns:** `IntegrationMapping`
57
57
 
@@ -118,7 +118,7 @@ const result = await client.integrationMappings.createTeams({ /* … */ });
118
118
  |---|---|---|---|
119
119
  | `integration_mapping_id` | path | `string` | yes |
120
120
 
121
- **Request body** (`application/json`): `TeamUpdateRequest`
121
+ **Request body** (`application/json`): `UpdateTeamRequest`
122
122
 
123
123
  **Returns:** `IntegrationMappingTeams`
124
124
 
@@ -11,7 +11,7 @@ Reach these methods through the `invites` field on `Client`.
11
11
  |---|---|---|---|
12
12
  | `fields` | query | `Array<string>` | no |
13
13
 
14
- **Request body** (`application/json`): `InviteCreateRequest`
14
+ **Request body** (`application/json`): `CreateInviteRequest`
15
15
 
16
16
  **Returns:** `Invite`
17
17
 
@@ -30,7 +30,7 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
30
30
 
31
31
  `POST /legal_hold_policies`
32
32
 
33
- **Request body** (`application/json`): `LegalHoldPolicyCreateRequest`
33
+ **Request body** (`application/json`): `CreateLegalHoldPolicyRequest`
34
34
 
35
35
  **Returns:** `LegalHoldPolicy`
36
36
 
@@ -64,7 +64,7 @@ const result = await client.legalHoldPolicies.get("LEGAL_HOLD_POLICY_ID");
64
64
  |---|---|---|---|
65
65
  | `legal_hold_policy_id` | path | `string` | yes |
66
66
 
67
- **Request body** (`application/json`): `LegalHoldPolicyUpdateRequest`
67
+ **Request body** (`application/json`): `UpdateLegalHoldPolicyRequest`
68
68
 
69
69
  **Returns:** `LegalHoldPolicy`
70
70
 
@@ -32,7 +32,7 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
32
32
 
33
33
  `POST /legal_hold_policy_assignments`
34
34
 
35
- **Request body** (`application/json`): `LegalHoldPolicyAssignmentCreateRequest`
35
+ **Request body** (`application/json`): `CreateLegalHoldPolicyAssignmentRequest`
36
36
 
37
37
  **Returns:** `LegalHoldPolicyAssignment`
38
38
 
@@ -47,7 +47,7 @@ for await (const item of client.memberships.listGroup("GROUP_ID")) {
47
47
 
48
48
  Paginated — `listGroup(...)` is an async iterable that yields each entry across pages (`for await (const item of ...)`), threading the cursor for you. See the [pagination guide](../pagination.md).
49
49
 
50
- ## createGroup
50
+ ## createGroupMembership
51
51
 
52
52
  `POST /group_memberships`
53
53
 
@@ -55,17 +55,17 @@ Paginated — `listGroup(...)` is an async iterable that yields each entry acros
55
55
  |---|---|---|---|
56
56
  | `fields` | query | `Array<string>` | no |
57
57
 
58
- **Request body** (`application/json`): `GroupCreateRequest2`
58
+ **Request body** (`application/json`): `CreateGroupMembershipRequest`
59
59
 
60
60
  **Returns:** `GroupMembership`
61
61
 
62
62
  **Example**
63
63
 
64
64
  ```ts
65
- const result = await client.memberships.createGroup({ /* … */ });
65
+ const result = await client.memberships.createGroupMembership({ /* … */ });
66
66
  ```
67
67
 
68
- ## getGroup
68
+ ## getGroupMembership
69
69
 
70
70
  `GET /group_memberships/{group_membership_id}`
71
71
 
@@ -79,10 +79,10 @@ const result = await client.memberships.createGroup({ /* … */ });
79
79
  **Example**
80
80
 
81
81
  ```ts
82
- const result = await client.memberships.getGroup("GROUP_MEMBERSHIP_ID");
82
+ const result = await client.memberships.getGroupMembership("GROUP_MEMBERSHIP_ID");
83
83
  ```
84
84
 
85
- ## updateGroup
85
+ ## updateGroupMembership
86
86
 
87
87
  `PUT /group_memberships/{group_membership_id}`
88
88
 
@@ -91,17 +91,17 @@ const result = await client.memberships.getGroup("GROUP_MEMBERSHIP_ID");
91
91
  | `group_membership_id` | path | `string` | yes |
92
92
  | `fields` | query | `Array<string>` | no |
93
93
 
94
- **Request body** (`application/json`): `GroupUpdateRequest2`
94
+ **Request body** (`application/json`): `UpdateGroupMembershipRequest`
95
95
 
96
96
  **Returns:** `GroupMembership`
97
97
 
98
98
  **Example**
99
99
 
100
100
  ```ts
101
- const result = await client.memberships.updateGroup("GROUP_MEMBERSHIP_ID", { /* … */ });
101
+ const result = await client.memberships.updateGroupMembership("GROUP_MEMBERSHIP_ID", { /* … */ });
102
102
  ```
103
103
 
104
- ## deleteGroup
104
+ ## deleteGroupMembership
105
105
 
106
106
  `DELETE /group_memberships/{group_membership_id}`
107
107
 
@@ -114,6 +114,6 @@ const result = await client.memberships.updateGroup("GROUP_MEMBERSHIP_ID", { /*
114
114
  **Example**
115
115
 
116
116
  ```ts
117
- await client.memberships.deleteGroup("GROUP_MEMBERSHIP_ID");
117
+ await client.memberships.deleteGroupMembership("GROUP_MEMBERSHIP_ID");
118
118
  ```
119
119