get: summary: Returns a list of (optionally filtered) person relationships for a given person. description: Returns the list of (optionally filtered) person relationships of a given person and which are visible to the current user or any of it's assumed roles. tags: - hs-office-relationships operationId: listRelationships parameters: - $ref: './auth.yaml#/components/parameters/currentUser' - $ref: './auth.yaml#/components/parameters/assumedRoles' - name: personUuid in: query required: true schema: type: string format: uuid description: Prefix of name properties from relHolder or contact to filter the results. - name: relationshipType in: query required: false schema: $ref: './hs-office-relationship-schemas.yaml#/components/schemas/HsOfficeRelationshipType' description: Prefix of name properties from relHolder or contact to filter the results. responses: "200": description: OK content: 'application/json': schema: type: array items: $ref: './hs-office-relationship-schemas.yaml#/components/schemas/HsOfficeRelationship' "401": $ref: './error-responses.yaml#/components/responses/Unauthorized' "403": $ref: './error-responses.yaml#/components/responses/Forbidden' post: summary: Adds a new person relationship. tags: - hs-office-relationships operationId: addRelationship parameters: - $ref: './auth.yaml#/components/parameters/currentUser' - $ref: './auth.yaml#/components/parameters/assumedRoles' requestBody: content: 'application/json': schema: $ref: './hs-office-relationship-schemas.yaml#/components/schemas/HsOfficeRelationshipInsert' required: true responses: "201": description: Created content: 'application/json': schema: $ref: './hs-office-relationship-schemas.yaml#/components/schemas/HsOfficeRelationship' "401": $ref: './error-responses.yaml#/components/responses/Unauthorized' "403": $ref: './error-responses.yaml#/components/responses/Forbidden' "409": $ref: './error-responses.yaml#/components/responses/Conflict'