2022-09-26 10:57:22 +02:00
get :
2024-03-13 15:01:24 +01:00
summary : Returns a list of (optionally filtered) person relations for a given person.
description : Returns the list of (optionally filtered) person relations of a given person and which are visible to the current user or any of it's assumed roles.
2022-09-26 10:57:22 +02:00
tags :
2024-03-13 15:01:24 +01:00
- hs-office-relations
operationId : listRelations
2022-09-26 10:57:22 +02:00
parameters :
- $ref : './auth.yaml#/components/parameters/currentUser'
- $ref : './auth.yaml#/components/parameters/assumedRoles'
- name : personUuid
in : query
required : true
schema :
type : string
format : uuid
2024-03-13 15:01:24 +01:00
description : Prefix of name properties from holder or contact to filter the results.
- name : relationType
2022-09-26 10:57:22 +02:00
in : query
required : false
schema :
2024-03-13 15:01:24 +01:00
$ref : './hs-office-relations-schemas.yaml#/components/schemas/HsOfficeRelationType'
description : Prefix of name properties from holder or contact to filter the results.
2022-09-26 10:57:22 +02:00
responses :
"200" :
description : OK
content :
'application/json' :
schema :
type : array
items :
2024-03-13 15:01:24 +01:00
$ref : './hs-office-relations-schemas.yaml#/components/schemas/HsOfficeRelation'
2022-09-26 10:57:22 +02:00
"401" :
$ref : './error-responses.yaml#/components/responses/Unauthorized'
"403" :
$ref : './error-responses.yaml#/components/responses/Forbidden'
post :
2024-03-13 15:01:24 +01:00
summary : Adds a new person relation.
2022-09-26 10:57:22 +02:00
tags :
2024-03-13 15:01:24 +01:00
- hs-office-relations
operationId : addRelation
2022-09-26 10:57:22 +02:00
parameters :
- $ref : './auth.yaml#/components/parameters/currentUser'
- $ref : './auth.yaml#/components/parameters/assumedRoles'
requestBody :
content :
'application/json' :
schema :
2024-03-13 15:01:24 +01:00
$ref : './hs-office-relations-schemas.yaml#/components/schemas/HsOfficeRelationInsert'
2022-09-26 10:57:22 +02:00
required : true
responses :
"201" :
description : Created
content :
'application/json' :
schema :
2024-03-13 15:01:24 +01:00
$ref : './hs-office-relations-schemas.yaml#/components/schemas/HsOfficeRelation'
2022-09-26 10:57:22 +02:00
"401" :
$ref : './error-responses.yaml#/components/responses/Unauthorized'
"403" :
$ref : './error-responses.yaml#/components/responses/Forbidden'
"409" :
$ref : './error-responses.yaml#/components/responses/Conflict'