## Whom I share my calendar with and who shares theirs with me (tenant:access)

`GET /api/hr/v1/calendar/shares`

Module: HR · operationId: `listCalendarShares` · Tag: Work entries · Auth: access token (`Authorization: Bearer <accessToken>`)

`sharedWith` are the colleagues the caller lets see their calendar, `sharedWithMe` the colleagues who share
theirs with the caller; oldest share first. A share only opens the calendar: what the viewer sees of each item
is decided per item. Without an employee record `403 no_employee`.

### Responses

- **200** The shares (`application/json`)
- **403** Error (`application/json`)

Fields of the 200 answer:

- `sharedWith` (array of PersonRef, required): The colleagues the caller shares their calendar with
  - `displayName` (string): Display name of the employee
  - `email` (string): E-mail address of the employee
  - `id` (string): Id of the employee
- `sharedWithMe` (array of PersonRef, required): The colleagues who share their calendar with the caller
  - `displayName` (string): Display name of the employee
  - `email` (string): E-mail address of the employee
  - `id` (string): Id of the employee

Example 200 answer:

```json
{
  "sharedWith": [
    {
      "displayName": "Elias Gruber",
      "email": "elias.gruber@muster-it.example",
      "id": "c7e9a1b3-5d7f-4b2c-8e4a-6f8b0d2c4e06"
    },
    {
      "displayName": "Martin Brandl",
      "email": "martin.brandl@muster-it.example",
      "id": "b2d4f6a8-0c1e-4a3b-9d5f-7e9a1c3b5d04"
    }
  ],
  "sharedWithMe": []
}
```

### Example request

```bash
curl -X GET 'https://api.mbcom.cloud/api/hr/v1/calendar/shares' \
  -H "Authorization: Bearer $ACCESS_TOKEN"
```
