haskell-servant / haskell-servant/servant

Dynamic Content Type

Open
#501 14 comments 1 reaction 0 assignees View on GitHub
enhancement help wanted rfc servant-client
Dominant language
Haskell
Stars
2k
Forks
427
Avg merge
2d 23h
Merged PRs (30d)
5

Description

The library is great! But there is one thing that I've been trying to figure out how to do: setting a content type on servant client depending on the input. How do I let the user define the content type? When I create the client routes, the content type is always defined next to `ReqBody`. Is there any way to do that?

A use case is file upload. For example, an avatar could have many different mime type values.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.