MCPcopy Create free account
hub / github.com/vercel/vercel / getServiceTarget

Function getServiceTarget

packages/cli/src/util/input/display-services.ts:131–148  ·  view source on GitHub ↗
(service: ExperimentalService)

Source from the content-addressed store, hash-verified

129}
130
131function getServiceTarget(service: ExperimentalService): string {
132 if (isScheduleTriggeredService(service)) {
133 return `schedule: ${service.schedule ?? 'none'}`;
134 }
135
136 if (isQueueTriggeredService(service)) {
137 const topics = getServiceQueueTopics(service);
138 return `topics: ${topics.join(', ')}`;
139 }
140
141 if (isWorkflowTriggeredService(service)) {
142 return 'workflow';
143 }
144
145 return service.routePrefix
146 ? formatRoutePrefix(service.routePrefix)
147 : 'no route';
148}
149
150/**
151 * Output format (`experimentalServices`):

Callers 1

buildServiceRowsV1Function · 0.85

Calls 6

isQueueTriggeredServiceFunction · 0.90
getServiceQueueTopicsFunction · 0.90
formatRoutePrefixFunction · 0.85
joinMethod · 0.45

Tested by

no test coverage detected