更新 SSO 文档

I frequently refer to the Official Single-Sign-On post for SSO documentation. I just noticed, however, that the reference implementation has a few accessors that aren’t mentioned in that post (notably avatar_force_update, title, and groups). Would it be possible to update that post to include descriptions of these fields?

It is a wiki :slight_smile: feel free to give it a shot!

:open_mouth: no way! Here goes nothing!

That was easy enough. Thanks @sam!

I inspected discourse code base and added some notes about groups and the discourse option called sso overrides groups based on what I learned from that.

Perhaps someone could verify I got it right? Official Single-Sign-On for Discourse (sso)

Edit seems fine, thanks Erik.

我一直在努力解决这个实现问题,首先想感谢你们对 SSO 功能的文档记录!没有这些文档,我根本无法完成这项工作!

不过,我刚才用全新测试观察到的行为与文档描述并不完全一致。当指定了“SSO 覆盖组”选项时,add_groups 参数并不会添加列出的组,但 groups 参数却能正确定义组成员关系。

而当未指定“SSO 覆盖组”选项时,add_groups 可以正常工作,但 groups 参数却无法生效。

此外,我还发现以逗号分隔的组列表对逗号周围(至少是逗号后)的空格不兼容。据我回忆,如果存在空格,系统只会识别第一个组。

SSO 文档非常优秀,帮助我成功完成了 SSO 配置。然而,现在我需要在有效载荷中包含自定义字段数据,不幸的是,文档中(位于高级功能下)的链接指向了一个错误页面。如果有人能指引我正确的方向,我很乐意更新文档。

我在这页面上发现了一个线索((Retired) Use an ID in a custom user field to link to a user's external profile - #11 by techAPJ