website/docs: update discord social login script example (cherry-pick #18026 to version-2025.10) (#18057)

website/docs: update discord social login script example (#18026)

update the guild membership example to no longer cause an exception from a missing import.

Closes #18025

Signed-off-by: TMUniversal <10200399+TMUniversal@users.noreply.github.com>
Co-authored-by: TMUniversal <10200399+TMUniversal@users.noreply.github.com>
This commit is contained in:
authentik-automation[bot]
2025-11-11 13:02:48 +01:00
committed by GitHub
parent fb56a54eb1
commit 7edebdec03
@@ -143,6 +143,8 @@ Ensure that the Discord OAuth source in **Federation & Social login** has the ad
4. Provide a name for the policy and set the following expression:
```python
from authentik.sources.oauth.models import OAuthSource
# To get the guild ID number for the parameters, open Discord, go to Settings > Advanced and enable developer mode.
# Right-click on the server/guild title and select "Copy ID" to get the guild ID.