@distilled.cloud/slack 1.0.0-rc.17 → 1.0.0-rc.19
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.
- package/lib/_bundle/sdk.js +1 -1
- package/lib/_bundle/sdk.js.map +1 -1
- package/lib/credentials.d.ts +2 -1
- package/lib/credentials.d.ts.map +1 -1
- package/lib/index.d.ts +3 -4
- package/lib/index.d.ts.map +1 -1
- package/lib/index.lazy.js.map +1 -1
- package/lib/protocol.d.ts +3 -2
- package/lib/protocol.d.ts.map +1 -1
- package/lib/services/admin.d.ts +594 -356
- package/lib/services/admin.d.ts.map +1 -1
- package/lib/services/admin.js +149 -139
- package/lib/services/admin.js.map +1 -1
- package/lib/services/agents.d.ts +89 -97
- package/lib/services/agents.d.ts.map +1 -1
- package/lib/services/agents.js +1 -1
- package/lib/services/agents.js.map +1 -1
- package/lib/services/api.d.ts +2 -2
- package/lib/services/api.d.ts.map +1 -1
- package/lib/services/api.js +1 -1
- package/lib/services/api.js.map +1 -1
- package/lib/services/apps.d.ts +74 -74
- package/lib/services/apps.d.ts.map +1 -1
- package/lib/services/apps.js +34 -33
- package/lib/services/apps.js.map +1 -1
- package/lib/services/assistant.d.ts +55 -46
- package/lib/services/assistant.d.ts.map +1 -1
- package/lib/services/assistant.js +1 -1
- package/lib/services/assistant.js.map +1 -1
- package/lib/services/auth.d.ts +27 -27
- package/lib/services/auth.d.ts.map +1 -1
- package/lib/services/auth.js +1 -1
- package/lib/services/auth.js.map +1 -1
- package/lib/services/blocks.d.ts +3 -3
- package/lib/services/blocks.d.ts.map +1 -1
- package/lib/services/blocks.js +1 -1
- package/lib/services/blocks.js.map +1 -1
- package/lib/services/bookmarks.d.ts +19 -19
- package/lib/services/bookmarks.d.ts.map +1 -1
- package/lib/services/bookmarks.js +1 -1
- package/lib/services/bookmarks.js.map +1 -1
- package/lib/services/bots.d.ts +23 -23
- package/lib/services/bots.d.ts.map +1 -1
- package/lib/services/bots.js +1 -1
- package/lib/services/bots.js.map +1 -1
- package/lib/services/calls.d.ts +10 -10
- package/lib/services/calls.d.ts.map +1 -1
- package/lib/services/calls.js +1 -1
- package/lib/services/calls.js.map +1 -1
- package/lib/services/canvases.d.ts +18 -18
- package/lib/services/canvases.d.ts.map +1 -1
- package/lib/services/canvases.js +1 -1
- package/lib/services/canvases.js.map +1 -1
- package/lib/services/chat.d.ts +103 -103
- package/lib/services/chat.d.ts.map +1 -1
- package/lib/services/chat.js +1 -1
- package/lib/services/chat.js.map +1 -1
- package/lib/services/conversations.d.ts +109 -103
- package/lib/services/conversations.d.ts.map +1 -1
- package/lib/services/conversations.js +39 -38
- package/lib/services/conversations.js.map +1 -1
- package/lib/services/dialog.d.ts.map +1 -1
- package/lib/services/dialog.js +1 -1
- package/lib/services/dialog.js.map +1 -1
- package/lib/services/dnd.d.ts +14 -14
- package/lib/services/dnd.d.ts.map +1 -1
- package/lib/services/dnd.js +1 -1
- package/lib/services/dnd.js.map +1 -1
- package/lib/services/emoji.d.ts +6 -6
- package/lib/services/emoji.d.ts.map +1 -1
- package/lib/services/emoji.js +1 -1
- package/lib/services/emoji.js.map +1 -1
- package/lib/services/entity.d.ts +14 -14
- package/lib/services/entity.d.ts.map +1 -1
- package/lib/services/entity.js +1 -1
- package/lib/services/entity.js.map +1 -1
- package/lib/services/files.d.ts +106 -106
- package/lib/services/files.d.ts.map +1 -1
- package/lib/services/files.js +30 -1
- package/lib/services/files.js.map +1 -1
- package/lib/services/functions.d.ts +37 -37
- package/lib/services/functions.d.ts.map +1 -1
- package/lib/services/functions.js +1 -1
- package/lib/services/functions.js.map +1 -1
- package/lib/services/index.d.ts +1 -0
- package/lib/services/index.d.ts.map +1 -1
- package/lib/services/index.js +1 -0
- package/lib/services/lists.d.ts +47 -45
- package/lib/services/lists.d.ts.map +1 -1
- package/lib/services/lists.js +1 -1
- package/lib/services/lists.js.map +1 -1
- package/lib/services/migration.d.ts +3 -3
- package/lib/services/migration.d.ts.map +1 -1
- package/lib/services/migration.js +1 -1
- package/lib/services/migration.js.map +1 -1
- package/lib/services/oauth.d.ts +102 -102
- package/lib/services/oauth.d.ts.map +1 -1
- package/lib/services/oauth.js +1 -1
- package/lib/services/oauth.js.map +1 -1
- package/lib/services/openid.d.ts +40 -40
- package/lib/services/openid.d.ts.map +1 -1
- package/lib/services/openid.js +1 -1
- package/lib/services/openid.js.map +1 -1
- package/lib/services/pins.d.ts +9 -9
- package/lib/services/pins.d.ts.map +1 -1
- package/lib/services/pins.js +1 -1
- package/lib/services/pins.js.map +1 -1
- package/lib/services/reactions.d.ts +23 -23
- package/lib/services/reactions.d.ts.map +1 -1
- package/lib/services/reactions.js +1 -1
- package/lib/services/reactions.js.map +1 -1
- package/lib/services/reminders.d.ts +8 -8
- package/lib/services/reminders.d.ts.map +1 -1
- package/lib/services/reminders.js +1 -1
- package/lib/services/reminders.js.map +1 -1
- package/lib/services/rtm.d.ts +11 -11
- package/lib/services/rtm.d.ts.map +1 -1
- package/lib/services/rtm.js +1 -1
- package/lib/services/rtm.js.map +1 -1
- package/lib/services/search.d.ts +84 -80
- package/lib/services/search.d.ts.map +1 -1
- package/lib/services/search.js +1 -1
- package/lib/services/search.js.map +1 -1
- package/lib/services/slackbot.d.ts +366 -0
- package/lib/services/slackbot.d.ts.map +1 -0
- package/lib/services/slackbot.js +2 -0
- package/lib/services/slackbot.js.map +1 -0
- package/lib/services/stars.d.ts +16 -16
- package/lib/services/stars.d.ts.map +1 -1
- package/lib/services/stars.js +1 -1
- package/lib/services/stars.js.map +1 -1
- package/lib/services/team.d.ts +39 -37
- package/lib/services/team.d.ts.map +1 -1
- package/lib/services/team.js +1 -1
- package/lib/services/team.js.map +1 -1
- package/lib/services/tooling.d.ts.map +1 -1
- package/lib/services/tooling.js +1 -1
- package/lib/services/tooling.js.map +1 -1
- package/lib/services/usergroups.d.ts +30 -30
- package/lib/services/usergroups.d.ts.map +1 -1
- package/lib/services/usergroups.js +1 -1
- package/lib/services/usergroups.js.map +1 -1
- package/lib/services/users.d.ts +37 -37
- package/lib/services/users.d.ts.map +1 -1
- package/lib/services/users.js +1 -1
- package/lib/services/users.js.map +1 -1
- package/lib/services/views.d.ts +9 -9
- package/lib/services/views.d.ts.map +1 -1
- package/lib/services/views.js +1 -1
- package/lib/services/views.js.map +1 -1
- package/lib/services/workflows.d.ts +16 -16
- package/lib/services/workflows.d.ts.map +1 -1
- package/lib/services/workflows.js +1 -1
- package/lib/services/workflows.js.map +1 -1
- package/lib/services.lazy/admin.js +2 -2
- package/lib/services.lazy/apps.js +1 -1
- package/lib/services.lazy/conversations.js +1 -1
- package/lib/services.lazy/files.js +3 -1
- package/lib/services.lazy/index.js +2 -2
- package/lib/services.lazy/slackbot.js +1 -0
- package/package.json +8 -7
- package/src/credentials.ts +3 -2
- package/src/index.ts +3 -4
- package/src/protocol.ts +23 -21
- package/src/services/admin.ts +1882 -1034
- package/src/services/agents.ts +128 -103
- package/src/services/api.ts +17 -2
- package/src/services/apps.ts +133 -74
- package/src/services/assistant.ts +109 -54
- package/src/services/auth.ts +46 -27
- package/src/services/blocks.ts +18 -3
- package/src/services/bookmarks.ts +40 -19
- package/src/services/bots.ts +38 -23
- package/src/services/calls.ts +35 -10
- package/src/services/canvases.ts +77 -46
- package/src/services/chat.ts +142 -103
- package/src/services/conversations.ts +195 -115
- package/src/services/dialog.ts +15 -0
- package/src/services/dnd.ts +37 -14
- package/src/services/emoji.ts +21 -6
- package/src/services/entity.ts +33 -14
- package/src/services/files.ts +149 -106
- package/src/services/functions.ts +66 -37
- package/src/services/index.ts +1 -0
- package/src/services/lists.ts +86 -46
- package/src/services/migration.ts +18 -3
- package/src/services/oauth.ts +127 -102
- package/src/services/openid.ts +57 -40
- package/src/services/pins.ts +28 -9
- package/src/services/reactions.ts +44 -23
- package/src/services/reminders.ts +31 -8
- package/src/services/rtm.ts +28 -11
- package/src/services/search.ts +142 -130
- package/src/services/slackbot.ts +766 -0
- package/src/services/stars.ts +35 -16
- package/src/services/team.ts +73 -37
- package/src/services/tooling.ts +15 -0
- package/src/services/usergroups.ts +57 -30
- package/src/services/users.ts +76 -37
- package/src/services/views.ts +30 -9
- package/src/services/workflows.ts +45 -16
|
@@ -11,17 +11,30 @@ const __s: any[] = [];
|
|
|
11
11
|
|
|
12
12
|
export type { SlackOpError, SlackOpContext };
|
|
13
13
|
|
|
14
|
+
/** Span facts shared by every operation (com.distilled.telemetry#service). */
|
|
15
|
+
const TELEMETRY = {
|
|
16
|
+
system: "slack-api",
|
|
17
|
+
responseHeaders: [
|
|
18
|
+
{ header: "x-request-id", name: "http.response.header.x-request-id", transform: "list" },
|
|
19
|
+
{ header: "request-id", name: "http.response.header.request-id", transform: "list" },
|
|
20
|
+
{ header: "x-slack-req-id", name: "http.response.header.x-slack-req-id", transform: "list" },
|
|
21
|
+
],
|
|
22
|
+
prefix: "Slack",
|
|
23
|
+
service: "Functions",
|
|
24
|
+
propagate: "w3c",
|
|
25
|
+
} as const;
|
|
26
|
+
|
|
14
27
|
/** List of encoded user IDs */
|
|
15
28
|
export type AddDistributionsPermissionsRequestUserIdsList = Array<string>;
|
|
16
29
|
export interface AddDistributionsPermissionsRequest {
|
|
17
30
|
/** The encoded ID of the function */
|
|
18
|
-
function_id?: string;
|
|
31
|
+
function_id?: string | undefined;
|
|
19
32
|
/** The callback ID defined in the function's definition file */
|
|
20
|
-
function_callback_id?: string;
|
|
33
|
+
function_callback_id?: string | undefined;
|
|
21
34
|
/** The encoded ID of the app */
|
|
22
|
-
function_app_id?: string;
|
|
35
|
+
function_app_id?: string | undefined;
|
|
23
36
|
/** List of encoded user IDs */
|
|
24
|
-
user_ids?: AddDistributionsPermissionsRequestUserIdsList;
|
|
37
|
+
user_ids?: AddDistributionsPermissionsRequestUserIdsList | undefined;
|
|
25
38
|
}
|
|
26
39
|
export type AddDistributionsPermissionsResponsePermissionType =
|
|
27
40
|
| "everyone"
|
|
@@ -29,9 +42,9 @@ export type AddDistributionsPermissionsResponsePermissionType =
|
|
|
29
42
|
| "named_entities"
|
|
30
43
|
| "system";
|
|
31
44
|
export interface AddDistributionsPermissionsResponseUsersItem {
|
|
32
|
-
user_id?: string;
|
|
33
|
-
username?: string;
|
|
34
|
-
email?: string;
|
|
45
|
+
user_id?: string | undefined;
|
|
46
|
+
username?: string | undefined;
|
|
47
|
+
email?: string | undefined;
|
|
35
48
|
}
|
|
36
49
|
export type AddDistributionsPermissionsResponseUsersList =
|
|
37
50
|
Array<AddDistributionsPermissionsResponseUsersItem>;
|
|
@@ -39,7 +52,7 @@ export interface AddDistributionsPermissionsResponse {
|
|
|
39
52
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
40
53
|
ok: boolean;
|
|
41
54
|
permission_type: AddDistributionsPermissionsResponsePermissionType;
|
|
42
|
-
users?: AddDistributionsPermissionsResponseUsersList;
|
|
55
|
+
users?: AddDistributionsPermissionsResponseUsersList | undefined;
|
|
43
56
|
}
|
|
44
57
|
export interface CompleteErrorRequest {
|
|
45
58
|
/** Context identifier that maps to the executed function */
|
|
@@ -65,11 +78,11 @@ export interface CompleteSuccessResponse {
|
|
|
65
78
|
}
|
|
66
79
|
export interface ExportWorkflowsStepsResponseRequest {
|
|
67
80
|
/** The workflow ID, starts with Wf* */
|
|
68
|
-
workflow_id?: string;
|
|
81
|
+
workflow_id?: string | undefined;
|
|
69
82
|
/** The workflow encoded ID or workflow reference */
|
|
70
|
-
workflow?: string;
|
|
83
|
+
workflow?: string | undefined;
|
|
71
84
|
/** The app tied to the workflow reference. */
|
|
72
|
-
workflow_app_id?: string;
|
|
85
|
+
workflow_app_id?: string | undefined;
|
|
73
86
|
/** The ID of the OpenForm step to export. */
|
|
74
87
|
step_id: string;
|
|
75
88
|
}
|
|
@@ -79,11 +92,11 @@ export interface ExportWorkflowsStepsResponseResponse {
|
|
|
79
92
|
}
|
|
80
93
|
export interface ListDistributionsPermissionsRequest {
|
|
81
94
|
/** The encoded ID of the function */
|
|
82
|
-
function_id?: string;
|
|
95
|
+
function_id?: string | undefined;
|
|
83
96
|
/** The callback ID defined in the function's definition file */
|
|
84
|
-
function_callback_id?: string;
|
|
97
|
+
function_callback_id?: string | undefined;
|
|
85
98
|
/** The encoded ID of the app */
|
|
86
|
-
function_app_id?: string;
|
|
99
|
+
function_app_id?: string | undefined;
|
|
87
100
|
}
|
|
88
101
|
export type ListDistributionsPermissionsResponsePermissionType =
|
|
89
102
|
| "everyone"
|
|
@@ -102,19 +115,19 @@ export interface ListDistributionsPermissionsResponse {
|
|
|
102
115
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
103
116
|
ok: boolean;
|
|
104
117
|
permission_type: ListDistributionsPermissionsResponsePermissionType;
|
|
105
|
-
users?: ListDistributionsPermissionsResponseUsersList;
|
|
118
|
+
users?: ListDistributionsPermissionsResponseUsersList | undefined;
|
|
106
119
|
/** List of team IDs allowed with named_entities permission. */
|
|
107
|
-
team_ids?: ListDistributionsPermissionsResponseTeamIdsList;
|
|
120
|
+
team_ids?: ListDistributionsPermissionsResponseTeamIdsList | undefined;
|
|
108
121
|
/** List of org IDs allowed with named_entities permission. */
|
|
109
|
-
org_ids?: ListDistributionsPermissionsResponseOrgIdsList;
|
|
122
|
+
org_ids?: ListDistributionsPermissionsResponseOrgIdsList | undefined;
|
|
110
123
|
}
|
|
111
124
|
export interface ListWorkflowsStepsRequest {
|
|
112
125
|
/** The workflow ID, starts with Wf* */
|
|
113
|
-
workflow_id?: string;
|
|
126
|
+
workflow_id?: string | undefined;
|
|
114
127
|
/** The workflow encoded ID or workflow reference */
|
|
115
|
-
workflow?: string;
|
|
128
|
+
workflow?: string | undefined;
|
|
116
129
|
/** The app tied to the workflow reference. */
|
|
117
|
-
workflow_app_id?: string;
|
|
130
|
+
workflow_app_id?: string | undefined;
|
|
118
131
|
/** The ID of the function to query */
|
|
119
132
|
function_id: string;
|
|
120
133
|
}
|
|
@@ -128,13 +141,13 @@ export interface ListWorkflowsStepsResponse {
|
|
|
128
141
|
export type RemoveDistributionsPermissionsRequestUserIdsList = Array<string>;
|
|
129
142
|
export interface RemoveDistributionsPermissionsRequest {
|
|
130
143
|
/** The encoded ID of the function */
|
|
131
|
-
function_id?: string;
|
|
144
|
+
function_id?: string | undefined;
|
|
132
145
|
/** The callback ID defined in the function's definition file */
|
|
133
|
-
function_callback_id?: string;
|
|
146
|
+
function_callback_id?: string | undefined;
|
|
134
147
|
/** The encoded ID of the app. */
|
|
135
|
-
function_app_id?: string;
|
|
148
|
+
function_app_id?: string | undefined;
|
|
136
149
|
/** List of encoded user IDs */
|
|
137
|
-
user_ids?: RemoveDistributionsPermissionsRequestUserIdsList;
|
|
150
|
+
user_ids?: RemoveDistributionsPermissionsRequestUserIdsList | undefined;
|
|
138
151
|
}
|
|
139
152
|
export type RemoveDistributionsPermissionsResponsePermissionType =
|
|
140
153
|
| "everyone"
|
|
@@ -149,7 +162,7 @@ export interface RemoveDistributionsPermissionsResponse {
|
|
|
149
162
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
150
163
|
ok: boolean;
|
|
151
164
|
permission_type: RemoveDistributionsPermissionsResponsePermissionType;
|
|
152
|
-
users?: RemoveDistributionsPermissionsResponseUsersList;
|
|
165
|
+
users?: RemoveDistributionsPermissionsResponseUsersList | undefined;
|
|
153
166
|
}
|
|
154
167
|
/** The type of permission that defines how the function can be distributed */
|
|
155
168
|
export type SetDistributionsPermissionsRequestPermissionType =
|
|
@@ -165,19 +178,19 @@ export type SetDistributionsPermissionsRequestTeamIdsList = Array<string>;
|
|
|
165
178
|
export type SetDistributionsPermissionsRequestOrgIdsList = Array<string>;
|
|
166
179
|
export interface SetDistributionsPermissionsRequest {
|
|
167
180
|
/** The encoded ID of the function */
|
|
168
|
-
function_id?: string;
|
|
181
|
+
function_id?: string | undefined;
|
|
169
182
|
/** The callback ID defined in the function's definition file */
|
|
170
|
-
function_callback_id?: string;
|
|
183
|
+
function_callback_id?: string | undefined;
|
|
171
184
|
/** The encoded ID of the app */
|
|
172
|
-
function_app_id?: string;
|
|
185
|
+
function_app_id?: string | undefined;
|
|
173
186
|
/** The type of permission that defines how the function can be distributed */
|
|
174
|
-
permission_type?: SetDistributionsPermissionsRequestPermissionType | (string & {});
|
|
187
|
+
permission_type?: SetDistributionsPermissionsRequestPermissionType | (string & {}) | undefined;
|
|
175
188
|
/** List of encoded user IDs */
|
|
176
|
-
user_ids?: SetDistributionsPermissionsRequestUserIdsList;
|
|
189
|
+
user_ids?: SetDistributionsPermissionsRequestUserIdsList | undefined;
|
|
177
190
|
/** List of team IDs to allow for named_entities permission */
|
|
178
|
-
team_ids?: SetDistributionsPermissionsRequestTeamIdsList;
|
|
191
|
+
team_ids?: SetDistributionsPermissionsRequestTeamIdsList | undefined;
|
|
179
192
|
/** List of org IDs to allow for named_entities permission */
|
|
180
|
-
org_ids?: SetDistributionsPermissionsRequestOrgIdsList;
|
|
193
|
+
org_ids?: SetDistributionsPermissionsRequestOrgIdsList | undefined;
|
|
181
194
|
}
|
|
182
195
|
export type SetDistributionsPermissionsResponsePermissionType =
|
|
183
196
|
| "everyone"
|
|
@@ -196,14 +209,14 @@ export interface SetDistributionsPermissionsResponse {
|
|
|
196
209
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
197
210
|
ok: boolean;
|
|
198
211
|
permission_type: SetDistributionsPermissionsResponsePermissionType;
|
|
199
|
-
users?: SetDistributionsPermissionsResponseUsersList;
|
|
212
|
+
users?: SetDistributionsPermissionsResponseUsersList | undefined;
|
|
200
213
|
/** List of team IDs allowed with named_entities permission. */
|
|
201
|
-
team_ids?: SetDistributionsPermissionsResponseTeamIdsList;
|
|
214
|
+
team_ids?: SetDistributionsPermissionsResponseTeamIdsList | undefined;
|
|
202
215
|
/** List of org IDs allowed with named_entities permission. */
|
|
203
|
-
org_ids?: SetDistributionsPermissionsResponseOrgIdsList;
|
|
216
|
+
org_ids?: SetDistributionsPermissionsResponseOrgIdsList | undefined;
|
|
204
217
|
}
|
|
205
218
|
export type AddDistributionsPermissionsError = SlackOpError;
|
|
206
|
-
/** Grant users access to a custom slack function if its permission_type is set to named_entities Required scopes -- configuration: `app_configurations:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `unknown_method` -- This method does not exist. - `access_denied` -- This actor does not have access to the permissions on this resource. - `function_not_found` -- This function does not exist. - `invalid_permission_type` -- This function requires permission_type to be set as named_entities before adding users. - `user_not_found` -- One or more of the named entities was not found. - `app_not_found` -- This app does not exist. See https://docs.slack.dev/reference/methods/functions.distributions.permissions.add */
|
|
219
|
+
/** Grant users access to a custom slack function if its permission_type is set to named_entities Required scopes -- configuration: `app_configurations:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `unknown_method` -- This method does not exist. - `access_denied` -- This actor does not have access to the permissions on this resource. - `function_not_found` -- This function does not exist. - `invalid_permission_type` -- This function requires permission_type to be set as named_entities before adding users. - `user_not_found` -- One or more of the named entities was not found. - `app_not_found` -- This app does not exist. - `app_edit_disabled` -- The app is managed in Salesforce, so access to its functions can't be changed here. See https://docs.slack.dev/reference/methods/functions.distributions.permissions.add */
|
|
207
220
|
export const addDistributionsPermissions: API.OperationMethod<
|
|
208
221
|
AddDistributionsPermissionsRequest,
|
|
209
222
|
AddDistributionsPermissionsResponse,
|
|
@@ -215,6 +228,8 @@ export const addDistributionsPermissions: API.OperationMethod<
|
|
|
215
228
|
errors: [SlackError, SlackRateLimited],
|
|
216
229
|
protocol: SlackProtocol,
|
|
217
230
|
retry: Retry.Retry,
|
|
231
|
+
telemetry: TELEMETRY,
|
|
232
|
+
span: "AddDistributionsPermissions",
|
|
218
233
|
}));
|
|
219
234
|
|
|
220
235
|
export type CompleteErrorError = SlackOpError;
|
|
@@ -230,6 +245,8 @@ export const completeError: API.OperationMethod<
|
|
|
230
245
|
errors: [SlackError, SlackRateLimited],
|
|
231
246
|
protocol: SlackProtocol,
|
|
232
247
|
retry: Retry.Retry,
|
|
248
|
+
telemetry: TELEMETRY,
|
|
249
|
+
span: "CompleteError",
|
|
233
250
|
}));
|
|
234
251
|
|
|
235
252
|
export type CompleteSuccessError = SlackOpError;
|
|
@@ -245,6 +262,8 @@ export const completeSuccess: API.OperationMethod<
|
|
|
245
262
|
errors: [SlackError, SlackRateLimited],
|
|
246
263
|
protocol: SlackProtocol,
|
|
247
264
|
retry: Retry.Retry,
|
|
265
|
+
telemetry: TELEMETRY,
|
|
266
|
+
span: "CompleteSuccess",
|
|
248
267
|
}));
|
|
249
268
|
|
|
250
269
|
export type ExportWorkflowsStepsResponseError = SlackOpError;
|
|
@@ -260,6 +279,8 @@ export const exportWorkflowsStepsResponse: API.OperationMethod<
|
|
|
260
279
|
errors: [SlackError, SlackRateLimited],
|
|
261
280
|
protocol: SlackProtocol,
|
|
262
281
|
retry: Retry.Retry,
|
|
282
|
+
telemetry: TELEMETRY,
|
|
283
|
+
span: "ExportWorkflowsStepsResponse",
|
|
263
284
|
}));
|
|
264
285
|
|
|
265
286
|
export type ListDistributionsPermissionsError = SlackOpError;
|
|
@@ -275,6 +296,8 @@ export const listDistributionsPermissions: API.OperationMethod<
|
|
|
275
296
|
errors: [SlackError, SlackRateLimited],
|
|
276
297
|
protocol: SlackProtocol,
|
|
277
298
|
retry: Retry.Retry,
|
|
299
|
+
telemetry: TELEMETRY,
|
|
300
|
+
span: "ListDistributionsPermissions",
|
|
278
301
|
}));
|
|
279
302
|
|
|
280
303
|
export type ListWorkflowsStepsError = SlackOpError;
|
|
@@ -290,6 +313,8 @@ export const listWorkflowsSteps: API.OperationMethod<
|
|
|
290
313
|
errors: [SlackError, SlackRateLimited],
|
|
291
314
|
protocol: SlackProtocol,
|
|
292
315
|
retry: Retry.Retry,
|
|
316
|
+
telemetry: TELEMETRY,
|
|
317
|
+
span: "ListWorkflowsSteps",
|
|
293
318
|
}));
|
|
294
319
|
|
|
295
320
|
export type RemoveDistributionsPermissionsError = SlackOpError;
|
|
@@ -305,10 +330,12 @@ export const removeDistributionsPermissions: API.OperationMethod<
|
|
|
305
330
|
errors: [SlackError, SlackRateLimited],
|
|
306
331
|
protocol: SlackProtocol,
|
|
307
332
|
retry: Retry.Retry,
|
|
333
|
+
telemetry: TELEMETRY,
|
|
334
|
+
span: "RemoveDistributionsPermissions",
|
|
308
335
|
}));
|
|
309
336
|
|
|
310
337
|
export type SetDistributionsPermissionsError = SlackOpError;
|
|
311
|
-
/** Set the access type of a custom slack function and define the users, team or org ids to be granted access if permission_type is set to named_entities Required scopes -- configuration: `app_configurations:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `unknown_method` -- This method does not exist. - `access_denied` -- This actor does not have access to the permissions on this resource. - `function_not_found` -- This function does not exist. - `invalid_named_entities` -- One or more of the named entities was not found - `invalid_permission_type` -- This function requires permission_type to be set as named_entities before adding users. - `user_not_found` -- One or more of the named entities was not found. - `app_not_found` -- This app does not exist. - `permission_type_required` -- `permission_type` is a required input. See https://docs.slack.dev/reference/methods/functions.distributions.permissions.set */
|
|
338
|
+
/** Set the access type of a custom slack function and define the users, team or org ids to be granted access if permission_type is set to named_entities Required scopes -- configuration: `app_configurations:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `unknown_method` -- This method does not exist. - `access_denied` -- This actor does not have access to the permissions on this resource. - `function_not_found` -- This function does not exist. - `invalid_named_entities` -- One or more of the named entities was not found - `invalid_permission_type` -- This function requires permission_type to be set as named_entities before adding users. - `user_not_found` -- One or more of the named entities was not found. - `app_not_found` -- This app does not exist. - `permission_type_required` -- `permission_type` is a required input. - `app_edit_disabled` -- The app is managed in Salesforce, so access to its functions can't be changed here. See https://docs.slack.dev/reference/methods/functions.distributions.permissions.set */
|
|
312
339
|
export const setDistributionsPermissions: API.OperationMethod<
|
|
313
340
|
SetDistributionsPermissionsRequest,
|
|
314
341
|
SetDistributionsPermissionsResponse,
|
|
@@ -320,6 +347,8 @@ export const setDistributionsPermissions: API.OperationMethod<
|
|
|
320
347
|
errors: [SlackError, SlackRateLimited],
|
|
321
348
|
protocol: SlackProtocol,
|
|
322
349
|
retry: Retry.Retry,
|
|
350
|
+
telemetry: TELEMETRY,
|
|
351
|
+
span: "SetDistributionsPermissions",
|
|
323
352
|
}));
|
|
324
353
|
|
|
325
354
|
// Schema builders: each runs one schema initializer, on that schema's first use.
|
package/src/services/index.ts
CHANGED
|
@@ -27,6 +27,7 @@ export * as reactions from "./reactions.ts";
|
|
|
27
27
|
export * as reminders from "./reminders.ts";
|
|
28
28
|
export * as rtm from "./rtm.ts";
|
|
29
29
|
export * as search from "./search.ts";
|
|
30
|
+
export * as slackbot from "./slackbot.ts";
|
|
30
31
|
export * as stars from "./stars.ts";
|
|
31
32
|
export * as team from "./team.ts";
|
|
32
33
|
export * as tooling from "./tooling.ts";
|
package/src/services/lists.ts
CHANGED
|
@@ -12,17 +12,30 @@ const __s: any[] = [];
|
|
|
12
12
|
|
|
13
13
|
export type { SlackOpError, SlackOpContext };
|
|
14
14
|
|
|
15
|
+
/** Span facts shared by every operation (com.distilled.telemetry#service). */
|
|
16
|
+
const TELEMETRY = {
|
|
17
|
+
system: "slack-api",
|
|
18
|
+
responseHeaders: [
|
|
19
|
+
{ header: "x-request-id", name: "http.response.header.x-request-id", transform: "list" },
|
|
20
|
+
{ header: "request-id", name: "http.response.header.request-id", transform: "list" },
|
|
21
|
+
{ header: "x-slack-req-id", name: "http.response.header.x-slack-req-id", transform: "list" },
|
|
22
|
+
],
|
|
23
|
+
prefix: "Slack",
|
|
24
|
+
service: "Lists",
|
|
25
|
+
propagate: "w3c",
|
|
26
|
+
} as const;
|
|
27
|
+
|
|
15
28
|
/** Initial item data. */
|
|
16
29
|
export type CreateItemRequestInitialFieldsList = Array<unknown>;
|
|
17
30
|
export interface CreateItemRequest {
|
|
18
31
|
/** ID of the List to add the item to. */
|
|
19
32
|
list_id: string;
|
|
20
33
|
/** ID of the record to make a copy of. */
|
|
21
|
-
duplicated_item_id?: string;
|
|
34
|
+
duplicated_item_id?: string | undefined;
|
|
22
35
|
/** ID of the parent record for this subtask. */
|
|
23
|
-
parent_item_id?: string;
|
|
36
|
+
parent_item_id?: string | undefined;
|
|
24
37
|
/** Initial item data. */
|
|
25
|
-
initial_fields?: CreateItemRequestInitialFieldsList;
|
|
38
|
+
initial_fields?: CreateItemRequestInitialFieldsList | undefined;
|
|
26
39
|
}
|
|
27
40
|
export interface CreateItemResponse {
|
|
28
41
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
@@ -37,15 +50,15 @@ export interface CreateSlackListRequest {
|
|
|
37
50
|
/** Name of the List. */
|
|
38
51
|
name: string;
|
|
39
52
|
/** A rich text description of the List. */
|
|
40
|
-
description_blocks?: CreateSlackListRequestDescriptionBlocksList;
|
|
53
|
+
description_blocks?: CreateSlackListRequestDescriptionBlocksList | undefined;
|
|
41
54
|
/** Column definition for the List. */
|
|
42
|
-
schema?: CreateSlackListRequestSchemaList;
|
|
55
|
+
schema?: CreateSlackListRequestSchemaList | undefined;
|
|
43
56
|
/** ID of the List to copy. */
|
|
44
|
-
copy_from_list_id?: string;
|
|
57
|
+
copy_from_list_id?: string | undefined;
|
|
45
58
|
/** Boolean indicating whether to include records when a List is copied. */
|
|
46
|
-
include_copied_list_records?: boolean;
|
|
59
|
+
include_copied_list_records?: boolean | undefined;
|
|
47
60
|
/** Boolean indicating whether the List should be used to track todo tasks. */
|
|
48
|
-
todo_mode?: boolean;
|
|
61
|
+
todo_mode?: boolean | undefined;
|
|
49
62
|
}
|
|
50
63
|
export interface CreateSlackListResponse {
|
|
51
64
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
@@ -53,7 +66,7 @@ export interface CreateSlackListResponse {
|
|
|
53
66
|
/** The ID of the List created. */
|
|
54
67
|
list_id: string;
|
|
55
68
|
/** The metadata of the List created. */
|
|
56
|
-
list_metadata?: unknown;
|
|
69
|
+
list_metadata?: unknown | undefined;
|
|
57
70
|
}
|
|
58
71
|
/** List of channels you wish to update access for. Can only be used if `user_ids` is not provided. */
|
|
59
72
|
export type DeleteAccessRequestChannelIdsList = Array<string>;
|
|
@@ -63,9 +76,9 @@ export interface DeleteAccessRequest {
|
|
|
63
76
|
/** Encoded ID of the List. */
|
|
64
77
|
list_id: string;
|
|
65
78
|
/** List of channels you wish to update access for. Can only be used if `user_ids` is not provided. */
|
|
66
|
-
channel_ids?: DeleteAccessRequestChannelIdsList;
|
|
79
|
+
channel_ids?: DeleteAccessRequestChannelIdsList | undefined;
|
|
67
80
|
/** List of users you wish to update access for. Can only be used if `channel_ids` is not provided. */
|
|
68
|
-
user_ids?: DeleteAccessRequestUserIdsList;
|
|
81
|
+
user_ids?: DeleteAccessRequestUserIdsList | undefined;
|
|
69
82
|
}
|
|
70
83
|
/** The channel IDs that could not be updated. */
|
|
71
84
|
export type DeleteAccessResponseFailedToUpdateChannelIdsList = Array<string>;
|
|
@@ -75,9 +88,9 @@ export interface DeleteAccessResponse {
|
|
|
75
88
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
76
89
|
ok: boolean;
|
|
77
90
|
/** The channel IDs that could not be updated. */
|
|
78
|
-
failed_to_update_channel_ids?: DeleteAccessResponseFailedToUpdateChannelIdsList;
|
|
91
|
+
failed_to_update_channel_ids?: DeleteAccessResponseFailedToUpdateChannelIdsList | undefined;
|
|
79
92
|
/** The user IDs that could not be updated. */
|
|
80
|
-
failed_to_update_user_ids?: DeleteAccessResponseFailedToUpdateUserIdsList;
|
|
93
|
+
failed_to_update_user_ids?: DeleteAccessResponseFailedToUpdateUserIdsList | undefined;
|
|
81
94
|
}
|
|
82
95
|
export interface DeleteItemRequest {
|
|
83
96
|
/** ID of the List containing the item. */
|
|
@@ -105,11 +118,13 @@ export interface DownloadGetRequest {
|
|
|
105
118
|
/** The ID of the recently started job to export the List. */
|
|
106
119
|
job_id: string;
|
|
107
120
|
/** Format the export was started with. Must match the `format` passed to `slackLists.download.start`. Defaults to `csv`. */
|
|
108
|
-
format?: string;
|
|
121
|
+
format?: string | undefined;
|
|
109
122
|
/** Must match the `include_threads` passed to `slackLists.download.start`. The returned `download_url` carries this through so the served export matches what was generated. Only applies when `format` is `json`. */
|
|
110
|
-
include_threads?: boolean;
|
|
123
|
+
include_threads?: boolean | undefined;
|
|
111
124
|
/** Must match the `include_attachments` passed to `slackLists.download.start`. The returned `download_url` carries this through so the served export matches what was generated. Only applies when `format` is `json`. */
|
|
112
|
-
include_attachments?: boolean;
|
|
125
|
+
include_attachments?: boolean | undefined;
|
|
126
|
+
/** Must match the `include_archived` passed to `slackLists.download.start`. The returned `download_url` carries this through so the served export includes archived items when they were requested. */
|
|
127
|
+
include_archived?: boolean | undefined;
|
|
113
128
|
}
|
|
114
129
|
export interface DownloadGetResponse {
|
|
115
130
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
@@ -117,24 +132,24 @@ export interface DownloadGetResponse {
|
|
|
117
132
|
/** Current status of the export job. */
|
|
118
133
|
status: unknown;
|
|
119
134
|
/** The URL at which to download the CSV. */
|
|
120
|
-
download_url?: string;
|
|
135
|
+
download_url?: string | undefined;
|
|
121
136
|
}
|
|
122
137
|
export interface DownloadStartRequest {
|
|
123
138
|
/** ID of the List to export. */
|
|
124
139
|
list_id: string;
|
|
125
|
-
include_archived?: boolean;
|
|
140
|
+
include_archived?: boolean | undefined;
|
|
126
141
|
/** Format of the export. Defaults to `csv` for backward compatibility. Use `json` for a complete, hierarchical export. */
|
|
127
|
-
format?: string;
|
|
142
|
+
format?: string | undefined;
|
|
128
143
|
/** Include each item's conversation thread in the export. Only applies when `format` is `json`. */
|
|
129
|
-
include_threads?: boolean;
|
|
144
|
+
include_threads?: boolean | undefined;
|
|
130
145
|
/** Include file attachment metadata and access paths in the export. Only applies when `format` is `json`. */
|
|
131
|
-
include_attachments?: boolean;
|
|
146
|
+
include_attachments?: boolean | undefined;
|
|
132
147
|
}
|
|
133
148
|
export interface DownloadStartResponse {
|
|
134
149
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
135
150
|
ok: boolean;
|
|
136
151
|
/** The ID of the recently started job to export the List. */
|
|
137
|
-
job_id:
|
|
152
|
+
job_id: string;
|
|
138
153
|
}
|
|
139
154
|
export interface ItemsInfoRequest {
|
|
140
155
|
/** ID of the List. */
|
|
@@ -142,7 +157,7 @@ export interface ItemsInfoRequest {
|
|
|
142
157
|
/** ID of the row to get. */
|
|
143
158
|
id: string;
|
|
144
159
|
/** Set to `true` to include `is_subscribed` data for the returned List row. */
|
|
145
|
-
include_is_subscribed?: boolean;
|
|
160
|
+
include_is_subscribed?: boolean | undefined;
|
|
146
161
|
}
|
|
147
162
|
export type ItemsInfoResponseSubtasksList = Array<unknown>;
|
|
148
163
|
export interface ItemsInfoResponse {
|
|
@@ -150,35 +165,35 @@ export interface ItemsInfoResponse {
|
|
|
150
165
|
ok: boolean;
|
|
151
166
|
list: unknown;
|
|
152
167
|
record: unknown;
|
|
153
|
-
parent_task?: unknown;
|
|
154
|
-
subtasks?: ItemsInfoResponseSubtasksList;
|
|
168
|
+
parent_task?: unknown | undefined;
|
|
169
|
+
subtasks?: ItemsInfoResponseSubtasksList | undefined;
|
|
155
170
|
}
|
|
156
171
|
export interface ListItemsRequest {
|
|
157
172
|
/** ID of the List. */
|
|
158
173
|
list_id: string;
|
|
159
|
-
/** The maximum number of records to return. */
|
|
160
|
-
limit?: number;
|
|
174
|
+
/** The maximum number of records to return, up to the list row limit of 5000. */
|
|
175
|
+
limit?: number | undefined;
|
|
161
176
|
/** Next cursor for pagination. */
|
|
162
|
-
cursor?: string;
|
|
177
|
+
cursor?: string | undefined;
|
|
163
178
|
/** Boolean indicating whether archived items or normal items should be returned. */
|
|
164
|
-
archived?: boolean;
|
|
179
|
+
archived?: boolean | undefined;
|
|
165
180
|
/** Set to `true` to also return the parent `list` object, including its title, column schema, and total row count. Defaults to `false` to keep the response small. */
|
|
166
|
-
include_list?: boolean;
|
|
181
|
+
include_list?: boolean | undefined;
|
|
167
182
|
}
|
|
168
183
|
export type ListItemsResponseItemsList = Array<unknown>;
|
|
169
184
|
/** Pagination metadata. An empty `next_cursor` means the last page. */
|
|
170
185
|
export interface ListItemsResponseResponseMetadata {
|
|
171
186
|
/** Cursor for the next page -- pass as `cursor` on the next call. */
|
|
172
|
-
next_cursor?: string;
|
|
187
|
+
next_cursor?: string | undefined;
|
|
173
188
|
}
|
|
174
189
|
export interface ListItemsResponse {
|
|
175
190
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
176
191
|
ok: boolean;
|
|
177
192
|
items: ListItemsResponseItemsList;
|
|
178
193
|
/** Pagination metadata. An empty `next_cursor` means the last page. */
|
|
179
|
-
response_metadata?: ListItemsResponseResponseMetadata;
|
|
194
|
+
response_metadata?: ListItemsResponseResponseMetadata | undefined;
|
|
180
195
|
/** The parent list. Only returned when `include_list` is `true`. `list_limits` carries `row_count` and no other key: the number of items matching this request's `archived` value, counting Slack-suggested items that `items` itself does not return, so it can exceed the number of items you can page through. Sharing and access fields (`channels`, `groups`, `ims`, `access`) are omitted; call `files.info` if you need those or the full set of list limits. */
|
|
181
|
-
list?: unknown;
|
|
196
|
+
list?: unknown | undefined;
|
|
182
197
|
}
|
|
183
198
|
/** List of channels you wish to update access for. Can only be used if `user_ids` is not provided. */
|
|
184
199
|
export type SetAccessRequestChannelIdsList = Array<string>;
|
|
@@ -190,9 +205,9 @@ export interface SetAccessRequest {
|
|
|
190
205
|
/** Desired level of access. */
|
|
191
206
|
access_level: string;
|
|
192
207
|
/** List of channels you wish to update access for. Can only be used if `user_ids` is not provided. */
|
|
193
|
-
channel_ids?: SetAccessRequestChannelIdsList;
|
|
208
|
+
channel_ids?: SetAccessRequestChannelIdsList | undefined;
|
|
194
209
|
/** List of users you wish to update access for. Can only be used if `channel_ids` is not provided. */
|
|
195
|
-
user_ids?: SetAccessRequestUserIdsList;
|
|
210
|
+
user_ids?: SetAccessRequestUserIdsList | undefined;
|
|
196
211
|
}
|
|
197
212
|
/** The channel IDs that could not be updated. */
|
|
198
213
|
export type SetAccessResponseFailedToUpdateChannelIdsList = Array<string>;
|
|
@@ -202,9 +217,9 @@ export interface SetAccessResponse {
|
|
|
202
217
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
203
218
|
ok: boolean;
|
|
204
219
|
/** The channel IDs that could not be updated. */
|
|
205
|
-
failed_to_update_channel_ids?: SetAccessResponseFailedToUpdateChannelIdsList;
|
|
220
|
+
failed_to_update_channel_ids?: SetAccessResponseFailedToUpdateChannelIdsList | undefined;
|
|
206
221
|
/** The user IDs that could not be updated. */
|
|
207
|
-
failed_to_update_user_ids?: SetAccessResponseFailedToUpdateUserIdsList;
|
|
222
|
+
failed_to_update_user_ids?: SetAccessResponseFailedToUpdateUserIdsList | undefined;
|
|
208
223
|
}
|
|
209
224
|
/** Cells to update. */
|
|
210
225
|
export type UpdateItemRequestCellsList = Array<unknown>;
|
|
@@ -224,18 +239,18 @@ export interface UpdateSlackListRequest {
|
|
|
224
239
|
/** The ID of the List to update. */
|
|
225
240
|
id: string;
|
|
226
241
|
/** The updated name of the List. */
|
|
227
|
-
name?: string;
|
|
242
|
+
name?: string | undefined;
|
|
228
243
|
/** A rich text description of the List. */
|
|
229
|
-
description_blocks?: UpdateSlackListRequestDescriptionBlocksList;
|
|
244
|
+
description_blocks?: UpdateSlackListRequestDescriptionBlocksList | undefined;
|
|
230
245
|
/** Boolean indicating whether the List should be in todo mode. */
|
|
231
|
-
todo_mode?: boolean;
|
|
246
|
+
todo_mode?: boolean | undefined;
|
|
232
247
|
}
|
|
233
248
|
export interface UpdateSlackListResponse {
|
|
234
249
|
/** Always `true` (a failed call raises a typed error instead). */
|
|
235
250
|
ok: boolean;
|
|
236
251
|
}
|
|
237
252
|
export type CreateItemError = SlackOpError;
|
|
238
|
-
/** Add a new item to an existing List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `list_not_found` -- The List was not found. - `over_row_maximum` -- Cannot create more items over the maximum. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. - `duplicated_item_not_found` -- The item to duplicate cannot be found. - `invalid_option_id` -- Option ID provided does not match column definition. - `invalid_args` -- The provided arguments are invalid. - `uneditable_column` -- Initial values provided for an uneditable column. - `invalid_input_type` -- The field value type does not match the column type. - `invalid_column_id` -- The column ID provided does not exist in the List. - `over_cell_fields_limit` -- Too many values provided for a single field. - `file_not_found` -- The attachment file could not be found. - `invalid_vote_value` -- Invalid value provided for a vote column. See https://docs.slack.dev/reference/methods/slackLists.items.create */
|
|
253
|
+
/** Add a new item to an existing List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `list_not_found` -- The List was not found. - `over_row_maximum` -- Cannot create more items over the maximum. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. - `duplicated_item_not_found` -- The item to duplicate cannot be found. - `invalid_option_id` -- Option ID provided does not match column definition. - `invalid_args` -- The provided arguments are invalid. - `uneditable_column` -- Initial values provided for an uneditable column. - `invalid_input_type` -- The field value type does not match the column type. - `invalid_column_id` -- The column ID provided does not exist in the List. - `over_cell_fields_limit` -- Too many values provided for a single field. - `file_not_found` -- The attachment file could not be found. - `invalid_vote_value` -- Invalid value provided for a vote column. - `invalid_date` -- Date supplied is invalid. - `invalid_email` -- Email supplied is invalid. - `invalid_phone_number` -- Invalid phone number provided. - `invalid_message` -- Invalid message provided. - `invalid_attachment` -- Invalid attachment provided. - `invalid_text_block` -- Rich text payload supplied is invalid. - `invalid_timestamp` -- Timestamp supplied is invalid. - `invalid_reference` -- Invalid reference provided; a reference cell holds one record or message. - `channel_not_found` -- The channel cannot be found. - `restricted_action` -- A team preference prevents this action. - `permission_denied` -- The user does not have permission to perform this action (for example, frontline members cannot create List items). See https://docs.slack.dev/reference/methods/slackLists.items.create */
|
|
239
254
|
export const createItem: API.OperationMethod<
|
|
240
255
|
CreateItemRequest,
|
|
241
256
|
CreateItemResponse,
|
|
@@ -247,10 +262,12 @@ export const createItem: API.OperationMethod<
|
|
|
247
262
|
errors: [SlackError, SlackRateLimited],
|
|
248
263
|
protocol: SlackProtocol,
|
|
249
264
|
retry: Retry.Retry,
|
|
265
|
+
telemetry: TELEMETRY,
|
|
266
|
+
span: "CreateItem",
|
|
250
267
|
}));
|
|
251
268
|
|
|
252
269
|
export type CreateSlackListError = SlackOpError;
|
|
253
|
-
/** Create a List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `permission_denied` -- The user does not have permission to perform this action. - `invalid_schema` -- The schema was invalid. - `invalid_primary_column` -- Missing or more than one primary column. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. - `over_list_file_maximum` -- Cannot create any more List files. - `over_title_length_maximum` -- Title can not exceed defined length. - `invalid_column_type` -- Column type not allowed. - `missing_arg_copy_from_list_id` -- Missing argument `copy_from_list_id`. - `invalid_copy_and_schema_args` -- Cannot provide both `copy_from_list_id` and `schema`. - `over_column_maximum` -- Cannot create List with more than allowed column count. See https://docs.slack.dev/reference/methods/slackLists.create */
|
|
270
|
+
/** Create a List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `permission_denied` -- The user does not have permission to perform this action. - `invalid_schema` -- The schema was invalid. - `invalid_primary_column` -- Missing or more than one primary column. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. - `over_list_file_maximum` -- Cannot create any more List files. - `over_title_length_maximum` -- Title can not exceed defined length. - `invalid_column_type` -- Column type not allowed. - `missing_arg_copy_from_list_id` -- Missing argument `copy_from_list_id`. - `invalid_copy_and_schema_args` -- Cannot provide both `copy_from_list_id` and `schema`. - `over_column_maximum` -- Cannot create List with more than allowed column count. - `list_not_found` -- The List was not found. - `invalid_view_metadata` -- A view on the List to copy has settings that cannot be read, so the List cannot be copied. See https://docs.slack.dev/reference/methods/slackLists.create */
|
|
254
271
|
export const createSlackList: API.OperationMethod<
|
|
255
272
|
CreateSlackListRequest,
|
|
256
273
|
CreateSlackListResponse,
|
|
@@ -262,6 +279,8 @@ export const createSlackList: API.OperationMethod<
|
|
|
262
279
|
errors: [SlackError, SlackRateLimited],
|
|
263
280
|
protocol: SlackProtocol,
|
|
264
281
|
retry: Retry.Retry,
|
|
282
|
+
telemetry: TELEMETRY,
|
|
283
|
+
span: "CreateSlackList",
|
|
265
284
|
}));
|
|
266
285
|
|
|
267
286
|
export type DeleteAccessError = SlackOpError;
|
|
@@ -277,10 +296,12 @@ export const deleteAccess: API.OperationMethod<
|
|
|
277
296
|
errors: [SlackError, SlackRateLimited],
|
|
278
297
|
protocol: SlackProtocol,
|
|
279
298
|
retry: Retry.Retry,
|
|
299
|
+
telemetry: TELEMETRY,
|
|
300
|
+
span: "DeleteAccess",
|
|
280
301
|
}));
|
|
281
302
|
|
|
282
303
|
export type DeleteItemError = SlackOpError;
|
|
283
|
-
/** Deletes an item from an existing List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `list_not_found` -- The List was not found. - `record_not_found` -- The record was not found in the List. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. See https://docs.slack.dev/reference/methods/slackLists.items.delete */
|
|
304
|
+
/** Deletes an item from an existing List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `list_not_found` -- The List was not found. - `record_not_found` -- The record was not found in the List. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. - `permission_denied` -- The user does not have permission to perform this action (for example, frontline members cannot delete List items). See https://docs.slack.dev/reference/methods/slackLists.items.delete */
|
|
284
305
|
export const deleteItem: API.OperationMethod<
|
|
285
306
|
DeleteItemRequest,
|
|
286
307
|
DeleteItemResponse,
|
|
@@ -292,10 +313,12 @@ export const deleteItem: API.OperationMethod<
|
|
|
292
313
|
errors: [SlackError, SlackRateLimited],
|
|
293
314
|
protocol: SlackProtocol,
|
|
294
315
|
retry: Retry.Retry,
|
|
316
|
+
telemetry: TELEMETRY,
|
|
317
|
+
span: "DeleteItem",
|
|
295
318
|
}));
|
|
296
319
|
|
|
297
320
|
export type DeleteMultipleError = SlackOpError;
|
|
298
|
-
/** Deletes multiple items from an existing List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `list_not_found` -- The List was not found. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. See https://docs.slack.dev/reference/methods/slackLists.items.deleteMultiple */
|
|
321
|
+
/** Deletes multiple items from an existing List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `list_not_found` -- The List was not found. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. - `permission_denied` -- The user does not have permission to perform this action (for example, frontline members cannot delete List items). See https://docs.slack.dev/reference/methods/slackLists.items.deleteMultiple */
|
|
299
322
|
export const deleteMultiple: API.OperationMethod<
|
|
300
323
|
DeleteMultipleRequest,
|
|
301
324
|
DeleteMultipleResponse,
|
|
@@ -307,6 +330,8 @@ export const deleteMultiple: API.OperationMethod<
|
|
|
307
330
|
errors: [SlackError, SlackRateLimited],
|
|
308
331
|
protocol: SlackProtocol,
|
|
309
332
|
retry: Retry.Retry,
|
|
333
|
+
telemetry: TELEMETRY,
|
|
334
|
+
span: "DeleteMultiple",
|
|
310
335
|
}));
|
|
311
336
|
|
|
312
337
|
export type DownloadGetError = SlackOpError;
|
|
@@ -322,6 +347,8 @@ export const downloadGet: API.OperationMethod<
|
|
|
322
347
|
errors: [SlackError, SlackRateLimited],
|
|
323
348
|
protocol: SlackProtocol,
|
|
324
349
|
retry: Retry.Retry,
|
|
350
|
+
telemetry: TELEMETRY,
|
|
351
|
+
span: "DownloadGet",
|
|
325
352
|
}));
|
|
326
353
|
|
|
327
354
|
export type DownloadStartError = SlackOpError;
|
|
@@ -337,6 +364,8 @@ export const downloadStart: API.OperationMethod<
|
|
|
337
364
|
errors: [SlackError, SlackRateLimited],
|
|
338
365
|
protocol: SlackProtocol,
|
|
339
366
|
retry: Retry.Retry,
|
|
367
|
+
telemetry: TELEMETRY,
|
|
368
|
+
span: "DownloadStart",
|
|
340
369
|
}));
|
|
341
370
|
|
|
342
371
|
export type ItemsInfoError = SlackOpError;
|
|
@@ -352,6 +381,8 @@ export const itemsInfo: API.OperationMethod<
|
|
|
352
381
|
errors: [SlackError, SlackRateLimited],
|
|
353
382
|
protocol: SlackProtocol,
|
|
354
383
|
retry: Retry.Retry,
|
|
384
|
+
telemetry: TELEMETRY,
|
|
385
|
+
span: "ItemsInfo",
|
|
355
386
|
}));
|
|
356
387
|
|
|
357
388
|
export type ListItemsError = SlackOpError;
|
|
@@ -369,6 +400,8 @@ export const listItems: API.PaginatedOperationMethod<
|
|
|
369
400
|
errors: [SlackError, SlackRateLimited],
|
|
370
401
|
protocol: SlackProtocol,
|
|
371
402
|
retry: Retry.Retry,
|
|
403
|
+
telemetry: TELEMETRY,
|
|
404
|
+
span: "ListItems",
|
|
372
405
|
pagination: {
|
|
373
406
|
mode: "cursor",
|
|
374
407
|
inputToken: "cursor",
|
|
@@ -393,6 +426,8 @@ export const setAccess: API.OperationMethod<
|
|
|
393
426
|
errors: [SlackError, SlackRateLimited],
|
|
394
427
|
protocol: SlackProtocol,
|
|
395
428
|
retry: Retry.Retry,
|
|
429
|
+
telemetry: TELEMETRY,
|
|
430
|
+
span: "SetAccess",
|
|
396
431
|
}));
|
|
397
432
|
|
|
398
433
|
export type UpdateItemError = SlackOpError;
|
|
@@ -408,10 +443,12 @@ export const updateItem: API.OperationMethod<
|
|
|
408
443
|
errors: [SlackError, SlackRateLimited],
|
|
409
444
|
protocol: SlackProtocol,
|
|
410
445
|
retry: Retry.Retry,
|
|
446
|
+
telemetry: TELEMETRY,
|
|
447
|
+
span: "UpdateItem",
|
|
411
448
|
}));
|
|
412
449
|
|
|
413
450
|
export type UpdateSlackListError = SlackOpError;
|
|
414
|
-
/** Update a List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `list_not_found` -- The List was not found. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. - `list_edits_update_error` -- Failed to update List metadata. - `list_editor_upsert_error` -- Failed to upsert List editor. - `over_title_length_maximum` -- Title can not exceed defined length. - `file_channel_rename_error` -- Failed to rename file channel based on file title. - `unexpected_description_blocks_arg` -- Unexpected description blocks argument. - `missing_arguments` -- No arguments were provided to update the List. See https://docs.slack.dev/reference/methods/slackLists.update */
|
|
451
|
+
/** Update a List. Required scopes -- bot: `lists:write`; user: `lists:write` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `list_not_found` -- The List was not found. - `team_not_found` -- The team cannot be found. - `user_not_found` -- The user cannot be found. - `list_edits_update_error` -- Failed to update List metadata. - `list_editor_upsert_error` -- Failed to upsert List editor. - `over_title_length_maximum` -- Title can not exceed defined length. - `file_channel_rename_error` -- Failed to rename file channel based on file title. - `unexpected_description_blocks_arg` -- Unexpected description blocks argument. - `missing_arguments` -- No arguments were provided to update the List. - `permission_denied` -- The user does not have permission to perform this action. See https://docs.slack.dev/reference/methods/slackLists.update */
|
|
415
452
|
export const updateSlackList: API.OperationMethod<
|
|
416
453
|
UpdateSlackListRequest,
|
|
417
454
|
UpdateSlackListResponse,
|
|
@@ -423,6 +460,8 @@ export const updateSlackList: API.OperationMethod<
|
|
|
423
460
|
errors: [SlackError, SlackRateLimited],
|
|
424
461
|
protocol: SlackProtocol,
|
|
425
462
|
retry: Retry.Retry,
|
|
463
|
+
telemetry: TELEMETRY,
|
|
464
|
+
span: "UpdateSlackList",
|
|
426
465
|
}));
|
|
427
466
|
|
|
428
467
|
// Schema builders: each runs one schema initializer, on that schema's first use.
|
|
@@ -571,6 +610,7 @@ function __c11(j: number): any {
|
|
|
571
610
|
format: S.optional(S.String),
|
|
572
611
|
include_threads: S.optional(S.Boolean),
|
|
573
612
|
include_attachments: S.optional(S.Boolean),
|
|
613
|
+
include_archived: S.optional(S.Boolean),
|
|
574
614
|
}).pipe(T.Http({ method: "POST", uri: "/slackLists.download.get", code: 200 })),
|
|
575
615
|
).annotate({ identifier: "DownloadGetRequest" });
|
|
576
616
|
case 1:
|
|
@@ -599,7 +639,7 @@ function __c12(j: number): any {
|
|
|
599
639
|
return S.suspend(() =>
|
|
600
640
|
S.Struct({
|
|
601
641
|
ok: S.Boolean,
|
|
602
|
-
job_id: S.
|
|
642
|
+
job_id: S.String,
|
|
603
643
|
}),
|
|
604
644
|
).annotate({ identifier: "DownloadStartResponse" });
|
|
605
645
|
}
|