Sorry if this is a noobie question but I have being looking at this for sometime now and always thought I am missing something really obvious but time has passed by and I don’t seem to understand what is it that I am missing.
I just want to make a regular request something like the following
getFromS3 : UploadCreds -> Cmd Msg
getFromS3 creds =
Http.request
{ method = "GET"
, headers =
[
Http.header "X-Amz-Signature" creds.credentials.signature
]
, tracker = Nothing
, timeout = Nothing
, body = Http.emptyBody
!!!!!!, expect = ?? Http.expectByte or something with File.decoder probably ? !!!!!!
, url = "https://images.s3.amazonaws.com/users/user.jpg"
}
the problem is that I want to get images from the with a get method because I need credentials
I can’t just directly use the url in an img src.
is there anyway to create a custom method that would work like Http.expectFile would so I can just get the FIle ?