MCPcopy Index your code
hub / github.com/Effect-TS/effect / onGroup

Function onGroup

packages/platform/src/OpenApi.ts:298–320  ·  view source on GitHub ↗
({ group })

Source from the content-addressed store, hash-verified

296 })
297 HttpApi.reflect(api, {
298 onGroup({ group }) {
299 if (Context.get(group.annotations, Exclude)) {
300 return
301 }
302 let tag: OpenAPISpecTag = {
303 name: Context.getOrElse(group.annotations, Title, () => group.identifier)
304 }
305
306 processAnnotation(group.annotations, Description, (description) => {
307 tag.description = description
308 })
309 processAnnotation(group.annotations, ExternalDocs, (externalDocs) => {
310 tag.externalDocs = externalDocs
311 })
312 processAnnotation(group.annotations, Override, (override) => {
313 Object.assign(tag, override)
314 })
315 processAnnotation(group.annotations, Transform, (transformFn) => {
316 tag = transformFn(tag) as OpenAPISpecTag
317 })
318
319 spec.tags.push(tag)
320 },
321 onEndpoint({ endpoint, errors, group, mergedAnnotations, middleware, payloads, successes }) {
322 if (Context.get(mergedAnnotations, Exclude)) {
323 return

Callers

nothing calls this directly

Calls 2

processAnnotationFunction · 0.85
getMethod · 0.65

Tested by

no test coverage detected