Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- newtype RawBytes = RawBytes {}
- type ContentLength = Header "Content-Length" Integer
- type ContentDisposition = Header "Content-Disposition" Text
- data StateAPI auth f = StateAPI {
- putProjectStateData :: f :- (Summary "Upload a state file" :> ("projects" :> (Capture' '[Required, Strict] "projectId" (Id Project) :> ("state" :> (Capture' '[Required, Strict] "stateName" Text :> ("data" :> (StreamBody NoFraming OctetStream (SourceIO RawBytes) :> (auth :> Put '[JSON] NoContent))))))))
- getProjectStates :: f :- (Summary "List all state files" :> ("projects" :> (Capture' '[Required, Strict] "projectId" (Id Project) :> ("states" :> (auth :> Get '[JSON] ProjectState)))))
- getProjectStateData :: f :- (Summary "Download a state file" :> ("projects" :> (Capture' '[Required, Strict] "projectId" (Id Project) :> ("state" :> (Capture' '[Required, Strict] "stateName" Text :> ("data" :> (auth :> StreamGet NoFraming OctetStream (Headers '[ContentLength, ContentDisposition] (SourceIO RawBytes)))))))))
Documentation
A newtype wrapper for servant-swagger
Instances
ToSchema RawBytes Source # | |
Defined in Hercules.API.State | |
MimeRender OctetStream RawBytes Source # | |
Defined in Hercules.API.State mimeRender :: Proxy OctetStream -> RawBytes -> ByteString # | |
MimeUnrender OctetStream RawBytes Source # | |
Defined in Hercules.API.State mimeUnrender :: Proxy OctetStream -> ByteString -> Either String RawBytes # mimeUnrenderWithType :: Proxy OctetStream -> MediaType -> ByteString -> Either String RawBytes # |
type ContentLength = Header "Content-Length" Integer Source #
type ContentDisposition = Header "Content-Disposition" Text Source #
StateAPI | |
|