Using an API Key & Secret for Swagger Security Scheme -


swagger supports security of api key, seems limited single parameter.

is there way define set of parameters (key , secret) expected parameters in request?

or way skip security scheme, , add parameters every request?

yes, in swagger 2.0 can specify multiple api key security definition , mark operation require multiple securities.

in following example, i'm using 2 api key securities should presented in header of each request in order authenticated.

swagger: '2.0' info:   version: 0.0.0   title: simple api securitydefinitions:   key:     type: apikey     in: header     name: key   value:     type: apikey     in: header     name: value paths:   /:     get:       security:         - key: []         - value: []       responses:         200:           description: ok 

at moment swagger editor's "try operation" not support multiple securities being used doesn't mean swagger not supporting it.

follow this issue in github support of feature in swagger editor.


Popular posts from this blog

c# - ODP.NET Oracle.ManagedDataAccess causes ORA-12537 network session end of file -

matlab - Compression and Decompression of ECG Signal using HUFFMAN ALGORITHM -

utf 8 - split utf-8 string into bytes in python -