import type { UiServiceDeps, Result, ApprovalInfo, ApprovalMutateReturn, ApprovalsApproveArgs, ApprovalsRejectArgs, ApprovalsRequestArgs, ApprovalsRequestReturn } from '../types.js'; /** * Flip a single approval's Status line to `approved`/`rejected` (with `now` timestamp and, * for reject, an optional parenthetical feedback). Idempotent: if the target entry already has * the requested status, the markdown is returned unchanged. Throws `not-found` for an unknown id. * Only the matched entry's `- **Status**:` line is rewritten — every other line is byte-preserved. */ export declare function applyApprovalDecision(md: string, id: string, decision: 'approved' | 'rejected', now: string, feedback?: string): { md: string; entry: ApprovalInfo; }; export declare function handleApproveApproval(deps: UiServiceDeps, args: ApprovalsApproveArgs): Promise>; export declare function handleRejectApproval(deps: UiServiceDeps, args: ApprovalsRejectArgs): Promise>; /** * Build the markdown block for a queued high-privilege operation, matching the `need-approval` * skill's format exactly (so `parseApprovals` reads it back and the Approval Center renders it). * SECURITY: every prose field is SERVER-constructed from the closed `kind` enum — the browser never * supplies markdown. The only free-text input, `machineName`, is sanitized (newlines stripped, * length-capped) so it cannot inject a new `##` heading or bullet. Returns the heading line (for a * stable `headingId`) alongside the full block. Deliberately NO `Project` bullet: both kinds are * system-level operations → projectId stays null ("global") when parsed back. */ export declare function buildApprovalEntry(args: ApprovalsRequestArgs, today: string): { heading: string; block: string; }; /** * Append a `pending` approval entry for a high-privilege operation. Enqueue-only: it NEVER runs the * operation (a human/agent actions it after approval, mirroring approve/reject). Creates the file if * absent; otherwise appends after a single blank-line separator, preserving all prior entries. */ export declare function handleRequestApproval(deps: UiServiceDeps, args: ApprovalsRequestArgs): Promise>;