UNPKG

@loopback/docs

Version:

Documentation files rendered at [https://loopback.io](https://loopback.io)

81 lines (41 loc) 1.45 kB
--- lang: en title: 'API docs: authentication.getauthenticatemetadata' keywords: LoopBack 4.0, LoopBack 4, Node.js, TypeScript, OpenAPI sidebar: lb4_sidebar editurl: https://github.com/loopbackio/loopback-next/tree/master/packages/authentication permalink: /doc/en/lb4/apidocs.authentication.getauthenticatemetadata.html --- <!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@loopback/authentication](./authentication.md) &gt; [getAuthenticateMetadata](./authentication.getauthenticatemetadata.md) ## getAuthenticateMetadata() function Fetch authentication metadata stored by `@authenticate` decorator. **Signature:** ```typescript export declare function getAuthenticateMetadata(targetClass: Constructor<{}>, methodName: string): AuthenticationMetadata[] | undefined; ``` ## Parameters <table><thead><tr><th> Parameter </th><th> Type </th><th> Description </th></tr></thead> <tbody><tr><td markdown="1"> targetClass </td><td markdown="1"> [Constructor](./context.constructor.md)<!-- -->&lt;{}&gt; </td><td markdown="1"> Target controller </td></tr> <tr><td markdown="1"> methodName </td><td markdown="1"> string </td><td markdown="1"> Target method </td></tr> </tbody></table> **Returns:** [AuthenticationMetadata](./authentication.authenticationmetadata.md)<!-- -->\[\] \| undefined