@unofficialbox/box-open-sdk 0.1.0 → 0.2.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 (101) hide show
  1. package/README.md +85 -7
  2. package/dist/cjs/index.js +2 -1
  3. package/dist/cjs/managers/search.js +1 -1
  4. package/dist/cjs/managers/transfer.js +1 -1
  5. package/dist/cjs/managers/uploads.js +2 -2
  6. package/dist/esm/index.js +1 -0
  7. package/dist/esm/managers/search.js +1 -1
  8. package/dist/esm/managers/transfer.js +1 -1
  9. package/dist/esm/managers/uploads.js +2 -2
  10. package/dist/types/index.d.ts +1 -0
  11. package/dist/types/managers/search.d.ts +1 -1
  12. package/dist/types/managers/transfer.d.ts +3 -3
  13. package/dist/types/managers/uploads.d.ts +6 -6
  14. package/docs/auth.md +10 -10
  15. package/docs/errors.md +2 -2
  16. package/docs/managers/ai.md +30 -0
  17. package/docs/managers/ai_studio.md +32 -0
  18. package/docs/managers/app_item_associations.md +16 -0
  19. package/docs/managers/archives.md +26 -0
  20. package/docs/managers/authorization.md +24 -0
  21. package/docs/managers/automate_workflows.md +14 -0
  22. package/docs/managers/avatars.md +18 -0
  23. package/docs/managers/chunked_uploads.md +44 -0
  24. package/docs/managers/classifications.md +24 -0
  25. package/docs/managers/collaboration_allowlist_entries.md +26 -0
  26. package/docs/managers/collaboration_allowlist_exempt_targets.md +26 -0
  27. package/docs/managers/collections.md +22 -0
  28. package/docs/managers/comments.md +32 -0
  29. package/docs/managers/device_pinners.md +20 -0
  30. package/docs/managers/docgen.md +28 -0
  31. package/docs/managers/docgen_template.md +42 -0
  32. package/docs/managers/downloads.md +6 -0
  33. package/docs/managers/email_aliases.md +18 -0
  34. package/docs/managers/enterprise_configurations.md +6 -0
  35. package/docs/managers/events.md +12 -0
  36. package/docs/managers/external_users.md +6 -0
  37. package/docs/managers/file_classifications.md +24 -0
  38. package/docs/managers/file_metadata.md +30 -0
  39. package/docs/managers/file_requests.md +24 -0
  40. package/docs/managers/file_version_legal_holds.md +14 -0
  41. package/docs/managers/file_version_retentions.md +14 -0
  42. package/docs/managers/file_versions.md +32 -0
  43. package/docs/managers/file_watermarks.md +18 -0
  44. package/docs/managers/files.md +30 -0
  45. package/docs/managers/folder_classifications.md +24 -0
  46. package/docs/managers/folder_locks.md +18 -0
  47. package/docs/managers/folder_metadata.md +30 -0
  48. package/docs/managers/folder_watermarks.md +18 -0
  49. package/docs/managers/folders.md +38 -0
  50. package/docs/managers/groups.md +32 -0
  51. package/docs/managers/hub_collaborations.md +32 -0
  52. package/docs/managers/hub_document.md +16 -0
  53. package/docs/managers/hub_items.md +14 -0
  54. package/docs/managers/hubs.md +46 -0
  55. package/docs/managers/integration_mappings.md +50 -0
  56. package/docs/managers/invites.md +12 -0
  57. package/docs/managers/legal_hold_policies.md +32 -0
  58. package/docs/managers/legal_hold_policy_assignments.md +42 -0
  59. package/docs/managers/list_collaborations.md +32 -0
  60. package/docs/managers/memberships.md +40 -0
  61. package/docs/managers/metadata_cascade_policies.md +32 -0
  62. package/docs/managers/metadata_taxonomies.md +96 -0
  63. package/docs/managers/metadata_templates.md +54 -0
  64. package/docs/managers/notes.md +6 -0
  65. package/docs/managers/recent_items.md +8 -0
  66. package/docs/managers/retention_policies.md +32 -0
  67. package/docs/managers/retention_policy_assignments.md +42 -0
  68. package/docs/managers/search.md +13 -1
  69. package/docs/managers/session_termination.md +12 -0
  70. package/docs/managers/shared_links_app_items.md +6 -0
  71. package/docs/managers/shared_links_files.md +30 -0
  72. package/docs/managers/shared_links_folders.md +30 -0
  73. package/docs/managers/shared_links_web_links.md +30 -0
  74. package/docs/managers/shield_information_barrier_reports.md +20 -0
  75. package/docs/managers/shield_information_barrier_segment_members.md +26 -0
  76. package/docs/managers/shield_information_barrier_segment_restrictions.md +26 -0
  77. package/docs/managers/shield_information_barrier_segments.md +32 -0
  78. package/docs/managers/shield_information_barriers.md +26 -0
  79. package/docs/managers/shield_lists.md +30 -0
  80. package/docs/managers/sign_requests.md +32 -0
  81. package/docs/managers/sign_templates.md +14 -0
  82. package/docs/managers/skills.md +30 -0
  83. package/docs/managers/storage_policies.md +14 -0
  84. package/docs/managers/storage_policy_assignments.md +32 -0
  85. package/docs/managers/task_assignments.md +30 -0
  86. package/docs/managers/tasks.md +30 -0
  87. package/docs/managers/terms_of_service_user_statuses.md +18 -0
  88. package/docs/managers/terms_of_services.md +24 -0
  89. package/docs/managers/transfer.md +7 -1
  90. package/docs/managers/trashed_files.md +18 -0
  91. package/docs/managers/trashed_folders.md +18 -0
  92. package/docs/managers/trashed_items.md +8 -0
  93. package/docs/managers/trashed_web_links.md +18 -0
  94. package/docs/managers/uploads.md +20 -2
  95. package/docs/managers/user_collaborations.md +24 -0
  96. package/docs/managers/users.md +38 -0
  97. package/docs/managers/web_links.md +24 -0
  98. package/docs/managers/webhooks.md +32 -0
  99. package/docs/managers/workflows.md +14 -0
  100. package/docs/managers/zip_downloads.md +18 -0
  101. package/package.json +3 -2
