CDNClient
API client that handles working with content (for example uploading attachments)
public protocol CDNClient
Requirements
maxAttachmentSize
Specifies maximum attachment size in bytes.
static var maxAttachmentSize: Int64
uploadAttachment(_:progress:completion:)
func uploadAttachment(
_ attachment: AnyChatMessageAttachment,
progress: ((Double) -> Void)?,
completion: @escaping (Result<URL, Error>) -> Void
)
Parameters
attachment
: An attachment to uploadprogress
: A closure that broadcasts upload progresscompletion
: Returns uploading result on upload completion or failure