mirai-core / net.mamoe.mirai.message / java.io.InputStream / uploadAsImage

uploadAsImage

suspend fun InputStream.uploadAsImage(contact: Contact): OfflineImage

Dispatchers.IO 中读取 InputStream 到临时文件并将其作为图片上传后构造 Image

Exceptions

OverFileSizeMaxException -