From 19eb1641eece9f03ca193417cdf244efc1a9da8a Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Sun, 27 May 2018 14:45:07 -0700 Subject: swagger spec: body -> entity --- rust/fatcat-api/api.yaml | 76 +++++++++++++++++++++++++++++------------------- 1 file changed, 46 insertions(+), 30 deletions(-) (limited to 'rust/fatcat-api/api.yaml') diff --git a/rust/fatcat-api/api.yaml b/rust/fatcat-api/api.yaml index 585932b3..f1b94234 100644 --- a/rust/fatcat-api/api.yaml +++ b/rust/fatcat-api/api.yaml @@ -38,29 +38,6 @@ x-entity-props: &ENTITYPROPS extra: type: object additionalProperties: {} -x-entity-edit-props: &ENTITYEDITPROPS - edit_id: - type: integer - example: 847 - format: int64 - ident: - type: string - example: "f1f046a3-45c9-4b99-adce-000000000001" - revision: - type: integer - example: 42 - format: int64 - redirect_ident: - type: string - example: "f1f046a3-45c9-4b99-adce-000000000002" - #format: uuid - editgroup_id: - type: integer - example: 16 - format: int64 - extra: - type: object - additionalProperties: {} definitions: @@ -196,7 +173,28 @@ definitions: - ident - editgroup_id properties: - <<: *ENTITYEDITPROPS + edit_id: + type: integer + example: 847 + format: int64 + ident: + type: string + example: "f1f046a3-45c9-4b99-adce-000000000001" + revision: + type: integer + example: 42 + format: int64 + redirect_ident: + type: string + example: "f1f046a3-45c9-4b99-adce-000000000002" + #format: uuid + editgroup_id: + type: integer + example: 16 + format: int64 + extra: + type: object + additionalProperties: {} editor: type: object required: @@ -305,7 +303,7 @@ paths: /creator: post: parameters: - - name: body + - name: entity in: body required: true schema: @@ -316,6 +314,24 @@ paths: schema: $ref: "#/definitions/entity_edit" <<: *ENTITYRESPONSES +# /creator/batch: +# post: +# parameters: +# - name: entity_list +# in: body +# required: true +# schema: +# type: array +# items: +# $ref: "#/definitions/creator_entity" +# responses: +# 201: +# description: Created Entities +# schema: +# type: array +# items: +# $ref: "#/definitions/entity_edit" +# <<: *ENTITYRESPONSES /creator/{id}: parameters: - name: id @@ -345,7 +361,7 @@ paths: /container: post: parameters: - - name: body + - name: entity in: body required: true schema: @@ -385,7 +401,7 @@ paths: /file: post: parameters: - - name: body + - name: entity in: body required: true schema: @@ -425,7 +441,7 @@ paths: /release: post: parameters: - - name: body + - name: entity in: body required: true schema: @@ -465,7 +481,7 @@ paths: /work: post: parameters: - - name: body + - name: entity in: body required: true schema: @@ -532,7 +548,7 @@ paths: /editgroup: post: parameters: - - name: body + - name: entity in: body required: true schema: -- cgit v1.2.3