/** * v1.2 §3.1 / §4.2 — Discord OAuth Invite URL synthesis + browser-open. * * The bot owner runs `solosquad discord invite-url` (or it is auto-invoked * by `init` / `add-org` Step 4). The URL is composed deterministically from * the application's client_id and the v1.2 §4.2 permissions bitfield, so * the result is the same every run for a given workspace — the user can * paste it into a guild owner's hands without re-deriving anything. * * No external `open` / `clipboardy` dependency is added — we shell out to * the OS-default URL handler. If the handler is missing or returns an * error, callers see the URL printed and can copy it manually. */ /** * Permissions enumerated in v1.2 PRD §4.2. Stored as a `Record` because Discord permission bits are 64-bit and several entries * (Send Messages in Threads, Use Application Commands, etc.) exceed * Number.MAX_SAFE_INTEGER's relevance for sum stability — bigint keeps * the math exact. * * Excluded (Discord verification trigger): Administrator, Manage Guild, * Manage Roles, Kick/Ban, Mention Everyone. */ export declare const DEFAULT_PERMISSIONS: Readonly>; /** Sum of DEFAULT_PERMISSIONS — invite URL `permissions` param. */ export declare const DEFAULT_PERMISSIONS_BITFIELD: bigint; export interface InviteUrlInput { applicationClientId: string; /** Override the default bitfield (rare — testing only). */ permissions?: bigint; /** Discord OAuth scopes. Default: ["bot", "applications.commands"]. */ scopes?: string[]; } /** * Build the invite URL deterministically. Pure function — no side effects. */ export declare function buildInviteUrl(input: InviteUrlInput): string; /** * Attempt to open `url` in the OS default browser. Returns `true` when the * spawn was issued successfully — note this does not guarantee the user * actually saw the page (e.g. headless CI). Callers should always print the * URL as the canonical signal regardless of return value. */ export declare function openInBrowser(url: string): boolean;