PMT-32: Define Endpoint Specification
This commit is contained in:
parent
0e9525cde4
commit
b936136b53
1 changed files with 20 additions and 16 deletions
36
api/pmt.yml
36
api/pmt.yml
|
@ -14,20 +14,22 @@ components:
|
||||||
type: http
|
type: http
|
||||||
scheme: bearer
|
scheme: bearer
|
||||||
bearerFormat: JWT
|
bearerFormat: JWT
|
||||||
schemas:
|
schemas:
|
||||||
HelloOut:
|
ProjectInfo:
|
||||||
description: "A Test Schema"
|
|
||||||
type: object
|
type: object
|
||||||
properties:
|
properties:
|
||||||
msg:
|
id:
|
||||||
|
type: integer
|
||||||
|
format: int64
|
||||||
|
name:
|
||||||
type: string
|
type: string
|
||||||
|
GetAllProjectsDTO:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
$ref: "#/components/schemas/ProjectInfo"
|
||||||
responses:
|
responses:
|
||||||
OK:
|
UnAuthorized:
|
||||||
description: "OK"
|
description: "Un Authorized"
|
||||||
content:
|
|
||||||
text/plain:
|
|
||||||
schema:
|
|
||||||
type: string
|
|
||||||
InternalError:
|
InternalError:
|
||||||
description: "Internal Server Error"
|
description: "Internal Server Error"
|
||||||
content:
|
content:
|
||||||
|
@ -35,16 +37,18 @@ components:
|
||||||
schema:
|
schema:
|
||||||
type: string
|
type: string
|
||||||
paths:
|
paths:
|
||||||
/hello:
|
/project:
|
||||||
get:
|
get:
|
||||||
operationId: "GetHello"
|
operationId: "getAllProjects"
|
||||||
description: "A Simple Hello World Endpoint"
|
description: "Get a List of all Projects"
|
||||||
responses:
|
responses:
|
||||||
200:
|
200:
|
||||||
description: "A Hello Response"
|
description: ""
|
||||||
content:
|
content:
|
||||||
application/json:
|
application/json:
|
||||||
schema:
|
schema:
|
||||||
$ref: "#/components/schemas/HelloOut"
|
$ref: "#/components/schemas/GetAllProjectsDTO"
|
||||||
|
401:
|
||||||
|
$ref: "#/components/responses/UnAuthorized"
|
||||||
500:
|
500:
|
||||||
$ref: "#/components/responses/InternalError"
|
$ref: "#/components/responses/InternalError"
|
Loading…
Reference in a new issue