Kind: Function
Source: atloria-monorepo/packages/ui-core/src/components/api-explorer/oauth2.ts
Which OAuth2 scheme — and which scopes — this operation demands.
security is an OR of alternatives, each an AND of schemes. We take the first alternative
naming a scheme we can run, which is the one a reader would be steered towards anyway. An
operation declaring no security of its own inherits the document default; security: []
is explicitly public and inherits nothing.
Signature
tsfunction resolveOAuth2Requirement(endpointSecurity: Array<Record<string, string[]>> | undefined, documentSecurity: Array<Record<string, string[]>> | undefined, schemes: OAuth2Scheme[]): OAuth2Requirement | null
Parameters
| Name | Type |
|---|---|
endpointSecurity | `Array<Record<string, string[]>> |
documentSecurity | `Array<Record<string, string[]>> |
schemes | OAuth2Scheme[] |
Returns: OAuth2Requirement | null
Was this page helpful?