@@ -571,6 +571,7 @@ export { CollectionFormatService } from './services/CollectionFormatService';
571571export { ComplexService } from './services/ComplexService';
572572export { DefaultsService } from './services/DefaultsService';
573573export { DuplicateService } from './services/DuplicateService';
574+ export { ErrorService } from './services/ErrorService';
574575export { HeaderService } from './services/HeaderService';
575576export { MultipleTags1Service } from './services/MultipleTags1Service';
576577export { MultipleTags2Service } from './services/MultipleTags2Service';
@@ -2179,6 +2180,42 @@ export class DuplicateService {
21792180}"
21802181`;
21812182
2183+ exports[`v2 should generate: ./test/generated/v2/services/ErrorService.ts 1`] = `
2184+ "/* istanbul ignore file */
2185+ /* tslint:disable */
2186+ /* eslint-disable */
2187+ import type { CancelablePromise } from '../core/CancelablePromise';
2188+ import { request as __request } from '../core/request';
2189+ import { OpenAPI } from '../core/OpenAPI';
2190+
2191+ export class ErrorService {
2192+
2193+ /**
2194+ * @param status Status code to return
2195+ * @returns any Custom message: Successful response
2196+ * @throws ApiError
2197+ */
2198+ public static testErrorCode(
2199+ status: string,
2200+ ): CancelablePromise<any> {
2201+ return __request({
2202+ method: 'POST',
2203+ path: \`/api/v\${OpenAPI.VERSION}/error\`,
2204+ query: {
2205+ 'status': status,
2206+ },
2207+ errors: {
2208+ 500: \`Custom message: Internal Server Error\`,
2209+ 501: \`Custom message: Not Implemented\`,
2210+ 502: \`Custom message: Bad Gateway\`,
2211+ 503: \`Custom message: Service Unavailable\`,
2212+ },
2213+ });
2214+ }
2215+
2216+ }"
2217+ `;
2218+
21822219exports[`v2 should generate: ./test/generated/v2/services/HeaderService.ts 1`] = `
21832220"/* istanbul ignore file */
21842221/* tslint:disable */
@@ -3197,6 +3234,7 @@ export { CollectionFormatService } from './services/CollectionFormatService';
31973234export { ComplexService } from './services/ComplexService';
31983235export { DefaultsService } from './services/DefaultsService';
31993236export { DuplicateService } from './services/DuplicateService';
3237+ export { ErrorService } from './services/ErrorService';
32003238export { FormDataService } from './services/FormDataService';
32013239export { HeaderService } from './services/HeaderService';
32023240export { MultipartService } from './services/MultipartService';
@@ -5227,6 +5265,42 @@ export class DuplicateService {
52275265}"
52285266`;
52295267
5268+ exports[`v3 should generate: ./test/generated/v3/services/ErrorService.ts 1`] = `
5269+ "/* istanbul ignore file */
5270+ /* tslint:disable */
5271+ /* eslint-disable */
5272+ import type { CancelablePromise } from '../core/CancelablePromise';
5273+ import { request as __request } from '../core/request';
5274+ import { OpenAPI } from '../core/OpenAPI';
5275+
5276+ export class ErrorService {
5277+
5278+ /**
5279+ * @param status Status code to return
5280+ * @returns any Custom message: Successful response
5281+ * @throws ApiError
5282+ */
5283+ public static testErrorCode(
5284+ status: number,
5285+ ): CancelablePromise<any> {
5286+ return __request({
5287+ method: 'POST',
5288+ path: \`/api/v\${OpenAPI.VERSION}/error\`,
5289+ query: {
5290+ 'status': status,
5291+ },
5292+ errors: {
5293+ 500: \`Custom message: Internal Server Error\`,
5294+ 501: \`Custom message: Not Implemented\`,
5295+ 502: \`Custom message: Bad Gateway\`,
5296+ 503: \`Custom message: Service Unavailable\`,
5297+ },
5298+ });
5299+ }
5300+
5301+ }"
5302+ `;
5303+
52305304exports[`v3 should generate: ./test/generated/v3/services/FormDataService.ts 1`] = `
52315305"/* istanbul ignore file */
52325306/* tslint:disable */
0 commit comments