# Mark notifications as read from Discourse API

**URL:** <https://meta.discourse.org/t/mark-notifications-as-read-from-discourse-api/113420>\
**Category:** Development\
**Created:** [04.Апрель.2019 07:13:31 UTC](https://meta.discourse.org/t/mark-notifications-as-read-from-discourse-api/113420 "2019-04-04T07:13:31Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![duranmla](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/duranmla/32/109295_2.png) [@duranmla](https://meta.discourse.org/u/duranmla)\
**Post date:** [06.Апрель.2019 17:36:43 UTC](https://meta.discourse.org/t/mark-notifications-as-read-from-discourse-api/113420/5 "2019-04-06T17:36:43Z")

</div>

In my very specific case the problem was related to the fact that I had one plugin in place that rewrite the `class Discourse::Cors` method `def self.apply_headers(cors_origins, env, headers)`, thus, I didn’t have the behaviour of the Discourse source code defined at [discourse/config/initializers/008-rack-cors.rb at main · discourse/discourse · GitHub](https://github.com/discourse/discourse/blob/master/config/initializers/008-rack-cors.rb#L44) but instead some custom thing that I don’t even need.

Once I remove the plugin I get back the core definition for CORS and everything works as expected.

---

_[View the full topic](https://meta.discourse.org/t/mark-notifications-as-read-from-discourse-api/113420)._
