UNPKG

@loopback/docs

Version:
32 lines (20 loc) 764 B
--- lang: en title: 'API docs: security.defaultsubject.getprincipal' keywords: LoopBack 4.0, LoopBack 4 sidebar: lb4_sidebar permalink: /doc/en/lb4/apidocs.security.defaultsubject.getprincipal.html --- <!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@loopback/security](./security.md) &gt; [DefaultSubject](./security.defaultsubject.md) &gt; [getPrincipal](./security.defaultsubject.getprincipal.md) ## DefaultSubject.getPrincipal() method <b>Signature:</b> ```typescript getPrincipal(type: string): Principal | undefined; ``` ## Parameters | Parameter | Type | Description | | --- | --- | --- | | type | <code>string</code> | | <b>Returns:</b> `Principal | undefined`