@@ -15,6 +15,14 @@ Reach these methods through the `hubDocument` field on `Client`.
15
15
 
16
16
  **Returns:** `HubDocumentPages`
17
17
 
18
+ **Example**
19
+
20
+ ```ts
21
+ for await (const item of client.hubDocument.listPages("HUB_ID")) {
22
+ // use item
23
+ }
24
+ ```
25
+
18
26
  Paginated — `listPages(...)` 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).
19
27
 
20
28
  ## listBlocks
@@ -30,5 +38,13 @@ Paginated — `listPages(...)` is an async iterable that yields each entry acros
30
38
 
31
39
  **Returns:** `HubDocumentBlocks`
32
40
 
41
+ **Example**
42
+
43
+ ```ts
44
+ for await (const item of client.hubDocument.listBlocks("HUB_ID", "PAGE_ID")) {
45
+ // use item
46
+ }
47
+ ```
48
+
33
49
  Paginated — `listBlocks(...)` 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).
34
50
 
@@ -16,6 +16,14 @@ Reach these methods through the `hubItems` field on `Client`.
16
16
 
17
17
  **Returns:** `HubItems`
18
18
 
19
+ **Example**
20
+
21
+ ```ts
22
+ for await (const item of client.hubItems.list("HUB_ID")) {
23
+ // use item
24
+ }
25
+ ```
26
+
19
27
  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).
20
28
 
21
29
  ## createHubManageItems
@@ -30,3 +38,9 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
30
38
 
31
39
  **Returns:** `HubItemsManageResponse`
32
40
 
