UNPKG

forge-sql-orm

Version:

Drizzle ORM integration for Forge-SQL in Atlassian Forge applications.

33 lines 1.27 kB
import { MigrationRunner } from "@forge/sql/out/migration"; /** * Web trigger for applying database schema migrations in Atlassian Forge SQL. * This function handles the complete migration process including: * - Database provisioning * - Migration execution * - Migration history tracking * * @param migration - A function that takes a MigrationRunner instance and returns a Promise of MigrationRunner * This function should define the sequence of migrations to be applied * @returns {Promise<{ * headers: { "Content-Type": ["application/json"] }, * statusCode: number, * statusText: string, * body: string * }>} A response object containing: * - headers: Content-Type header set to application/json * - statusCode: 200 on success * - statusText: "OK" on success * - body: Success message or error details * * @throws {Error} If database provisioning fails * @throws {Error} If migration execution fails */ export declare const applySchemaMigrations: (migration: (migrationRunner: MigrationRunner) => Promise<MigrationRunner>) => Promise<{ headers: { "Content-Type": string[]; }; statusCode: number; statusText: string; body: string; }>; //# sourceMappingURL=applyMigrationsWebTrigger.d.ts.map