How to access case-sensitive username in backend API?

Are you using a custom database? What about leveraging a call to pull the details from the ID token instead of saving the entire token in a custom database?