Skip to content

Not all ouath endpoints generated in Swagger #327

Closed
@Marx2

Description

@Marx2

I have Oauth configuration like this:

public static final String OAUTH_PATH = "/oauth/token";

openAPI.addSecurityItem(new SecurityRequirement().addList(SECURITY_SCHEMA_OAUTH2, Collections.emptyList()))
       .components(
		       new Components()
				       .addSecuritySchemes(SECURITY_SCHEMA_OAUTH2,
				                           new SecurityScheme()
						                           .type(SecurityScheme.Type.OAUTH2)
						                           .bearerFormat(BEARER_FORMAT)
						                           .flows(new OAuthFlows()
								                                  .password(new OAuthFlow()
										                                            .refreshUrl(OAUTH_PATH)
										                                            .tokenUrl(OAUTH_PATH)
										                                            .scopes(new Scopes())))));


However generated documentation have only:
auth-controller
/whoAmI
/oauth/token/revokeById/{tokenId}
/tokens/revokeRefreshToken/{tokenId}

I miss /oauth/token endpoint, which is used to generate and refresh tokens.
Of course oauth flow is working ok

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions