botas-core
    Preparing search index...

    Interface Storage

    Storage provider for reading/writing bot state.

    interface Storage {
        read(keys: string[]): Promise<Record<string, unknown>>;
        write(changes: Record<string, unknown>): Promise<void>;
        delete(keys: string[]): Promise<void>;
    }

    Implemented by

    Index

    Methods

    Methods

    • Read items from storage.

      Parameters

      • keys: string[]

        Keys to read.

      Returns Promise<Record<string, unknown>>

      Dictionary of key-value pairs that exist in storage.

    • Write items to storage.

      Parameters

      • changes: Record<string, unknown>

        Dictionary of key-value pairs to write.

      Returns Promise<void>