UNPKG

6.17 kBTypeScriptView Raw
1import { WebAPICallResult } from '../../WebClient';
2export type ViewsUpdateResponse = WebAPICallResult & {
3 error?: string;
4 needed?: string;
5 ok?: boolean;
6 provided?: string;
7 response_metadata?: ResponseMetadata;
8 view?: View;
9 warning?: string;
10};
11export interface ResponseMetadata {
12 messages?: string[];
13}
14export interface View {
15 app_id?: string;
16 app_installed_team_id?: string;
17 blocks?: Block[];
18 bot_id?: string;
19 callback_id?: string;
20 clear_on_close?: boolean;
21 close?: Close;
22 external_id?: string;
23 hash?: string;
24 id?: string;
25 notify_on_close?: boolean;
26 previous_view_id?: string;
27 private_metadata?: string;
28 root_view_id?: string;
29 state?: State;
30 submit?: Close;
31 submit_disabled?: boolean;
32 team_id?: string;
33 title?: Close;
34 type?: string;
35}
36export interface Block {
37 accessory?: Accessory;
38 alt_text?: string;
39 author_name?: string;
40 block_id?: string;
41 description?: Close;
42 dispatch_action?: boolean;
43 element?: PurpleElement;
44 elements?: StickyElement[];
45 fallback?: string;
46 fields?: Close[];
47 hint?: Close;
48 image_bytes?: number;
49 image_height?: number;
50 image_url?: string;
51 image_width?: number;
52 is_animated?: boolean;
53 label?: Close;
54 optional?: boolean;
55 provider_icon_url?: string;
56 provider_name?: string;
57 slack_file?: SlackFile;
58 text?: Close;
59 thumbnail_url?: string;
60 title?: Close;
61 title_url?: string;
62 type?: string;
63 video_url?: string;
64}
65export interface Accessory {
66 alt_text?: string;
67 fallback?: string;
68 image_bytes?: number;
69 image_height?: number;
70 image_url?: string;
71 image_width?: number;
72 slack_file?: SlackFile;
73 type?: string;
74}
75export interface SlackFile {
76 id?: string;
77 url?: string;
78}
79export interface Close {
80 emoji?: boolean;
81 text?: string;
82 type?: CloseType;
83 verbatim?: boolean;
84}
85export declare enum CloseType {
86 Empty = "",
87 Mrkdwn = "mrkdwn",
88 PlainText = "plain_text"
89}
90export interface PurpleElement {
91 accessibility_label?: string;
92 action_id?: string;
93 alt_text?: string;
94 confirm?: Confirm;
95 default_to_current_conversation?: boolean;
96 dispatch_action_config?: DispatchActionConfig;
97 fallback?: string;
98 filter?: Filter;
99 focus_on_load?: boolean;
100 image_bytes?: number;
101 image_height?: number;
102 image_url?: string;
103 image_width?: number;
104 initial_channel?: string;
105 initial_conversation?: string;
106 initial_date?: string;
107 initial_date_time?: number;
108 initial_option?: Option;
109 initial_time?: string;
110 initial_user?: string;
111 initial_value?: InitialValueClass | string;
112 max_length?: number;
113 min_length?: number;
114 min_query_length?: number;
115 multiline?: boolean;
116 option_groups?: OptionGroup[];
117 options?: Option[];
118 placeholder?: Close;
119 response_url_enabled?: boolean;
120 slack_file?: SlackFile;
121 style?: string;
122 text?: Close;
123 timezone?: string;
124 type?: string;
125 url?: string;
126 value?: string;
127}
128export interface Confirm {
129 confirm?: Close;
130 deny?: Close;
131 style?: string;
132 text?: Close;
133 title?: Close;
134}
135export interface DispatchActionConfig {
136 trigger_actions_on?: string[];
137}
138export interface Filter {
139 exclude_bot_users?: boolean;
140 exclude_external_shared_channels?: boolean;
141 include?: any[];
142}
143export interface Option {
144 description?: Close;
145 text?: Close;
146 url?: string;
147 value?: string;
148}
149export interface InitialValueClass {
150 block_id?: string;
151 elements?: InitialValueElement[];
152 type?: string;
153}
154export interface InitialValueElement {
155 border?: number;
156 elements?: FluffyElement[];
157 indent?: number;
158 offset?: number;
159 style?: string;
160 type?: string;
161}
162export interface FluffyElement {
163 border?: number;
164 elements?: TentacledElement[];
165 indent?: number;
166 offset?: number;
167 style?: string;
168 type?: string;
169}
170export interface TentacledElement {
171 channel_id?: string;
172 name?: string;
173 range?: string;
174 skin_tone?: number;
175 style?: Style;
176 team_id?: string;
177 text?: string;
178 timestamp?: string;
179 type?: ElementType;
180 unicode?: string;
181 url?: string;
182 user_id?: string;
183 usergroup_id?: string;
184 value?: string;
185}
186export interface Style {
187 bold?: boolean;
188 code?: boolean;
189 italic?: boolean;
190 strike?: boolean;
191}
192export declare enum ElementType {
193 Broadcast = "broadcast",
194 Channel = "channel",
195 Color = "color",
196 Date = "date",
197 Emoji = "emoji",
198 Link = "link",
199 Team = "team",
200 Text = "text",
201 User = "user",
202 Usergroup = "usergroup"
203}
204export interface OptionGroup {
205 label?: Close;
206 options?: Option[];
207}
208export interface StickyElement {
209 accessibility_label?: string;
210 action_id?: string;
211 alt_text?: string;
212 confirm?: Confirm;
213 default_to_current_conversation?: boolean;
214 fallback?: string;
215 filter?: Filter;
216 focus_on_load?: boolean;
217 image_bytes?: number;
218 image_height?: number;
219 image_url?: string;
220 image_width?: number;
221 initial_channel?: string;
222 initial_channels?: string[];
223 initial_conversation?: string;
224 initial_conversations?: string[];
225 initial_date?: string;
226 initial_date_time?: number;
227 initial_option?: Option;
228 initial_options?: Option[];
229 initial_time?: string;
230 initial_user?: string;
231 initial_users?: string[];
232 max_selected_items?: number;
233 min_query_length?: number;
234 option_groups?: OptionGroup[];
235 options?: Option[];
236 placeholder?: Close;
237 response_url_enabled?: boolean;
238 slack_file?: SlackFile;
239 style?: string;
240 text?: Close;
241 timezone?: string;
242 type?: string;
243 url?: string;
244 value?: string;
245 workflow?: Workflow;
246}
247export interface Workflow {
248 trigger?: Trigger;
249}
250export interface Trigger {
251 customizable_input_parameters?: CustomizableInputParameter[];
252 url?: string;
253}
254export interface CustomizableInputParameter {
255 name?: string;
256 value?: string;
257}
258export interface State {
259}
260//# sourceMappingURL=ViewsUpdateResponse.d.ts.map
\No newline at end of file