-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathorders-endpoint.openapi.json
1 lines (1 loc) · 2.48 KB
/
orders-endpoint.openapi.json
1
{"openapi":"3.0.1","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://bravo-ch4mp:8080","description":"Generated server url"}],"paths":{"/orders/{id}":{"get":{"tags":["order-controller"],"operationId":"retrieveById","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"404":{"description":"Not Found"},"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderResponseDto"}},"application/xml":{"schema":{"$ref":"#/components/schemas/OrderResponseDto"}}}}}},"put":{"tags":["order-controller"],"operationId":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"long"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCreationRequestDto"}}},"required":true},"responses":{"404":{"description":"Not Found"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}},"application/xml":{"schema":{"type":"object"}}}}}},"delete":{"tags":["order-controller"],"operationId":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"long"}}],"responses":{"404":{"description":"Not Found"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}},"application/xml":{"schema":{"type":"object"}}}}}}},"/orders":{"get":{"tags":["order-controller"],"operationId":"retrieveAll","responses":{"404":{"description":"Not Found"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OrderResponseDto"}}},"application/xml":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OrderResponseDto"}}}}}}},"post":{"tags":["order-controller"],"operationId":"create","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCreationRequestDto"}}},"required":true},"responses":{"404":{"description":"Not Found"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}},"application/xml":{"schema":{"type":"object"}}}}}}}},"components":{"schemas":{"OrderCreationRequestDto":{"required":["drink"],"type":"object","properties":{"drink":{"type":"string"},"table":{"type":"string"}}},"OrderResponseDto":{"required":["createdOn","drink","id","owner"],"type":"object","properties":{"id":{"type":"integer","format":"int64"},"drink":{"type":"string"},"owner":{"type":"string"},"table":{"type":"string"},"createdOn":{"type":"integer","format":"int64"}}}}}}