swagger-api / swagger-api/swagger-ui

Unknown security definition type

Open
#8,144 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
29k
Forks
9.3k
Avg merge
2d 23h
Merged PRs (30d)
25

Description

Q&A (please complete the following information)
  • OS: [e.g. macOS] Windows 10
  • Browser: [e.g. chrome, safari] firefox
  • Version: [e.g. 22] 103.0 (64 bit)
  • Method of installation: [e.g. npm, dist assets] npm
  • Swagger-UI version: [e.g. 3.10.0] 2.0
  • Swagger/OpenAPI version: [e.g. Swagger 2.0, OpenAPI 3.0] Swagger 2.0
Content & configuration

Swagger/OpenAPI definition:

# your YAML here

Swagger-UI configuration options:

SwaggerUI({
  "securityDefinitions": {
    "basicAuth": [
      {
        "type": "basic"
      } 
    ]
  },
  "security": {
     "basicAuth": []
  }
})
?yourQueryStringConfig
Screenshots

image

How can we help?

I am not sure what's wrong with the code that I keep getting "Unknown security definition type" when "basic" type I have specified is a valid one in swagger version 2.0. I would really appreciate if someone can identify my mistake.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by checking the supplied Swagger 2.0 securityDefinitions configuration against the Swagger 2.0 schema and the reported Swagger-UI version. Done means determining whether the configuration or Swagger-UI produces the error and documenting a reproducible resolution; no repository file or test is named in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
documentation
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.