Set SSO record fields via API


(Roarke Lynch) #1

Is it possible to set a user’s SSO record fields (those included in the single_sign_on_record object from /admin/user/username) via the API?

Here is our scenario: We have a Discourse instance that uses Wordpress for SSO. It works great. But, when a user changes their avatar or email address in their Wordpress profile, that information is not synced back to Discourse until their next re-log.

I’d like to listen to the profile_update action (or something similar) in Wordpress and push changes to the external_email and external_avatar_url user fields in Discourse so these changes are immediately synced across both platforms.

Any ideas? Am I missing something?

(Steven Greco) #3

Take a look at this post under the integrations section. Is this what you are looking for?

(Roarke Lynch) #4

This is helpful! Using Discourse to host the avatars is an interesting approach.