mirror of
https://github.com/Redocly/redoc.git
synced 2024-11-25 10:03:45 +03:00
Security definitions docs
This commit is contained in:
parent
9e7ba0ea8d
commit
9955cb8fec
|
@ -94,6 +94,9 @@ For npm:
|
|||
|
||||
## Configuration
|
||||
|
||||
### Security Definition location
|
||||
You can inject Security Definitions widget into any place of your specification `description`. Check out details [here](docs/security-definitions-injection.md).
|
||||
|
||||
### Swagger vendor extensions
|
||||
ReDoc makes use of the following [vendor extensions](http://swagger.io/specification/#vendorExtensions):
|
||||
* [`x-logo`](docs/redoc-vendor-extensions.md#x-logo) - is used to specify API logo
|
||||
|
|
19
docs/security-definitions-injection.md
Normal file
19
docs/security-definitions-injection.md
Normal file
|
@ -0,0 +1,19 @@
|
|||
# Injection security definitions
|
||||
|
||||
You can inject Security Definitions widget into any place of your specification `description`:
|
||||
|
||||
```markdown
|
||||
...
|
||||
# Authorization
|
||||
Some description
|
||||
|
||||
<!-- ReDoc-Inject: <security-definitions> -->
|
||||
...
|
||||
```
|
||||
Inject instruction is wrapped into HTML comment so it is **visible only in ReDoc**. It won't be visible e.g. in SwaggerUI.
|
||||
|
||||
# Default behavior
|
||||
If injection tag is not found in the description it will be appended to the end
|
||||
of description under `Authentication` header.
|
||||
|
||||
If `Authentication` header is already present in the description, Security Definitions won't be inserted and rendered at all.
|
Loading…
Reference in New Issue
Block a user