41
+ **Example**
42
+
43
+ ```ts
44
+ const result = await client.hubItems.createHubManageItems("HUB_ID", { /* … */ });
45
+ ```
46
+
@@ -18,6 +18,14 @@ Reach these methods through the `hubs` field on `Client`.
18
18
 
19
19
  **Returns:** `Hubs`
20
20
 
21
+ **Example**
22
+
23
+ ```ts
24
+ for await (const item of client.hubs.list()) {
25
+ // use item
26
+ }
27
+ ```
28
+
21
29
  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).
22
30
 
23
31
  ## create
@@ -28,6 +36,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
28
36
 
29
37
  **Returns:** `Hub`
30
38
 
39
+ **Example**
40
+
41
+ ```ts
42
+ const result = await client.hubs.create({ /* … */ });
43
+ ```
44
+
31
45
  ## listEnterprise
32
46
 
33
47
  `GET /enterprise_hubs`
@@ -42,6 +56,14 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
42
56
 
43
57
  **Returns:** `Hubs`
44
58
 
59
+ **Example**
60
+
61
+ ```ts
62
+ for await (const item of client.hubs.listEnterprise()) {
63
+ // use item
64
+ }
65
+ ```
66
+
45
67
  Paginated — `listEnterprise(...)` 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).
46
68
 
47
69
  ## get
@@ -54,6 +76,12 @@ Paginated — `listEnterprise(...)` is an async iterable that yields each entry
54
76
 
55
77
  **Returns:** `Hub`
56
78
 
79
+ **Example**
80
+
81
+ ```ts
82
+ const result = await client.hubs.get("HUB_ID");
83
+ ```
84
+
57
85
  ## update
58
86
 
59
87
  `PUT /hubs/{hub_id}`
@@ -66,6 +94,12 @@ Paginated — `listEnterprise(...)` is an async iterable that yields each entry
66
94
 
67
95
  **Returns:** `Hub`
68
96
 
97
+ **Example**
98
+
99
+ ```ts
100
+ const result = await client.hubs.update("HUB_ID", { /* … */ });
101
+ ```
102
+
69
103
  ## delete_
70
104
 
71
105
  `DELETE /hubs/{hub_id}`
@@ -76,6 +110,12 @@ Paginated — `listEnterprise(...)` is an async iterable that yields each entry
76
110
 
77
111
  **Returns:** `void`
78
112
 
113
+ **Example**
114
+
115
+ ```ts
116
+ await client.hubs.delete_("HUB_ID");
117
+ ```
118
+
79
119
  ## copy
80
120
 
81
121
  `POST /hubs/{hub_id}/copy`
@@ -88,3 +128,9 @@ Paginated — `listEnterprise(...)` is an async iterable that yields each entry
88
128
 
89
129
  **Returns:** `Hub`
90
130
 
131
+ **Example**
132
+
133
+ ```ts
134
+ const result = await client.hubs.copy("HUB_ID", { /* … */ });
135
+ ```
136
+
@@ -19,6 +19,14 @@ Reach these methods through the `integrationMappings` field on `Client`.
19
19
 
20
20
  **Returns:** `IntegrationMappings`
21
21
 
22
+ **Example**
23
+
24
+ ```ts
25
+ for await (const item of client.integrationMappings.listSlack()) {
26
+ // use item
27
+ }
28
+ ```
29
+
22
30
  Paginated — `listSlack(...)` 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).
23
31
 
24
32
  ## createSlack
@@ -29,6 +37,12 @@ Paginated — `listSlack(...)` is an async iterable that yields each entry acros
29
37
 
30
38
  **Returns:** `IntegrationMapping`
31
39
 
40
+ **Example**
41
+
42
+ ```ts
43
+ const result = await client.integrationMappings.createSlack({ /* … */ });
44
+ ```
45
+
32
46
  ## updateSlack
33
47
 
34
48
  `PUT /integration_mappings/slack/{integration_mapping_id}`
