/** * GitLab CI schema fetching — downloads the CI JSON Schema * and caches it locally. */ /** * Pinned schema version — a GitLab release tag that produces a known-good * schema. Override at runtime with `--schema-version ` in generate-cli * or by setting `schemaVersion` in the generate options. * * Using a tag (e.g. "v17.8.1-ee") rather than `master` ensures reproducible * codegen across environments and CI runs. */ export declare const GITLAB_SCHEMA_VERSION = "v17.8.1-ee"; /** * Get the cache file path for the CI schema. */ export declare function getCachePath(): string; /** * Path to the vendored CI schema committed in this lexicon. Reading it offline * is the default so `generate` never depends on gitlab.com — which aggressively * 429-rate-limits the raw endpoint and chronically flaked CI (#574). The * `GITLAB_SCHEMA_VERSION` pin already makes the fetch deterministic, so a * committed copy is equivalent and network-free. */ export declare function getVendoredSchemaPath(): string; /** * Fetch the GitLab CI JSON Schema, returning the raw JSON buffer. * * Default (pinned version, no force): read the vendored, committed schema — * offline, deterministic, no gitlab.com 429s (#574). Pass `force` or a custom * `version` to fetch live — used to verify against upstream or to refresh the * vendored copy when bumping the pin (see {@link refreshVendoredSchema}). * * @param force Bypass the vendored copy and download fresh. * @param version GitLab ref (tag, branch, or SHA) to fetch from. * Defaults to {@link GITLAB_SCHEMA_VERSION}. */ export declare function fetchCISchema(force?: boolean, version?: string): Promise; /** * Refresh the vendored schema from upstream. Call this when bumping * `GITLAB_SCHEMA_VERSION` so the committed copy tracks the new pin — the * lexicon-upgrade pipeline (#523) runs it as part of a gitlab pin bump. * Fetches the given version live and overwrites the vendored file. */ export declare function refreshVendoredSchema(version?: string): Promise; /** * Fetch the CI schema and return it as a Map * compatible with the generatePipeline fetchSchemas callback. * * The CI schema is a single document, so we return a single entry * keyed by "GitLab::CI::Pipeline" — the parse step will split it * into multiple entities. */ export declare function fetchSchemas(force?: boolean, version?: string): Promise>; /** * Clear the cached schema file. */ export declare function clearCache(): void; //# sourceMappingURL=fetch.d.ts.map