Polymorphic Endpoint Validation Fails in ApiDog Despite Correct OpenAPI (oneOf + Discriminator)

I have an endpoint setup with polymorphic types.

In the generated swagger.json, the polymorphism is described as follows:

"oneOf": [
  { "$ref": "#/components/schemas/SchemaA" },
  { "$ref": "#/components/schemas/SchemaB" },
  ...
],
"discriminator": {
  "propertyName": "$type",
  "mapping": {
    "identifier1": "#/components/schemas/SchemaA",
    "identifier2": "#/components/schemas/SchemaB",
    ...
  }
}

Thus:
The payload includes a $type property to identify the actual type.
Each $type maps to a specific schema reference under components/schemas.

Problem
When calling the endpoint via ApiDog (with a valid response payload including $type), the ApiDog validation fails.

The reported errors are:
“Additional properties not allowed”
“Missing required properties”

These errors occur even though:
The response payload matches the expected polymorphic type based on $type.
The Swagger/OpenAPI definition has the correct discriminator and oneOf entries.

Hi Jens , thanks for reaching out, we will look into this issue and get back to you soon.

Hello Jens, Based on the information you provided, it’s unclear whether the involved models have additionalProperties: false defined. To investigate further, could you share:

  1. The JSON schema of the model that was matched (based on $type).
  2. The actual response payload.
  3. The specific fields mentioned in the errors (“Additional properties not allowed” / “Missing required properties”).
    This will help us pinpoint the issue. Thanks!