import type { HackMdConfig } from "../config.js"; type Fetch = typeof fetch; export type NotePermissionRole = "owner" | "signed_in" | "guest"; export type CommentPermissionType = "disabled" | "forbidden" | "owners" | "signed_in_users" | "everyone"; export type SuggestEditPermissionType = "disabled" | "forbidden" | "owners" | "signed_in_users"; export interface NoteSelector { noteId: string; teamPath?: string; } export interface ListNotesInput { teamPath?: string; } export interface FolderSelector { teamPath?: string; folderId: string; } export interface ListFoldersInput { teamPath?: string; } export interface CreateFolderInput { teamPath?: string; name: string; description?: string; icon?: string; color?: string; parentFolderId?: string; } export interface UpdateFolderInput { teamPath?: string; folderId: string; name?: string; description?: string | null; icon?: string | null; color?: string | null; parentFolderId?: string | null; } export interface CreateNoteInput { teamPath?: string; title?: string; content: string; tags?: string[]; description?: string; readPermission?: NotePermissionRole; writePermission?: NotePermissionRole; commentPermission?: CommentPermissionType; suggestEditPermission?: SuggestEditPermissionType; parentFolderId?: string; permalink?: string; } export interface UpdateNoteInput { teamPath?: string; noteId: string; title?: string; content?: string; tags?: string[]; description?: string; readPermission?: NotePermissionRole; writePermission?: NotePermissionRole; parentFolderId?: string; permalink?: string; } export interface HackMdClientOptions extends HackMdConfig { fetch?: Fetch; } export declare class HackMdHttpError extends Error { readonly status: number; readonly path: string; readonly responseText: string; constructor(status: number, path: string, responseText: string); } export declare class HackMdNetworkError extends Error { readonly url: string; readonly cause: unknown; constructor(url: string, cause: unknown); } export declare class HackMdClient { private readonly apiToken?; private readonly apiUrl; private readonly fetchImpl; constructor(options: HackMdClientOptions); getProfile(): Promise; listNotes(input?: ListNotesInput): Promise; getNote(input: NoteSelector): Promise; createNote(input: CreateNoteInput): Promise; updateNote(input: UpdateNoteInput): Promise; listFolders(input?: ListFoldersInput): Promise; getFolder(input: FolderSelector): Promise; createFolder(input: CreateFolderInput): Promise; updateFolder(input: UpdateFolderInput): Promise; private notesPath; private foldersPath; private request; } export {}; //# sourceMappingURL=client.d.ts.map