UNPKG

@bzr/bazaar

Version:

The Bazaar SDK. Conveniently use Bazaar with your app in the browser.

25 lines (24 loc) 681 B
import { ContextOptions } from "../types"; import type { API } from "./raw"; /** * The class that encapsulates the collections API * @internal */ export declare class CollectionsAPI { private api; private contextOptions; constructor(api: API, contextOptions?: ContextOptions); /** * Creates a collection. */ create(collectionName: string): Promise<import("../types").BazaarMessage>; /** * Drops a collection. */ drop(collectionName: string): Promise<import("../types").BazaarMessage>; /** * Lists all collection names. * @returns Where `data` is an array of collection names */ list(): Promise<string[]>; }