import type { CommonGeneratorOptions } from '@sap-cloud-sdk/generator-common'; import type { ParsedOptions } from '@sap-cloud-sdk/generator-common/internal'; /** * Options to configure OData client generation when using the generator programmatically. */ export type GeneratorOptions = CommonGeneratorOptions & OpenAPIGeneratorOptions; /** * Options to configure OpenAPI client generation when using the generator programmatically. */ export interface OpenAPIGeneratorOptions { /** * Whether to generate ECMAScript modules instead of CommonJS modules. */ generateESM?: boolean; /** * Prefix all schema names with a value. * @experimental */ schemaPrefix?: string; /** * Resolve external references. */ resolveExternal?: boolean; } /** * @internal * Represents the parsed generator options. */ export type ParsedGeneratorOptions = ParsedOptions; /** * @internal */ export declare const cliOptions: { readonly generateESM: { readonly describe: "When enabled, all generated files follow the ECMAScript module syntax."; readonly type: "boolean"; readonly default: false; }; readonly schemaPrefix: { readonly describe: "Prefix all schema names with a value. This is useful to avoid naming conflicts when multiple services are generated."; readonly type: "string"; readonly default: ""; readonly hidden: true; }; readonly resolveExternal: { readonly describe: "By default, external $ref pointers will be resolved. If set to false, external $ref pointers will be ignored."; readonly type: "boolean"; readonly default: true; readonly hidden: true; }; readonly input: { readonly alias: "i"; readonly describe: string; readonly coerce: (arg: string, options: { config?: string; }) => string[]; readonly type: "string"; readonly demandOption: true; readonly requiresArg: true; }; readonly optionsPerService: { readonly alias: "s"; readonly describe: "Configuration file to ensure consistent names between multiple generation runs with updated / changed metadata files. The configuration allows to set a `directoryName` and `npmPackageName` for every service, identified by the path to the original file. It also makes sure that names do not change between generator runs. If a directory is passed, a `options-per-service.json` file is read/created in this directory."; readonly type: "string"; readonly coerce: typeof import("@sap-cloud-sdk/generator-common/internal").resolveOptionsPerService; }; readonly clearOutputDir: { readonly type: "boolean"; readonly describe: "Remove all files in the output directory before generation. Be cautious when using this option, as it really removes EVERYTHING in the output directory."; readonly default: false; }; readonly include: { readonly type: "string"; readonly coerce: typeof import("@sap-cloud-sdk/generator-common/internal").resolveGlob; readonly describe: "Include files matching the given glob into the root of each generated client directory."; readonly requiresArg: true; }; readonly metadata: { readonly describe: "When set to true, SDK metadata for the API hub is generated."; readonly type: "boolean"; readonly default: false; readonly hidden: true; }; readonly outputDir: { readonly type: "string"; readonly alias: "o"; readonly describe: "Specify the path to the directory to generate the client(s) in. Each client is generated into a subdirectory within the given output directory. Creates the directory if it does not exist. Customize subdirectory naming through `--optionsPerService`."; readonly coerce: typeof import("@sap-cloud-sdk/generator-common/internal").resolveRequiredPath; readonly demandOption: true; readonly requiresArg: true; }; readonly overwrite: { readonly describe: "By default, the generator will exit when encountering a file that already exists. When set to true, it will be overwritten instead. Please note that compared to the --clearOutputDir option, this will not delete outdated files."; readonly type: "boolean"; readonly default: false; }; readonly packageJson: { readonly describe: "When enabled, a `package.json` that specifies dependencies and scripts for transpilation is generated."; readonly type: "boolean"; readonly default: false; }; readonly prettierConfig: { readonly type: "string"; readonly alias: "p"; readonly describe: "Specify the path to the prettier config. If not given a default config will be used for the generated sources."; readonly coerce: typeof import("@sap-cloud-sdk/generator-common/internal").resolvePath; readonly requiresArg: true; }; readonly skipValidation: { readonly type: "boolean"; readonly describe: "By default, the generation fails, when there are duplicate or invalid names in the generated services. Set this to true to enable unique and valid name generation. The names will then be generated by appending numbers and prepending prefixes."; readonly default: false; }; readonly transpile: { readonly type: "boolean"; readonly alias: "t"; readonly describe: "Transpile the generated TypeScript code. When enabled a default `tsconfig.json` will be generated and used. It emits `.js`, `.js.map`, and `.d.ts` files. To configure transpilation set `--tsconfig`."; readonly default: false; }; readonly tsconfig: { readonly describe: "Replace the default `tsconfig.json` by passing a path to a custom config. By default, a `tsconfig.json` is only generated, when transpilation is enabled (`--transpile`). If a directory is passed, a `tsconfig.json` file is read from this directory."; readonly type: "string"; readonly coerce: typeof import("@sap-cloud-sdk/generator-common/internal").resolvePath; }; readonly verbose: { readonly describe: "By default, only errors, warnings and important info logs will be displayed. If set to true, all logs will be displayed."; readonly type: "boolean"; readonly default: false; }; readonly readme: { readonly type: "boolean"; readonly describe: string; readonly default: false; readonly hidden: true; }; };