async fn resolve_gated_upstream_id(
conn: &mut PgConnection,
introspecting_client: &OAuthClient,
token_user_id: Option<Uuid>,
) -> Option<i32>Expand description
Resolve the token owner’s legacy TMC upstream_id for the introspection
response — a privileged, non-standard claim consumed by tmc-server.
Only a caller that authenticated as a confidential client (its secret was verified before this point) receives it; for public clients the user lookup is skipped entirely. A lookup failure omits the claim rather than failing introspection.