Skip to content

Commit

Permalink
feat(notifications): add global notification preferences
Browse files Browse the repository at this point in the history
  • Loading branch information
lpezzolla committed Feb 1, 2024
1 parent fa5b5db commit c058461
Showing 1 changed file with 80 additions and 0 deletions.
80 changes: 80 additions & 0 deletions openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2533,6 +2533,39 @@ paths:
isRead: false
500:
$ref: '#/components/responses/ErrorResponse'

/notifications/preferences:
get:
tags:
- Student
summary: Get notification preferences | Ottieni preferenze notifiche
operationId: getNotificationPreferences
responses:
200:
description: Success
content:
application/json:
schema:
$ref: '#/components/schemas/NotificationPreferences'
500:
$ref: '#/components/responses/ErrorResponse'
patch:
tags:
- Student
summary: Update notification preferences | Aggiorna preferenze notifiche
operationId: updateNotificationPreferences
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateNotificationPreferencesRequest'
responses:
200:
description: Success
500:
$ref: '#/components/responses/ErrorResponse'


/notifications/{notificationId}:
delete:
tags:
Expand Down Expand Up @@ -4914,6 +4947,53 @@ components:
enum: [ it, en ]
example: it

NotificationPreferences:
type: object
properties:
data:
type: object
properties:
notices:
type: boolean
example: true
files:
type: boolean
example: true
lectures:
type: boolean
example: true
bookings:
type: boolean
example: true
tickets:
type: boolean
example: true
required: [ notices, files, lectures, bookings, tickets]
required: [ data ]

UpdateNotificationPreferencesRequest:
type: object
properties:
data:
type: object
properties:
notices:
type: boolean
example: true
files:
type: boolean
example: true
lectures:
type: boolean
example: true
bookings:
type: boolean
example: true
tickets:
type: boolean
example: true
required: [ data ]

LoginRequest:
type: object
properties:
Expand Down

0 comments on commit c058461

Please sign in to comment.