UNPKG

appwrite-utils-cli

Version:

Appwrite Utility Functions to help with database management, data conversion, data import, migrations, and much more. Meant to be used as a CLI tool, I do not recommend installing this in frontend environments.

17 lines (16 loc) 793 B
import { Databases } from "node-appwrite"; import type { DatabaseAdapter } from "../adapters/DatabaseAdapter.js"; export declare const wipeDatabase: (database: Databases, databaseId: string) => Promise<{ collectionId: string; collectionName: string; }[]>; export declare const wipeCollection: (database: Databases, databaseId: string, collectionId: string) => Promise<void>; export declare const wipeAllTables: (adapter: DatabaseAdapter, databaseId: string) => Promise<{ tableId: string; tableName: string; }[]>; /** * Optimized deletion of all rows from a table using direct bulk deletion * Uses Query.limit() to delete rows without fetching IDs first */ export declare const wipeTableRows: (adapter: DatabaseAdapter, databaseId: string, tableId: string) => Promise<void>;