I'm building an API where the client can send me a blob of data and I save it somewhere for retrieval later. I don't care what the content-type is. I just want to get the raw data every time, no matter what they set Content-Type to. I know this can be achieved in older versions of ASPNET by accessing the Request object, but this does not seem possible with ASPNET 5, nor would I want to do this because it would make unit testing impossible (Request is not dependency injected).
I've seen some mentions of the IInputFormatter and IOutputFormatter interfaces, but those seem to attach to a specific Content-Type. I think I'm looking for something that's more like the [FromBody] attribute, but that gives me raw output. Something like [RawBody]. I've done quite a bit of searching and can't seem to find any simple solutions for this.