Created
February 3, 2021 09:59
-
-
Save theletterf/cbc36c937bf1da986b0f19ec4159622d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Adapted from http://json.schemastore.org/json-patch | |
components: | |
schemas: | |
patchRequest: | |
type: array | |
items: | |
oneOf: | |
- additionalProperties: false | |
required: | |
- value | |
- op | |
- path | |
properties: | |
path: | |
description: A JSON Pointer path. | |
type: string | |
op: | |
description: The operation to perform. | |
type: string | |
enum: | |
- add | |
- replace | |
- test | |
value: | |
description: The value to add, replace or test. | |
- additionalProperties: false | |
required: | |
- op | |
- path | |
properties: | |
path: | |
description: A JSON Pointer path. | |
type: string | |
op: | |
description: The operation to perform. | |
type: string | |
enum: | |
- remove | |
- additionalProperties: false | |
required: | |
- from | |
- op | |
- path | |
properties: | |
path: | |
description: A JSON Pointer path. | |
type: string | |
op: | |
description: The operation to perform. | |
type: string | |
enum: | |
- move | |
- copy |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In the move/copy operation definition, there is a required field "from" which is not defined as a property.