createBucket

abstract suspend fun createBucket(id: String, builder: BucketBuilder.() -> Unit = {})(source)

Creates a new bucket in the storage

Parameters

id

the id of the bucket

builder

overrides bucket config options (like whether the bucket should be public, file size limit, etc.)

Throws

containing an error code, if receiving an error response

HttpRequestTimeoutException

if the request timed out

HttpRequestException

on network related issues