@@ -41,6 +55,12 @@ Paginated — `listSlack(...)` is an async iterable that yields each entry acros
41
55
 
42
56
  **Returns:** `IntegrationMapping`
43
57
 
58
+ **Example**
59
+
60
+ ```ts
61
+ const result = await client.integrationMappings.updateSlack("INTEGRATION_MAPPING_ID", { /* … */ });
62
+ ```
63
+
44
64
  ## deleteSlack
45
65
 
46
66
  `DELETE /integration_mappings/slack/{integration_mapping_id}`
@@ -51,6 +71,12 @@ Paginated — `listSlack(...)` is an async iterable that yields each entry acros
51
71
 
52
72
  **Returns:** `void`
53
73
 
74
+ **Example**
75
+
76
+ ```ts
77
+ await client.integrationMappings.deleteSlack("INTEGRATION_MAPPING_ID");
78
+ ```
79
+
54
80
  ## listTeams
55
81
 
56
82
  `GET /integration_mappings/teams`
@@ -64,6 +90,12 @@ Paginated — `listSlack(...)` is an async iterable that yields each entry acros
64
90
 
65
91
  **Returns:** `IntegrationMappingsTeams`
66
92
 
93
+ **Example**
94
+
95
+ ```ts
96
+ const result = await client.integrationMappings.listTeams();
97
+ ```
98
+
67
99
  ## createTeams
68
100
 
69
101
  `POST /integration_mappings/teams`
@@ -72,6 +104,12 @@ Paginated — `listSlack(...)` is an async iterable that yields each entry acros
72
104
 
73
105
  **Returns:** `IntegrationMappingTeams`
74
106
 
107
+ **Example**
108
+
109
+ ```ts
110
+ const result = await client.integrationMappings.createTeams({ /* … */ });
111
+ ```
112
+
75
113
  ## updateTeam
76
114
 
77
115
  `PUT /integration_mappings/teams/{integration_mapping_id}`
@@ -84,6 +122,12 @@ Paginated — `listSlack(...)` is an async iterable that yields each entry acros
84
122
 
85
123
  **Returns:** `IntegrationMappingTeams`
86
124
 
125
+ **Example**
126
+
127
+ ```ts
128
+ const result = await client.integrationMappings.updateTeam("INTEGRATION_MAPPING_ID", { /* … */ });
129
+ ```
130
+
87
131
  ## deleteTeam
88
132
 
89
133
  `DELETE /integration_mappings/teams/{integration_mapping_id}`
@@ -94,3 +138,9 @@ Paginated — `listSlack(...)` is an async iterable that yields each entry acros
94
138
 
95
139
  **Returns:** `void`
96
140
 
141
+ **Example**
142
+
143
+ ```ts
144
+ await client.integrationMappings.deleteTeam("INTEGRATION_MAPPING_ID");
145
+ ```
146
+
@@ -15,6 +15,12 @@ Reach these methods through the `invites` field on `Client`.
15
15
 
16
16
  **Returns:** `Invite`
17
17
 
18
+ **Example**
19
+
20
+ ```ts
21
+ const result = await client.invites.create({ /* … */ });
22
+ ```
23
+
18
24
  ## get
19
25
 
20
26
  `GET /invites/{invite_id}`
@@ -26,3 +32,9 @@ Reach these methods through the `invites` field on `Client`.
26
32
 
27
33
  **Returns:** `Invite`
28
34
 
35
+ **Example**
36
+
37
+ ```ts
38
+ const result = await client.invites.get("INVITE_ID");
39
+ ```
40
+
@@ -16,6 +16,14 @@ Reach these methods through the `legalHoldPolicies` field on `Client`.
16
16
 
17
17
  **Returns:** `LegalHoldPolicies`
18
18
 
19
+ **Example**
20
+
21
+ ```ts
22
+ for await (const item of client.legalHoldPolicies.list()) {
23
+ // use item
24
+ }
25
+ ```
26
+
19
27
  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).
