consumeContent

abstract suspend fun consumeContent(): ByteSource(source)

Open an async stream up that consumes the content of this body.

IMPORTANT: You can only call this once! Attempting to call this a second time will throw.

The returned ByteSource is Closeable, so either call use on it, e.g. body?.consumeContent()?.use { ... }, or otherwise close it when you're done with it, which will release any resources associated with file or network streams.

Note that multipart bodies should not be consumed directly; instead, call multipart.