Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

[#40397] added model for notification settings

Eric Schubertb83c9b97dd06
diff --git a/docs/api/apiv3/components/schemas/notification_settings_model.yml b/docs/api/apiv3/components/schemas/notification_settings_model.yml
new file mode 100644
index 00000000000..46882817af9
--- /dev/null
+++ b/docs/api/apiv3/components/schemas/notification_settings_model.yml
@@ -0,0 +1,71 @@
+# Schema: NotificationSettingModel
+---
+type: array
+description: The settings for the notifications to be received by the user
+items:
+ type: object
+ required:
+ - watched
+ - involved
+ - mentioned
+ - workPackageCreated
+ - workPackageCommented
+ - workPackageProcessed
+ - workPackagePrioritized
+ - workPackageScheduled
+ - newsAdded
+ - newsCommented
+ - documentAdded
+ - forumMessages
+ - wikiPageAdded
+ - wikiPageUpdated
+ - membershipAdded
+ - membershipUpdated
+ - _links
+ properties:
+ watched:
+ type: boolean
+ involved:
+ type: boolean
+ mentioned:
+ type: boolean
+ workPackageCreated:
+ type: boolean
+ workPackageCommented:
+ type: boolean
+ workPackageProcessed:
+ type: boolean
+ workPackagePrioritized:
+ type: boolean
+ workPackageScheduled:
+ type: boolean
+ newsAdded:
+ type: boolean
+ newsCommented:
+ type: boolean
+ documentAdded:
+ type: boolean
+ forumMessages:
+ type: boolean
+ wikiPageAdded:
+ type: boolean
+ wikiPageUpdated:
+ type: boolean
+ membershipAdded:
+ type: boolean
+ membershipUpdated:
+ type: boolean
+ _links:
+ type: object
+ required:
+ - project
+ properties:
+ project:
+ type: object
+ required:
+ - href
+ properties:
+ href:
+ type: string
+ format: uri
+
\ No newline at end of file
diff --git a/docs/api/apiv3/components/schemas/user_preference_model.yml b/docs/api/apiv3/components/schemas/user_preference_model.yml
index 704c0799fa8..31c201c4572 100644
--- a/docs/api/apiv3/components/schemas/user_preference_model.yml
+++ b/docs/api/apiv3/components/schemas/user_preference_model.yml
@@ -9,8 +9,7 @@ properties:
type: boolean
description: Hide mail address from other users
notifications:
- type: object
- description: The settings for the notifications to be received by the user
+ $ref: "./notification_settings_model.yml"
timeZone:
type: string
description: Current selected time zone
diff --git a/docs/api/apiv3/openapi-spec.yml b/docs/api/apiv3/openapi-spec.yml
index 60dab8e9fc4..ee53f8f3e68 100644
--- a/docs/api/apiv3/openapi-spec.yml
+++ b/docs/api/apiv3/openapi-spec.yml
@@ -569,6 +569,8 @@ components:
"$ref": "./components/schemas/news_model.yml"
NotificationModel:
"$ref": "./components/schemas/notification_model.yml"
+ NotificationSettingsModel:
+ "$ref": "./components/schemas/notification_settings_model.yml"
Offset_based_pagination:
"$ref": "./components/schemas/offset_based_pagination.yml"
Plain_Text:
@@ -754,50 +756,50 @@ components:
type: http
scheme: basic
tags:
-- "$ref": "./tags/basic_objects.yml"
-- "$ref": "./tags/collections.yml"
-- "$ref": "./tags/filters.yml"
-- "$ref": "./tags/forms.yml"
-- "$ref": "./tags/actions_and_capabilities.yml"
-- "$ref": "./tags/activities.yml"
-- "$ref": "./tags/attachments.yml"
-- "$ref": "./tags/budgets.yml"
-- "$ref": "./tags/categories.yml"
-- "$ref": "./tags/configuration.yml"
-- "$ref": "./tags/custom_actions.yml"
-- "$ref": "./tags/custom_objects.yml"
-- "$ref": "./tags/documents.yml"
-- "$ref": "./tags/grids.yml"
-- "$ref": "./tags/groups.yml"
-- "$ref": "./tags/help_texts.yml"
-- "$ref": "./tags/memberships.yml"
-- "$ref": "./tags/news.yml"
-- "$ref": "./tags/notifications.yml"
-- "$ref": "./tags/posts.yml"
-- "$ref": "./tags/principals.yml"
-- "$ref": "./tags/priorities.yml"
-- "$ref": "./tags/projects.yml"
-- "$ref": "./tags/queries.yml"
-- "$ref": "./tags/query_columns.yml"
-- "$ref": "./tags/query_filters.yml"
-- "$ref": "./tags/query_operators.yml"
-- "$ref": "./tags/query_sort_bys.yml"
-- "$ref": "./tags/query_filter_instance_schema.yml"
-- "$ref": "./tags/relations.yml"
-- "$ref": "./tags/previewing.yml"
-- "$ref": "./tags/revisions.yml"
-- "$ref": "./tags/roles.yml"
-- "$ref": "./tags/root.yml"
-- "$ref": "./tags/schemas.yml"
-- "$ref": "./tags/statuses.yml"
-- "$ref": "./tags/time_entries.yml"
-- "$ref": "./tags/time_entry_activities.yml"
-- "$ref": "./tags/types.yml"
-- "$ref": "./tags/userpreferences.yml"
-- "$ref": "./tags/users.yml"
-- "$ref": "./tags/versions.yml"
-- "$ref": "./tags/views.yml"
-- "$ref": "./tags/wiki_pages.yml"
-- "$ref": "./tags/work_packages.yml"
+ - "$ref": "./tags/basic_objects.yml"
+ - "$ref": "./tags/collections.yml"
+ - "$ref": "./tags/filters.yml"
+ - "$ref": "./tags/forms.yml"
+ - "$ref": "./tags/actions_and_capabilities.yml"
+ - "$ref": "./tags/activities.yml"
+ - "$ref": "./tags/attachments.yml"
+ - "$ref": "./tags/budgets.yml"
+ - "$ref": "./tags/categories.yml"
+ - "$ref": "./tags/configuration.yml"
+ - "$ref": "./tags/custom_actions.yml"
+ - "$ref": "./tags/custom_objects.yml"
+ - "$ref": "./tags/documents.yml"
+ - "$ref": "./tags/grids.yml"
+ - "$ref": "./tags/groups.yml"
+ - "$ref": "./tags/help_texts.yml"
+ - "$ref": "./tags/memberships.yml"
+ - "$ref": "./tags/news.yml"
+ - "$ref": "./tags/notifications.yml"
+ - "$ref": "./tags/posts.yml"
+ - "$ref": "./tags/principals.yml"
+ - "$ref": "./tags/priorities.yml"
+ - "$ref": "./tags/projects.yml"
+ - "$ref": "./tags/queries.yml"
+ - "$ref": "./tags/query_columns.yml"
+ - "$ref": "./tags/query_filters.yml"
+ - "$ref": "./tags/query_operators.yml"
+ - "$ref": "./tags/query_sort_bys.yml"
+ - "$ref": "./tags/query_filter_instance_schema.yml"
+ - "$ref": "./tags/relations.yml"
+ - "$ref": "./tags/previewing.yml"
+ - "$ref": "./tags/revisions.yml"
+ - "$ref": "./tags/roles.yml"
+ - "$ref": "./tags/root.yml"
+ - "$ref": "./tags/schemas.yml"
+ - "$ref": "./tags/statuses.yml"
+ - "$ref": "./tags/time_entries.yml"
+ - "$ref": "./tags/time_entry_activities.yml"
+ - "$ref": "./tags/types.yml"
+ - "$ref": "./tags/userpreferences.yml"
+ - "$ref": "./tags/users.yml"
+ - "$ref": "./tags/versions.yml"
+ - "$ref": "./tags/views.yml"
+ - "$ref": "./tags/wiki_pages.yml"
+ - "$ref": "./tags/work_packages.yml"
security:
-- BasicAuth: []
+ - BasicAuth: []