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.

26 lines (25 loc) 1.12 kB
import type { Storage, Databases } from "node-appwrite"; import type { DatabaseAdapter } from "../../adapters/DatabaseAdapter.js"; import type { DatabaseBackupReference, BucketBackupReference } from "../schemas/comprehensiveManifest.js"; import type { AppwriteConfig } from "appwrite-utils"; export interface ComprehensiveBackupOptions { trackingDatabaseId: string; backupFormat?: 'json' | 'zip'; skipDatabases?: boolean; skipBuckets?: boolean; parallelDownloads?: number; onProgress?: (message: string) => void; } export interface ComprehensiveBackupResult { backupId: string; manifestFileId: string; databaseBackups: DatabaseBackupReference[]; bucketBackups: BucketBackupReference[]; totalSizeBytes: number; status: 'completed' | 'partial' | 'failed'; errors: string[]; } /** * Orchestrates comprehensive backup of ALL databases and ALL storage buckets */ export declare function comprehensiveBackup(config: AppwriteConfig, databases: Databases, storage: Storage, adapter: DatabaseAdapter, options: ComprehensiveBackupOptions): Promise<ComprehensiveBackupResult>;