> For the complete documentation index, see [llms.txt](https://api-docs.myhappyforce.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://api-docs.myhappyforce.com/docs/api-reference/notifications.md).

# Notifications

## POST /api/v1/employee/notifications/{employeeId}/viewed/{notificationId}

> Mark a notification as seen

```json
{"openapi":"3.1.0","info":{"title":"Happyforce API","version":"v1"},"tags":[],"servers":[{"url":"{url}","description":"API URL","variables":{"url":{"description":"API Environment","enum":["https://api.happyforce.com","https://staging.happyforce.com","http://localhost:9000"],"default":"https://api.happyforce.com"}}}],"security":[{"employeeAPISessionId":[]}],"components":{"securitySchemes":{},"schemas":{"EmployeeNotificationDTO":{"type":"object","description":"Employee notification: id, title, image, date, seen, target type, and target id.","properties":{"id":{"type":"string","description":"Notification identifier"},"title":{"type":"string","description":"Notification title"},"imagePath":{"type":"string","description":"URL or path to the notification image"},"date":{"type":"string","format":"date-time","description":"Date and time of the notification"},"seen":{"type":"boolean","description":"Whether the notification has been seen"},"targetType":{"$ref":"#/components/schemas/NotificationTargetType","description":"Type of target this notification refers to"},"targetId":{"type":"string","description":"ID of the target (comment, conversation, announcement, etc.)"}}},"NotificationTargetType":{"type":"string","description":"Type of target: COMMENT, CONVERSATION, ANNOUNCEMENT, QUESTION, SUGGESTION, PERSONAL_REPORT, NONE","enum":["COMMENT","CONVERSATION","ANNOUNCEMENT","QUESTION","SUGGESTION","PERSONAL_REPORT","NONE"]}}},"paths":{"/api/v1/employee/notifications/{employeeId}/viewed/{notificationId}":{"post":{"tags":["Notifications"],"description":"Mark a notification as seen","operationId":"updateViewedEmployeeNotification","parameters":[{"name":"notificationId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmployeeNotificationDTO"}}}}}}}}}
```

## POST /api/v1/employee/notifications/{employeeId}/count/reset

> Resets the number of new notifications

```json
{"openapi":"3.1.0","info":{"title":"Happyforce API","version":"v1"},"tags":[],"servers":[{"url":"{url}","description":"API URL","variables":{"url":{"description":"API Environment","enum":["https://api.happyforce.com","https://staging.happyforce.com","http://localhost:9000"],"default":"https://api.happyforce.com"}}}],"security":[{"employeeAPISessionId":[]}],"components":{"securitySchemes":{},"schemas":{"EmployeeNotificationCountDTO":{"type":"object","description":"Total count of notifications for the employee.","properties":{"count":{"type":"integer","format":"int32","description":"Number of notifications"}}}}},"paths":{"/api/v1/employee/notifications/{employeeId}/count/reset":{"post":{"tags":["Notifications"],"description":"Resets the number of new notifications","operationId":"resetNotificationsCount","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmployeeNotificationCountDTO"}}}}}}}}}
```

## GET /api/v1/employee/notifications/{employeeId}

> Lists all the notifications of the logged employee

```json
{"openapi":"3.1.0","info":{"title":"Happyforce API","version":"v1"},"tags":[],"servers":[{"url":"{url}","description":"API URL","variables":{"url":{"description":"API Environment","enum":["https://api.happyforce.com","https://staging.happyforce.com","http://localhost:9000"],"default":"https://api.happyforce.com"}}}],"security":[{"employeeAPISessionId":[]}],"components":{"securitySchemes":{},"schemas":{"PaginableGenericListResultEmployeeNotificationDTO":{"type":"object","properties":{"from":{"type":"integer","format":"int32"},"to":{"type":"integer","format":"int32"},"total":{"type":"integer","format":"int32"},"noContent":{"type":"boolean"},"results":{"type":"array","items":{"$ref":"#/components/schemas/EmployeeNotificationDTO"}}}},"EmployeeNotificationDTO":{"type":"object","description":"Employee notification: id, title, image, date, seen, target type, and target id.","properties":{"id":{"type":"string","description":"Notification identifier"},"title":{"type":"string","description":"Notification title"},"imagePath":{"type":"string","description":"URL or path to the notification image"},"date":{"type":"string","format":"date-time","description":"Date and time of the notification"},"seen":{"type":"boolean","description":"Whether the notification has been seen"},"targetType":{"$ref":"#/components/schemas/NotificationTargetType","description":"Type of target this notification refers to"},"targetId":{"type":"string","description":"ID of the target (comment, conversation, announcement, etc.)"}}},"NotificationTargetType":{"type":"string","description":"Type of target: COMMENT, CONVERSATION, ANNOUNCEMENT, QUESTION, SUGGESTION, PERSONAL_REPORT, NONE","enum":["COMMENT","CONVERSATION","ANNOUNCEMENT","QUESTION","SUGGESTION","PERSONAL_REPORT","NONE"]}}},"paths":{"/api/v1/employee/notifications/{employeeId}":{"get":{"tags":["Notifications"],"description":"Lists all the notifications of the logged employee","operationId":"getEmployeeNotifications","parameters":[{"name":"from","in":"query","required":false,"schema":{"type":"integer","format":"int32","default":0}},{"name":"to","in":"query","required":false,"schema":{"type":"integer","format":"int32","default":10}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginableGenericListResultEmployeeNotificationDTO"}}}}}}}}}
```

## GET /api/v1/employee/notifications/{employeeId}/count/new

> Get the number of new notifications since las visit

```json
{"openapi":"3.1.0","info":{"title":"Happyforce API","version":"v1"},"tags":[],"servers":[{"url":"{url}","description":"API URL","variables":{"url":{"description":"API Environment","enum":["https://api.happyforce.com","https://staging.happyforce.com","http://localhost:9000"],"default":"https://api.happyforce.com"}}}],"security":[{"employeeAPISessionId":[]}],"components":{"securitySchemes":{},"schemas":{"EmployeeNotificationCountDTO":{"type":"object","description":"Total count of notifications for the employee.","properties":{"count":{"type":"integer","format":"int32","description":"Number of notifications"}}}}},"paths":{"/api/v1/employee/notifications/{employeeId}/count/new":{"get":{"tags":["Notifications"],"description":"Get the number of new notifications since las visit","operationId":"getNewNotificationsCount","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmployeeNotificationCountDTO"}}}}}}}}}
```
