request-property-discriminator-mapping-changed
Request property discriminator mapping changed.
Not breaking (level: info)
oasdiff records this in the changelog but does not fail CI by default. Requests that were valid under the old contract are still valid, so existing clients are not affected.
What this check detects
A `discriminator` tells tooling which subschema of a `oneOf` or `anyOf` a payload belongs to, by looking at one property. Its `mapping` connects each value of that property to a schema.
Changing a mapping entry repoints a value at a different schema. oasdiff reports it as informational because the discriminator is a resolution hint, not the validation itself: what a request must look like is still decided by the `oneOf` / `anyOf` branches. It is worth reviewing though, since generated clients use the mapping to choose a type, so a remap can change which model a payload deserializes into.
Example
A request with "petType": "cat" now resolves to Dog. The oneOf branches still decide what validates, but a generated client picks a different model.
Change its severity
oasdiff reports request-property-discriminator-mapping-changed as informational, so it does not fail CI. To treat it as a warning or an error under your own compatibility policy, or to turn it off, set its level in a severity-levels file:
Put one rule per line; the level can be err, warn, or info, or none to disable the check entirely:
# severity.txt
request-property-discriminator-mapping-changed errThen pass it to oasdiff:
oasdiff changelog base.yaml revision.yaml --severity-levels severity.txt