@@ -39,6 +39,7 @@ impl GetParams {
3939#[ utoipa:: path(
4040 get,
4141 path = "/api/v1/me/tokens" ,
42+ security( ( "cookie" = [ ] ) ) ,
4243 tag = "api_tokens" ,
4344 responses( ( status = 200 , description = "Successful Response" ) ) ,
4445) ]
@@ -86,6 +87,7 @@ pub struct NewApiTokenRequest {
8687#[ utoipa:: path(
8788 put,
8889 path = "/api/v1/me/tokens" ,
90+ security( ( "cookie" = [ ] ) ) ,
8991 tag = "api_tokens" ,
9092 responses( ( status = 200 , description = "Successful Response" ) ) ,
9193) ]
@@ -184,6 +186,10 @@ pub async fn create_api_token(
184186 params(
185187 ( "id" = i32 , Path , description = "ID of the API token" ) ,
186188 ) ,
189+ security(
190+ ( "api_token" = [ ] ) ,
191+ ( "cookie" = [ ] ) ,
192+ ) ,
187193 tag = "api_tokens" ,
188194 responses( ( status = 200 , description = "Successful Response" ) ) ,
189195) ]
@@ -211,6 +217,10 @@ pub async fn find_api_token(
211217 params(
212218 ( "id" = i32 , Path , description = "ID of the API token" ) ,
213219 ) ,
220+ security(
221+ ( "api_token" = [ ] ) ,
222+ ( "cookie" = [ ] ) ,
223+ ) ,
214224 tag = "api_tokens" ,
215225 responses( ( status = 200 , description = "Successful Response" ) ) ,
216226) ]
@@ -237,6 +247,7 @@ pub async fn revoke_api_token(
237247#[ utoipa:: path(
238248 delete,
239249 path = "/api/v1/tokens/current" ,
250+ security( ( "api_token" = [ ] ) ) ,
240251 tag = "api_tokens" ,
241252 responses( ( status = 200 , description = "Successful Response" ) ) ,
242253) ]
0 commit comments