File tree Expand file tree Collapse file tree 1 file changed +25
-1
lines changed Expand file tree Collapse file tree 1 file changed +25
-1
lines changed Original file line number Diff line number Diff line change @@ -1464,7 +1464,31 @@ operationToAuthorizationInfo operation =
14641464 |> CliMonad . succeed
14651465
14661466 OpenApi . SecurityScheme . Cookie ->
1467- CliMonad . todoWithDefault acc " Unsupported security schema: ApiKey in Cookie"
1467+ if Dict . member " Cookie" acc. headers then
1468+ CliMonad . todoWithDefault acc " Cookie header already set"
1469+
1470+ else
1471+ CliMonad . succeed
1472+ { acc
1473+ | headers =
1474+ Dict . insert " Cookie"
1475+ ( \ config ->
1476+ Elm . Op . append
1477+ ( Elm . string ( apiKey. name ++ " =" ))
1478+ ( config
1479+ |> Elm . get " authorization"
1480+ |> Elm . get cleanName
1481+ )
1482+ )
1483+ acc. headers
1484+ , params =
1485+ Dict . insert " authorization"
1486+ ( Dict . insert cleanName Elm . Annotation . string <|
1487+ Maybe . withDefault Dict . empty <|
1488+ Dict . get " authorization" acc. params
1489+ )
1490+ acc. params
1491+ }
14681492
14691493 OpenApi . SecurityScheme . Http details ->
14701494 case details. scheme of
You can’t perform that action at this time.
0 commit comments