@loopback/docs
Version:
Documentation for LoopBack 4
1,443 lines (1,442 loc) • 74.3 kB
JSON
{
"metadata": {
"toolPackage": "@microsoft/api-extractor",
"toolVersion": "7.7.10",
"schemaVersion": 1003,
"oldestForwardsCompatibleVersion": 1001
},
"kind": "Package",
"canonicalReference": "@loopback/authorization!",
"docComment": "",
"name": "@loopback/authorization",
"members": [
{
"kind": "EntryPoint",
"canonicalReference": "@loopback/authorization!",
"name": "",
"members": [
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!ANONYMOUS:var",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "ANONYMOUS = \"$anonymous\""
}
],
"releaseTag": "Public",
"name": "ANONYMOUS",
"variableTypeTokenRange": {
"startIndex": 0,
"endIndex": 0
}
},
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!AUTHENTICATED:var",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "AUTHENTICATED = \"$authenticated\""
}
],
"releaseTag": "Public",
"name": "AUTHENTICATED",
"variableTypeTokenRange": {
"startIndex": 0,
"endIndex": 0
}
},
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!AUTHORIZATION_CLASS_KEY:var",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "AUTHORIZATION_CLASS_KEY: "
},
{
"kind": "Reference",
"text": "MetadataAccessor",
"canonicalReference": "@loopback/metadata!MetadataAccessor:class"
},
{
"kind": "Content",
"text": "<"
},
{
"kind": "Reference",
"text": "AuthorizationMetadata",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata:interface"
},
{
"kind": "Content",
"text": ", "
},
{
"kind": "Reference",
"text": "ClassDecorator",
"canonicalReference": "!ClassDecorator:type"
},
{
"kind": "Content",
"text": ">"
}
],
"releaseTag": "Public",
"name": "AUTHORIZATION_CLASS_KEY",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 7
}
},
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!AUTHORIZATION_METHOD_KEY:var",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "AUTHORIZATION_METHOD_KEY: "
},
{
"kind": "Reference",
"text": "MetadataAccessor",
"canonicalReference": "@loopback/metadata!MetadataAccessor:class"
},
{
"kind": "Content",
"text": "<"
},
{
"kind": "Reference",
"text": "AuthorizationMetadata",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata:interface"
},
{
"kind": "Content",
"text": ", "
},
{
"kind": "Reference",
"text": "MethodDecorator",
"canonicalReference": "!MethodDecorator:type"
},
{
"kind": "Content",
"text": ">"
}
],
"releaseTag": "Public",
"name": "AUTHORIZATION_METHOD_KEY",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 7
}
},
{
"kind": "Namespace",
"canonicalReference": "@loopback/authorization!AuthorizationBindings:namespace",
"docComment": "/**\n * Binding keys used by authorization component.\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "export declare namespace AuthorizationBindings "
}
],
"releaseTag": "Public",
"name": "AuthorizationBindings",
"members": [
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!AuthorizationBindings.COMPONENT:var",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "COMPONENT: "
},
{
"kind": "Reference",
"text": "BindingKey",
"canonicalReference": "@loopback/context!BindingKey:class"
},
{
"kind": "Content",
"text": "<"
},
{
"kind": "Reference",
"text": "AuthorizationComponent",
"canonicalReference": "@loopback/authorization!AuthorizationComponent:class"
},
{
"kind": "Content",
"text": ">"
}
],
"releaseTag": "Public",
"name": "COMPONENT",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 5
}
},
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!AuthorizationBindings.METADATA:var",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "METADATA: "
},
{
"kind": "Reference",
"text": "BindingKey",
"canonicalReference": "@loopback/context!BindingKey:class"
},
{
"kind": "Content",
"text": "<"
},
{
"kind": "Reference",
"text": "AuthorizationMetadata",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata:interface"
},
{
"kind": "Content",
"text": ">"
}
],
"releaseTag": "Public",
"name": "METADATA",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 5
}
}
]
},
{
"kind": "Class",
"canonicalReference": "@loopback/authorization!AuthorizationComponent:class",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "export declare class AuthorizationComponent implements "
},
{
"kind": "Reference",
"text": "Component",
"canonicalReference": "@loopback/core!Component:interface"
},
{
"kind": "Content",
"text": " "
}
],
"releaseTag": "Public",
"name": "AuthorizationComponent",
"members": [
{
"kind": "Property",
"canonicalReference": "@loopback/authorization!AuthorizationComponent#bindings:member",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "bindings: "
},
{
"kind": "Content",
"text": "import(\"@loopback/core\")."
},
{
"kind": "Reference",
"text": "Binding",
"canonicalReference": "@loopback/context!Binding:class"
},
{
"kind": "Content",
"text": "<import(\"@loopback/core\")."
},
{
"kind": "Reference",
"text": "Interceptor",
"canonicalReference": "@loopback/context!Interceptor:interface"
},
{
"kind": "Content",
"text": ">[]"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "bindings",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 6
},
"isStatic": false
}
],
"implementsTokenRanges": [
{
"startIndex": 1,
"endIndex": 3
}
]
},
{
"kind": "Interface",
"canonicalReference": "@loopback/authorization!AuthorizationContext:interface",
"docComment": "/**\n * Request context for authorization\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "export interface AuthorizationContext "
}
],
"releaseTag": "Public",
"name": "AuthorizationContext",
"members": [
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationContext#invocationContext:member",
"docComment": "/**\n * Context for the invocation\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "invocationContext: "
},
{
"kind": "Reference",
"text": "InvocationContext",
"canonicalReference": "@loopback/context!InvocationContext:class"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "invocationContext",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationContext#principals:member",
"docComment": "/**\n * An array of principals identified for the request - it should come from authentication\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "principals: "
},
{
"kind": "Reference",
"text": "Principal",
"canonicalReference": "@loopback/security!Principal:interface"
},
{
"kind": "Content",
"text": "[]"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "principals",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 3
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationContext#resource:member",
"docComment": "/**\n * An name for the target resource to be accessed, such as `OrderController.prototype.cancelOrder`\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "resource: "
},
{
"kind": "Content",
"text": "string"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "resource",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationContext#roles:member",
"docComment": "/**\n * An array of roles for principals\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "roles: "
},
{
"kind": "Reference",
"text": "Role",
"canonicalReference": "@loopback/security!Role:interface"
},
{
"kind": "Content",
"text": "[]"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "roles",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 3
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationContext#scopes:member",
"docComment": "/**\n * An array of scopes representing granted permissions - usually come from access tokens\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "scopes: "
},
{
"kind": "Content",
"text": "string[]"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "scopes",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
}
],
"extendsTokenRanges": []
},
{
"kind": "Enum",
"canonicalReference": "@loopback/authorization!AuthorizationDecision:enum",
"docComment": "/**\n * Decisions for authorization\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "export declare enum AuthorizationDecision "
}
],
"releaseTag": "Public",
"name": "AuthorizationDecision",
"members": [
{
"kind": "EnumMember",
"canonicalReference": "@loopback/authorization!AuthorizationDecision.ABSTAIN:member",
"docComment": "/**\n * No decision\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "ABSTAIN = "
},
{
"kind": "Content",
"text": "\"Abstain\""
}
],
"releaseTag": "Public",
"name": "ABSTAIN",
"initializerTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "EnumMember",
"canonicalReference": "@loopback/authorization!AuthorizationDecision.ALLOW:member",
"docComment": "/**\n * Access allowed\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "ALLOW = "
},
{
"kind": "Content",
"text": "\"Allow\""
}
],
"releaseTag": "Public",
"name": "ALLOW",
"initializerTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "EnumMember",
"canonicalReference": "@loopback/authorization!AuthorizationDecision.DENY:member",
"docComment": "/**\n * Access denied\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "DENY = "
},
{
"kind": "Content",
"text": "\"Deny\""
}
],
"releaseTag": "Public",
"name": "DENY",
"initializerTokenRange": {
"startIndex": 1,
"endIndex": 2
}
}
]
},
{
"kind": "Class",
"canonicalReference": "@loopback/authorization!AuthorizationError:class",
"docComment": "/**\n * The custom error class that describes the error thrown by the authorization module. Should be extracted to the common layer shared by authentication and authorization.\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "export declare class AuthorizationError extends "
},
{
"kind": "Reference",
"text": "Error",
"canonicalReference": "!Error:interface"
},
{
"kind": "Content",
"text": " "
}
],
"releaseTag": "Public",
"name": "AuthorizationError",
"members": [
{
"kind": "Property",
"canonicalReference": "@loopback/authorization!AuthorizationError#code:member",
"docComment": "/**\n * Machine readable code, can be understood by any clients\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "code?: "
},
{
"kind": "Content",
"text": "string"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "code",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
},
"isStatic": false
},
{
"kind": "Property",
"canonicalReference": "@loopback/authorization!AuthorizationError#statusCode:member",
"docComment": "/**\n * The status code for HTTP requests\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "statusCode?: "
},
{
"kind": "Content",
"text": "number"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "statusCode",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
},
"isStatic": false
}
],
"extendsTokenRange": {
"startIndex": 1,
"endIndex": 3
},
"implementsTokenRanges": []
},
{
"kind": "Class",
"canonicalReference": "@loopback/authorization!AuthorizationInterceptor:class",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "export declare class AuthorizationInterceptor implements "
},
{
"kind": "Reference",
"text": "Provider",
"canonicalReference": "@loopback/context!Provider:interface"
},
{
"kind": "Content",
"text": "<"
},
{
"kind": "Reference",
"text": "Interceptor",
"canonicalReference": "@loopback/context!Interceptor:interface"
},
{
"kind": "Content",
"text": "> "
}
],
"releaseTag": "Public",
"name": "AuthorizationInterceptor",
"members": [
{
"kind": "Constructor",
"canonicalReference": "@loopback/authorization!AuthorizationInterceptor:constructor(1)",
"docComment": "/**\n * Constructs a new instance of the `AuthorizationInterceptor` class\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "constructor(options?: "
},
{
"kind": "Reference",
"text": "AuthorizationOptions",
"canonicalReference": "@loopback/authorization!AuthorizationOptions:interface"
},
{
"kind": "Content",
"text": ");"
}
],
"releaseTag": "Public",
"overloadIndex": 1,
"parameters": [
{
"parameterName": "options",
"parameterTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
}
]
},
{
"kind": "Method",
"canonicalReference": "@loopback/authorization!AuthorizationInterceptor#intercept:member(1)",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "intercept(invocationCtx: "
},
{
"kind": "Reference",
"text": "InvocationContext",
"canonicalReference": "@loopback/context!InvocationContext:class"
},
{
"kind": "Content",
"text": ", next: "
},
{
"kind": "Reference",
"text": "Next",
"canonicalReference": "@loopback/context!Next:type"
},
{
"kind": "Content",
"text": "): "
},
{
"kind": "Reference",
"text": "Promise",
"canonicalReference": "!Promise:interface"
},
{
"kind": "Content",
"text": "<any>"
},
{
"kind": "Content",
"text": ";"
}
],
"isStatic": false,
"returnTypeTokenRange": {
"startIndex": 5,
"endIndex": 7
},
"releaseTag": "Public",
"overloadIndex": 1,
"parameters": [
{
"parameterName": "invocationCtx",
"parameterTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"parameterName": "next",
"parameterTypeTokenRange": {
"startIndex": 3,
"endIndex": 4
}
}
],
"name": "intercept"
},
{
"kind": "Method",
"canonicalReference": "@loopback/authorization!AuthorizationInterceptor#value:member(1)",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "value(): "
},
{
"kind": "Reference",
"text": "Interceptor",
"canonicalReference": "@loopback/context!Interceptor:interface"
},
{
"kind": "Content",
"text": ";"
}
],
"isStatic": false,
"returnTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
},
"releaseTag": "Public",
"overloadIndex": 1,
"parameters": [],
"name": "value"
}
],
"implementsTokenRanges": [
{
"startIndex": 1,
"endIndex": 5
}
]
},
{
"kind": "Interface",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata:interface",
"docComment": "/**\n * Authorization metadata supplied via `@authorize` decorator\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "export interface AuthorizationMetadata "
}
],
"releaseTag": "Public",
"name": "AuthorizationMetadata",
"members": [
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata#allowedRoles:member",
"docComment": "/**\n * Roles that are allowed access\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "allowedRoles?: "
},
{
"kind": "Content",
"text": "string[]"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "allowedRoles",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata#deniedRoles:member",
"docComment": "/**\n * Roles that are denied access\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "deniedRoles?: "
},
{
"kind": "Content",
"text": "string[]"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "deniedRoles",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata#resource:member",
"docComment": "/**\n * Name of the resource, default to the method name\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "resource?: "
},
{
"kind": "Content",
"text": "string"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "resource",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata#scopes:member",
"docComment": "/**\n * Define the access scopes\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "scopes?: "
},
{
"kind": "Content",
"text": "string[]"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "scopes",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata#skip:member",
"docComment": "/**\n * A flag to skip authorization\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "skip?: "
},
{
"kind": "Content",
"text": "boolean"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "skip",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata#voters:member",
"docComment": "/**\n * Voters that help make the authorization decision\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "voters?: "
},
{
"kind": "Content",
"text": "("
},
{
"kind": "Reference",
"text": "Authorizer",
"canonicalReference": "@loopback/authorization!Authorizer:type"
},
{
"kind": "Content",
"text": " | "
},
{
"kind": "Reference",
"text": "BindingAddress",
"canonicalReference": "@loopback/context!BindingAddress:type"
},
{
"kind": "Content",
"text": "<"
},
{
"kind": "Reference",
"text": "Authorizer",
"canonicalReference": "@loopback/authorization!Authorizer:type"
},
{
"kind": "Content",
"text": ">)[]"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "voters",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 8
}
}
],
"extendsTokenRanges": []
},
{
"kind": "Interface",
"canonicalReference": "@loopback/authorization!AuthorizationOptions:interface",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "export interface AuthorizationOptions "
}
],
"releaseTag": "Public",
"name": "AuthorizationOptions",
"members": [
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationOptions#defaultDecision:member",
"docComment": "/**\n * Default decision if all authorizers vote for ABSTAIN If not set, default to `AuthorizationDecision.DENY`\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "defaultDecision?: "
},
{
"kind": "Reference",
"text": "AuthorizationDecision.DENY",
"canonicalReference": "@loopback/authorization!AuthorizationDecision.DENY:member"
},
{
"kind": "Content",
"text": " | "
},
{
"kind": "Reference",
"text": "AuthorizationDecision.ALLOW",
"canonicalReference": "@loopback/authorization!AuthorizationDecision.ALLOW:member"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "defaultDecision",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 4
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationOptions#defaultMetadata:member",
"docComment": "/**\n * Default authorization metadata if a method is not decorated with `@authorize`. If not set, no authorization will be enforced for those methods that are not associated with authorization metadata.\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "defaultMetadata?: "
},
{
"kind": "Reference",
"text": "AuthorizationMetadata",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata:interface"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "defaultMetadata",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationOptions#precedence:member",
"docComment": "/**\n * Controls if Allow/Deny vote takes precedence and override other votes. If not set, default to `AuthorizationDecision.DENY`.\n *\n * Once a vote matches the `precedence`, it becomes the final decision. The rest of votes will be skipped.\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "precedence?: "
},
{
"kind": "Reference",
"text": "AuthorizationDecision.DENY",
"canonicalReference": "@loopback/authorization!AuthorizationDecision.DENY:member"
},
{
"kind": "Content",
"text": " | "
},
{
"kind": "Reference",
"text": "AuthorizationDecision.ALLOW",
"canonicalReference": "@loopback/authorization!AuthorizationDecision.ALLOW:member"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "precedence",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 4
}
}
],
"extendsTokenRanges": []
},
{
"kind": "Interface",
"canonicalReference": "@loopback/authorization!AuthorizationRequest:interface",
"docComment": "/**\n * Inspired by https://github.com/casbin/node-casbin\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "export interface AuthorizationRequest "
}
],
"releaseTag": "Public",
"name": "AuthorizationRequest",
"members": [
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationRequest#action:member",
"docComment": "/**\n * The operation that the requestor performs on the resource.\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "action: "
},
{
"kind": "Content",
"text": "string"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "action",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationRequest#domain:member",
"docComment": "/**\n * The domain (realm/tenant)\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "domain?: "
},
{
"kind": "Content",
"text": "string"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "domain",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationRequest#object:member",
"docComment": "/**\n * The resource that is going to be accessed.\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "object: "
},
{
"kind": "Content",
"text": "string"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "object",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
},
{
"kind": "PropertySignature",
"canonicalReference": "@loopback/authorization!AuthorizationRequest#subject:member",
"docComment": "/**\n * The requestor that wants to access a resource.\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "subject: "
},
{
"kind": "Content",
"text": "string"
},
{
"kind": "Content",
"text": ";"
}
],
"releaseTag": "Public",
"name": "subject",
"propertyTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
}
],
"extendsTokenRanges": []
},
{
"kind": "Namespace",
"canonicalReference": "@loopback/authorization!AuthorizationTags:namespace",
"docComment": "/**\n * Binding tags used by authorization component\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "export declare namespace AuthorizationTags "
}
],
"releaseTag": "Public",
"name": "AuthorizationTags",
"members": [
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!AuthorizationTags.AUTHORIZER:var",
"docComment": "/**\n * A tag for authorizers\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "AUTHORIZER = \"authorizer\""
}
],
"releaseTag": "Public",
"name": "AUTHORIZER",
"variableTypeTokenRange": {
"startIndex": 0,
"endIndex": 0
}
}
]
},
{
"kind": "Function",
"canonicalReference": "@loopback/authorization!authorize:function(1)",
"docComment": "/**\n * Decorator `@authorize` to mark methods that require authorization\n *\n * @param - spec Authorization metadata\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "export declare function authorize(spec: "
},
{
"kind": "Reference",
"text": "AuthorizationMetadata",
"canonicalReference": "@loopback/authorization!AuthorizationMetadata:interface"
},
{
"kind": "Content",
"text": "): "
},
{
"kind": "Content",
"text": "(target: any, method?: string | undefined, methodDescriptor?: "
},
{
"kind": "Reference",
"text": "TypedPropertyDescriptor",
"canonicalReference": "!TypedPropertyDescriptor:interface"
},
{
"kind": "Content",
"text": "<any> | undefined) => any"
},
{
"kind": "Content",
"text": ";"
}
],
"returnTypeTokenRange": {
"startIndex": 3,
"endIndex": 6
},
"releaseTag": "Public",
"overloadIndex": 1,
"parameters": [
{
"parameterName": "spec",
"parameterTypeTokenRange": {
"startIndex": 1,
"endIndex": 2
}
}
],
"name": "authorize"
},
{
"kind": "Namespace",
"canonicalReference": "@loopback/authorization!authorize:namespace",
"docComment": "",
"excerptTokens": [
{
"kind": "Content",
"text": "export declare namespace authorize "
}
],
"releaseTag": "Public",
"name": "authorize",
"members": [
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!authorize.allow:var",
"docComment": "/**\n * Shortcut to configure allowed roles\n *\n * @param - roles\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "allow: "
},
{
"kind": "Content",
"text": "(...roles: string[]) => (target: any, method?: string | undefined, methodDescriptor?: "
},
{
"kind": "Reference",
"text": "TypedPropertyDescriptor",
"canonicalReference": "!TypedPropertyDescriptor:interface"
},
{
"kind": "Content",
"text": "<any> | undefined) => any"
}
],
"releaseTag": "Public",
"name": "allow",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 4
}
},
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!authorize.allowAll:var",
"docComment": "/**\n * Allows all\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "allowAll: "
},
{
"kind": "Content",
"text": "() => (target: any, method?: string | undefined, methodDescriptor?: "
},
{
"kind": "Reference",
"text": "TypedPropertyDescriptor",
"canonicalReference": "!TypedPropertyDescriptor:interface"
},
{
"kind": "Content",
"text": "<any> | undefined) => any"
}
],
"releaseTag": "Public",
"name": "allowAll",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 4
}
},
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!authorize.allowAllExcept:var",
"docComment": "/**\n * Allow all but the given roles\n *\n * @param - roles\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "allowAllExcept: "
},
{
"kind": "Content",
"text": "(...roles: string[]) => (target: any, method?: string | undefined, methodDescriptor?: "
},
{
"kind": "Reference",
"text": "TypedPropertyDescriptor",
"canonicalReference": "!TypedPropertyDescriptor:interface"
},
{
"kind": "Content",
"text": "<any> | undefined) => any"
}
],
"releaseTag": "Public",
"name": "allowAllExcept",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 4
}
},
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!authorize.allowAuthenticated:var",
"docComment": "/**\n * Allow authenticated users\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "allowAuthenticated: "
},
{
"kind": "Content",
"text": "() => (target: any, method?: string | undefined, methodDescriptor?: "
},
{
"kind": "Reference",
"text": "TypedPropertyDescriptor",
"canonicalReference": "!TypedPropertyDescriptor:interface"
},
{
"kind": "Content",
"text": "<any> | undefined) => any"
}
],
"releaseTag": "Public",
"name": "allowAuthenticated",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 4
}
},
{
"kind": "Variable",
"canonicalReference": "@loopback/authorization!authorize.deny:var",
"docComment": "/**\n * Shortcut to configure denied roles\n *\n * @param - roles\n */\n",
"excerptTokens": [
{
"kind": "Content",
"text": "deny: "
},
{
"kind": "Content",
"text": "(...roles: string[]) => (target: any, method?: string | undefined, methodDescriptor?: "
},
{
"kind": "Reference",
"text": "TypedPropertyDescriptor",
"canonicalReference": "!TypedPropertyDescriptor:interface"
},
{
"kind": "Content",
"text": "<any> | undefined) => any"
}
],
"releaseTag": "Public",
"name": "deny",
"variableTypeTokenRange": {
"startIndex": 1,
"endIndex": 4
}