20
28
 
21
29
  ## create
@@ -26,6 +34,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
26
34
 
27
35
  **Returns:** `LegalHoldPolicy`
28
36
 
37
+ **Example**
38
+
39
+ ```ts
40
+ const result = await client.legalHoldPolicies.create({ /* … */ });
41
+ ```
42
+
29
43
  ## get
30
44
 
31
45
  `GET /legal_hold_policies/{legal_hold_policy_id}`
@@ -36,6 +50,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
36
50
 
37
51
  **Returns:** `LegalHoldPolicy`
38
52
 
53
+ **Example**
54
+
55
+ ```ts
56
+ const result = await client.legalHoldPolicies.get("LEGAL_HOLD_POLICY_ID");
57
+ ```
58
+
39
59
  ## update
40
60
 
41
61
  `PUT /legal_hold_policies/{legal_hold_policy_id}`
@@ -48,6 +68,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
48
68
 
49
69
  **Returns:** `LegalHoldPolicy`
50
70
 
71
+ **Example**
72
+
73
+ ```ts
74
+ const result = await client.legalHoldPolicies.update("LEGAL_HOLD_POLICY_ID", { /* … */ });
75
+ ```
76
+
51
77
  ## delete_
52
78
 
53
79
  `DELETE /legal_hold_policies/{legal_hold_policy_id}`
@@ -58,3 +84,9 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
58
84
 
59
85
  **Returns:** `void`
60
86
 
87
+ **Example**
88
+
89
+ ```ts
90
+ await client.legalHoldPolicies.delete_("LEGAL_HOLD_POLICY_ID");
91
+ ```
92
+
@@ -18,6 +18,14 @@ Reach these methods through the `legalHoldPolicyAssignments` field on `Client`.
18
18
 
19
19
  **Returns:** `LegalHoldPolicyAssignments`
20
20
 
21
+ **Example**
22
+
23
+ ```ts
24
+ for await (const item of client.legalHoldPolicyAssignments.list("POLICY_ID")) {
25
+ // use item
26
+ }
27
+ ```
28
+
21
29
  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).
22
30
 
23
31
  ## create
@@ -28,6 +36,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
28
36
 
29
37
  **Returns:** `LegalHoldPolicyAssignment`
30
38
 
39
+ **Example**
40
+
41
+ ```ts
42
+ const result = await client.legalHoldPolicyAssignments.create({ /* … */ });
43
+ ```
44
+
31
45
  ## get
32
46
 
33
47
  `GET /legal_hold_policy_assignments/{legal_hold_policy_assignment_id}`
@@ -38,6 +52,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
38
52
 
39
53
  **Returns:** `LegalHoldPolicyAssignment`
40
54
 
55
+ **Example**
56
+
57
+ ```ts
58
+ const result = await client.legalHoldPolicyAssignments.get("LEGAL_HOLD_POLICY_ASSIGNMENT_ID");
59
+ ```
60
+
41
61
  ## delete_
42
62
 
43
63
  `DELETE /legal_hold_policy_assignments/{legal_hold_policy_assignment_id}`
@@ -48,6 +68,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
48
68
 
49
69
  **Returns:** `void`
50
70
 
71
+ **Example**
72
+
73
+ ```ts
74
+ await client.legalHoldPolicyAssignments.delete_("LEGAL_HOLD_POLICY_ASSIGNMENT_ID");
75
+ ```
76
+
51
77
  ## listFileOnHold
52
78
 
53
79
  `GET /legal_hold_policy_assignments/{legal_hold_policy_assignment_id}/files_on_hold`
@@ -61,6 +87,14 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
61
87
 
62
88
  **Returns:** `FilesOnHold`
63
89
 
