filecoin-pin
    Preparing search index...

    Interface DatasetOptions

    Dataset selection options for multi-tenant scenarios.

    This is a curated subset of Synapse SDK options focused on the common use cases for filecoin-pin.

    interface DatasetOptions {
        createNew?: boolean;
        metadata?: Record<string, string>;
        useExisting?: number;
    }
    Index

    Properties

    createNew?: boolean

    Create a new dataset even if one exists for this wallet.

    Set to true when you want each user to have their own dataset despite sharing the same wallet (e.g., multi-tenant websites and org/enterprise services using the same wallet).

    false
    
    metadata?: Record<string, string>

    Custom metadata to attach to the dataset.

    Note: If useExisting is provided, metadata is ignored since you're connecting to an existing dataset.

    useExisting?: number

    Connect to a specific dataset by ID.

    Use this to reconnect to a user's existing dataset after retrieving the ID from localStorage or a database.

    Takes precedence over createNew if both are provided.