Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/Servant/Swagger/Internal.hs
Original file line number Diff line number Diff line change
Expand Up @@ -318,6 +318,10 @@ instance (KnownSymbol desc, HasSwagger api) => HasSwagger (Description desc :> a
toSwagger _ = toSwagger (Proxy :: Proxy api)
& allOperations.description %~ (Just (Text.pack (symbolVal (Proxy :: Proxy desc))) <>)

instance (KnownSymbol opid, HasSwagger api) => HasSwagger (OperationId opid :> api) where
toSwagger _ = toSwagger (Proxy :: Proxy api)
& allOperations.operationId ?~ Text.pack (symbolVal (Proxy :: Proxy opid))

instance (KnownSymbol desc, HasSwagger api) => HasSwagger (Summary desc :> api) where
toSwagger _ = toSwagger (Proxy :: Proxy api)
& allOperations.summary %~ (Just (Text.pack (symbolVal (Proxy :: Proxy desc))) <>)
Expand Down