import { type Database } from "./database.js"; /** * One token bucket per connected agent and budget, in Postgres so every API * process counts the same calls (docs/mcp-surfaces.md). Returns 0 when the * call is admitted (and counted), otherwise the seconds until it would be. * One conditional UPSERT refills and takes a token atomically, so concurrent * calls on several processes never overspend. Rows live in the * organization's account context; the key is hashed and nothing else is * stored. */ export declare function admitMcpConnectionRateLimit(db: Database, input: { accountId: string; budget: string; key: string; capacity: number; refillPerSecond: number; }): Promise;