streamFileContent

abstract fun streamFileContent(fileId: String): Flow<ByteArray>

Streams a file's content as a Flow of byte arrays.

Return

A Flow emitting chunks of the file content.

Parameters

fileId

The ID of the file.

Samples

// To stream file content use streamFileContent() function.
client.streamFileContent("file_id").collect { bytesChunk ->
    println(bytesChunk.contentToString())
}