@@ -15,7 +15,9 @@ export default {
1515 } ,
1616 } ) ;
1717 return (
18- data ?. map ( ( { id : value , name : label } ) => ( {
18+ data ?. map ( ( {
19+ id : value , name : label ,
20+ } ) => ( {
1921 label,
2022 value,
2123 } ) ) || [ ]
@@ -26,15 +28,19 @@ export default {
2628 type : "string" ,
2729 label : "Flow ID" ,
2830 description : "The unique identifier for the flow" ,
29- async options ( { workerId, page } ) {
31+ async options ( {
32+ workerId, page,
33+ } ) {
3034 const { data } = await this . listFlows ( {
3135 workerId,
3236 params : {
3337 page : page + 1 ,
3438 } ,
3539 } ) ;
3640 return (
37- data ?. map ( ( { id : value , name : label } ) => ( {
41+ data ?. map ( ( {
42+ id : value , name : label ,
43+ } ) => ( {
3844 label,
3945 value,
4046 } ) ) || [ ]
@@ -45,15 +51,19 @@ export default {
4551 type : "string" ,
4652 label : "Deployment ID" ,
4753 description : "The unique identifier for the voice deployment" ,
48- async options ( { workerId, page } ) {
54+ async options ( {
55+ workerId, page,
56+ } ) {
4957 const { data } = await this . listVoiceDeployments ( {
5058 workerId,
5159 params : {
5260 page : page + 1 ,
5361 } ,
5462 } ) ;
5563 return (
56- data ?. map ( ( { id : value , name : label } ) => ( {
64+ data ?. map ( ( {
65+ id : value , name : label ,
66+ } ) => ( {
5767 label,
5868 value,
5969 } ) ) || [ ]
@@ -71,7 +81,9 @@ export default {
7181 } ,
7282 } ) ;
7383 return (
74- data ?. map ( ( { id : value , type : label } ) => ( {
84+ data ?. map ( ( {
85+ id : value , type : label ,
86+ } ) => ( {
7587 label : `${ label } - ${ value } ` ,
7688 value,
7789 } ) ) || [ ]
@@ -82,7 +94,9 @@ export default {
8294 type : "string" ,
8395 label : "Phone Number ID" ,
8496 description : "The unique identifier for the phone number" ,
85- async options ( { integrationId, page } ) {
97+ async options ( {
98+ integrationId, page,
99+ } ) {
86100 const params = {
87101 page : page + 1 ,
88102 } ;
@@ -93,7 +107,9 @@ export default {
93107 params,
94108 } ) ;
95109 return (
96- data ?. map ( ( { id : value , phoneNumber : label } ) => ( {
110+ data ?. map ( ( {
111+ id : value , phoneNumber : label ,
112+ } ) => ( {
97113 label,
98114 value,
99115 } ) ) || [ ]
@@ -112,7 +128,9 @@ export default {
112128 "Content-Type" : "application/json" ,
113129 } ;
114130 } ,
115- _makeRequest ( { $ = this , path, headers, ...args } = { } ) {
131+ _makeRequest ( {
132+ $ = this , path, headers, ...args
133+ } = { } ) {
116134 return axios ( $ , {
117135 ...args ,
118136 url : this . getUrl ( path ) ,
@@ -144,7 +162,9 @@ export default {
144162 } ) ;
145163 } ,
146164 // Assets
147- deletePhoneNumber ( { phoneNumberId, ...args } = { } ) {
165+ deletePhoneNumber ( {
166+ phoneNumberId, ...args
167+ } = { } ) {
148168 return this . delete ( {
149169 path : `/api/team/assets/phone_numbers/${ phoneNumberId } /delete` ,
150170 ...args ,
@@ -163,31 +183,41 @@ export default {
163183 } ) ;
164184 } ,
165185 // Flows
166- createFlow ( { workerId, ...args } = { } ) {
186+ createFlow ( {
187+ workerId, ...args
188+ } = { } ) {
167189 return this . post ( {
168190 path : `/api/workers/${ workerId } /flows` ,
169191 ...args ,
170192 } ) ;
171193 } ,
172- deleteFlow ( { workerId, flowId, ...args } = { } ) {
194+ deleteFlow ( {
195+ workerId, flowId, ...args
196+ } = { } ) {
173197 return this . delete ( {
174198 path : `/api/workers/${ workerId } /flows/${ flowId } ` ,
175199 ...args ,
176200 } ) ;
177201 } ,
178- getFlow ( { workerId, flowId, ...args } = { } ) {
202+ getFlow ( {
203+ workerId, flowId, ...args
204+ } = { } ) {
179205 return this . _makeRequest ( {
180206 path : `/api/workers/${ workerId } /flows/${ flowId } ` ,
181207 ...args ,
182208 } ) ;
183209 } ,
184- listFlows ( { workerId, ...args } = { } ) {
210+ listFlows ( {
211+ workerId, ...args
212+ } = { } ) {
185213 return this . _makeRequest ( {
186214 path : `/api/workers/${ workerId } /flows` ,
187215 ...args ,
188216 } ) ;
189217 } ,
190- updateFlow ( { workerId, flowId, ...args } = { } ) {
218+ updateFlow ( {
219+ workerId, flowId, ...args
220+ } = { } ) {
191221 return this . patch ( {
192222 path : `/api/workers/${ workerId } /flows/${ flowId } ` ,
193223 ...args ,
@@ -200,13 +230,17 @@ export default {
200230 ...args ,
201231 } ) ;
202232 } ,
203- deleteIntegration ( { integrationId, ...args } = { } ) {
233+ deleteIntegration ( {
234+ integrationId, ...args
235+ } = { } ) {
204236 return this . delete ( {
205237 path : `/api/team/integrations/twilio/${ integrationId } /delete` ,
206238 ...args ,
207239 } ) ;
208240 } ,
209- getIntegration ( { integrationId, ...args } = { } ) {
241+ getIntegration ( {
242+ integrationId, ...args
243+ } = { } ) {
210244 return this . _makeRequest ( {
211245 path : `/api/team/integrations/${ integrationId } ` ,
212246 ...args ,
@@ -226,50 +260,66 @@ export default {
226260 } ) ;
227261 } ,
228262 // Voice Deployment Logs
229- listVoiceDeploymentLogs ( { workerId, ...args } = { } ) {
263+ listVoiceDeploymentLogs ( {
264+ workerId, ...args
265+ } = { } ) {
230266 return this . _makeRequest ( {
231267 path : `/api/workers/${ workerId } /deploymentLogs/voice` ,
232268 ...args ,
233269 } ) ;
234270 } ,
235- getVoiceDeploymentLog ( { workerId, logId, ...args } = { } ) {
271+ getVoiceDeploymentLog ( {
272+ workerId, logId, ...args
273+ } = { } ) {
236274 return this . _makeRequest ( {
237275 path : `/api/workers/${ workerId } /deploymentLogs/voice/${ logId } ` ,
238276 ...args ,
239277 } ) ;
240278 } ,
241279 // Voice Deployments
242- createVoiceDeployment ( { workerId, ...args } = { } ) {
280+ createVoiceDeployment ( {
281+ workerId, ...args
282+ } = { } ) {
243283 return this . post ( {
244284 path : `/api/workers/${ workerId } /deployments/voice` ,
245285 ...args ,
246286 } ) ;
247287 } ,
248- deleteVoiceDeployment ( { workerId, deploymentId, ...args } = { } ) {
288+ deleteVoiceDeployment ( {
289+ workerId, deploymentId, ...args
290+ } = { } ) {
249291 return this . delete ( {
250292 path : `/api/workers/${ workerId } /deployments/voice/${ deploymentId } ` ,
251293 ...args ,
252294 } ) ;
253295 } ,
254- getVoiceDeployment ( { workerId, deploymentId, ...args } = { } ) {
296+ getVoiceDeployment ( {
297+ workerId, deploymentId, ...args
298+ } = { } ) {
255299 return this . _makeRequest ( {
256300 path : `/api/workers/${ workerId } /deployments/voice/${ deploymentId } ` ,
257301 ...args ,
258302 } ) ;
259303 } ,
260- listVoiceDeployments ( { workerId, ...args } = { } ) {
304+ listVoiceDeployments ( {
305+ workerId, ...args
306+ } = { } ) {
261307 return this . _makeRequest ( {
262308 path : `/api/workers/${ workerId } /deployments/voice` ,
263309 ...args ,
264310 } ) ;
265311 } ,
266- makeVoiceBatchCalls ( { workerId, deploymentId, ...args } = { } ) {
312+ makeVoiceBatchCalls ( {
313+ workerId, deploymentId, ...args
314+ } = { } ) {
267315 return this . post ( {
268316 path : `/api/workers/${ workerId } /deployments/voice/${ deploymentId } /make-batch-calls` ,
269317 ...args ,
270318 } ) ;
271319 } ,
272- updateVoiceDeployment ( { workerId, deploymentId, ...args } = { } ) {
320+ updateVoiceDeployment ( {
321+ workerId, deploymentId, ...args
322+ } = { } ) {
273323 return this . patch ( {
274324 path : `/api/workers/${ workerId } /deployments/voice/${ deploymentId } ` ,
275325 ...args ,
@@ -282,13 +332,17 @@ export default {
282332 ...args ,
283333 } ) ;
284334 } ,
285- deleteWorker ( { workerId, ...args } = { } ) {
335+ deleteWorker ( {
336+ workerId, ...args
337+ } = { } ) {
286338 return this . delete ( {
287339 path : `/api/workers/${ workerId } ` ,
288340 ...args ,
289341 } ) ;
290342 } ,
291- getWorker ( { workerId, ...args } = { } ) {
343+ getWorker ( {
344+ workerId, ...args
345+ } = { } ) {
292346 return this . _makeRequest ( {
293347 path : `/api/workers/${ workerId } ` ,
294348 ...args ,
@@ -300,7 +354,9 @@ export default {
300354 ...args ,
301355 } ) ;
302356 } ,
303- updateWorker ( { workerId, ...args } = { } ) {
357+ updateWorker ( {
358+ workerId, ...args
359+ } = { } ) {
304360 return this . patch ( {
305361 path : `/api/workers/${ workerId } ` ,
306362 ...args ,
0 commit comments