# Email field not populated on SSO User?

**URL:** <https://meta.discourse.org/t/email-field-not-populated-on-sso-user/97622>\
**Category:** SSO\
**Created:** [20 september 2018 om 07:19 UTC](https://meta.discourse.org/t/email-field-not-populated-on-sso-user/97622 "2018-09-20T07:19:10Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![Julian\_Elve](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/julian_elve/32/119540_2.png) [@Julian\_Elve](https://meta.discourse.org/u/Julian_Elve)\
**Post date:** [20 september 2018 om 07:19 UTC](https://meta.discourse.org/t/email-field-not-populated-on-sso-user/97622/1 "2018-09-20T07:19:10Z")

</div>

We are successfully creating Discourse users via SSO, using a custom endpoint on our IdentityServer3 IdP (using an approach extended from [this idea](https://blogg.blank.no/enabling-sso-for-discourse-with-identityserver3-7da2aca64bab))

We are passing in an email value in the SSO payload (I think it is mandatory, so implicit in the fact what we are doing works).

In the admin backend of Discourse, if I look on an individual user record the “Primary Email” field contains the email we passed in via SSO.

BUT, if I look at the user list at `/admin/users/list/active` the email column is empty for those users, and if I query via the API by `GET /admin/users/list/active.json` those records also have nothing in the email field.

Is this a bug, or have we missed something we should be doing?

**UPDATE**

The webhook events that are fired for `user_created` and `user_loggedin` contain a correctly-populated email field in the payload

**UPDATE 2**  
Querying via `GET /admin/users/{id}/{username}.json` shows the email in `[single_sign_on_record][external_email]`

---

_[View the full topic](https://meta.discourse.org/t/email-field-not-populated-on-sso-user/97622)._
