Add gateway-first pattern: when AGILITON_API_KEY is set, route all external API calls through the gateway with X-API-Key auth. Falls back to direct API access when gateway is unavailable. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
16 lines
572 B
TypeScript
16 lines
572 B
TypeScript
import { FormatMode, FormatName } from "./formats";
|
|
import type { Plugin, Format } from "ajv";
|
|
export { FormatMode, FormatName } from "./formats";
|
|
export { LimitFormatError } from "./limit";
|
|
export interface FormatOptions {
|
|
mode?: FormatMode;
|
|
formats?: FormatName[];
|
|
keywords?: boolean;
|
|
}
|
|
export type FormatsPluginOptions = FormatName[] | FormatOptions;
|
|
export interface FormatsPlugin extends Plugin<FormatsPluginOptions> {
|
|
get: (format: FormatName, mode?: FormatMode) => Format;
|
|
}
|
|
declare const formatsPlugin: FormatsPlugin;
|
|
export default formatsPlugin;
|