90
+ **Example**
91
+
92
+ ```ts
93
+ for await (const item of client.legalHoldPolicyAssignments.listFileOnHold("LEGAL_HOLD_POLICY_ASSIGNMENT_ID")) {
94
+ // use item
95
+ }
96
+ ```
97
+
64
98
  Paginated — `listFileOnHold(...)` 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).
65
99
 
66
100
  ## listFileVersionOnHold
@@ -76,5 +110,13 @@ Paginated — `listFileOnHold(...)` is an async iterable that yields each entry
76
110
 
77
111
  **Returns:** `FileVersionsOnHold`
78
112
 
113
+ **Example**
114
+
115
+ ```ts
116
+ for await (const item of client.legalHoldPolicyAssignments.listFileVersionOnHold("LEGAL_HOLD_POLICY_ASSIGNMENT_ID")) {
117
+ // use item
118
+ }
119
+ ```
120
+
79
121
  Paginated — `listFileVersionOnHold(...)` 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).
80
122
 
@@ -16,6 +16,14 @@ Reach these methods through the `listCollaborations` field on `Client`.
16
16
 
17
17
  **Returns:** `Collaborations`
18
18
 
19
+ **Example**
20
+
21
+ ```ts
22
+ for await (const item of client.listCollaborations.listFileCollaborations("FILE_ID")) {
23
+ // use item
24
+ }
25
+ ```
26
+
19
27
  Paginated — `listFileCollaborations(...)` 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).
20
28
 
21
29
  ## listFolderCollaborations
@@ -31,6 +39,14 @@ Paginated — `listFileCollaborations(...)` is an async iterable that yields eac
31
39
 
32
40
  **Returns:** `Collaborations`
33
41
 
42
+ **Example**
43
+
44
+ ```ts
45
+ for await (const item of client.listCollaborations.listFolderCollaborations("FOLDER_ID")) {
46
+ // use item
47
+ }
48
+ ```
49
+
34
50
  Paginated — `listFolderCollaborations(...)` 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).
35
51
 
36
52
  ## listCollaborations
@@ -46,6 +62,14 @@ Paginated — `listFolderCollaborations(...)` is an async iterable that yields e
46
62
 
47
63
  **Returns:** `CollaborationsOffsetPaginated`
48
64
 
65
+ **Example**
66
+
67
+ ```ts
68
+ for await (const item of client.listCollaborations.listCollaborations("...")) {
69
+ // use item
70
+ }
71
+ ```
72
+
49
73
  Paginated — `listCollaborations(...)` 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).
50
74
 
51
75
  ## listGroupCollaborations
@@ -60,5 +84,13 @@ Paginated — `listCollaborations(...)` is an async iterable that yields each en
60
84
 
61
85
  **Returns:** `CollaborationsOffsetPaginated`
62
86
 
87
+ **Example**
88
+
89
+ ```ts
90
+ for await (const item of client.listCollaborations.listGroupCollaborations("GROUP_ID")) {
91
+ // use item
92
+ }
93
+ ```
94
+
63
95
  Paginated — `listGroupCollaborations(...)` 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).
64
96
 
@@ -15,6 +15,14 @@ Reach these methods through the `memberships` field on `Client`.
15
15
 
16
16
  **Returns:** `GroupMemberships`
17
17
 
18
+ **Example**
19
+
20
+ ```ts
21
+ for await (const item of client.memberships.listUser("USER_ID")) {
22
+ // use item
23
+ }
24
+ ```
25
+
18
26
  Paginated — `listUser(...)` 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).
19
27
 
20
28
  ## listGroup
@@ -29,6 +37,14 @@ Paginated — `listUser(...)` is an async iterable that yields each entry across
29
37
 
30
38
  **Returns:** `GroupMemberships`
31
39
 
40
+ **Example**
41
+
42
+ ```ts
43
+ for await (const item of client.memberships.listGroup("GROUP_ID")) {
44
+ // use item
45
+ }
46
+ ```
47
+
32
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).
33
49
 
34
50
  ## createGroup
