Co-authored-by: Michael Hoennig <michael@hoennig.de> Reviewed-on: https://dev.hostsharing.net/hostsharing/hs.hsadmin.ng/pulls/128 Reviewed-by: Timotheus Pokorra <timotheus.pokorra@hostsharing.net>
59 lines
2.2 KiB
YAML
59 lines
2.2 KiB
YAML
get:
|
|
summary: Returns a list of all booking projects for a specified debitor.
|
|
description: Returns the list of all booking projects for a specified debitor which are visible to the current subject or any of it's assumed roles.
|
|
tags:
|
|
- hs-booking-projects
|
|
operationId: getListOfBookingProjectsByDebitorUuid
|
|
parameters:
|
|
- $ref: 'auth.yaml#/components/parameters/currentSubject'
|
|
- $ref: 'auth.yaml#/components/parameters/assumedRoles'
|
|
- name: debitorUuid
|
|
in: query
|
|
required: true
|
|
schema:
|
|
type: string
|
|
format: uuid
|
|
description: The UUID of the debitor, whose booking projects are to be listed.
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
content:
|
|
'application/json':
|
|
schema:
|
|
type: array
|
|
items:
|
|
$ref: 'hs-booking-project-schemas.yaml#/components/schemas/HsBookingProject'
|
|
"401":
|
|
$ref: 'error-responses.yaml#/components/responses/Unauthorized'
|
|
"403":
|
|
$ref: 'error-responses.yaml#/components/responses/Forbidden'
|
|
|
|
post:
|
|
summary: Adds a new project as a container for booking items.
|
|
tags:
|
|
- hs-booking-projects
|
|
operationId: postNewBookingProject
|
|
parameters:
|
|
- $ref: 'auth.yaml#/components/parameters/currentSubject'
|
|
- $ref: 'auth.yaml#/components/parameters/assumedRoles'
|
|
requestBody:
|
|
description: A JSON object describing the new booking project.
|
|
required: true
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: 'hs-booking-project-schemas.yaml#/components/schemas/HsBookingProjectInsert'
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
content:
|
|
'application/json':
|
|
schema:
|
|
$ref: 'hs-booking-project-schemas.yaml#/components/schemas/HsBookingProject'
|
|
"401":
|
|
$ref: 'error-responses.yaml#/components/responses/Unauthorized'
|
|
"403":
|
|
$ref: 'error-responses.yaml#/components/responses/Forbidden'
|
|
"409":
|
|
$ref: 'error-responses.yaml#/components/responses/Conflict'
|