spring-doc 에서 제공하는 swagger-ui 기능에 accesstoken , refreshtoken 추가하기 #7
seonminKim1122
started this conversation in
docs
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
일반적으로 구글링해서 나오는 글들은 springfox 를 이용하거나 혹은 spring doc 을 이용하더라도 accesstoken 기능을 추가하는 것만을 다루고 있어 spring-doc에서 제공하는 swagger-ui 에서 accesstoken과 refreshtoken 을 사용하는 방법을 공유합니다.(이는 비단 token 뿐만 아니라 헤더에 key를 추가하는 방법입니다)
SecuritySceheme을 Component에 추가할 때 type을 APIKEY, in을 HEADER로 설정해주면 헤더에 원하는 key를 추가할 수 있습니다.
Beta Was this translation helpful? Give feedback.
All reactions