1- import { LogsConfig as ApiLogsConfig } from '@twilio-labs/serverless-api' ;
1+ import {
2+ ClientConfig ,
3+ LogsConfig as ApiLogsConfig ,
4+ } from '@twilio-labs/serverless-api' ;
25import path from 'path' ;
36import { Arguments } from 'yargs' ;
47import checkForValidServiceSid from '../checks/check-service-sid' ;
58import { cliInfo } from '../commands/logs' ;
69import {
710 ExternalCliOptions ,
8- SharedFlagsWithCrdentials ,
11+ SharedFlagsWithCredentials ,
912} from '../commands/shared' ;
1013import { getFullCommand } from '../commands/utils' ;
1114import { readSpecializedConfig } from './global' ;
1215import { getCredentialsFromFlags } from './utils' ;
1316import { mergeFlagsAndConfig } from './utils/mergeFlagsAndConfig' ;
1417
15- export type LogsConfig = ApiLogsConfig & {
16- cwd : string ;
17- accountSid : string ;
18- authToken : string ;
19- properties ?: string [ ] ;
20- outputFormat ?: string ;
21- } ;
18+ export type LogsConfig = ClientConfig &
19+ ApiLogsConfig & {
20+ cwd : string ;
21+ accountSid : string ;
22+ authToken : string ;
23+ properties ?: string [ ] ;
24+ outputFormat ?: string ;
25+ } ;
2226
2327export type LogsCliFlags = Arguments <
24- SharedFlagsWithCrdentials & {
28+ SharedFlagsWithCredentials & {
2529 cwd ?: string ;
2630 environment ?: string ;
2731 serviceSid ?: string ;
@@ -61,6 +65,8 @@ export async function getConfigFromFlags(
6165 const command = getFullCommand ( flags ) ;
6266 const serviceSid = checkForValidServiceSid ( command , flags . serviceSid ) ;
6367 const outputFormat = flags . outputFormat || externalCliOptions ?. outputFormat ;
68+ const region = flags . region ;
69+ const edge = flags . edge ;
6470
6571 return {
6672 cwd,
@@ -71,5 +77,7 @@ export async function getConfigFromFlags(
7177 outputFormat,
7278 filterByFunction : flags . functionSid ,
7379 tail : flags . tail ,
80+ region,
81+ edge,
7482 } ;
7583}
0 commit comments