import { API as GithubAPI } from '../github'; import type { FetchError } from '@staticcms/core/lib/util'; import type { Config as GitHubConfig } from '../github/API'; export type GitHubApiOptions = GitHubConfig & { apiRoot: string; tokenPromise: () => Promise; commitAuthor: { name: string; }; isLargeMedia: (filename: string) => Promise; }; export default class API extends GithubAPI { tokenPromise: () => Promise; commitAuthor: { name: string; }; isLargeMedia: (filename: string) => Promise; constructor(options: GitHubApiOptions); hasWriteAccess(): Promise; requestHeaders(headers?: {}): Promise<{ Authorization: string; 'Content-Type': string; }>; handleRequestError(error: FetchError & { msg: string; }, responseStatus: number): void; user(): Promise<{ name: string; login: string; }>; getHeadReference(head: string): Promise; commit(message: string, changeTree: { parentSha?: string; sha: string; }): Promise; nextUrlProcessor(): (url: string) => string; }