Skip to content

Commit 45edf2f

Browse files
committed
add ClientMeta definition
A `oneOf` for a `client_meta` property is defined multiple times with the same values. Move the definition into `schemas` and share it.
1 parent 04e02c3 commit 45edf2f

1 file changed

Lines changed: 14 additions & 15 deletions

File tree

openapi/openapi.yaml

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -652,12 +652,8 @@ paths:
652652
comment. You cannot reply to other replies (a comment that
653653
has a parent_id).
654654
client_meta:
655+
$ref: "#/components/schemas/ClientMeta"
655656
description: The position where to place the comment.
656-
oneOf:
657-
- $ref: "#/components/schemas/Vector"
658-
- $ref: "#/components/schemas/FrameOffset"
659-
- $ref: "#/components/schemas/Region"
660-
- $ref: "#/components/schemas/FrameOffsetRegion"
661657
required:
662658
- message
663659
responses:
@@ -6394,16 +6390,8 @@ components:
63946390
type: string
63956391
description: Unique identifier for comment.
63966392
client_meta:
6397-
description: Positioning information of the comment. Includes information on the
6398-
location of the comment pin, which is either the absolute
6399-
coordinates on the canvas or a relative offset within a frame. If
6400-
the comment is a region, it will also contain the region height,
6401-
width, and position of the anchor in regards to the region.
6402-
oneOf:
6403-
- $ref: "#/components/schemas/Vector"
6404-
- $ref: "#/components/schemas/FrameOffset"
6405-
- $ref: "#/components/schemas/Region"
6406-
- $ref: "#/components/schemas/FrameOffsetRegion"
6393+
$ref: "#/components/schemas/ClientMeta"
6394+
description: The position of the comment.
64076395
file_key:
64086396
type: string
64096397
description: The file in which the comment lives
@@ -6446,6 +6434,17 @@ components:
64466434
- message
64476435
- reactions
64486436
- order_id
6437+
ClientMeta:
6438+
description: Positioning information of a comment. Includes information on the
6439+
location of the comment pin, which is either the absolute
6440+
coordinates on the canvas or a relative offset within a frame. If
6441+
the comment is a region, it will also contain the region height,
6442+
width, and position of the anchor in regards to the region.
6443+
oneOf:
6444+
- $ref: "#/components/schemas/Vector"
6445+
- $ref: "#/components/schemas/FrameOffset"
6446+
- $ref: "#/components/schemas/Region"
6447+
- $ref: "#/components/schemas/FrameOffsetRegion"
64496448
Reaction:
64506449
type: object
64516450
description: A reaction left by a user.

0 commit comments

Comments
 (0)