-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Per readme.com support, they don't support type: null to clear field values. Instead, they require type: [null, "string"]
This ticket is a feature request to support this compound type in MergePatch where parameters can be cleared.
Example:
interfaces:
Target:
...
members:
payload_map:
required: false
initializable: true
mutable: true
schema:
type: object
additionalProperties:
type: string
Current output:
components:
schemas:
...
TargetMergePatch:
type: object
properties:
payload_map:
oneOf:
- type: object
additionalProperties:
type: string
description: Pass this value to overwrite the existing value.
title: Overwrite
- type: "null" # unsupported by readme.com
description: "Pass `null` to clear this field's existing value."
title: Clear
additionalProperties: false
Desired output:
components:
schemas:
...
TargetMergePatch:
type: object
properties:
payload_map:
oneOf:
- type: object
additionalProperties:
type: string
description: Pass this value to overwrite the existing value.
title: Overwrite
- type: [string, "null"] # required by readme.com
pattern: ^null$
description: "Pass `null` to clear this field's existing value."
title: Clear
additionalProperties: false
Metadata
Metadata
Assignees
Labels
No labels