/**
 * @fileoverview Approval lifecycle service for governed actions, comments,
 * hire-agent activation, budget setup, and decision records.
 *
 * @see doc/product/domains/control-plane/approvals-budgets-activity.md - approval gates and activity evidence
 * @see doc/product/domains/review-feedback-learning/review-closeout-learning.md - review decisions and follow-up
 * @see doc/product/domains/agents/identity-config.md - pending-approval agent activation
 */
import type { Db } from "@rudderhq/db";
import { approvals } from "@rudderhq/db";
export declare function approvalService(db: Db): {
    list: (orgId: string, status?: string) => Omit<import("drizzle-orm/pg-core").PgSelectBase<"approvals", {
        id: import("drizzle-orm/pg-core").PgColumn<{
            name: "id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgUUID";
            data: string;
            driverParam: string;
            notNull: true;
            hasDefault: true;
            isPrimaryKey: true;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        orgId: import("drizzle-orm/pg-core").PgColumn<{
            name: "org_id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgUUID";
            data: string;
            driverParam: string;
            notNull: true;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        type: import("drizzle-orm/pg-core").PgColumn<{
            name: "type";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: true;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        requestedByAgentId: import("drizzle-orm/pg-core").PgColumn<{
            name: "requested_by_agent_id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgUUID";
            data: string;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        requestedByUserId: import("drizzle-orm/pg-core").PgColumn<{
            name: "requested_by_user_id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        status: import("drizzle-orm/pg-core").PgColumn<{
            name: "status";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: true;
            hasDefault: true;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        payload: import("drizzle-orm/pg-core").PgColumn<{
            name: "payload";
            tableName: "approvals";
            dataType: "json";
            columnType: "PgJsonb";
            data: Record<string, unknown>;
            driverParam: unknown;
            notNull: true;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {
            $type: Record<string, unknown>;
        }>;
        decisionNote: import("drizzle-orm/pg-core").PgColumn<{
            name: "decision_note";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        decidedByUserId: import("drizzle-orm/pg-core").PgColumn<{
            name: "decided_by_user_id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        decidedAt: import("drizzle-orm/pg-core").PgColumn<{
            name: "decided_at";
            tableName: "approvals";
            dataType: "date";
            columnType: "PgTimestamp";
            data: Date;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        createdAt: import("drizzle-orm/pg-core").PgColumn<{
            name: "created_at";
            tableName: "approvals";
            dataType: "date";
            columnType: "PgTimestamp";
            data: Date;
            driverParam: string;
            notNull: true;
            hasDefault: true;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        updatedAt: import("drizzle-orm/pg-core").PgColumn<{
            name: "updated_at";
            tableName: "approvals";
            dataType: "date";
            columnType: "PgTimestamp";
            data: Date;
            driverParam: string;
            notNull: true;
            hasDefault: true;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
    }, "single", Record<"approvals", "not-null">, false, "where", {
        id: string;
        orgId: string;
        status: string;
        createdAt: Date;
        updatedAt: Date;
        type: string;
        decisionNote: string | null;
        payload: Record<string, unknown>;
        requestedByAgentId: string | null;
        decidedByUserId: string | null;
        requestedByUserId: string | null;
        decidedAt: Date | null;
    }[], {
        id: import("drizzle-orm/pg-core").PgColumn<{
            name: "id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgUUID";
            data: string;
            driverParam: string;
            notNull: true;
            hasDefault: true;
            isPrimaryKey: true;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        orgId: import("drizzle-orm/pg-core").PgColumn<{
            name: "org_id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgUUID";
            data: string;
            driverParam: string;
            notNull: true;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        type: import("drizzle-orm/pg-core").PgColumn<{
            name: "type";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: true;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        requestedByAgentId: import("drizzle-orm/pg-core").PgColumn<{
            name: "requested_by_agent_id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgUUID";
            data: string;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        requestedByUserId: import("drizzle-orm/pg-core").PgColumn<{
            name: "requested_by_user_id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        status: import("drizzle-orm/pg-core").PgColumn<{
            name: "status";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: true;
            hasDefault: true;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        payload: import("drizzle-orm/pg-core").PgColumn<{
            name: "payload";
            tableName: "approvals";
            dataType: "json";
            columnType: "PgJsonb";
            data: Record<string, unknown>;
            driverParam: unknown;
            notNull: true;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {
            $type: Record<string, unknown>;
        }>;
        decisionNote: import("drizzle-orm/pg-core").PgColumn<{
            name: "decision_note";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        decidedByUserId: import("drizzle-orm/pg-core").PgColumn<{
            name: "decided_by_user_id";
            tableName: "approvals";
            dataType: "string";
            columnType: "PgText";
            data: string;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: [string, ...string[]];
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        decidedAt: import("drizzle-orm/pg-core").PgColumn<{
            name: "decided_at";
            tableName: "approvals";
            dataType: "date";
            columnType: "PgTimestamp";
            data: Date;
            driverParam: string;
            notNull: false;
            hasDefault: false;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        createdAt: import("drizzle-orm/pg-core").PgColumn<{
            name: "created_at";
            tableName: "approvals";
            dataType: "date";
            columnType: "PgTimestamp";
            data: Date;
            driverParam: string;
            notNull: true;
            hasDefault: true;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
        updatedAt: import("drizzle-orm/pg-core").PgColumn<{
            name: "updated_at";
            tableName: "approvals";
            dataType: "date";
            columnType: "PgTimestamp";
            data: Date;
            driverParam: string;
            notNull: true;
            hasDefault: true;
            isPrimaryKey: false;
            isAutoincrement: false;
            hasRuntimeDefault: false;
            enumValues: undefined;
            baseColumn: never;
            identity: undefined;
            generated: undefined;
        }, {}, {}>;
    }>, "where">;
    getById: (id: string) => Promise<{
        id: string;
        orgId: string;
        status: string;
        createdAt: Date;
        updatedAt: Date;
        type: string;
        decisionNote: string | null;
        payload: Record<string, unknown>;
        requestedByAgentId: string | null;
        decidedByUserId: string | null;
        requestedByUserId: string | null;
        decidedAt: Date | null;
    }>;
    create: (orgId: string, data: Omit<typeof approvals.$inferInsert, "orgId">) => Promise<{
        id: string;
        orgId: string;
        status: string;
        createdAt: Date;
        updatedAt: Date;
        type: string;
        decisionNote: string | null;
        payload: Record<string, unknown>;
        requestedByAgentId: string | null;
        decidedByUserId: string | null;
        requestedByUserId: string | null;
        decidedAt: Date | null;
    }>;
    approve: (id: string, decidedByUserId: string, decisionNote?: string | null, payloadOverride?: Record<string, unknown>) => Promise<{
        approval: {
            id: string;
            orgId: string;
            status: string;
            createdAt: Date;
            updatedAt: Date;
            type: string;
            decisionNote: string | null;
            payload: Record<string, unknown>;
            requestedByAgentId: string | null;
            decidedByUserId: string | null;
            requestedByUserId: string | null;
            decidedAt: Date | null;
        };
        applied: boolean;
    }>;
    reject: (id: string, decidedByUserId: string, decisionNote?: string | null) => Promise<{
        approval: {
            id: string;
            orgId: string;
            status: string;
            createdAt: Date;
            updatedAt: Date;
            type: string;
            decisionNote: string | null;
            payload: Record<string, unknown>;
            requestedByAgentId: string | null;
            decidedByUserId: string | null;
            requestedByUserId: string | null;
            decidedAt: Date | null;
        };
        applied: boolean;
    }>;
    requestRevision: (id: string, decidedByUserId: string, decisionNote?: string | null) => Promise<{
        id: string;
        orgId: string;
        type: string;
        requestedByAgentId: string | null;
        requestedByUserId: string | null;
        status: string;
        payload: Record<string, unknown>;
        decisionNote: string | null;
        decidedByUserId: string | null;
        decidedAt: Date | null;
        createdAt: Date;
        updatedAt: Date;
    }>;
    resubmit: (id: string, payload?: Record<string, unknown>) => Promise<{
        id: string;
        orgId: string;
        type: string;
        requestedByAgentId: string | null;
        requestedByUserId: string | null;
        status: string;
        payload: Record<string, unknown>;
        decisionNote: string | null;
        decidedByUserId: string | null;
        decidedAt: Date | null;
        createdAt: Date;
        updatedAt: Date;
    }>;
    listComments: (approvalId: string) => Promise<{
        id: string;
        orgId: string;
        createdAt: Date;
        updatedAt: Date;
        body: string;
        approvalId: string;
        authorAgentId: string | null;
        authorUserId: string | null;
    }[]>;
    addComment: (approvalId: string, body: string, actor: {
        agentId?: string;
        userId?: string;
    }) => Promise<{
        id: string;
        orgId: string;
        createdAt: Date;
        updatedAt: Date;
        body: string;
        approvalId: string;
        authorAgentId: string | null;
        authorUserId: string | null;
    }>;
};
//# sourceMappingURL=approvals.d.ts.map