@distilled.cloud/slack 1.0.0-rc.15 → 1.0.0-rc.16
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/credentials.d.ts +1 -1
- package/lib/credentials.d.ts.map +1 -1
- package/lib/credentials.js +39 -34
- package/lib/credentials.js.map +1 -1
- package/lib/errors.d.ts +31 -31
- package/lib/errors.d.ts.map +1 -1
- package/lib/errors.js +41 -41
- package/lib/errors.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +9 -9
- package/lib/pagination.d.ts +2 -2
- package/lib/pagination.js +28 -28
- package/lib/protocol.d.ts.map +1 -1
- package/lib/protocol.js +61 -59
- package/lib/protocol.js.map +1 -1
- package/lib/retry.d.ts +2 -2
- package/lib/retry.d.ts.map +1 -1
- package/lib/retry.js +34 -33
- package/lib/retry.js.map +1 -1
- package/lib/services/admin.d.ts +123 -575
- package/lib/services/admin.d.ts.map +1 -1
- package/lib/services/admin.js +304 -2878
- package/lib/services/agents.d.ts +13 -55
- package/lib/services/agents.d.ts.map +1 -1
- package/lib/services/agents.js +48 -309
- package/lib/services/api.d.ts +0 -4
- package/lib/services/api.d.ts.map +1 -1
- package/lib/services/api.js +16 -18
- package/lib/services/apps.d.ts +25 -106
- package/lib/services/apps.d.ts.map +1 -1
- package/lib/services/apps.js +84 -509
- package/lib/services/assistant.d.ts +6 -40
- package/lib/services/assistant.d.ts.map +1 -1
- package/lib/services/assistant.js +33 -204
- package/lib/services/auth.d.ts +4 -15
- package/lib/services/auth.d.ts.map +1 -1
- package/lib/services/auth.js +22 -90
- package/lib/services/blocks.d.ts +1 -7
- package/lib/services/blocks.d.ts.map +1 -1
- package/lib/services/blocks.js +16 -21
- package/lib/services/bookmarks.d.ts +4 -15
- package/lib/services/bookmarks.d.ts.map +1 -1
- package/lib/services/bookmarks.js +27 -76
- package/lib/services/bots.d.ts +1 -9
- package/lib/services/bots.d.ts.map +1 -1
- package/lib/services/bots.js +17 -54
- package/lib/services/calls.d.ts +6 -22
- package/lib/services/calls.d.ts.map +1 -1
- package/lib/services/calls.js +35 -110
- package/lib/services/canvases.d.ts +7 -35
- package/lib/services/canvases.d.ts.map +1 -1
- package/lib/services/canvases.js +39 -135
- package/lib/services/chat.d.ts +14 -83
- package/lib/services/chat.d.ts.map +1 -1
- package/lib/services/chat.js +59 -381
- package/lib/services/conversations.d.ts +31 -116
- package/lib/services/conversations.d.ts.map +1 -1
- package/lib/services/conversations.js +94 -690
- package/lib/services/dialog.d.ts +1 -4
- package/lib/services/dialog.d.ts.map +1 -1
- package/lib/services/dialog.js +13 -17
- package/lib/services/dnd.d.ts +5 -17
- package/lib/services/dnd.d.ts.map +1 -1
- package/lib/services/dnd.js +26 -91
- package/lib/services/emoji.d.ts +1 -8
- package/lib/services/emoji.d.ts.map +1 -1
- package/lib/services/emoji.js +18 -29
- package/lib/services/entity.d.ts +4 -16
- package/lib/services/entity.d.ts.map +1 -1
- package/lib/services/entity.js +29 -71
- package/lib/services/files.d.ts +16 -80
- package/lib/services/files.d.ts.map +1 -1
- package/lib/services/files.js +75 -433
- package/lib/services/functions.d.ts +8 -49
- package/lib/services/functions.d.ts.map +1 -1
- package/lib/services/functions.js +45 -203
- package/lib/services/lists.d.ts +13 -55
- package/lib/services/lists.d.ts.map +1 -1
- package/lib/services/lists.js +53 -248
- package/lib/services/migration.d.ts +1 -7
- package/lib/services/migration.d.ts.map +1 -1
- package/lib/services/migration.js +18 -27
- package/lib/services/oauth.d.ts +7 -43
- package/lib/services/oauth.d.ts.map +1 -1
- package/lib/services/oauth.js +34 -289
- package/lib/services/openid.d.ts +3 -10
- package/lib/services/openid.d.ts.map +1 -1
- package/lib/services/openid.js +19 -79
- package/lib/services/pins.d.ts +3 -13
- package/lib/services/pins.d.ts.map +1 -1
- package/lib/services/pins.js +27 -61
- package/lib/services/reactions.d.ts +5 -17
- package/lib/services/reactions.d.ts.map +1 -1
- package/lib/services/reactions.js +30 -96
- package/lib/services/reminders.d.ts +5 -17
- package/lib/services/reminders.d.ts.map +1 -1
- package/lib/services/reminders.js +33 -83
- package/lib/services/rtm.d.ts +2 -11
- package/lib/services/rtm.d.ts.map +1 -1
- package/lib/services/rtm.js +22 -56
- package/lib/services/search.d.ts +4 -35
- package/lib/services/search.d.ts.map +1 -1
- package/lib/services/search.js +28 -167
- package/lib/services/stars.d.ts +4 -26
- package/lib/services/stars.d.ts.map +1 -1
- package/lib/services/stars.js +28 -128
- package/lib/services/team.d.ts +11 -63
- package/lib/services/team.d.ts.map +1 -1
- package/lib/services/team.js +45 -289
- package/lib/services/tooling.d.ts +2 -5
- package/lib/services/tooling.d.ts.map +1 -1
- package/lib/services/tooling.js +15 -28
- package/lib/services/usergroups.d.ts +7 -31
- package/lib/services/usergroups.d.ts.map +1 -1
- package/lib/services/usergroups.js +40 -146
- package/lib/services/users.d.ts +14 -48
- package/lib/services/users.d.ts.map +1 -1
- package/lib/services/users.js +54 -249
- package/lib/services/views.d.ts +4 -14
- package/lib/services/views.d.ts.map +1 -1
- package/lib/services/views.js +28 -73
- package/lib/services/workflows.d.ts +8 -51
- package/lib/services/workflows.d.ts.map +1 -1
- package/lib/services/workflows.js +37 -188
- package/lib/traits.d.ts +1 -1
- package/lib/traits.js +8 -8
- package/package.json +14 -10
- package/src/credentials.ts +20 -21
- package/src/errors.ts +31 -27
- package/src/index.ts +1 -1
- package/src/pagination.ts +2 -2
- package/src/protocol.ts +30 -29
- package/src/retry.ts +6 -6
- package/src/services/admin.ts +2717 -3451
- package/src/services/agents.ts +380 -370
- package/src/services/api.ts +31 -21
- package/src/services/apps.ts +569 -621
- package/src/services/assistant.ts +235 -270
- package/src/services/auth.ts +118 -100
- package/src/services/blocks.ts +33 -29
- package/src/services/bookmarks.ts +101 -83
- package/src/services/bots.ts +74 -67
- package/src/services/calls.ts +118 -124
- package/src/services/canvases.ts +171 -178
- package/src/services/chat.ts +428 -496
- package/src/services/conversations.ts +675 -761
- package/src/services/dialog.ts +30 -17
- package/src/services/dnd.ts +125 -99
- package/src/services/emoji.ts +46 -42
- package/src/services/entity.ts +94 -92
- package/src/services/files.ts +536 -531
- package/src/services/functions.ts +209 -274
- package/src/services/lists.ts +289 -304
- package/src/services/migration.ts +39 -37
- package/src/services/oauth.ts +345 -361
- package/src/services/openid.ts +137 -122
- package/src/services/pins.ts +83 -70
- package/src/services/reactions.ts +119 -103
- package/src/services/reminders.ts +112 -90
- package/src/services/rtm.ts +73 -65
- package/src/services/search.ts +193 -244
- package/src/services/stars.ts +101 -160
- package/src/services/team.ts +333 -369
- package/src/services/tooling.ts +43 -30
- package/src/services/usergroups.ts +175 -179
- package/src/services/users.ts +301 -268
- package/src/services/views.ts +85 -80
- package/src/services/workflows.ts +184 -269
- package/src/traits.ts +1 -1
- package/lib/protocol.test.d.ts +0 -2
- package/lib/protocol.test.d.ts.map +0 -1
- package/lib/protocol.test.js +0 -288
- package/lib/protocol.test.js.map +0 -1
- package/lib/services/admin.js.map +0 -1
- package/lib/services/agents.js.map +0 -1
- package/lib/services/api.js.map +0 -1
- package/lib/services/apps.js.map +0 -1
- package/lib/services/assistant.js.map +0 -1
- package/lib/services/auth.js.map +0 -1
- package/lib/services/blocks.js.map +0 -1
- package/lib/services/bookmarks.js.map +0 -1
- package/lib/services/bots.js.map +0 -1
- package/lib/services/calls.js.map +0 -1
- package/lib/services/canvases.js.map +0 -1
- package/lib/services/chat.js.map +0 -1
- package/lib/services/conversations.js.map +0 -1
- package/lib/services/dialog.js.map +0 -1
- package/lib/services/dnd.js.map +0 -1
- package/lib/services/emoji.js.map +0 -1
- package/lib/services/entity.js.map +0 -1
- package/lib/services/files.js.map +0 -1
- package/lib/services/functions.js.map +0 -1
- package/lib/services/lists.js.map +0 -1
- package/lib/services/migration.js.map +0 -1
- package/lib/services/oauth.js.map +0 -1
- package/lib/services/openid.js.map +0 -1
- package/lib/services/pins.js.map +0 -1
- package/lib/services/reactions.js.map +0 -1
- package/lib/services/reminders.js.map +0 -1
- package/lib/services/rtm.js.map +0 -1
- package/lib/services/search.js.map +0 -1
- package/lib/services/stars.js.map +0 -1
- package/lib/services/team.js.map +0 -1
- package/lib/services/tooling.js.map +0 -1
- package/lib/services/usergroups.js.map +0 -1
- package/lib/services/users.js.map +0 -1
- package/lib/services/views.js.map +0 -1
- package/lib/services/workflows.js.map +0 -1
- package/src/protocol.test.ts +0 -372
package/lib/services/canvases.js
CHANGED
|
@@ -1,141 +1,45 @@
|
|
|
1
1
|
import * as API from "@distilled.cloud/core/api";
|
|
2
2
|
// AUTO-GENERATED by scripts/generate.ts from .generated-specs (docs.slack.dev JSON twins). Do not edit.
|
|
3
|
-
import * as S from "@distilled.cloud/core/schema";
|
|
3
|
+
import * as S from "@distilled.cloud/core/schema-lite";
|
|
4
|
+
import * as __L from "@distilled.cloud/core/schema-lite";
|
|
4
5
|
import { SlackError, SlackRateLimited } from "../errors.js";
|
|
5
6
|
import { SlackProtocol } from "../protocol.js";
|
|
6
7
|
import * as Retry from "../retry.js";
|
|
7
8
|
import * as T from "../traits.js";
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
export const
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
export const
|
|
25
|
-
|
|
26
|
-
export const
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
})).
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
}
|
|
45
|
-
export const GetContentRequestContentType = S.String;
|
|
46
|
-
export const GetContentRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
|
|
47
|
-
canvas_id: S.String,
|
|
48
|
-
content_type: S.optional(GetContentRequestContentType),
|
|
49
|
-
}).pipe(T.Http({ method: "POST", uri: "/canvases.getContent", code: 200 }))).annotate({ identifier: "GetContentRequest" });
|
|
50
|
-
export const GetContentResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
|
|
51
|
-
ok: S.Boolean,
|
|
52
|
-
content: S.String,
|
|
53
|
-
})).annotate({ identifier: "GetContentResponse" });
|
|
54
|
-
export const LookupSectionRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
|
|
55
|
-
canvas_id: S.String,
|
|
56
|
-
criteria: S.Unknown,
|
|
57
|
-
}).pipe(T.Http({ method: "POST", uri: "/canvases.sections.lookup", code: 200 }))).annotate({ identifier: "LookupSectionRequest" });
|
|
58
|
-
export const LookupSectionResponseSectionsItemChildSectionIdsList = /*@__PURE__*/ S.Array(S.String);
|
|
59
|
-
export const LookupSectionResponseSectionsItem = /*@__PURE__*/ S.suspend(() => S.Struct({
|
|
60
|
-
id: S.String,
|
|
61
|
-
child_section_ids: S.optional(LookupSectionResponseSectionsItemChildSectionIdsList),
|
|
62
|
-
})).annotate({
|
|
63
|
-
identifier: "LookupSectionResponseSectionsItem",
|
|
64
|
-
});
|
|
65
|
-
export const LookupSectionResponseSectionsList = /*@__PURE__*/ S.Array(LookupSectionResponseSectionsItem);
|
|
66
|
-
export const LookupSectionResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
|
|
67
|
-
ok: S.Boolean,
|
|
68
|
-
sections: LookupSectionResponseSectionsList,
|
|
69
|
-
})).annotate({ identifier: "LookupSectionResponse" });
|
|
70
|
-
export const SetAccessRequestChannelIdsList = /*@__PURE__*/ S.Array(S.String);
|
|
71
|
-
export const SetAccessRequestUserIdsList = /*@__PURE__*/ S.Array(S.String);
|
|
72
|
-
export const SetAccessRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
|
|
73
|
-
canvas_id: S.String,
|
|
74
|
-
access_level: S.String,
|
|
75
|
-
channel_ids: S.optional(SetAccessRequestChannelIdsList),
|
|
76
|
-
user_ids: S.optional(SetAccessRequestUserIdsList),
|
|
77
|
-
}).pipe(T.Http({ method: "POST", uri: "/canvases.access.set", code: 200 }))).annotate({ identifier: "SetAccessRequest" });
|
|
78
|
-
export const SetAccessResponseFailedToUpdateChannelIdsList = /*@__PURE__*/ S.Array(S.String);
|
|
79
|
-
export const SetAccessResponseFailedToUpdateUserIdsList = /*@__PURE__*/ S.Array(S.String);
|
|
80
|
-
export const SetAccessResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
|
|
81
|
-
ok: S.Boolean,
|
|
82
|
-
failed_to_update_channel_ids: S.optional(SetAccessResponseFailedToUpdateChannelIdsList),
|
|
83
|
-
failed_to_update_user_ids: S.optional(SetAccessResponseFailedToUpdateUserIdsList),
|
|
84
|
-
})).annotate({ identifier: "SetAccessResponse" });
|
|
85
|
-
/** Create canvas for a user Required scopes — bot: `canvases:write`; user: `canvases:write`; seamless_user: `seamless.user` Rate limit tier: 2 Method-specific errors (the `error` slug on the SlackError): - `canvas_disabled_user_team` — Canvas is disabled on user's team - `restricted_action` — User does not have permission to perform this action. - `canvas_creation_failed` — Canvas was unable to be created. - `free_team_canvas_tab_already_exists` — Free teams are limited to one canvas tab per channel - `free_teams_cannot_create_standalone_canvases` — Free teams cannot create standalone canvases See https://docs.slack.dev/reference/methods/canvases.create */
|
|
86
|
-
export const createCanvase = /*@__PURE__*/ API.make(() => ({
|
|
87
|
-
input: CreateCanvaseRequest,
|
|
88
|
-
output: CreateCanvaseResponse,
|
|
89
|
-
errors: [SlackError, SlackRateLimited],
|
|
90
|
-
protocol: SlackProtocol,
|
|
91
|
-
retry: Retry.Retry,
|
|
92
|
-
}));
|
|
93
|
-
/** Remove access to a canvas for specified entities Required scopes — bot: `canvases:write`; user: `canvases:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `canvas_not_found` — The canvas you wish to revoke permissions for is not available. - `restricted_action` — User does not have permission to perform this action. - `canvas_disabled_user_team` — Canvas is disabled on user's team. - `invalid_parameters` — One of user_ids and channel_ids must be defined. - `channel_not_found` — A channel could not be found. - `user_not_found` — A user could not be found. See https://docs.slack.dev/reference/methods/canvases.access.delete */
|
|
94
|
-
export const deleteAccess = /*@__PURE__*/ API.make(() => ({
|
|
95
|
-
input: DeleteAccessRequest,
|
|
96
|
-
output: DeleteAccessResponse,
|
|
97
|
-
errors: [SlackError, SlackRateLimited],
|
|
98
|
-
protocol: SlackProtocol,
|
|
99
|
-
retry: Retry.Retry,
|
|
100
|
-
}));
|
|
101
|
-
/** Deletes a canvas Required scopes — bot: `canvases:write`; user: `canvases:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `canvas_deleting_disabled` — This functionality is disabled. - `canvas_not_found` — The canvas does not exist, or is not visible to the calling user. - `restricted_action` — User does not have permission to perform this action. See https://docs.slack.dev/reference/methods/canvases.delete */
|
|
102
|
-
export const deleteCanvase = /*@__PURE__*/ API.make(() => ({
|
|
103
|
-
input: DeleteCanvaseRequest,
|
|
104
|
-
output: DeleteCanvaseResponse,
|
|
105
|
-
errors: [SlackError, SlackRateLimited],
|
|
106
|
-
protocol: SlackProtocol,
|
|
107
|
-
retry: Retry.Retry,
|
|
108
|
-
}));
|
|
109
|
-
/** Update an existing canvas Required scopes — bot: `canvases:write`; user: `canvases:write`; seamless_user: `seamless.user` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `canvas_not_found` — The canvas you wish to apply changes to is not available. - `canvas_disabled_user_team` — Canvas is disabled on user's team - `free_teams_cannot_edit_standalone_canvases` — Free teams cannot edit standalone canvases - `restricted_action` — User does not have permission to perform this action. - `canvas_editing_failed` — The changes to the canvas failed to be applied. - `canvas_editing_locked` — Another edit to this canvas is currently in progress. Please retry after a short delay. - `canvas_too_large` — The canvas is too large to apply the requested changes. Reduce the size of the canvas or the edit and try again. See https://docs.slack.dev/reference/methods/canvases.edit */
|
|
110
|
-
export const editCanvase = /*@__PURE__*/ API.make(() => ({
|
|
111
|
-
input: EditCanvaseRequest,
|
|
112
|
-
output: EditCanvaseResponse,
|
|
113
|
-
errors: [SlackError, SlackRateLimited],
|
|
114
|
-
protocol: SlackProtocol,
|
|
115
|
-
retry: Retry.Retry,
|
|
116
|
-
}));
|
|
117
|
-
/** Get the content of a canvas as markdown (default) or HTML. Required scopes — bot: `canvases:read`; user: `canvases:read` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `canvas_disabled_user_team` — Canvas is disabled on user's team - `canvas_not_found` — The canvas does not exist, or is not visible to the calling user. See https://docs.slack.dev/reference/methods/canvases.getContent */
|
|
118
|
-
export const getContent = /*@__PURE__*/ API.make(() => ({
|
|
119
|
-
input: GetContentRequest,
|
|
120
|
-
output: GetContentResponse,
|
|
121
|
-
errors: [SlackError, SlackRateLimited],
|
|
122
|
-
protocol: SlackProtocol,
|
|
123
|
-
retry: Retry.Retry,
|
|
124
|
-
}));
|
|
125
|
-
/** Find sections matching the provided criteria Required scopes — bot: `canvases:read`; user: `canvases:read` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `canvas_deleted` — The canvas you wish to search is not available. - `canvas_disabled_user_team` — Canvas is disabled on user's team. - `canvas_not_found` — The canvas you wish to search for is not available. - `internal_error` — Something went wrong on our end, please try again. See https://docs.slack.dev/reference/methods/canvases.sections.lookup */
|
|
126
|
-
export const lookupSection = /*@__PURE__*/ API.make(() => ({
|
|
127
|
-
input: LookupSectionRequest,
|
|
128
|
-
output: LookupSectionResponse,
|
|
129
|
-
errors: [SlackError, SlackRateLimited],
|
|
130
|
-
protocol: SlackProtocol,
|
|
131
|
-
retry: Retry.Retry,
|
|
132
|
-
}));
|
|
133
|
-
/** Sets the access level to a canvas for specified entities Required scopes — bot: `canvases:write`; user: `canvases:write` Rate limit tier: 3 Method-specific errors (the `error` slug on the SlackError): - `canvas_disabled_user_team` — Canvas is disabled on user's team - `canvas_not_found` — The canvas you wish to update permissions for is not available. - `channel_not_found` — A channel could not be found. - `failed_to_update_user_ids` — Failed to update the specified user_ids. - `invalid_parameters` — One of user_ids or channel_ids must be defined, but not both. - `restricted_action` — User does not have permission to perform this action. - `user_not_found` — A user could not be found. See https://docs.slack.dev/reference/methods/canvases.access.set */
|
|
134
|
-
export const setAccess = /*@__PURE__*/ API.make(() => ({
|
|
135
|
-
input: SetAccessRequest,
|
|
136
|
-
output: SetAccessResponse,
|
|
137
|
-
errors: [SlackError, SlackRateLimited],
|
|
138
|
-
protocol: SlackProtocol,
|
|
139
|
-
retry: Retry.Retry,
|
|
140
|
-
}));
|
|
141
|
-
//# sourceMappingURL=canvases.js.map
|
|
9
|
+
const __0 = __L.at;
|
|
10
|
+
const __1 = T.Http;
|
|
11
|
+
const __2 = S.String;
|
|
12
|
+
const __3 = S.optional;
|
|
13
|
+
const __4 = S.Unknown;
|
|
14
|
+
const __5 = S.Struct;
|
|
15
|
+
const __6 = S.suspend;
|
|
16
|
+
const __7 = S.Boolean;
|
|
17
|
+
const __8 = S.Array;
|
|
18
|
+
|
|
19
|
+
export const createCanvase = /*@__PURE__*/ API.op((i) => i === API.D ? ['{input:#1,output:#2,errors:[$8,$9],protocol:$10,retry:$11};$6(>3)@"CreateCanvaseRequest";$6(>4)@"CreateCanvaseResponse";$5({title:$3($2),document_content:$3($4),channel_id:$3($2)}).pipe($1({method:"POST",uri:"/canvases.create",code:200}));$5({ok:$7,canvas_id:$2})', [__0, __1, __2, __3, __4, __5, __6, __7, SlackError, SlackRateLimited, SlackProtocol, Retry.Retry]] : API.call(createCanvase, i));
|
|
20
|
+
|
|
21
|
+
export const deleteAccess = /*@__PURE__*/ API.op((i) => i === API.D ? ['{input:#1,output:#7:0,errors:[$8,$9],protocol:$10,retry:$11};$6(>2)@"DeleteAccessRequest";$5({canvas_id:$2,channel_ids:$4(#3:0),user_ids:$4(#3:0)}).pipe($1({method:"POST",uri:"/canvases.access.delete",code:200}))', [__0, __1, __2, __d0, __3, __5, __6, __d1, SlackError, SlackRateLimited, SlackProtocol, Retry.Retry]] : API.call(deleteAccess, i));
|
|
22
|
+
|
|
23
|
+
export const deleteCanvase = /*@__PURE__*/ API.op((i) => i === API.D ? ['{input:#1,output:#5:0,errors:[$6,$7],protocol:$8,retry:$9};$4(>2)@"DeleteCanvaseRequest";$3({canvas_id:$2}).pipe($1({method:"POST",uri:"/canvases.delete",code:200}))', [__0, __1, __2, __5, __6, __d2, SlackError, SlackRateLimited, SlackProtocol, Retry.Retry]] : API.call(deleteCanvase, i));
|
|
24
|
+
|
|
25
|
+
export const editCanvase = /*@__PURE__*/ API.op((i) => i === API.D ? ['{input:#2,output:#7:0,errors:[$8,$9],protocol:$10,retry:$11};$2($1);$6(>3)@"EditCanvaseRequest";$5({canvas_id:$4,changes:#1}).pipe($3({method:"POST",uri:"/canvases.edit",code:200}))', [__0, __4, __8, __1, __2, __5, __6, __d2, SlackError, SlackRateLimited, SlackProtocol, Retry.Retry]] : API.call(editCanvase, i));
|
|
26
|
+
|
|
27
|
+
export const getContent = /*@__PURE__*/ API.op((i) => i === API.D ? ['{input:#1,output:#2,errors:[$7,$8],protocol:$9,retry:$10};$5(>3)@"GetContentRequest";$5(>4)@"GetContentResponse";$4({canvas_id:$2,content_type:$3($2)}).pipe($1({method:"POST",uri:"/canvases.getContent",code:200}));$4({ok:$6,content:$2})', [__0, __1, __2, __3, __5, __6, __7, SlackError, SlackRateLimited, SlackProtocol, Retry.Retry]] : API.call(getContent, i));
|
|
28
|
+
|
|
29
|
+
export const lookupSection = /*@__PURE__*/ API.op((i) => i === API.D ? API.named("LookupSectionResponse", '{input:#1,output:#4,errors:[$10,$11],protocol:$12,retry:$13};$5(>5)@"LookupSectionRequest";$5(>6)@"%SectionsItem";$8(#2);$5(>7)@"%";$4({canvas_id:$2,criteria:$3}).pipe($1({method:"POST",uri:"/canvases.sections.lookup",code:200}));$4({id:$2,child_section_ids:$7(#6:0)});$4({ok:$9,sections:#3})', [__0, __1, __2, __4, __5, __6, __d0, __3, __8, __7, SlackError, SlackRateLimited, SlackProtocol, Retry.Retry]) : API.call(lookupSection, i));
|
|
30
|
+
|
|
31
|
+
export const setAccess = /*@__PURE__*/ API.op((i) => i === API.D ? ['{input:#1,output:#7:0,errors:[$8,$9],protocol:$10,retry:$11};$6(>2)@"SetAccessRequest";$5({canvas_id:$2,access_level:$2,channel_ids:$4(#3:0),user_ids:$4(#3:0)}).pipe($1({method:"POST",uri:"/canvases.access.set",code:200}))', [__0, __1, __2, __d0, __3, __5, __6, __d1, SlackError, SlackRateLimited, SlackProtocol, Retry.Retry]] : API.call(setAccess, i));
|
|
32
|
+
// Schema builders: each runs one schema initializer, on that schema's first use.
|
|
33
|
+
// Schema table: entry i is schema j of builder f, made on first reach.
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
// Shared schema data (see `op` in core/api).
|
|
37
|
+
function __d0() {
|
|
38
|
+
return ['$2($1)', [__0, __2, __8]];
|
|
39
|
+
}
|
|
40
|
+
function __d1() {
|
|
41
|
+
return ['$5(>1)@"DeleteAccessResponse";$4({ok:$1,failed_to_update_channel_ids:$3(#2:0),failed_to_update_user_ids:$3(#2:0)})', [__0, __7, __d0, __3, __5, __6]];
|
|
42
|
+
}
|
|
43
|
+
function __d2() {
|
|
44
|
+
return ['$3(>1)@"DeleteCanvaseResponse";$2({ok:$1})', [__0, __7, __5, __6]];
|
|
45
|
+
}
|