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 662ec63b5b8..d1751f7135d 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache @@ -181,7 +181,7 @@ export class {{classname}} extends runtime.BaseAPI { {{#hasBodyParam}} {{#bodyParam}} {{#isContainer}} - body: requestParameters.{{paramName}}.map({{#items}}{{datatype}}{{/items}}ToJSON), + body: requestParameters.{{paramName}}{{#isListContainer}}{{#items}}{{^isPrimitiveType}}.map({{datatype}}ToJSON){{/isPrimitiveType}}{{/items}}{{/isListContainer}}, {{/isContainer}} {{^isContainer}} {{^isPrimitiveType}}