# Unsubscribing a user from all emails via an API call?

**URL:** <https://meta.discourse.org/t/unsubscribing-a-user-from-all-emails-via-an-api-call/133319>\
**Category:** Product Support\
**Created:** [13 november 2019 om 18:32 UTC](https://meta.discourse.org/t/unsubscribing-a-user-from-all-emails-via-an-api-call/133319 "2019-11-13T18:32:27Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![jezra](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jezra/32/105986_2.png) [@jezra](https://meta.discourse.org/u/jezra)\
**Post date:** [13 november 2019 om 18:32 UTC](https://meta.discourse.org/t/unsubscribing-a-user-from-all-emails-via-an-api-call/133319/1 "2019-11-13T18:32:27Z")

</div>

The site I maintain uses Discourse via SSO. When a user of my site unsubscribes from site generated emails, I would also like to unsubscribe the user from Discourse emails. It should be possible to determine what is required by looking at the API calls that are made when user email settings are changed via the UI, but I was wondering if there is an easier way?

---

_[View the full topic](https://meta.discourse.org/t/unsubscribing-a-user-from-all-emails-via-an-api-call/133319)._
