Avena Webapp API - v0.0.1
    Preparing search index...

    Function deleteKey

    • Deletes one key from a KV bucket.

      Uses the KV delete operation, which records a delete marker rather than purging the key's history. Errors are logged to the console and reported through the return value instead of being thrown.

      Uses shared when it is given and still open, and leaves it open. Otherwise a new connection is opened and always closed before returning.

      Parameters

      • serverName: string

        Server text passed to connect.

      • credentialsContent: string

        Contents of a .creds file, not a path.

      • bucket: string

        KV bucket name, e.g. avenabox.

      • key: string

        Key to delete.

      • Optionalshared: NatsService | null

        Open connection to reuse, such as the page's own. Optional.

      Returns Promise<boolean>

      true if the key was deleted, false if connecting or deleting failed.