[DefaultCodegen] Possible missing model for request body for OAS 3.0
Created by: Articus
Description
Consider the following spec:
openapi: 3.0.0
info:
title: Test
version: 1.0.0
servers:
- url: 'http://test/'
components:
requestBodies:
TestBodyInline:
content:
application/json:
schema:
type: object
properties:
test:
type: string
paths:
/test/ref/inline:
post:
summary: Test
requestBody:
$ref: '#/components/requestBodies/TestBodyInline'
responses:
'200':
description: Success
content:
application/json:
schema:
type: string
For this spec CodegenOperation::bodyParam.dataType
equals to "object" and no codegen model is generated for request body. A bit lost why this is happenning because 3 other possible scenarios (inline body + inline schema, inline body + ref schema, ref body + ref schema) work perfectly well.