UNPKG

@loopback/docs

Version:
48 lines (32 loc) 2.11 kB
--- lang: en title: 'API docs: openapi-v3.oasenhancerservice' keywords: LoopBack 4.0, LoopBack 4 sidebar: lb4_sidebar editurl: https://github.com/strongloop/loopback-next/tree/master/packages/openapi-v3 permalink: /doc/en/lb4/apidocs.openapi-v3.oasenhancerservice.html --- <!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@loopback/openapi-v3](./openapi-v3.md) &gt; [OASEnhancerService](./openapi-v3.oasenhancerservice.md) ## OASEnhancerService class An extension point for OpenAPI Spec enhancement This service is used for enhancing an OpenAPI spec by loading and applying one or more registered enhancers. A typical use of it would be generating the OpenAPI spec for the endpoints on a server in the `@loopback/rest` module. <b>Signature:</b> ```typescript export declare class OASEnhancerService ``` ## Constructors | Constructor | Modifiers | Description | | --- | --- | --- | | [(constructor)(getEnhancers, options)](./openapi-v3.oasenhancerservice._constructor_.md) | | Constructs a new instance of the <code>OASEnhancerService</code> class | ## Properties | Property | Modifiers | Type | Description | | --- | --- | --- | --- | | [options](./openapi-v3.oasenhancerservice.options.md) | | <code>OASEnhancerServiceOptions &#124; undefined</code> | An extension point should be able to receive its options via dependency injection. | | [spec](./openapi-v3.oasenhancerservice.spec.md) | | <code>OpenApiSpec</code> | Getter for <code>_spec</code> | ## Methods | Method | Modifiers | Description | | --- | --- | --- | | [applyAllEnhancers(options)](./openapi-v3.oasenhancerservice.applyallenhancers.md) | | Generate OpenAPI spec by applying ALL registered enhancers TBD: load enhancers by group names | | [applyEnhancerByName(name)](./openapi-v3.oasenhancerservice.applyenhancerbyname.md) | | Apply a given enhancer's merge function. Return the latest \_spec. | | [getEnhancerByName(name)](./openapi-v3.oasenhancerservice.getenhancerbyname.md) | | Find an enhancer by its name |