/**
 * @fileoverview Budget policy, spend observation, incident, and hard-stop
 * enforcement service.
 *
 * @see doc/product/domains/control-plane/approvals-budgets-activity.md - budget visibility and hard-stop behavior
 * @see doc/product/domains/execution/run-admission-and-recovery.md - budget-blocked run admission
 * @see doc/product/domains/agents/identity-config.md - agent pause state from budget enforcement
 */
import type { Db } from "@rudderhq/db";
import { costEvents } from "@rudderhq/db";
import type { BudgetIncident, BudgetIncidentResolutionInput, BudgetOverview, BudgetPolicy, BudgetPolicySummary, BudgetPolicyUpsertInput, BudgetScopeType } from "@rudderhq/shared";
export type BudgetEnforcementScope = {
    orgId: string;
    scopeType: BudgetScopeType;
    scopeId: string;
};
export type BudgetServiceHooks = {
    cancelWorkForScope?: (scope: BudgetEnforcementScope) => Promise<void>;
};
export declare function budgetService(db: Db, hooks?: BudgetServiceHooks): {
    listPolicies: (orgId: string) => Promise<BudgetPolicy[]>;
    upsertPolicy: (orgId: string, input: BudgetPolicyUpsertInput, actorUserId: string | null) => Promise<BudgetPolicySummary>;
    deletePolicy: (orgId: string, policyId: string, actorUserId: string | null) => Promise<{
        ok: true;
        policyId: string;
    }>;
    overview: (orgId: string) => Promise<BudgetOverview>;
    evaluateCostEvent: (event: typeof costEvents.$inferSelect) => Promise<void>;
    getInvocationBlock: (orgId: string, agentId: string, context?: {
        issueId?: string | null;
        projectId?: string | null;
    }) => Promise<{
        scopeType: "organization";
        scopeId: string;
        scopeName: string;
        reason: string;
    } | {
        scopeType: "agent";
        scopeId: string;
        scopeName: string;
        reason: string;
    } | {
        scopeType: "project";
        scopeId: string;
        scopeName: string;
        reason: string;
    } | null>;
    resolveIncident: (orgId: string, incidentId: string, input: BudgetIncidentResolutionInput, actorUserId: string) => Promise<BudgetIncident>;
};
//# sourceMappingURL=budgets.d.ts.map