import type { CompletionResult, ParsedArgs } from "@cotal-ai/core"; import { type MeshEntry } from "@cotal-ai/workspace"; export declare const spaceFlags: readonly [{ readonly name: "json"; readonly short: "j"; readonly type: "boolean"; readonly description: "structured output on stdout"; }, { readonly name: "plain"; readonly type: "boolean"; readonly description: "plain line-oriented output"; }, { readonly name: "server"; readonly type: "string"; readonly value: ""; readonly description: "add: the space's broker URL"; }, { readonly name: "root"; readonly type: "string"; readonly value: ""; readonly description: "add: the folder for the space's personas and, for an auth space, its .cotal/auth trust (default: this project; required outside one); create: the folder it starts in (default: this one)"; }, { readonly name: "mode"; readonly type: "string"; readonly value: ""; readonly description: "add: how the broker authenticates (default: auth when --root holds the space's trust, else open)"; }, { readonly name: "file"; readonly short: "f"; readonly type: "string"; readonly value: ""; readonly description: "add: a user-auth connection bundle exported where the space runs"; }, { readonly name: "from"; readonly type: "string"; readonly value: ""; readonly description: "add: fetch the space's discovery document; its pins are shown and confirmed"; }, { readonly name: "tls"; readonly type: "boolean"; readonly description: "add: require TLS on every connection to the space (a tls:// or wss:// --server implies it)"; }, { readonly name: "allow-unencrypted-overlay"; readonly type: "boolean"; readonly description: "add: accept that an overlay address is protected only while its tunnel is up"; }, { readonly name: "force"; readonly type: "boolean"; readonly description: "add: replace a registration added by hand, and add a --server space without checking its broker"; }, { readonly name: "yes"; readonly short: "y"; readonly type: "boolean"; readonly description: "confirm without the terminal question; a delete must name the exact space, and an add still confirms fetched pins"; }, { readonly name: "dry-run"; readonly type: "boolean"; readonly description: "delete: read native first-party impact without deleting anything"; }]; /** Whether a registration's broker answered. A discovered catalog entry is never dialed by a read, so * its broker is `not-checked` rather than a guessed answer. */ export type Check = "reachable" | "unreachable" | "not-checked"; /** One registered space, as `cotal space` lists it: the same row `cotal status --json` gives under * `meshes.items`. */ export interface SpaceRow { readonly space: string; readonly server: string; readonly mode: MeshEntry["mode"]; readonly root: string; /** `up` when this machine started it, `manual` when it was registered by hand, `catalog` when a * signed-in catalog lists it, null for a record written before origins were recorded. */ readonly origin: MeshEntry["origin"] | null; readonly tlsRequired: boolean; readonly eventsRequired: boolean; /** Whether it is the space `cotal use` selected. */ readonly current: boolean; readonly check: Check; /** A discovered space's catalog name when it differs from the space, and the last fetch. */ readonly catalog: { readonly name: string | null; readonly fetchedAt: string | null; readonly error: string | null; } | null; } /** A prepared space, as `cotal space` lists it and `cotal space show` shows it. */ export interface PreparedRow { readonly space: string; readonly root: string; readonly preparedAt: string; readonly current: boolean; } /** One registration in full. Pins and endpoints are public; credential paths are left out. */ export interface SpaceDetail extends Omit { readonly kind: "space"; readonly recordedAt: string; readonly attachHost: string | null; readonly maxSessions: number | null; readonly storeDir: string | null; readonly unencryptedOverlay: boolean; readonly userAuth: { readonly provider: string; readonly idp: { readonly url: string; readonly issuer: string; readonly audience: string; }; readonly remote: boolean; } | null; readonly catalog: (NonNullable & { readonly id: string | null; readonly slug: string | null; readonly kind: string | null; readonly role: string | null; }) | null; } /** * `cotal space` lists the spaces this machine can reach, and `cotal space show []` shows one in * full. Both read the local registry and probe brokers; neither writes anything. A broker that does * not answer leaves its registration in place, reported `unreachable`. Spaces `space create` * prepared are listed apart, with no broker to probe. `space add`, `space create` and * `space forget` change what is recorded (see `space-registration.ts`). */ export declare function space(args: ParsedArgs): Promise; /** One registration in full, as `space show` reports it. */ export declare function detail(m: MeshEntry, current: string | null, check: Check): SpaceDetail; /** Argument completion: the subcommand, then registered names. */ export declare function spaceComplete(argv: string[]): CompletionResult; //# sourceMappingURL=space.d.ts.map