2022-09-20 14:17:12 +02:00
|
|
|
get:
|
|
|
|
summary: Returns a list of (optionally filtered) contacts.
|
2024-09-16 15:36:37 +02:00
|
|
|
description: Returns the list of (optionally filtered) contacts which are visible to the current subject or any of it's assumed roles.
|
2022-09-20 14:17:12 +02:00
|
|
|
tags:
|
|
|
|
- hs-office-contacts
|
2024-12-03 16:17:04 +01:00
|
|
|
operationId: getListOfContacts
|
2022-09-20 14:17:12 +02:00
|
|
|
parameters:
|
2024-09-16 15:36:37 +02:00
|
|
|
- $ref: 'auth.yaml#/components/parameters/currentSubject'
|
2024-04-16 10:08:00 +02:00
|
|
|
- $ref: 'auth.yaml#/components/parameters/assumedRoles'
|
2022-09-20 14:17:12 +02:00
|
|
|
- name: name
|
|
|
|
in: query
|
|
|
|
required: false
|
|
|
|
schema:
|
|
|
|
type: string
|
2024-05-06 09:22:21 +02:00
|
|
|
description: Prefix of caption to filter the results.
|
2022-09-20 14:17:12 +02:00
|
|
|
responses:
|
|
|
|
"200":
|
|
|
|
description: OK
|
|
|
|
content:
|
|
|
|
'application/json':
|
|
|
|
schema:
|
|
|
|
type: array
|
|
|
|
items:
|
2024-04-16 10:08:00 +02:00
|
|
|
$ref: 'hs-office-contact-schemas.yaml#/components/schemas/HsOfficeContact'
|
2022-09-20 14:17:12 +02:00
|
|
|
"401":
|
2024-04-16 10:08:00 +02:00
|
|
|
$ref: 'error-responses.yaml#/components/responses/Unauthorized'
|
2022-09-20 14:17:12 +02:00
|
|
|
"403":
|
2024-04-16 10:08:00 +02:00
|
|
|
$ref: 'error-responses.yaml#/components/responses/Forbidden'
|
2022-09-20 14:17:12 +02:00
|
|
|
|
|
|
|
post:
|
|
|
|
summary: Adds a new contact.
|
|
|
|
tags:
|
|
|
|
- hs-office-contacts
|
2024-12-03 16:17:04 +01:00
|
|
|
operationId: postNewContact
|
2022-09-20 14:17:12 +02:00
|
|
|
parameters:
|
2024-09-16 15:36:37 +02:00
|
|
|
- $ref: 'auth.yaml#/components/parameters/currentSubject'
|
2024-04-16 10:08:00 +02:00
|
|
|
- $ref: 'auth.yaml#/components/parameters/assumedRoles'
|
2022-09-20 14:17:12 +02:00
|
|
|
requestBody:
|
|
|
|
content:
|
|
|
|
'application/json':
|
|
|
|
schema:
|
2024-04-16 10:08:00 +02:00
|
|
|
$ref: 'hs-office-contact-schemas.yaml#/components/schemas/HsOfficeContactInsert'
|
2022-09-20 14:17:12 +02:00
|
|
|
required: true
|
|
|
|
responses:
|
|
|
|
"201":
|
|
|
|
description: Created
|
|
|
|
content:
|
|
|
|
'application/json':
|
|
|
|
schema:
|
2024-04-16 10:08:00 +02:00
|
|
|
$ref: 'hs-office-contact-schemas.yaml#/components/schemas/HsOfficeContact'
|
2022-09-20 14:17:12 +02:00
|
|
|
"401":
|
2024-04-16 10:08:00 +02:00
|
|
|
$ref: 'error-responses.yaml#/components/responses/Unauthorized'
|
2022-09-20 14:17:12 +02:00
|
|
|
"403":
|
2024-04-16 10:08:00 +02:00
|
|
|
$ref: 'error-responses.yaml#/components/responses/Forbidden'
|
2022-09-20 14:17:12 +02:00
|
|
|
"409":
|
2024-04-16 10:08:00 +02:00
|
|
|
$ref: 'error-responses.yaml#/components/responses/Conflict'
|