import type { Terminal } from "../terminal.js"; import { type Fetched } from "./api.js"; import { type CanvasRegistry } from "./registry.js"; /** Shared by `canvas pull` and by `canvas open` on a canvas this checkout did not push. */ export type CanvasRef = { id: string; origin: string | undefined; writeToken: string | undefined; }; /** Pulling an edit link is how a checkout that never pushed a canvas gets its token. */ export declare const readCanvasRef: (value: string) => CanvasRef; /** A pasted link says where it lives; --api still wins. */ export declare const refApi: (origin: string | undefined, apiFlag: unknown, env: Record) => string; export type Recorded = "imported" | "kept" | "overtaken" | "refused" | "elsewhere"; export declare const tellRecorded: (recorded: Recorded, id: string, terminal: Terminal) => void; export type Pulled = { fetched: Fetched | undefined; recorded: Recorded; }; /** An edit link's token is recorded only once the app accepts it. `token` lets an owner fetch a private canvas. */ export declare const pullCanvas: (registry: CanvasRegistry, pull: { api: string; id: string; writeToken: string | undefined; out: string; token: string | undefined; }, terminal: Terminal) => Promise; //# sourceMappingURL=pull.d.ts.map