Add description to ID token (#1234)

This commit is contained in:
Tobias Genannt
2025-05-16 17:19:10 +02:00
committed by GitHub
parent dcdf68b774
commit 2b36d50c59
2 changed files with 5 additions and 0 deletions

View File

@@ -92,6 +92,10 @@ pub struct StandardClaims {
#[serde(skip_serializing_if = "Option::is_none")]
#[serde(default)]
pub email: Option<String>,
#[serde(skip_serializing_if = "Option::is_none")]
#[serde(default)]
pub description: Option<String>,
}
impl Server {

View File

@@ -329,6 +329,7 @@ impl TokenHandler for Server {
nonce,
preferred_username: access_token.name.clone().into(),
email: access_token.emails.first().cloned(),
description: access_token.description.clone().into(),
},
) {
Ok(id_token) => Some(id_token),