From 3699286a2c24785ab5eafcbd2835b8aed77690df Mon Sep 17 00:00:00 2001 From: sreichi Date: Tue, 19 Nov 2019 11:13:05 +0100 Subject: [PATCH 1/6] FIXES #4539 replace line comment with block comment eslint requires you to use a block comment for ignoring whole files. --- .../src/main/resources/typescript-fetch/models.mustache | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/models.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/models.mustache index 87d5531951a2..20135a844250 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/models.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/models.mustache @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ {{>licenseInfo}} {{#models}} {{#model}} From f2b8c350d9de48fc770ee473c6cc79094c8b8111 Mon Sep 17 00:00:00 2001 From: Stephan Reichinger Date: Tue, 19 Nov 2019 12:47:53 +0100 Subject: [PATCH 2/6] changed comment style in other templates --- .../src/main/resources/typescript-fetch/apis.mustache | 4 ++-- .../src/main/resources/typescript-fetch/runtime.mustache | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache index 8080ff02457c..5bc1efdf1607 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ {{>licenseInfo}} import * as runtime from '../runtime'; diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/runtime.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/runtime.mustache index 33ecaa1197a3..03e1f986f128 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/runtime.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/runtime.mustache @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ {{>licenseInfo}} export const BASE_PATH = "{{{basePath}}}".replace(/\/+$/, ""); From 4467457c5cf195ffacc20986ee87138d6b214e41 Mon Sep 17 00:00:00 2001 From: Stephan Reichinger Date: Tue, 19 Nov 2019 12:48:21 +0100 Subject: [PATCH 3/6] generated samples --- .../petstore/typescript-fetch/builds/default/apis/PetApi.ts | 4 ++-- .../petstore/typescript-fetch/builds/default/apis/StoreApi.ts | 4 ++-- .../petstore/typescript-fetch/builds/default/apis/UserApi.ts | 4 ++-- .../typescript-fetch/builds/default/models/Category.ts | 4 ++-- .../builds/default/models/ModelApiResponse.ts | 4 ++-- .../petstore/typescript-fetch/builds/default/models/Order.ts | 4 ++-- .../petstore/typescript-fetch/builds/default/models/Pet.ts | 4 ++-- .../petstore/typescript-fetch/builds/default/models/Tag.ts | 4 ++-- .../petstore/typescript-fetch/builds/default/models/User.ts | 4 ++-- .../petstore/typescript-fetch/builds/default/runtime.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/apis/PetApi.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/apis/StoreApi.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/apis/UserApi.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/models/Category.ts | 4 ++-- .../builds/es6-target/src/models/ModelApiResponse.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/models/Order.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/models/Pet.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/models/Tag.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/models/User.ts | 4 ++-- .../typescript-fetch/builds/es6-target/src/runtime.ts | 4 ++-- .../builds/multiple-parameters/apis/PetApi.ts | 4 ++-- .../builds/multiple-parameters/apis/StoreApi.ts | 4 ++-- .../builds/multiple-parameters/apis/UserApi.ts | 4 ++-- .../builds/multiple-parameters/models/Category.ts | 4 ++-- .../builds/multiple-parameters/models/ModelApiResponse.ts | 4 ++-- .../builds/multiple-parameters/models/Order.ts | 4 ++-- .../typescript-fetch/builds/multiple-parameters/models/Pet.ts | 4 ++-- .../typescript-fetch/builds/multiple-parameters/models/Tag.ts | 4 ++-- .../builds/multiple-parameters/models/User.ts | 4 ++-- .../typescript-fetch/builds/multiple-parameters/runtime.ts | 4 ++-- .../builds/typescript-three-plus/src/apis/PetApi.ts | 4 ++-- .../builds/typescript-three-plus/src/apis/StoreApi.ts | 4 ++-- .../builds/typescript-three-plus/src/apis/UserApi.ts | 4 ++-- .../builds/typescript-three-plus/src/models/Category.ts | 4 ++-- .../typescript-three-plus/src/models/ModelApiResponse.ts | 4 ++-- .../builds/typescript-three-plus/src/models/Order.ts | 4 ++-- .../builds/typescript-three-plus/src/models/Pet.ts | 4 ++-- .../builds/typescript-three-plus/src/models/Tag.ts | 4 ++-- .../builds/typescript-three-plus/src/models/User.ts | 4 ++-- .../builds/typescript-three-plus/src/runtime.ts | 4 ++-- .../typescript-fetch/builds/with-interfaces/apis/PetApi.ts | 4 ++-- .../typescript-fetch/builds/with-interfaces/apis/StoreApi.ts | 4 ++-- .../typescript-fetch/builds/with-interfaces/apis/UserApi.ts | 4 ++-- .../builds/with-interfaces/models/Category.ts | 4 ++-- .../builds/with-interfaces/models/ModelApiResponse.ts | 4 ++-- .../typescript-fetch/builds/with-interfaces/models/Order.ts | 4 ++-- .../typescript-fetch/builds/with-interfaces/models/Pet.ts | 4 ++-- .../typescript-fetch/builds/with-interfaces/models/Tag.ts | 4 ++-- .../typescript-fetch/builds/with-interfaces/models/User.ts | 4 ++-- .../typescript-fetch/builds/with-interfaces/runtime.ts | 4 ++-- .../builds/with-npm-version/src/apis/PetApi.ts | 4 ++-- .../builds/with-npm-version/src/apis/StoreApi.ts | 4 ++-- .../builds/with-npm-version/src/apis/UserApi.ts | 4 ++-- .../builds/with-npm-version/src/models/Category.ts | 4 ++-- .../builds/with-npm-version/src/models/ModelApiResponse.ts | 4 ++-- .../builds/with-npm-version/src/models/Order.ts | 4 ++-- .../builds/with-npm-version/src/models/Pet.ts | 4 ++-- .../builds/with-npm-version/src/models/Tag.ts | 4 ++-- .../builds/with-npm-version/src/models/User.ts | 4 ++-- .../typescript-fetch/builds/with-npm-version/src/runtime.ts | 4 ++-- 60 files changed, 120 insertions(+), 120 deletions(-) diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts index b0d3563297dd..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts index 6a05a366c1ee..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts index 48114f33057b..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/Category.ts b/samples/client/petstore/typescript-fetch/builds/default/models/Category.ts index 936e0db23894..faf9aabb9de1 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/models/Category.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/models/Category.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/ModelApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/default/models/ModelApiResponse.ts index b897a9a57237..63fa57adc033 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/models/ModelApiResponse.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/models/ModelApiResponse.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/Order.ts b/samples/client/petstore/typescript-fetch/builds/default/models/Order.ts index aae84ac329d6..104c3157f61f 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/models/Order.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/models/Order.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/Pet.ts b/samples/client/petstore/typescript-fetch/builds/default/models/Pet.ts index 2a0ca231c74a..7e084c084a98 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/models/Pet.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/models/Pet.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/Tag.ts b/samples/client/petstore/typescript-fetch/builds/default/models/Tag.ts index efe3bb708792..8ea5895e79be 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/models/Tag.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/models/Tag.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/User.ts b/samples/client/petstore/typescript-fetch/builds/default/models/User.ts index cfe1263dc651..841b50d0fa2e 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/models/User.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/models/User.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/default/runtime.ts b/samples/client/petstore/typescript-fetch/builds/default/runtime.ts index 5a21387c25a1..f6718ebc236f 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/runtime.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts index b0d3563297dd..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts index 6a05a366c1ee..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts index 48114f33057b..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Category.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Category.ts index 936e0db23894..faf9aabb9de1 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Category.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Category.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/ModelApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/ModelApiResponse.ts index b897a9a57237..63fa57adc033 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/ModelApiResponse.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/ModelApiResponse.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Order.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Order.ts index aae84ac329d6..104c3157f61f 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Order.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Order.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Pet.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Pet.ts index 2a0ca231c74a..7e084c084a98 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Pet.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Pet.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Tag.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Tag.ts index efe3bb708792..8ea5895e79be 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Tag.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/Tag.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/User.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/User.ts index cfe1263dc651..841b50d0fa2e 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/User.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/User.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/runtime.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/runtime.ts index 5a21387c25a1..f6718ebc236f 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/runtime.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts index 02971f4df7ea..7be9cd13bfd8 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts index 21bd734d4ab9..9d094207bb78 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts index aeb81e01e284..36150d523bc5 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Category.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Category.ts index 936e0db23894..faf9aabb9de1 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Category.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Category.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/ModelApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/ModelApiResponse.ts index b897a9a57237..63fa57adc033 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/ModelApiResponse.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/ModelApiResponse.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Order.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Order.ts index aae84ac329d6..104c3157f61f 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Order.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Order.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Pet.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Pet.ts index 2a0ca231c74a..7e084c084a98 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Pet.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Pet.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Tag.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Tag.ts index efe3bb708792..8ea5895e79be 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Tag.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Tag.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/User.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/User.ts index cfe1263dc651..841b50d0fa2e 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/User.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/User.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts index 5a21387c25a1..f6718ebc236f 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/PetApi.ts index b0d3563297dd..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/PetApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/StoreApi.ts index 6a05a366c1ee..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/StoreApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/UserApi.ts index 48114f33057b..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/apis/UserApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Category.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Category.ts index 936e0db23894..faf9aabb9de1 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Category.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Category.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/ModelApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/ModelApiResponse.ts index b897a9a57237..63fa57adc033 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/ModelApiResponse.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/ModelApiResponse.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Order.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Order.ts index aae84ac329d6..104c3157f61f 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Order.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Order.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Pet.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Pet.ts index 2a0ca231c74a..7e084c084a98 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Pet.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Pet.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Tag.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Tag.ts index efe3bb708792..8ea5895e79be 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Tag.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/Tag.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/User.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/User.ts index cfe1263dc651..841b50d0fa2e 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/User.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/models/User.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/runtime.ts b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/runtime.ts index 20e067182478..a21e1e1ed99f 100644 --- a/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/typescript-three-plus/src/runtime.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts index b0d3563297dd..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts index 6a05a366c1ee..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts index 48114f33057b..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Category.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Category.ts index 936e0db23894..faf9aabb9de1 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Category.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Category.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/ModelApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/ModelApiResponse.ts index b897a9a57237..63fa57adc033 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/ModelApiResponse.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/ModelApiResponse.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Order.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Order.ts index aae84ac329d6..104c3157f61f 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Order.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Order.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Pet.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Pet.ts index 2a0ca231c74a..7e084c084a98 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Pet.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Pet.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Tag.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Tag.ts index efe3bb708792..8ea5895e79be 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Tag.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/Tag.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/User.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/User.ts index cfe1263dc651..841b50d0fa2e 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/User.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/User.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/runtime.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/runtime.ts index 5a21387c25a1..f6718ebc236f 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/runtime.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts index b0d3563297dd..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts index 6a05a366c1ee..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts index 48114f33057b..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Category.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Category.ts index 936e0db23894..faf9aabb9de1 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Category.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Category.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/ModelApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/ModelApiResponse.ts index b897a9a57237..63fa57adc033 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/ModelApiResponse.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/ModelApiResponse.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Order.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Order.ts index aae84ac329d6..104c3157f61f 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Order.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Order.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Pet.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Pet.ts index 2a0ca231c74a..7e084c084a98 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Pet.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Pet.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Tag.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Tag.ts index efe3bb708792..8ea5895e79be 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Tag.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/Tag.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/User.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/User.ts index cfe1263dc651..841b50d0fa2e 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/User.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/User.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/runtime.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/runtime.ts index 5a21387c25a1..f6718ebc236f 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/runtime.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. From 98af3dfcd773882f5e02af5d6f929a6a91bd62c0 Mon Sep 17 00:00:00 2001 From: Stephan Reichinger Date: Tue, 19 Nov 2019 12:50:11 +0100 Subject: [PATCH 4/6] generated openapi3 samples --- .../builds/default/apis/PetApi.ts | 20 ++++++------ .../builds/default/apis/StoreApi.ts | 8 ++--- .../builds/default/apis/UserApi.ts | 32 +++++++++---------- .../builds/default/models/index.ts | 2 ++ .../builds/es6-target/src/apis/PetApi.ts | 20 ++++++------ .../builds/es6-target/src/apis/StoreApi.ts | 8 ++--- .../builds/es6-target/src/apis/UserApi.ts | 32 +++++++++---------- .../builds/es6-target/src/models/index.ts | 2 ++ .../builds/with-interfaces/apis/PetApi.ts | 20 ++++++------ .../builds/with-interfaces/apis/StoreApi.ts | 8 ++--- .../builds/with-interfaces/apis/UserApi.ts | 32 +++++++++---------- .../builds/with-interfaces/models/index.ts | 2 ++ .../with-npm-version/src/apis/PetApi.ts | 20 ++++++------ .../with-npm-version/src/apis/StoreApi.ts | 8 ++--- .../with-npm-version/src/apis/UserApi.ts | 32 +++++++++---------- .../with-npm-version/src/models/index.ts | 2 ++ 16 files changed, 128 insertions(+), 120 deletions(-) diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts index 9f3378899328..f3ec75350c21 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts @@ -24,7 +24,7 @@ import { } from '../models'; export interface AddPetRequest { - body: Pet; + pet: Pet; } export interface DeletePetRequest { @@ -45,7 +45,7 @@ export interface GetPetByIdRequest { } export interface UpdatePetRequest { - body: Pet; + pet: Pet; } export interface UpdatePetWithFormRequest { @@ -69,8 +69,8 @@ export class PetApi extends runtime.BaseAPI { * Add a new pet to the store */ async addPetRaw(requestParameters: AddPetRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); + if (requestParameters.pet === null || requestParameters.pet === undefined) { + throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling addPet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -93,7 +93,7 @@ export class PetApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.body), + body: PetToJSON(requestParameters.pet), }); return new runtime.VoidApiResponse(response); @@ -168,7 +168,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -213,7 +213,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -278,8 +278,8 @@ export class PetApi extends runtime.BaseAPI { * Update an existing pet */ async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); + if (requestParameters.pet === null || requestParameters.pet === undefined) { + throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling updatePet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -302,7 +302,7 @@ export class PetApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.body), + body: PetToJSON(requestParameters.pet), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts index 4d281723815a..395731cfee8b 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts @@ -29,7 +29,7 @@ export interface GetOrderByIdRequest { } export interface PlaceOrderRequest { - body: Order; + order: Order; } /** @@ -136,8 +136,8 @@ export class StoreApi extends runtime.BaseAPI { * Place an order for a pet */ async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); + if (requestParameters.order === null || requestParameters.order === undefined) { + throw new runtime.RequiredError('order','Required parameter requestParameters.order was null or undefined when calling placeOrder.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -151,7 +151,7 @@ export class StoreApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: OrderToJSON(requestParameters.body), + body: OrderToJSON(requestParameters.order), }); return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts index e5441f0aaf17..408c6373bb8c 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts @@ -21,15 +21,15 @@ import { } from '../models'; export interface CreateUserRequest { - body: User; + user: User; } export interface CreateUsersWithArrayInputRequest { - body: Array; + user: Array; } export interface CreateUsersWithListInputRequest { - body: Array; + user: Array; } export interface DeleteUserRequest { @@ -47,7 +47,7 @@ export interface LoginUserRequest { export interface UpdateUserRequest { username: string; - body: User; + user: User; } /** @@ -60,8 +60,8 @@ export class UserApi extends runtime.BaseAPI { * Create user */ async createUserRaw(requestParameters: CreateUserRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -75,7 +75,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.body), + body: UserToJSON(requestParameters.user), }); return new runtime.VoidApiResponse(response); @@ -93,8 +93,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithArrayInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -108,7 +108,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.body.map(UserToJSON), + body: requestParameters.user.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -125,8 +125,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithListInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -140,7 +140,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.body.map(UserToJSON), + body: requestParameters.user.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -290,8 +290,8 @@ export class UserApi extends runtime.BaseAPI { throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); } - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling updateUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -305,7 +305,7 @@ export class UserApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.body), + body: UserToJSON(requestParameters.user), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/index.ts b/samples/client/petstore/typescript-fetch/builds/default/models/index.ts index b07ddc8446a0..5eefa748f29f 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/models/index.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/models/index.ts @@ -1,4 +1,6 @@ export * from './Category'; +export * from './InlineObject'; +export * from './InlineObject1'; export * from './ModelApiResponse'; export * from './Order'; export * from './Pet'; diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts index 9f3378899328..f3ec75350c21 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts @@ -24,7 +24,7 @@ import { } from '../models'; export interface AddPetRequest { - body: Pet; + pet: Pet; } export interface DeletePetRequest { @@ -45,7 +45,7 @@ export interface GetPetByIdRequest { } export interface UpdatePetRequest { - body: Pet; + pet: Pet; } export interface UpdatePetWithFormRequest { @@ -69,8 +69,8 @@ export class PetApi extends runtime.BaseAPI { * Add a new pet to the store */ async addPetRaw(requestParameters: AddPetRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); + if (requestParameters.pet === null || requestParameters.pet === undefined) { + throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling addPet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -93,7 +93,7 @@ export class PetApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.body), + body: PetToJSON(requestParameters.pet), }); return new runtime.VoidApiResponse(response); @@ -168,7 +168,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -213,7 +213,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -278,8 +278,8 @@ export class PetApi extends runtime.BaseAPI { * Update an existing pet */ async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); + if (requestParameters.pet === null || requestParameters.pet === undefined) { + throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling updatePet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -302,7 +302,7 @@ export class PetApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.body), + body: PetToJSON(requestParameters.pet), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts index 4d281723815a..395731cfee8b 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts @@ -29,7 +29,7 @@ export interface GetOrderByIdRequest { } export interface PlaceOrderRequest { - body: Order; + order: Order; } /** @@ -136,8 +136,8 @@ export class StoreApi extends runtime.BaseAPI { * Place an order for a pet */ async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); + if (requestParameters.order === null || requestParameters.order === undefined) { + throw new runtime.RequiredError('order','Required parameter requestParameters.order was null or undefined when calling placeOrder.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -151,7 +151,7 @@ export class StoreApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: OrderToJSON(requestParameters.body), + body: OrderToJSON(requestParameters.order), }); return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts index e5441f0aaf17..408c6373bb8c 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts @@ -21,15 +21,15 @@ import { } from '../models'; export interface CreateUserRequest { - body: User; + user: User; } export interface CreateUsersWithArrayInputRequest { - body: Array; + user: Array; } export interface CreateUsersWithListInputRequest { - body: Array; + user: Array; } export interface DeleteUserRequest { @@ -47,7 +47,7 @@ export interface LoginUserRequest { export interface UpdateUserRequest { username: string; - body: User; + user: User; } /** @@ -60,8 +60,8 @@ export class UserApi extends runtime.BaseAPI { * Create user */ async createUserRaw(requestParameters: CreateUserRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -75,7 +75,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.body), + body: UserToJSON(requestParameters.user), }); return new runtime.VoidApiResponse(response); @@ -93,8 +93,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithArrayInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -108,7 +108,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.body.map(UserToJSON), + body: requestParameters.user.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -125,8 +125,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithListInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -140,7 +140,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.body.map(UserToJSON), + body: requestParameters.user.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -290,8 +290,8 @@ export class UserApi extends runtime.BaseAPI { throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); } - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling updateUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -305,7 +305,7 @@ export class UserApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.body), + body: UserToJSON(requestParameters.user), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/index.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/index.ts index b07ddc8446a0..5eefa748f29f 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/index.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/index.ts @@ -1,4 +1,6 @@ export * from './Category'; +export * from './InlineObject'; +export * from './InlineObject1'; export * from './ModelApiResponse'; export * from './Order'; export * from './Pet'; diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts index 9f3378899328..f3ec75350c21 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts @@ -24,7 +24,7 @@ import { } from '../models'; export interface AddPetRequest { - body: Pet; + pet: Pet; } export interface DeletePetRequest { @@ -45,7 +45,7 @@ export interface GetPetByIdRequest { } export interface UpdatePetRequest { - body: Pet; + pet: Pet; } export interface UpdatePetWithFormRequest { @@ -69,8 +69,8 @@ export class PetApi extends runtime.BaseAPI { * Add a new pet to the store */ async addPetRaw(requestParameters: AddPetRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); + if (requestParameters.pet === null || requestParameters.pet === undefined) { + throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling addPet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -93,7 +93,7 @@ export class PetApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.body), + body: PetToJSON(requestParameters.pet), }); return new runtime.VoidApiResponse(response); @@ -168,7 +168,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -213,7 +213,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -278,8 +278,8 @@ export class PetApi extends runtime.BaseAPI { * Update an existing pet */ async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); + if (requestParameters.pet === null || requestParameters.pet === undefined) { + throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling updatePet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -302,7 +302,7 @@ export class PetApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.body), + body: PetToJSON(requestParameters.pet), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts index 4d281723815a..395731cfee8b 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts @@ -29,7 +29,7 @@ export interface GetOrderByIdRequest { } export interface PlaceOrderRequest { - body: Order; + order: Order; } /** @@ -136,8 +136,8 @@ export class StoreApi extends runtime.BaseAPI { * Place an order for a pet */ async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); + if (requestParameters.order === null || requestParameters.order === undefined) { + throw new runtime.RequiredError('order','Required parameter requestParameters.order was null or undefined when calling placeOrder.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -151,7 +151,7 @@ export class StoreApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: OrderToJSON(requestParameters.body), + body: OrderToJSON(requestParameters.order), }); return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts index e5441f0aaf17..408c6373bb8c 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts @@ -21,15 +21,15 @@ import { } from '../models'; export interface CreateUserRequest { - body: User; + user: User; } export interface CreateUsersWithArrayInputRequest { - body: Array; + user: Array; } export interface CreateUsersWithListInputRequest { - body: Array; + user: Array; } export interface DeleteUserRequest { @@ -47,7 +47,7 @@ export interface LoginUserRequest { export interface UpdateUserRequest { username: string; - body: User; + user: User; } /** @@ -60,8 +60,8 @@ export class UserApi extends runtime.BaseAPI { * Create user */ async createUserRaw(requestParameters: CreateUserRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -75,7 +75,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.body), + body: UserToJSON(requestParameters.user), }); return new runtime.VoidApiResponse(response); @@ -93,8 +93,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithArrayInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -108,7 +108,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.body.map(UserToJSON), + body: requestParameters.user.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -125,8 +125,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithListInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -140,7 +140,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.body.map(UserToJSON), + body: requestParameters.user.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -290,8 +290,8 @@ export class UserApi extends runtime.BaseAPI { throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); } - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling updateUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -305,7 +305,7 @@ export class UserApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.body), + body: UserToJSON(requestParameters.user), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/index.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/index.ts index b07ddc8446a0..5eefa748f29f 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/index.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/index.ts @@ -1,4 +1,6 @@ export * from './Category'; +export * from './InlineObject'; +export * from './InlineObject1'; export * from './ModelApiResponse'; export * from './Order'; export * from './Pet'; diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts index 9f3378899328..f3ec75350c21 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts @@ -24,7 +24,7 @@ import { } from '../models'; export interface AddPetRequest { - body: Pet; + pet: Pet; } export interface DeletePetRequest { @@ -45,7 +45,7 @@ export interface GetPetByIdRequest { } export interface UpdatePetRequest { - body: Pet; + pet: Pet; } export interface UpdatePetWithFormRequest { @@ -69,8 +69,8 @@ export class PetApi extends runtime.BaseAPI { * Add a new pet to the store */ async addPetRaw(requestParameters: AddPetRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); + if (requestParameters.pet === null || requestParameters.pet === undefined) { + throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling addPet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -93,7 +93,7 @@ export class PetApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.body), + body: PetToJSON(requestParameters.pet), }); return new runtime.VoidApiResponse(response); @@ -168,7 +168,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -213,7 +213,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -278,8 +278,8 @@ export class PetApi extends runtime.BaseAPI { * Update an existing pet */ async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); + if (requestParameters.pet === null || requestParameters.pet === undefined) { + throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling updatePet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -302,7 +302,7 @@ export class PetApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.body), + body: PetToJSON(requestParameters.pet), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts index 4d281723815a..395731cfee8b 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts @@ -29,7 +29,7 @@ export interface GetOrderByIdRequest { } export interface PlaceOrderRequest { - body: Order; + order: Order; } /** @@ -136,8 +136,8 @@ export class StoreApi extends runtime.BaseAPI { * Place an order for a pet */ async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); + if (requestParameters.order === null || requestParameters.order === undefined) { + throw new runtime.RequiredError('order','Required parameter requestParameters.order was null or undefined when calling placeOrder.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -151,7 +151,7 @@ export class StoreApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: OrderToJSON(requestParameters.body), + body: OrderToJSON(requestParameters.order), }); return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts index e5441f0aaf17..408c6373bb8c 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts @@ -21,15 +21,15 @@ import { } from '../models'; export interface CreateUserRequest { - body: User; + user: User; } export interface CreateUsersWithArrayInputRequest { - body: Array; + user: Array; } export interface CreateUsersWithListInputRequest { - body: Array; + user: Array; } export interface DeleteUserRequest { @@ -47,7 +47,7 @@ export interface LoginUserRequest { export interface UpdateUserRequest { username: string; - body: User; + user: User; } /** @@ -60,8 +60,8 @@ export class UserApi extends runtime.BaseAPI { * Create user */ async createUserRaw(requestParameters: CreateUserRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -75,7 +75,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.body), + body: UserToJSON(requestParameters.user), }); return new runtime.VoidApiResponse(response); @@ -93,8 +93,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithArrayInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -108,7 +108,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.body.map(UserToJSON), + body: requestParameters.user.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -125,8 +125,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithListInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -140,7 +140,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.body.map(UserToJSON), + body: requestParameters.user.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -290,8 +290,8 @@ export class UserApi extends runtime.BaseAPI { throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); } - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); + if (requestParameters.user === null || requestParameters.user === undefined) { + throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling updateUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -305,7 +305,7 @@ export class UserApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.body), + body: UserToJSON(requestParameters.user), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/index.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/index.ts index b07ddc8446a0..5eefa748f29f 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/index.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/index.ts @@ -1,4 +1,6 @@ export * from './Category'; +export * from './InlineObject'; +export * from './InlineObject1'; export * from './ModelApiResponse'; export * from './Order'; export * from './Pet'; From cb85a2e513f261bc1253441ef654062bc8fcd6f8 Mon Sep 17 00:00:00 2001 From: Stephan Reichinger Date: Thu, 21 Nov 2019 08:16:43 +0100 Subject: [PATCH 5/6] Revert "generated openapi3 samples" This reverts commit 98af3dfc --- .../builds/default/apis/PetApi.ts | 20 ++++++------ .../builds/default/apis/StoreApi.ts | 8 ++--- .../builds/default/apis/UserApi.ts | 32 +++++++++---------- .../builds/default/models/index.ts | 2 -- .../builds/es6-target/src/apis/PetApi.ts | 20 ++++++------ .../builds/es6-target/src/apis/StoreApi.ts | 8 ++--- .../builds/es6-target/src/apis/UserApi.ts | 32 +++++++++---------- .../builds/es6-target/src/models/index.ts | 2 -- .../builds/with-interfaces/apis/PetApi.ts | 20 ++++++------ .../builds/with-interfaces/apis/StoreApi.ts | 8 ++--- .../builds/with-interfaces/apis/UserApi.ts | 32 +++++++++---------- .../builds/with-interfaces/models/index.ts | 2 -- .../with-npm-version/src/apis/PetApi.ts | 20 ++++++------ .../with-npm-version/src/apis/StoreApi.ts | 8 ++--- .../with-npm-version/src/apis/UserApi.ts | 32 +++++++++---------- .../with-npm-version/src/models/index.ts | 2 -- 16 files changed, 120 insertions(+), 128 deletions(-) diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts index f3ec75350c21..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts @@ -24,7 +24,7 @@ import { } from '../models'; export interface AddPetRequest { - pet: Pet; + body: Pet; } export interface DeletePetRequest { @@ -45,7 +45,7 @@ export interface GetPetByIdRequest { } export interface UpdatePetRequest { - pet: Pet; + body: Pet; } export interface UpdatePetWithFormRequest { @@ -69,8 +69,8 @@ export class PetApi extends runtime.BaseAPI { * Add a new pet to the store */ async addPetRaw(requestParameters: AddPetRequest): Promise> { - if (requestParameters.pet === null || requestParameters.pet === undefined) { - throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling addPet.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -93,7 +93,7 @@ export class PetApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.pet), + body: PetToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); @@ -168,7 +168,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -213,7 +213,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -278,8 +278,8 @@ export class PetApi extends runtime.BaseAPI { * Update an existing pet */ async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { - if (requestParameters.pet === null || requestParameters.pet === undefined) { - throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling updatePet.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -302,7 +302,7 @@ export class PetApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.pet), + body: PetToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts index 395731cfee8b..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts @@ -29,7 +29,7 @@ export interface GetOrderByIdRequest { } export interface PlaceOrderRequest { - order: Order; + body: Order; } /** @@ -136,8 +136,8 @@ export class StoreApi extends runtime.BaseAPI { * Place an order for a pet */ async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { - if (requestParameters.order === null || requestParameters.order === undefined) { - throw new runtime.RequiredError('order','Required parameter requestParameters.order was null or undefined when calling placeOrder.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -151,7 +151,7 @@ export class StoreApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: OrderToJSON(requestParameters.order), + body: OrderToJSON(requestParameters.body), }); return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts index 408c6373bb8c..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts @@ -21,15 +21,15 @@ import { } from '../models'; export interface CreateUserRequest { - user: User; + body: User; } export interface CreateUsersWithArrayInputRequest { - user: Array; + body: Array; } export interface CreateUsersWithListInputRequest { - user: Array; + body: Array; } export interface DeleteUserRequest { @@ -47,7 +47,7 @@ export interface LoginUserRequest { export interface UpdateUserRequest { username: string; - user: User; + body: User; } /** @@ -60,8 +60,8 @@ export class UserApi extends runtime.BaseAPI { * Create user */ async createUserRaw(requestParameters: CreateUserRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUser.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -75,7 +75,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.user), + body: UserToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); @@ -93,8 +93,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithArrayInput.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -108,7 +108,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.user.map(UserToJSON), + body: requestParameters.body.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -125,8 +125,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithListInput.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -140,7 +140,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.user.map(UserToJSON), + body: requestParameters.body.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -290,8 +290,8 @@ export class UserApi extends runtime.BaseAPI { throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); } - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling updateUser.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -305,7 +305,7 @@ export class UserApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.user), + body: UserToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/index.ts b/samples/client/petstore/typescript-fetch/builds/default/models/index.ts index 5eefa748f29f..b07ddc8446a0 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/models/index.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/models/index.ts @@ -1,6 +1,4 @@ export * from './Category'; -export * from './InlineObject'; -export * from './InlineObject1'; export * from './ModelApiResponse'; export * from './Order'; export * from './Pet'; diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts index f3ec75350c21..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts @@ -24,7 +24,7 @@ import { } from '../models'; export interface AddPetRequest { - pet: Pet; + body: Pet; } export interface DeletePetRequest { @@ -45,7 +45,7 @@ export interface GetPetByIdRequest { } export interface UpdatePetRequest { - pet: Pet; + body: Pet; } export interface UpdatePetWithFormRequest { @@ -69,8 +69,8 @@ export class PetApi extends runtime.BaseAPI { * Add a new pet to the store */ async addPetRaw(requestParameters: AddPetRequest): Promise> { - if (requestParameters.pet === null || requestParameters.pet === undefined) { - throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling addPet.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -93,7 +93,7 @@ export class PetApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.pet), + body: PetToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); @@ -168,7 +168,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -213,7 +213,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -278,8 +278,8 @@ export class PetApi extends runtime.BaseAPI { * Update an existing pet */ async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { - if (requestParameters.pet === null || requestParameters.pet === undefined) { - throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling updatePet.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -302,7 +302,7 @@ export class PetApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.pet), + body: PetToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts index 395731cfee8b..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts @@ -29,7 +29,7 @@ export interface GetOrderByIdRequest { } export interface PlaceOrderRequest { - order: Order; + body: Order; } /** @@ -136,8 +136,8 @@ export class StoreApi extends runtime.BaseAPI { * Place an order for a pet */ async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { - if (requestParameters.order === null || requestParameters.order === undefined) { - throw new runtime.RequiredError('order','Required parameter requestParameters.order was null or undefined when calling placeOrder.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -151,7 +151,7 @@ export class StoreApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: OrderToJSON(requestParameters.order), + body: OrderToJSON(requestParameters.body), }); return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts index 408c6373bb8c..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts @@ -21,15 +21,15 @@ import { } from '../models'; export interface CreateUserRequest { - user: User; + body: User; } export interface CreateUsersWithArrayInputRequest { - user: Array; + body: Array; } export interface CreateUsersWithListInputRequest { - user: Array; + body: Array; } export interface DeleteUserRequest { @@ -47,7 +47,7 @@ export interface LoginUserRequest { export interface UpdateUserRequest { username: string; - user: User; + body: User; } /** @@ -60,8 +60,8 @@ export class UserApi extends runtime.BaseAPI { * Create user */ async createUserRaw(requestParameters: CreateUserRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUser.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -75,7 +75,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.user), + body: UserToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); @@ -93,8 +93,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithArrayInput.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -108,7 +108,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.user.map(UserToJSON), + body: requestParameters.body.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -125,8 +125,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithListInput.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -140,7 +140,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.user.map(UserToJSON), + body: requestParameters.body.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -290,8 +290,8 @@ export class UserApi extends runtime.BaseAPI { throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); } - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling updateUser.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -305,7 +305,7 @@ export class UserApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.user), + body: UserToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/index.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/index.ts index 5eefa748f29f..b07ddc8446a0 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/index.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/models/index.ts @@ -1,6 +1,4 @@ export * from './Category'; -export * from './InlineObject'; -export * from './InlineObject1'; export * from './ModelApiResponse'; export * from './Order'; export * from './Pet'; diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts index f3ec75350c21..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts @@ -24,7 +24,7 @@ import { } from '../models'; export interface AddPetRequest { - pet: Pet; + body: Pet; } export interface DeletePetRequest { @@ -45,7 +45,7 @@ export interface GetPetByIdRequest { } export interface UpdatePetRequest { - pet: Pet; + body: Pet; } export interface UpdatePetWithFormRequest { @@ -69,8 +69,8 @@ export class PetApi extends runtime.BaseAPI { * Add a new pet to the store */ async addPetRaw(requestParameters: AddPetRequest): Promise> { - if (requestParameters.pet === null || requestParameters.pet === undefined) { - throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling addPet.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -93,7 +93,7 @@ export class PetApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.pet), + body: PetToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); @@ -168,7 +168,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -213,7 +213,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -278,8 +278,8 @@ export class PetApi extends runtime.BaseAPI { * Update an existing pet */ async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { - if (requestParameters.pet === null || requestParameters.pet === undefined) { - throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling updatePet.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -302,7 +302,7 @@ export class PetApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.pet), + body: PetToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts index 395731cfee8b..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts @@ -29,7 +29,7 @@ export interface GetOrderByIdRequest { } export interface PlaceOrderRequest { - order: Order; + body: Order; } /** @@ -136,8 +136,8 @@ export class StoreApi extends runtime.BaseAPI { * Place an order for a pet */ async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { - if (requestParameters.order === null || requestParameters.order === undefined) { - throw new runtime.RequiredError('order','Required parameter requestParameters.order was null or undefined when calling placeOrder.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -151,7 +151,7 @@ export class StoreApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: OrderToJSON(requestParameters.order), + body: OrderToJSON(requestParameters.body), }); return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts index 408c6373bb8c..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts @@ -21,15 +21,15 @@ import { } from '../models'; export interface CreateUserRequest { - user: User; + body: User; } export interface CreateUsersWithArrayInputRequest { - user: Array; + body: Array; } export interface CreateUsersWithListInputRequest { - user: Array; + body: Array; } export interface DeleteUserRequest { @@ -47,7 +47,7 @@ export interface LoginUserRequest { export interface UpdateUserRequest { username: string; - user: User; + body: User; } /** @@ -60,8 +60,8 @@ export class UserApi extends runtime.BaseAPI { * Create user */ async createUserRaw(requestParameters: CreateUserRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUser.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -75,7 +75,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.user), + body: UserToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); @@ -93,8 +93,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithArrayInput.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -108,7 +108,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.user.map(UserToJSON), + body: requestParameters.body.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -125,8 +125,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithListInput.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -140,7 +140,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.user.map(UserToJSON), + body: requestParameters.body.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -290,8 +290,8 @@ export class UserApi extends runtime.BaseAPI { throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); } - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling updateUser.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -305,7 +305,7 @@ export class UserApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.user), + body: UserToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/index.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/index.ts index 5eefa748f29f..b07ddc8446a0 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/index.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/index.ts @@ -1,6 +1,4 @@ export * from './Category'; -export * from './InlineObject'; -export * from './InlineObject1'; export * from './ModelApiResponse'; export * from './Order'; export * from './Pet'; diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts index f3ec75350c21..9f3378899328 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts @@ -24,7 +24,7 @@ import { } from '../models'; export interface AddPetRequest { - pet: Pet; + body: Pet; } export interface DeletePetRequest { @@ -45,7 +45,7 @@ export interface GetPetByIdRequest { } export interface UpdatePetRequest { - pet: Pet; + body: Pet; } export interface UpdatePetWithFormRequest { @@ -69,8 +69,8 @@ export class PetApi extends runtime.BaseAPI { * Add a new pet to the store */ async addPetRaw(requestParameters: AddPetRequest): Promise> { - if (requestParameters.pet === null || requestParameters.pet === undefined) { - throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling addPet.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -93,7 +93,7 @@ export class PetApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.pet), + body: PetToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); @@ -168,7 +168,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -213,7 +213,7 @@ export class PetApi extends runtime.BaseAPI { if (this.configuration && this.configuration.accessToken) { // oauth required if (typeof this.configuration.accessToken === 'function') { - headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["read:pets"]); + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); } else { headerParameters["Authorization"] = this.configuration.accessToken; } @@ -278,8 +278,8 @@ export class PetApi extends runtime.BaseAPI { * Update an existing pet */ async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { - if (requestParameters.pet === null || requestParameters.pet === undefined) { - throw new runtime.RequiredError('pet','Required parameter requestParameters.pet was null or undefined when calling updatePet.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -302,7 +302,7 @@ export class PetApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: PetToJSON(requestParameters.pet), + body: PetToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts index 395731cfee8b..4d281723815a 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts @@ -29,7 +29,7 @@ export interface GetOrderByIdRequest { } export interface PlaceOrderRequest { - order: Order; + body: Order; } /** @@ -136,8 +136,8 @@ export class StoreApi extends runtime.BaseAPI { * Place an order for a pet */ async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { - if (requestParameters.order === null || requestParameters.order === undefined) { - throw new runtime.RequiredError('order','Required parameter requestParameters.order was null or undefined when calling placeOrder.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -151,7 +151,7 @@ export class StoreApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: OrderToJSON(requestParameters.order), + body: OrderToJSON(requestParameters.body), }); return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts index 408c6373bb8c..e5441f0aaf17 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts @@ -21,15 +21,15 @@ import { } from '../models'; export interface CreateUserRequest { - user: User; + body: User; } export interface CreateUsersWithArrayInputRequest { - user: Array; + body: Array; } export interface CreateUsersWithListInputRequest { - user: Array; + body: Array; } export interface DeleteUserRequest { @@ -47,7 +47,7 @@ export interface LoginUserRequest { export interface UpdateUserRequest { username: string; - user: User; + body: User; } /** @@ -60,8 +60,8 @@ export class UserApi extends runtime.BaseAPI { * Create user */ async createUserRaw(requestParameters: CreateUserRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUser.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -75,7 +75,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.user), + body: UserToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); @@ -93,8 +93,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithArrayInput.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -108,7 +108,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.user.map(UserToJSON), + body: requestParameters.body.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -125,8 +125,8 @@ export class UserApi extends runtime.BaseAPI { * Creates list of users with given input array */ async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling createUsersWithListInput.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -140,7 +140,7 @@ export class UserApi extends runtime.BaseAPI { method: 'POST', headers: headerParameters, query: queryParameters, - body: requestParameters.user.map(UserToJSON), + body: requestParameters.body.map(UserToJSON), }); return new runtime.VoidApiResponse(response); @@ -290,8 +290,8 @@ export class UserApi extends runtime.BaseAPI { throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); } - if (requestParameters.user === null || requestParameters.user === undefined) { - throw new runtime.RequiredError('user','Required parameter requestParameters.user was null or undefined when calling updateUser.'); + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); } const queryParameters: runtime.HTTPQuery = {}; @@ -305,7 +305,7 @@ export class UserApi extends runtime.BaseAPI { method: 'PUT', headers: headerParameters, query: queryParameters, - body: UserToJSON(requestParameters.user), + body: UserToJSON(requestParameters.body), }); return new runtime.VoidApiResponse(response); diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/index.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/index.ts index 5eefa748f29f..b07ddc8446a0 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/index.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/models/index.ts @@ -1,6 +1,4 @@ export * from './Category'; -export * from './InlineObject'; -export * from './InlineObject1'; export * from './ModelApiResponse'; export * from './Order'; export * from './Pet'; From 8b450ddca704adc10238a28543f3b8d88cb9d129 Mon Sep 17 00:00:00 2001 From: Stephan Reichinger Date: Thu, 21 Nov 2019 10:08:44 +0100 Subject: [PATCH 6/6] generated missing samples --- .../builds/prefix-parameter-interfaces/src/apis/PetApi.ts | 4 ++-- .../builds/prefix-parameter-interfaces/src/apis/StoreApi.ts | 4 ++-- .../builds/prefix-parameter-interfaces/src/apis/UserApi.ts | 4 ++-- .../builds/prefix-parameter-interfaces/src/models/Category.ts | 4 ++-- .../src/models/ModelApiResponse.ts | 4 ++-- .../builds/prefix-parameter-interfaces/src/models/Order.ts | 4 ++-- .../builds/prefix-parameter-interfaces/src/models/Pet.ts | 4 ++-- .../builds/prefix-parameter-interfaces/src/models/Tag.ts | 4 ++-- .../builds/prefix-parameter-interfaces/src/models/User.ts | 4 ++-- .../builds/prefix-parameter-interfaces/src/runtime.ts | 4 ++-- 10 files changed, 20 insertions(+), 20 deletions(-) diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/PetApi.ts index 5c45e3bb333e..17731c8760e2 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/PetApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/StoreApi.ts index e119ddf0a38a..7f38fd436aea 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/StoreApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/UserApi.ts index 96b0eb672d82..1d97220cb00f 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/UserApi.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Category.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Category.ts index 936e0db23894..faf9aabb9de1 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Category.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Category.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/ModelApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/ModelApiResponse.ts index b897a9a57237..63fa57adc033 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/ModelApiResponse.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/ModelApiResponse.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Order.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Order.ts index aae84ac329d6..104c3157f61f 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Order.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Order.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Pet.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Pet.ts index 2a0ca231c74a..7e084c084a98 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Pet.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Pet.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Tag.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Tag.ts index efe3bb708792..8ea5895e79be 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Tag.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/Tag.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/User.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/User.ts index cfe1263dc651..841b50d0fa2e 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/User.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/models/User.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/runtime.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/runtime.ts index 5a21387c25a1..f6718ebc236f 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/runtime.ts @@ -1,5 +1,5 @@ -// tslint:disable -// eslint-disable +/* tslint:disable */ +/* eslint-disable */ /** * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.