Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to provide security definitions #2959

Open
tommed opened this issue Aug 13, 2023 · 0 comments
Open

Unable to provide security definitions #2959

tommed opened this issue Aug 13, 2023 · 0 comments
Labels
generate spec Related to spec generation from code scanner

Comments

@tommed
Copy link

tommed commented Aug 13, 2023

Problem statement

My swagger:meta is working until I include SecurityDefinitions, then I get the error:

yaml: line 2: found character that cannot start any token

Swagger specification

Fragment which is causing the problem:

// Package authority ViPro Core Services Authority API.
//
// ...
//
//	SecurityDefinitions:
//		oauth2:
//			type: oauth2
//			name: Authorization
//			authorizationUrl: https://vipro.online/instances/instance/auth/authorization
//			tokenUrl: https://vipro.online/instances/instance/auth/token
//	   		in: header
//			flow: application
//	    	scopes:
//				authority: Access the claims relating to this authority service
//
// swagger:meta
package authority

Steps to reproduce

swagger generate spec -m -o swagger.yml

Environment

swagger version: version: v0.30.5 • commit: ab6a7885723430004f1d7db6395369b6e7f3370b
go version: 1.21
OS: macOS 13.5

@fredbi fredbi added scanner generate spec Related to spec generation from code labels Dec 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
generate spec Related to spec generation from code scanner
Projects
None yet
Development

No branches or pull requests

2 participants