#21927 [Feature]: Map Request Headers to LiteLLM User Email instead of ID. (e.g. OpenWebUI)
### Check for existing issues
- [x] I have searched the existing issues and checked that my issue is not a duplicate.
### The Feature
**Add option to map to other user properties beside user_id, by using `user_header_mappings`.**
- An External Tool, e.g. OpenWebUI needs to be able to map to a user, in order to track budget etc. - Users might already exist in LiteLLM. - User_ID differs between OpenWebUI and LiteLLM. - User_Email is the same and can be used for mapping. - User is able to see his own Requests done through OpenWebUI in his personal Usage/Logs (Currently only Admin sees)
### Motivation, pitch
### Context
We are hosting an OpenWebUI instance for our organization on Azure. We have SSO configured there, so users can simply sign in and a user is automatically created for them, with the correct email address.
We have setup a single Virtual Key, to be used by OpenWebUI, to minimize the configuration overhead for each individual user. But we do want per-user tracking of spend tokens. Therefore we are using LiteLLM to route the OpenWebUI Requests.
I followed the Tutorial here: https://docs.litellm.ai/docs/tutorials/openweb_ui
With setting the config on LiteLLM site …