@@ -43,6 +59,12 @@ Paginated — `listGroup(...)` is an async iterable that yields each entry acros
43
59
 
44
60
  **Returns:** `GroupMembership`
45
61
 
62
+ **Example**
63
+
64
+ ```ts
65
+ const result = await client.memberships.createGroup({ /* … */ });
66
+ ```
67
+
46
68
  ## getGroup
47
69
 
48
70
  `GET /group_memberships/{group_membership_id}`
@@ -54,6 +76,12 @@ Paginated — `listGroup(...)` is an async iterable that yields each entry acros
54
76
 
55
77
  **Returns:** `GroupMembership`
56
78
 
79
+ **Example**
80
+
81
+ ```ts
82
+ const result = await client.memberships.getGroup("GROUP_MEMBERSHIP_ID");
83
+ ```
84
+
57
85
  ## updateGroup
58
86
 
59
87
  `PUT /group_memberships/{group_membership_id}`
@@ -67,6 +95,12 @@ Paginated — `listGroup(...)` is an async iterable that yields each entry acros
67
95
 
68
96
  **Returns:** `GroupMembership`
69
97
 
98
+ **Example**
99
+
100
+ ```ts
101
+ const result = await client.memberships.updateGroup("GROUP_MEMBERSHIP_ID", { /* … */ });
102
+ ```
103
+
70
104
  ## deleteGroup
71
105
 
72
106
  `DELETE /group_memberships/{group_membership_id}`
@@ -77,3 +111,9 @@ Paginated — `listGroup(...)` is an async iterable that yields each entry acros
77
111
 
78
112
  **Returns:** `void`
79
113
 
114
+ **Example**
115
+
116
+ ```ts
117
+ await client.memberships.deleteGroup("GROUP_MEMBERSHIP_ID");
118
+ ```
119
+
@@ -16,6 +16,14 @@ Reach these methods through the `metadataCascadePolicies` field on `Client`.
16
16
 
17
17
  **Returns:** `MetadataCascadePolicies`
18
18
 
19
+ **Example**
20
+
21
+ ```ts
22
+ for await (const item of client.metadataCascadePolicies.list("FOLDER_ID")) {
23
+ // use item
24
+ }
25
+ ```
26
+
19
27
  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).
20
28
 
21
29
  ## create
@@ -26,6 +34,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
26
34
 
27
35
  **Returns:** `MetadataCascadePolicy`
28
36
 
37
+ **Example**
38
+
39
+ ```ts
40
+ const result = await client.metadataCascadePolicies.create({ /* … */ });
41
+ ```
42
+
29
43
  ## get
30
44
 
31
45
  `GET /metadata_cascade_policies/{metadata_cascade_policy_id}`
@@ -36,6 +50,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
36
50
 
37
51
  **Returns:** `MetadataCascadePolicy`
38
52
 
53
+ **Example**
54
+
55
+ ```ts
56
+ const result = await client.metadataCascadePolicies.get("METADATA_CASCADE_POLICY_ID");
57
+ ```
58
+
39
59
  ## delete_
40
60
 
41
61
  `DELETE /metadata_cascade_policies/{metadata_cascade_policy_id}`
@@ -46,6 +66,12 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
46
66
 
47
67
  **Returns:** `void`
48
68
 
69
+ **Example**
70
+
71
+ ```ts
72
+ await client.metadataCascadePolicies.delete_("METADATA_CASCADE_POLICY_ID");
73
+ ```
74
+
49
75
  ## apply
50
76
 
51
77
  `POST /metadata_cascade_policies/{metadata_cascade_policy_id}/apply`
@@ -58,3 +84,9 @@ Paginated — `list(...)` is an async iterable that yields each entry across pag
58
84
 
59
85
  **Returns:** `void`
60
86
 
87
+ **Example**
88
+
89
+ ```ts
90
+ await client.metadataCascadePolicies.apply("METADATA_CASCADE_POLICY_ID", { /* … */ });
91
+ ```
92
+