database in service

This commit is contained in:
2021-01-15 12:53:46 +01:00
parent ceadf3338f
commit 24482da680
4 changed files with 97 additions and 21 deletions

View File

@ -37,6 +37,8 @@ paths:
$ref: '#/definitions/Hero'
404:
description: Hero not found
500:
description: Some server error
put:
operationId: heroes.put_hero
summary: Update a hero
@ -53,12 +55,14 @@ paths:
responses:
200:
description: Hero updated
402:
description: Duplicate name
403:
description: Some error
409:
description: Duplicate name
404:
description: Hero not found
500:
description: Some server error
/hero:
post:
operationId: heroes.post_hero
@ -74,6 +78,10 @@ paths:
description: Hero inserted
403:
description: Some error
409:
description: Duplicate name
500:
description: Some server error
/heroes:
get:
operationId: heroes.get_heroes
@ -87,6 +95,8 @@ paths:
$ref: '#/definitions/Hero'
404:
description: No heroes available
500:
description: Some server error
definitions: