Hub JS Package

Hub JS Package

  • Users
  • Buckets
  • Threads
  • Textile Docs

@textile/hub > Buckets > setDefaultArchiveConfig

Buckets.setDefaultArchiveConfig() method

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

(Experimental) Set the default ArchiveConfig for the specified Bucket.

Signature:

setDefaultArchiveConfig(key: string, config: ArchiveConfig): Promise<void>;

Parameters

ParameterTypeDescription
keystringUnique (IPNS compatible) identifier key for a bucket.
configArchiveConfigThe ArchiveConfig to set as the new default.

Returns:

Promise<void>

Example

Set the default ArchiveConfig

import { Buckets, ArchiveConfig } from '@textile/hub'

async function setDefaultConfig (buckets: Buckets, key: string, config: ArchiveConfig) {
   await buckets.setDefaultArchiveConfig(key, config)
}

  • Buckets.setDefaultArchiveConfig() method
  • Parameters
  • Example
Hub JS Package
Docs
Getting StartedThreadDBBuckets
Resources
All DocumentationProject SlackBlog
More
GitHubStar
Follow @textileio