@textile/hub > Buckets > create
Buckets.create() method
Creates a new bucket.
Signature:
create(name: string, options?: CreateOptions): Promise<CreateResponse>;
Parameters
Parameter | Type | Description |
---|---|---|
name | string | Human-readable bucket name. It is only meant to help identify a bucket in a UI and is not unique. |
options | CreateOptions |
Returns:
Promise<CreateResponse>
Example
Create a Bucket called "app-name-files"
import { Buckets } from '@textile/hub'
const create = async (buckets: Buckets) => {
return buckets.create("app-name-files")
}