Skip to content

Commit

Permalink
fix: align upload API definition with implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
tpetillot committed Oct 29, 2024
1 parent 57bf8df commit c9b873c
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 1 deletion.
21 changes: 21 additions & 0 deletions openapi/src/main/openapi/pkgs/components.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -118,3 +118,24 @@ responses:
example: "424571fe-2351-4f3f-ae6a-04b7105f7157"
file:
$ref: "#/responses/PackageFile"

PackageUpload:
type: object
description: Package that have been uploaded
required:
- id
- filename
- contentLength
properties:
id:
type: string
description: Package ID
example: "0164293d-d15a-465f-8f40-41a2133fb35e"
filename:
type: string
description: Name of the uploaded file
example: "maven-sample-1.0.0-shaded.jar"
contentLength:
type: number
description: Content length of the uploaded file in bytes
example: "15000"
2 changes: 1 addition & 1 deletion openapi/src/main/openapi/pkgs/path.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ packages.upload:
content:
application/json:
schema:
$ref: 'components.yaml#/responses/Package'
$ref: 'components.yaml#/responses/PackageUpload'
'413':
description: Uploaded package is too large

Expand Down

0 comments on commit c9b873c

Please sign in to comment.